diff --git a/constants.js b/constants.js index e58a125..2b36ce4 100644 --- a/constants.js +++ b/constants.js @@ -211,6 +211,9 @@ const DEFAULT_PARAMETERS = { GRAPH_LOCATION: GRAPH_LOCATIONS.LOCAL_KG, GRAPH_STATE: GRAPH_STATES.CURRENT, HANDLE_NOT_MINED_ERROR: false, + SIMULATE_TXS: false, + FORCE_REPLACE_TXS: false, + GAS_LIMIT_MULTIPLIER: 1, }; const DEFAULT_GAS_PRICE = { diff --git a/dist/dkg.min.js b/dist/dkg.min.js index 21d1e6b..8a427a6 100644 --- a/dist/dkg.min.js +++ b/dist/dkg.min.js @@ -1,2 +1,2 @@ /*! For license information please see dkg.min.js.LICENSE.txt */ -var DKG;(()=>{var e={16381:e=>{const t={PUBLIC:"public",PRIVATE:"private",ALL:"all"},r={N_QUADS:"n-quads",JSON_LD:"json-ld"},n={LATEST:"LATEST",FINALIZED:"LATEST_FINALIZED"},i={PUBLIC_KG:"PUBLIC_KG",LOCAL_KG:"LOCAL_KG"},o={CURRENT:"CURRENT",HISTORICAL:"HISTORICAL"},a={ENVIRONMENT:"mainnet",PORT:8900,FREQUENCY:5,MAX_NUMBER_OF_RETRIES:5,HASH_FUNCTION_ID:1,IMMUTABLE:!1,VALIDATE:!0,OUTPUT_FORMAT:r.JSON_LD,STATE:n.LATEST,CONTENT_TYPE:t.PUBLIC,GRAPH_LOCATION:i.LOCAL_KG,GRAPH_STATE:o.CURRENT,HANDLE_NOT_MINED_ERROR:!1},s="high",u=["low","med",s,"all"];e.exports={MAX_FILE_SIZE:2621440,DID_PREFIX:"did:dkg",PRIVATE_ASSERTION_PREDICATE:"https://ontology.origintrail.io/dkg/1.0#privateAssertionID",ZERO_ADDRESS:"0x0000000000000000000000000000000000000000",BLOCKCHAINS:{development:{"hardhat1:31337":{rpc:"http://localhost:8545",hubContract:"0x5FbDB2315678afecb367f032d93F642f64180aa3"},"hardhat2:31337":{rpc:"http://localhost:9545",hubContract:"0x5FbDB2315678afecb367f032d93F642f64180aa3"},"otp:2043":{rpc:"http://parachain-alphanet-02.origin-trail.network:9933",hubContract:"0x7585a99C5C150a08f5CDeFD16465C6De8D41EbbD"}},devnet:{"otp:2160":{rpc:"https://lofar-tm-rpc.origin-trail.network",hubContract:"0x833048F6e6BEa78E0AAdedeCd2Dc2231dda443FB"},"gnosis:10200":{rpc:"https://rpc.chiadochain.net",hubContract:"0xD2bA102A0b11944d00180eE8136208ccF87bC39A",gasPriceOracleLink:"https://blockscout.chiadochain.net/api/v1/gas-price-oracle"},"base:84532":{hubContract:"0x6C861Cb69300C34DfeF674F7C00E734e840C29C0",rpc:"https://sepolia.base.org"}},testnet:{"otp:20430":{rpc:"https://lofar-testnet.origin-trail.network",hubContract:"0xBbfF7Ea6b2Addc1f38A0798329e12C08f03750A6"},"gnosis:10200":{rpc:"https://rpc.chiadochain.net",hubContract:"0xC06210312C9217A0EdF67453618F5eB96668679A",gasPriceOracleLink:"https://blockscout.chiadochain.net/api/v1/gas-price-oracle"},"base:84532":{hubContract:"0x144eDa5cbf8926327cb2cceef168A121F0E4A299",rpc:"https://sepolia.base.org"}},mainnet:{"otp:2043":{rpc:"https://astrosat-parachain-rpc.origin-trail.network",hubContract:"0x5fA7916c48Fe6D5F1738d12Ad234b78c90B4cAdA"},"gnosis:100":{rpc:"https://rpc.gnosischain.com/",hubContract:"0xbEF14fc04F870c2dD65c13Df4faB6ba01A9c746b",gasPriceOracleLink:"https://api.gnosisscan.io/api?module=proxy&action=eth_gasPrice"},"base:8453":{hubContract:"0xaBfcf2ad1718828E7D3ec20435b0d0b5EAfbDf2c",rpc:"https://mainnet.base.org"}}},BLOCKCHAINS_RENAME_PAIRS:{hardhat1:"hardhat1:31337",hardhat2:"hardhat2:31337","otp::devnet":"otp:2160","otp::testnet":"otp:20430","otp::mainnet":"otp:2043"},MAX_BLOCKCHAIN_CALL_RETRIES:3,TRANSACTION_RETRY_ERRORS:["transaction was not mined","already known","replacement transaction underpriced"],WEBSOCKET_PROVIDER_OPTIONS:{reconnect:{auto:!0,delay:1e3,maxAttempts:3},clientConfig:{keepalive:!0,keepaliveInterval:3e4}},OPERATIONS:{PUBLISH:"publish",GET:"get",UPDATE:"update",LOCAL_STORE:"local-store",QUERY:"query"},OPERATION_STATUSES:{PENDING:"PENDING",COMPLETED:"COMPLETED",FAILED:"FAILED"},ASSERTION_STATES:{LATEST:"latest",LATEST_FINALIZED:"latest_finalized"},CONTENT_TYPES:t,GET_OUTPUT_FORMATS:r,INCENTIVE_TYPE:{NEUROWEB:"Neuroweb"},ASSET_STATES:n,STORE_TYPES:{TRIPLE:"TRIPLE",PENDING:"PENDING"},GRAPH_LOCATIONS:i,GRAPH_STATES:o,OT_NODE_TRIPLE_STORE_REPOSITORIES:{PUBLIC_CURRENT:"publicCurrent",PUBLIC_HISTORY:"publicHistory",PRIVATE_CURRENT:"privateCurrent",PRIVATE_HISTORY:"privateHistory"},QUERY_TYPES:{CONSTRUCT:"CONSTRUCT",SELECT:"SELECT"},OPERATIONS_STEP_STATUS:{INCREASE_ALLOWANCE_COMPLETED:"INCREASE_ALLOWANCE_COMPLETED",CREATE_ASSET_COMPLETED:"CREATE_ASSET_COMPLETED",NETWORK_PUBLISH_COMPLETED:"NETWORK_PUBLISH_COMPLETED"},DEFAULT_GET_LOCAL_STORE_RESULT_FREQUENCY:.5,DEFAULT_PROXIMITY_SCORE_FUNCTIONS_PAIR_IDS:{development:{"hardhat1:31337":2,"hardhat2:31337":2,"otp:2043":2},devnet:{"otp:2160":2,"gnosis:10200":2,"base:84532":2},testnet:{"otp:20430":2,"gnosis:10200":2,"base:84532":2},mainnet:{"otp:2043":2,"gnosis:100":2,"base:8453":2}},DEFAULT_PARAMETERS:a,DEFAULT_GAS_PRICE:{GNOSIS:"20",OTP:"1"},LOW_BID_SUGGESTION:"low",MED_BID_SUGGESTION:"med",HIGH_BID_SUGGESTION:s,ALL_BID_SUGGESTION:"all",BID_SUGGESTION_RANGE_ENUM:u}},46010:(e,t,r)=>{const n=r(87128),i=r(65160),o=r(18538),a=r(2432),s=r(46792),u=r(83826),c=r(82689),l=r(76371);e.exports=class{constructor(e){const t=new l(e).getServices();this.assertion=new n(t),this.asset=new i(t),this.blockchain=new o(t),this.node=new u(t),this.graph=new a(t),this.network=new s(t),this.paranet=new c(t)}}},87128:(e,t,r)=>{const{assertionMetadata:n,calculateRoot:i,formatGraph:o}=r(50953);e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.inputService=e.inputService}async formatGraph(e){return o(e)}async getPublicAssertionId(e){const t=await o(e);return i(t.public)}async getSizeInBytes(e){const t=await o(e);return n.getAssertionSizeInBytes(t.public)}async getTriplesNumber(e){const t=await o(e);return n.getAssertionTriplesNumber(t.public)}async getChunksNumber(e){const t=await o(e);return n.getAssertionChunksNumber(t.public)}}},65160:(e,t,r)=>{const{assertionMetadata:n,calculateRoot:i,formatGraph:o}=r(50953),{ethers:a,ZeroHash:s}=r(59237),{deriveUAL:u,getOperationStatusObject:c,resolveUAL:l,toNQuads:f,toJSONLD:h,sleepForMilliseconds:d}=r(95200),{CONTENT_TYPES:p,OPERATIONS:m,OPERATIONS_STEP_STATUS:y,GET_OUTPUT_FORMATS:g,OPERATION_STATUSES:b,DEFAULT_GET_LOCAL_STORE_RESULT_FREQUENCY:v,PRIVATE_ASSERTION_PREDICATE:w,QUERY_TYPES:A,OT_NODE_TRIPLE_STORE_REPOSITORIES:S,ZERO_ADDRESS:k}=r(16381),E=r(54209),{STORE_TYPES:_,ASSET_STATES:M}=r(16381);e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.validationService=e.validationService,this.blockchainService=e.blockchainService,this.inputService=e.inputService}async isValidUAL(e,t={}){if("string"!=typeof e||""===e.trim())throw new Error("UAL must be a non-empty string.");const r=this.inputService.getBlockchain(t);this.validationService.validateIsValidUAL(r);const n=e.split("/");if(3!==n.length)throw new Error("UAL format is incorrect.");const i=n[0].split(":");if(3!==i.length&&4!==i.length)throw new Error("Prefix format in UAL is incorrect.");if("did"!==i[0])throw new Error(`Invalid DID prefix. Expected: 'did'. Received: '${i[0]}'.`);if("dkg"!==i[1])throw new Error(`Invalid DKG prefix. Expected: 'dkg'. Received: '${i[1]}'.`);if(i[2]!==r.name.split(":")[0])throw new Error(`Invalid blockchain name in the UAL prefix. Expected: '${r.name.split(":")[0]}'. Received: '${i[2]}'.`);if(4===i.length){const e=await this.blockchainService.getChainId(r);if(Number(i[3])!==e)throw new Error(`Chain ID in UAL does not match the blockchain. Expected: '${e}'. Received: '${i[3]}'.`)}const o=await this.blockchainService.getContractAddress("ContentAssetStorage",r);if(n[1].toLowerCase()!==o.toLowerCase())throw new Error(`Contract address in UAL does not match. Expected: '${o}'. Received: '${n[1]}'.`);try{const e=await this.blockchainService.getAssetOwner(n[2],r);if(!e||e===k)throw new Error("Token does not exist or has no owner.");return!0}catch(e){throw new Error(`Error fetching asset owner: ${e.message}`)}}async setAllowance(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateSetAllowance(r);const n=await this.blockchainService.getContractAddress("ServiceAgreementV1",r),i=e-BigInt(await this.blockchainService.callContractFunction("Token","allowance",[r.publicKey,n],r));let o;return i>0?o=await this.blockchainService.executeContractFunction("Token","increaseAllowance",[n,i],r):i<0&&(o=await this.blockchainService.executeContractFunction("Token","decreaseAllowance",[n,-i],r)),{transactionHash:o.transactionHash,status:o.status}}async increaseAllowance(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateIncreaseAllowance(r);const n=await this.blockchainService.getContractAddress("ServiceAgreementV1",r),i=await this.blockchainService.executeContractFunction("Token","increaseAllowance",[n,e],r);return{transactionHash:i.transactionHash,status:i.status}}async decreaseAllowance(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateDecreaseAllowance(r);const n=await this.blockchainService.getContractAddress("ServiceAgreementV1",r),i=await this.blockchainService.callContractFunction("Token","allowance",[r.publicKey,n],r),o=await this.blockchainService.executeContractFunction("Token","decreaseAllowance",[n,BigInt(e)>BigInt(i)?i:e],r);return{transactionHash:o.transactionHash,status:o.status}}async getCurrentAllowance(e={}){const t=this.inputService.getBlockchain(e),r=await this.blockchainService.getContractAddress("ServiceAgreementV1",t),n=await this.blockchainService.callContractFunction("Token","allowance",[t.publicKey,r],t);return BigInt(n)}async create(e,t={},r=E){this.validationService.validateObjectType(e);let a={};e.public||e.private?a=e:a.public=e;const{blockchain:s,endpoint:f,port:h,maxNumberOfRetries:d,frequency:p,epochsNum:g,hashFunctionId:w,scoreFunctionId:A,immutable:S,tokenAmount:k,authToken:M,paranetUAL:T}=this.inputService.getAssetCreateArguments(t);this.validationService.validateAssetCreate(a,s,f,h,d,p,g,w,A,S,k,M,T);const{public:x,private:P}=await o(a),I=n.getAssertionSizeInBytes(x);this.validationService.validateAssertionSizeInBytes(I+(void 0===P?0:n.getAssertionSizeInBytes(P)));const O=i(x),R=await this.blockchainService.getContractAddress("ContentAssetStorage",s),C=k??await this.nodeApiService.getBidSuggestion(f,h,M,s.name,g,I,R,O,w);let B;if(null==T)B=await this.blockchainService.createAsset({publicAssertionId:O,assertionSize:I,triplesNumber:n.getAssertionTriplesNumber(x),chunksNumber:n.getAssertionChunksNumber(x),epochsNum:g,tokenAmount:C,scoreFunctionId:A??1,immutable_:S},null,null,s,r);else{const{contract:e,tokenId:t}=l(T);B=await this.blockchainService.createAsset({publicAssertionId:O,assertionSize:I,triplesNumber:n.getAssertionTriplesNumber(x),chunksNumber:n.getAssertionChunksNumber(x),epochsNum:g,tokenAmount:C,scoreFunctionId:A??1,immutable_:S},e,t,s,r)}const N={blockchain:s.name,contract:R,tokenId:B},L=[{...N,assertionId:O,assertion:x,storeType:_.TRIPLE}];P?.length&&L.push({...N,assertionId:i(P),assertion:P,storeType:_.TRIPLE});const U=u(s.name,R,B);let F=await this.nodeApiService.publish(f,h,M,O,x,s.name,R,B,w),D=await this.nodeApiService.getOperationResult(f,h,M,m.PUBLISH,d,p,F);return D.status===b.FAILED?{UAL:U,assertionId:O,operation:c(D,F)}:(F=await this.nodeApiService.localStore(f,h,M,L),D=await this.nodeApiService.getOperationResult(f,h,M,m.LOCAL_STORE,d,v,F),r.afterHook({status:y.CREATE_ASSET_COMPLETED,data:{operationId:F,operationResult:D}}),{UAL:U,publicAssertionId:O,operation:c(D,F)})}async get(e,t={}){const{blockchain:r,endpoint:n,port:o,maxNumberOfRetries:a,frequency:u,state:d,contentType:y,validate:b,outputFormat:v,authToken:k,hashFunctionId:E}=this.inputService.getAssetGetArguments(t);this.validationService.validateAssetGet(e,r,n,o,a,u,d,y,E,b,v,k);const{tokenId:_}=l(e);let T,x=!1;if(d===M.LATEST){const e=await this.blockchainService.getUnfinalizedState(_,r);null!=e&&e!==s&&(T=e,x=!1)}let P=[];const I=Object.values(M).includes(d);if(!T)if(P=await this.blockchainService.getAssertionIds(_,r),I)T=P[P.length-1],x=!0;else if("number"==typeof d){if(d>=P.length)throw new Error("State index is out of range.");T=P[d],d===P.length-1&&(x=!0)}else if(P.includes(d))T=d,d===P[P.length-1]&&(x=!0);else{if(!/^0x[a-fA-F0-9]{64}$/.test(d))throw new Error("Incorrect state option.");{const e=await this.blockchainService.getUnfinalizedState(_,r);if(null==e||e===s||d!==e)throw new Error("Given state hash isn't a part of the Knowledge Asset.");T=e,x=!1}}const O=await this.nodeApiService.get(n,o,k,e,I?d:T,E),R=await this.nodeApiService.getOperationResult(n,o,k,m.GET,a,u,O);if(!R.data.assertion)return"FAILED"!==R.status&&(R.data={errorType:"DKG_CLIENT_ERROR",errorMessage:"Unable to find assertion on the network!"},R.status="FAILED"),{operation:{publicGet:c(R,O)}};const C=R.data.assertion;!0===b&&i(C)!==T&&(R.data={errorType:"DKG_CLIENT_ERROR",errorMessage:"Calculated root hashes don't match!"});let B={operation:{}};if(y!==p.PRIVATE){let e=C;try{e=v!==g.N_QUADS?await h(C.join("\n")):C.join("\n")}catch(e){R.data={errorType:"DKG_CLIENT_ERROR",errorMessage:e.message}}y===p.PUBLIC?B={...B,assertion:e,assertionId:T}:B.public={assertion:e,assertionId:T},B.operation.publicGet=c(R,O)}if(y!==p.PUBLIC){const e=C.filter((e=>e.includes(w)))[0];let t,r={};if(e){const s=e.match(/"(.*?)"/)[1];let l,d;if(R?.data?.privateAssertion?.length)l=R.data.privateAssertion;else{const e=`\n CONSTRUCT { ?s ?p ?o }\n WHERE {\n {\n GRAPH \n {\n ?s ?p ?o .\n }\n }\n }`;t=await this.nodeApiService.query(n,o,k,e,A.CONSTRUCT,x?S.PRIVATE_CURRENT:S.PRIVATE_HISTORY),r=await this.nodeApiService.getOperationResult(n,o,k,m.QUERY,a,u,t);const i=r.data;l=await f(i,"application/n-quads")}l.length&&!0===b&&i(l)!==s&&(r.data={errorType:"DKG_CLIENT_ERROR",errorMessage:"Calculated root hashes don't match!"});try{d=v!==g.N_QUADS?await h(l.join("\n")):l.join("\n")}catch(e){r.data={errorType:"DKG_CLIENT_ERROR",errorMessage:e.message}}y===p.PRIVATE?B={...B,assertion:d,assertionId:s}:B.private={assertion:d,assertionId:s},t&&(B.operation.queryPrivate=c(r,t))}}return B}async update(e,t,r={}){this.validationService.validateObjectType(t);const a=t,{blockchain:s,endpoint:u,port:f,maxNumberOfRetries:h,frequency:d,hashFunctionId:p,scoreFunctionId:y,tokenAmount:g,authToken:w}=this.inputService.getAssetUpdateArguments(r);this.validationService.validateAssetUpdate(a,s,u,f,h,d,p,y,g,w);const{tokenId:A}=l(e),{public:S,private:k}=await o(a),E=n.getAssertionSizeInBytes(S);this.validationService.validateAssertionSizeInBytes(E+(void 0===k?0:n.getAssertionSizeInBytes(k)));const M=i(S),T=await this.blockchainService.getContractAddress("ContentAssetStorage",s);let x;x=null!=g?g:await this._getUpdateBidSuggestion(e,s,u,f,w,M,E,p),await this.blockchainService.updateAsset(A,M,E,n.getAssertionTriplesNumber(S),n.getAssertionChunksNumber(S),x,s);const P={blockchain:s.name,contract:T,tokenId:A},I=[{...P,assertionId:M,assertion:S,storeType:_.PENDING}];k?.length&&I.push({...P,assertionId:i(k),assertion:k,storeType:_.PENDING});let O=await this.nodeApiService.localStore(u,f,w,I),R=await this.nodeApiService.getOperationResult(u,f,w,m.LOCAL_STORE,h,v,O);return R.status===b.FAILED?{UAL:e,assertionId:M,operation:c(R,O)}:(O=await this.nodeApiService.update(u,f,w,M,S,s.name,T,A,p),R=await this.nodeApiService.getOperationResult(u,f,w,m.UPDATE,h,d,O),{UAL:e,publicAssertionId:M,operation:c(R,O)})}async waitFinalization(e,t={}){const r=this.inputService.getBlockchain(t),n=this.inputService.getFrequency(t),i=this.inputService.getMaxNumberOfRetries(t);this.validationService.validateWaitAssetUpdateFinalization(e,r,n,i);const{tokenId:o}=l(e),a={status:b.PENDING};let s=!0,u=0;do{if(u>i){a.data={...a.data,data:{errorType:"DKG_CLIENT_ERROR",errorMessage:"Unable to get results. Max number of retries reached."}};break}u+=1,await d(1e3*n),s=await this.blockchainService.hasPendingUpdate(o,r)}while(s);return a.status=s?b.PENDING:b.COMPLETED,{UAL:e,operation:c({data:a.data,status:a.status},null)}}async cancelUpdate(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetUpdateCancel(e,r);const{tokenId:n}=l(e);return await this.blockchainService.cancelAssetUpdate(n,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async transfer(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateAssetTransfer(e,t,n);const{tokenId:i}=l(e);await this.blockchainService.transferAsset(i,t,n);return{UAL:e,owner:await this.blockchainService.getAssetOwner(i,n),operation:c({status:"COMPLETED"},null)}}async getOwner(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetGetOwner(e,r);const{tokenId:n}=l(e);return{UAL:e,owner:await this.blockchainService.getAssetOwner(n,r),operation:c({data:{},status:"COMPLETED"},null)}}async getStateIssuer(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateAssetGetStateIssuer(e,t,n);const{tokenId:i}=l(e),o=await this.blockchainService.getAssertionIdByIndex(i,t,n);return{UAL:e,issuer:await this.blockchainService.getAssertionIssuer(i,o,t,n),state:o,operation:c({data:{},status:"COMPLETED"},null)}}async getLatestStateIssuer(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetGetLatestStateIssuer(e,r);const{tokenId:n}=l(e),i=await this.blockchainService.getAssertionIds(n,r),o=i.length-1,a=i[o];return{UAL:e,issuer:await this.blockchainService.getAssertionIssuer(n,a,o,r),latestState:a,operation:c({data:{},status:"COMPLETED"},null)}}async getStates(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetGetStates(e,r);const{tokenId:n}=l(e);return{UAL:e,states:await this.blockchainService.getAssertionIds(n,r),operation:c({data:{},status:"COMPLETED"},null)}}async burn(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetBurn(e,r);const{tokenId:n}=l(e);return await this.blockchainService.burnAsset(n,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async extendStoringPeriod(e,t,r={}){const n=this.inputService.getBlockchain(r),i=this.inputService.getTokenAmount(r);this.validationService.validateExtendAssetStoringPeriod(e,t,i,n);const{tokenId:o,contract:a}=l(e);let s;if(null!=i)s=i;else{const e=this.inputService.getEndpoint(r),i=this.inputService.getPort(r),u=this.inputService.getAuthToken(r),c=this.inputService.getHashFunctionId(r),l=await this.blockchainService.getLatestAssertionId(o,n),f=await this.blockchainService.getAssertionSize(l,n);s=await this.nodeApiService.getBidSuggestion(e,i,u,n.name,t,f,a,l,c)}return await this.blockchainService.extendAssetStoringPeriod(o,t,s,n),{UAL:e,operation:c({status:"COMPLETED"},null)}}async addTokens(e,t={}){const r=this.inputService.getBlockchain(t),n=this.inputService.getTokenAmount(t);this.validationService.validateAddTokens(e,n,r);const{tokenId:i}=l(e);let o;if(null!=n)o=n;else{const n=this.inputService.getEndpoint(t),a=this.inputService.getPort(t),s=this.inputService.getAuthToken(t),u=this.inputService.getHashFunctionId(t),c=await this.blockchainService.getLatestAssertionId(i,r),l=await this.blockchainService.getAssertionSize(c,r);if(o=await this._getUpdateBidSuggestion(e,r,n,a,s,c,l,u),o<=0)throw new Error("Token amount is bigger than default suggested amount, please specify exact tokenAmount if you still want to add more tokens!")}return await this.blockchainService.addTokens(i,o,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async addUpdateTokens(e,t={}){const r=this.inputService.getBlockchain(t),n=this.inputService.getTokenAmount(t);this.validationService.validateAddTokens(e,n,r);const{tokenId:i}=l(e);let o;if(null!=n)o=n;else{const n=this.inputService.getEndpoint(t),a=this.inputService.getPort(t),s=this.inputService.getAuthToken(t),u=this.inputService.getHashFunctionId(t),c=await this.blockchainService.getUnfinalizedState(i,r),l=await this.blockchainService.getAssertionSize(c,r);if(o=await this._getUpdateBidSuggestion(e,r,n,a,s,c,l,u),o<=0)throw new Error("Token amount is bigger than default suggested amount, please specify exact tokenAmount if you still want to add more tokens!")}return await this.blockchainService.addUpdateTokens(i,o,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async _getUpdateBidSuggestion(e,t,r,n,i,o,s,u){const{contract:c,tokenId:f}=l(e),h=await this.blockchainService.getAssertionIdByIndex(f,0,t),d=a.solidityPacked(["address","bytes32"],[c,h]),p=a.sha256(a.solidityPacked(["address","uint256","bytes"],[c,f,d])),m=await this.blockchainService.getAgreementData(p,t),y=await this.blockchainService.getBlockchainTimestamp(t),g=Math.floor((y-m.startTime)/m.epochLength),b=m.epochsNumber-g,v=await this.nodeApiService.getBidSuggestion(r,n,i,t.name,b,s,c,o,u),w=BigInt(v)-(BigInt(m.tokenAmount)+BigInt(m.updateTokenAmount??0));return w>0?w:0}async submitToParanet(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateSubmitToParanet(e,t,n);const{contract:i,tokenId:o}=l(e),{contract:a,tokenId:s}=l(t);return await this.blockchainService.submitToParanet({paranetContract:a,paranetTokenId:s,contract:i,tokenId:o},n),{UAL:e,operation:c({status:"COMPLETED"},null)}}}},18538:e=>{e.exports=class{constructor(e){this.blockchainService=e.blockchainService,this.inputService=e.inputService}async getChainId(e={}){const t=this.inputService.getBlockchain(e);return this.blockchainService.getChainId(t)}async getGasPrice(e={}){const t=this.inputService.getBlockchain(e);return this.blockchainService.getGasPrice(t)}async getWalletBalances(e={}){const t=this.inputService.getBlockchain(e);return this.blockchainService.getWalletBalances(t)}}},2432:(e,t,r)=>{const{OPERATIONS:n}=r(16381),{deriveRepository:i}=r(95200);e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.validationService=e.validationService,this.inputService=e.inputService}async query(e,t,r={}){const{graphLocation:o,graphState:a,endpoint:s,port:u,maxNumberOfRetries:c,frequency:l,authToken:f}=this.inputService.getQueryArguments(r);this.validationService.validateGraphQuery(e,t,o,a,s,u,c,l,f);const h=i(o,a),d=await this.nodeApiService.query(s,u,f,e,t,h);return this.nodeApiService.getOperationResult(s,u,f,n.QUERY,c,l,d)}}},46792:e=>{e.exports=class{constructor(e){this.inputService=e.inputService,this.blockchainService=e.blockchainService,this.nodeApiService=e.nodeApiService}async getBidSuggestion(e,t,r={}){const{blockchain:n,endpoint:i,port:o,epochsNum:a,hashFunctionId:s,authToken:u,bidSuggestionRange:c}=this.inputService.getBidSuggestionArguments(r),l=await this.blockchainService.getContractAddress("ContentAssetStorage",n),f=await this.nodeApiService.getBidSuggestion(i,o,u,n.name,a,t,l,e,s,c);return"string"==typeof f?BigInt(f):f}}},83826:e=>{e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.inputService=e.inputService}async info(e={}){const t=this.inputService.getEndpoint(e),r=this.inputService.getPort(e),n=this.inputService.getAuthToken(e);return(await this.nodeApiService.info(t,r,n)).data}}},82689:(e,t,r)=>{const{ethers:n}=r(59237),{resolveUAL:i}=r(95200),{INCENTIVE_TYPE:o}=r(16381);e.exports=class{constructor(e){this.blockchainService=e.blockchainService,this.inputService=e.inputService,this.nodeApiService=e.nodeApiService,this.validationService=e.validationService}async create(e,t={}){const{blockchain:r,paranetName:n,paranetDescription:o}=this.inputService.getParanetCreateArguments(t);this.validationService.validateParanetCreate(e,r,n,o);const{contract:a,tokenId:s}=i(e);return await this.blockchainService.registerParanet({contract:a,tokenId:s,paranetName:n,paranetDescription:o},r),{paranetUAL:e}}async deployIncentivesContract(e,t,r={}){const{blockchain:a,tracToNeuroEmissionMultiplier:s,operatorRewardPercentage:u,incentivizationProposalVotersRewardPercentage:c}=this.inputService.getParanetDeployIncentivesContractArguments(r);if(this.validationService.validateDeployIncentivesContract(e,a,s,u,c),t===o.NEUROWEB){const{contract:t,tokenId:r}=i(e);await this.blockchainService.deployNeuroIncentivesPool({contract:t,tokenId:r,tracToNeuroEmissionMultiplier:s,operatorRewardPercentage:u,incentivizationProposalVotersRewardPercentage:c},a);const o=n.keccak256(n.solidityPacked(["address","uint256"],[t,r]));return{paranetUAL:e,incentivesPoolContractAddress:await this.blockchainService.getNeuroIncentivesPoolAddress(o,a)}}throw Error(`Unsupported incentive type: ${t}.`)}async createService(e,t={}){const{blockchain:r,paranetServiceName:n,paranetServiceDescription:o,paranetServiceAddresses:a}=this.inputService.getParanetCreateServiceArguments(t);this.validationService.validateParanetCreateServiceArguments(e,n,o,a,r);const{contract:s,tokenId:u}=i(e);return await this.blockchainService.registerParanetService({contract:s,tokenId:u,paranetServiceName:n,paranetServiceDescription:o,paranetServiceAddresses:a},r),{serviceUAL:e}}async addServices(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateParanetAddServicesArguments(e,t,n);const{contract:o,tokenId:a}=i(e),s=[];for(const e of t){const{contract:t,tokenId:r}=i(e);s.push([t,r])}return await this.blockchainService.addParanetServices({contract:o,tokenId:a,processedServicesArray:s},n),{paranetUAL:e,paranetServiceUALs:t}}async claimMinerReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.claimKnowledgeMinerReward(s,r);return{transactionHash:u.transactionHash,status:u.status}}async claimVoterReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.claimVoterReward(s,r);return{transactionHash:u.transactionHash,status:u.status}}async claimOperatorReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.claimOperatorReward(s,r);return{transactionHash:u.transactionHash,status:u.status}}async getClaimableMinerReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableKnowledgeMinerReward(s,r)}async getClaimableAllMinersReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableAllKnowledgeMinersReward(s,r)}async getClaimableVoterReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableVoterReward(s,r)}async getClaimableAllVotersReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableAllVotersReward(s,r)}async getClaimableOperatorReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableOperatorReward(s,r)}async updateClaimableRewards(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.getUpdatingKnowledgeAssetStates({miner:r.publicKey,paranetId:s},r);if(u.length>0){const e=await this.blockchainService.updateClaimableRewards({contract:o,tokenId:a,start:0,end:u.length},r);return{transactionHash:e.transactionHash,status:e.status}}return{status:"No updated knowledge assets."}}async isKnowledgeMiner(e,t={}){let{blockchain:r,roleAddress:o}=this.inputService.getParanetRoleCheckArguments(t);null==o&&(o=r.publicKey),this.validationService.validateParanetRoleCheckArguments(o,e,r);const{contract:a,tokenId:s}=i(e),u=n.keccak256(n.solidityPacked(["address","uint256"],[a,s]));return await this.blockchainService.isParanetKnowledgeMiner(o,u,r)}async isParanetOperator(e,t={}){let{blockchain:r,roleAddress:o}=this.inputService.getParanetRoleCheckArguments(t);null==o&&(o=r.publicKey),this.validationService.validateParanetRoleCheckArguments(o,e,r);const{contract:a,tokenId:s}=i(e),u=n.keccak256(n.solidityPacked(["address","uint256"],[a,s]));return await this.blockchainService.isParanetOperator(o,u,r)}async isProposalVoter(e,t={}){let{blockchain:r,roleAddress:o}=this.inputService.getParanetRoleCheckArguments(t);null==o&&(o=r.publicKey),this.validationService.validateParanetRoleCheckArguments(o,e,r);const{contract:a,tokenId:s}=i(e),u=n.keccak256(n.solidityPacked(["address","uint256"],[a,s]));return await this.blockchainService.isParanetProposalVoter(o,u,r)}}},48709:function(e){"use strict";!function(t){function r(e){return parseInt(e)===e}function n(e){if(!r(e.length))return!1;for(var t=0;t255)return!1;return!0}function i(e,t){if(e.buffer&&ArrayBuffer.isView(e)&&"Uint8Array"===e.name)return t&&(e=e.slice?e.slice():Array.prototype.slice.call(e)),e;if(Array.isArray(e)){if(!n(e))throw new Error("Array contains invalid value: "+e);return new Uint8Array(e)}if(r(e.length)&&n(e))return new Uint8Array(e);throw new Error("unsupported array-like object")}function o(e){return new Uint8Array(e)}function a(e,t,r,n,i){null==n&&null==i||(e=e.slice?e.slice(n,i):Array.prototype.slice.call(e,n,i)),t.set(e,r)}var s,u={toBytes:function(e){var t=[],r=0;for(e=encodeURI(e);r191&&n<224?(t.push(String.fromCharCode((31&n)<<6|63&e[r+1])),r+=2):(t.push(String.fromCharCode((15&n)<<12|(63&e[r+1])<<6|63&e[r+2])),r+=3)}return t.join("")}},c=(s="0123456789abcdef",{toBytes:function(e){for(var t=[],r=0;r>4]+s[15&n])}return t.join("")}}),l={16:10,24:12,32:14},f=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],h=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],d=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],p=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],m=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],y=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],g=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],b=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],v=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],w=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],A=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],S=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],k=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],E=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],_=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function M(e){for(var t=[],r=0;r>2,this._Ke[r][t%4]=o[t],this._Kd[e-r][t%4]=o[t];for(var a,s=0,u=i;u>16&255]<<24^h[a>>8&255]<<16^h[255&a]<<8^h[a>>24&255]^f[s]<<24,s+=1,8!=i)for(t=1;t>8&255]<<8^h[a>>16&255]<<16^h[a>>24&255]<<24;for(t=i/2+1;t>2,d=u%4,this._Ke[c][d]=o[t],this._Kd[e-c][d]=o[t++],u++}for(var c=1;c>24&255]^k[a>>16&255]^E[a>>8&255]^_[255&a]},T.prototype.encrypt=function(e){if(16!=e.length)throw new Error("invalid plaintext size (must be 16 bytes)");for(var t=this._Ke.length-1,r=[0,0,0,0],n=M(e),i=0;i<4;i++)n[i]^=this._Ke[0][i];for(var a=1;a>24&255]^m[n[(i+1)%4]>>16&255]^y[n[(i+2)%4]>>8&255]^g[255&n[(i+3)%4]]^this._Ke[a][i];n=r.slice()}var s,u=o(16);for(i=0;i<4;i++)s=this._Ke[t][i],u[4*i]=255&(h[n[i]>>24&255]^s>>24),u[4*i+1]=255&(h[n[(i+1)%4]>>16&255]^s>>16),u[4*i+2]=255&(h[n[(i+2)%4]>>8&255]^s>>8),u[4*i+3]=255&(h[255&n[(i+3)%4]]^s);return u},T.prototype.decrypt=function(e){if(16!=e.length)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var t=this._Kd.length-1,r=[0,0,0,0],n=M(e),i=0;i<4;i++)n[i]^=this._Kd[0][i];for(var a=1;a>24&255]^v[n[(i+3)%4]>>16&255]^w[n[(i+2)%4]>>8&255]^A[255&n[(i+1)%4]]^this._Kd[a][i];n=r.slice()}var s,u=o(16);for(i=0;i<4;i++)s=this._Kd[t][i],u[4*i]=255&(d[n[i]>>24&255]^s>>24),u[4*i+1]=255&(d[n[(i+3)%4]>>16&255]^s>>16),u[4*i+2]=255&(d[n[(i+2)%4]>>8&255]^s>>8),u[4*i+3]=255&(d[255&n[(i+1)%4]]^s);return u};var x=function(e){if(!(this instanceof x))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new T(e)};x.prototype.encrypt=function(e){if((e=i(e)).length%16!=0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var t=o(e.length),r=o(16),n=0;n=0;--t)this._counter[t]=e%256,e>>=8},R.prototype.setBytes=function(e){if(16!=(e=i(e,!0)).length)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=e},R.prototype.increment=function(){for(var e=15;e>=0;e--){if(255!==this._counter[e]){this._counter[e]++;break}this._counter[e]=0}};var C=function(e,t){if(!(this instanceof C))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",t instanceof R||(t=new R(t)),this._counter=t,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new T(e)};C.prototype.encrypt=function(e){for(var t=i(e,!0),r=0;r16)throw new Error("PKCS#7 padding byte out of range");for(var r=e.length-t,n=0;n{"use strict";function r(e){if(!Number.isSafeInteger(e)||e<0)throw new Error(`Wrong positive integer: ${e}`)}function n(e){if("boolean"!=typeof e)throw new Error(`Expected boolean, not ${e}`)}function i(e,...t){if(!(e instanceof Uint8Array))throw new TypeError("Expected Uint8Array");if(t.length>0&&!t.includes(e.length))throw new TypeError(`Expected Uint8Array of length ${t}, not of length=${e.length}`)}function o(e){if("function"!=typeof e||"function"!=typeof e.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");r(e.outputLen),r(e.blockLen)}function a(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function s(e,t){i(e);const r=t.outputLen;if(e.length{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SHA2=void 0;const n=r(27320),i=r(98089);class o extends i.Hash{constructor(e,t,r,n){super(),this.blockLen=e,this.outputLen=t,this.padOffset=r,this.isLE=n,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(e),this.view=(0,i.createView)(this.buffer)}update(e){n.default.exists(this);const{view:t,buffer:r,blockLen:o}=this,a=(e=(0,i.toBytes)(e)).length;for(let n=0;no-s&&(this.process(r,0),s=0);for(let e=s;e>i&o),s=Number(r&o),u=n?4:0,c=n?0:4;e.setUint32(t+u,a,n),e.setUint32(t+c,s,n)}(r,o-8,BigInt(8*this.length),a),this.process(r,0);const u=(0,i.createView)(e);this.get().forEach(((e,t)=>u.setUint32(4*t,e,a)))}digest(){const{buffer:e,outputLen:t}=this;this.digestInto(e);const r=e.slice(0,t);return this.destroy(),r}_cloneInto(e){e||(e=new this.constructor),e.set(...this.get());const{blockLen:t,buffer:r,length:n,finished:i,destroyed:o,pos:a}=this;return e.length=n,e.pos=a,e.finished=i,e.destroyed=o,n%t&&e.buffer.set(r),e}}t.SHA2=o},6873:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.add=t.toBig=t.split=t.fromBig=void 0;const r=BigInt(2**32-1),n=BigInt(32);function i(e,t=!1){return t?{h:Number(e&r),l:Number(e>>n&r)}:{h:0|Number(e>>n&r),l:0|Number(e&r)}}function o(e,t=!1){let r=new Uint32Array(e.length),n=new Uint32Array(e.length);for(let o=0;oBigInt(e>>>0)<>>0);function a(e,t,r,n){const i=(t>>>0)+(n>>>0);return{h:e+r+(i/2**32|0)|0,l:0|i}}t.add=a;const s={fromBig:i,split:o,toBig:t.toBig,shrSH:(e,t,r)=>e>>>r,shrSL:(e,t,r)=>e<<32-r|t>>>r,rotrSH:(e,t,r)=>e>>>r|t<<32-r,rotrSL:(e,t,r)=>e<<32-r|t>>>r,rotrBH:(e,t,r)=>e<<64-r|t>>>r-32,rotrBL:(e,t,r)=>e>>>r-32|t<<64-r,rotr32H:(e,t)=>t,rotr32L:(e,t)=>e,rotlSH:(e,t,r)=>e<>>32-r,rotlSL:(e,t,r)=>t<>>32-r,rotlBH:(e,t,r)=>t<>>64-r,rotlBL:(e,t,r)=>e<>>64-r,add:a,add3L:(e,t,r)=>(e>>>0)+(t>>>0)+(r>>>0),add3H:(e,t,r,n)=>t+r+n+(e/2**32|0)|0,add4L:(e,t,r,n)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0),add4H:(e,t,r,n,i)=>t+r+n+i+(e/2**32|0)|0,add5H:(e,t,r,n,i,o)=>t+r+n+i+o+(e/2**32|0)|0,add5L:(e,t,r,n,i)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0)+(i>>>0)};t.default=s},64421:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.crypto=void 0,t.crypto={node:void 0,web:"object"==typeof self&&"crypto"in self?self.crypto:void 0}},79569:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hmac=void 0;const n=r(27320),i=r(98089);class o extends i.Hash{constructor(e,t){super(),this.finished=!1,this.destroyed=!1,n.default.hash(e);const r=(0,i.toBytes)(t);if(this.iHash=e.create(),!(this.iHash instanceof i.Hash))throw new TypeError("Expected instance of class which extends utils.Hash");const o=this.blockLen=this.iHash.blockLen;this.outputLen=this.iHash.outputLen;const a=new Uint8Array(o);a.set(r.length>this.iHash.blockLen?e.create().update(r).digest():r);for(let e=0;enew o(e,t).update(r).digest(),t.hmac.create=(e,t)=>new o(e,t)},29023:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pbkdf2Async=t.pbkdf2=void 0;const n=r(27320),i=r(79569),o=r(98089);function a(e,t,r,a){n.default.hash(e);const s=(0,o.checkOpts)({dkLen:32,asyncTick:10},a),{c:u,dkLen:c,asyncTick:l}=s;if(n.default.number(u),n.default.number(c),n.default.number(l),u<1)throw new Error("PBKDF2: iterations (c) should be >= 1");const f=(0,o.toBytes)(t),h=(0,o.toBytes)(r),d=new Uint8Array(c),p=i.hmac.create(e,f),m=p._cloneInto().update(h);return{c:u,dkLen:c,asyncTick:l,DK:d,PRF:p,PRFSalt:m}}function s(e,t,r,n,i){return e.destroy(),t.destroy(),n&&n.destroy(),i.fill(0),r}t.pbkdf2=function(e,t,r,n){const{c:i,dkLen:u,DK:c,PRF:l,PRFSalt:f}=a(e,t,r,n);let h;const d=new Uint8Array(4),p=(0,o.createView)(d),m=new Uint8Array(l.outputLen);for(let e=1,t=0;t{f._cloneInto(d).update(y).digestInto(y);for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ripemd160=t.RIPEMD160=void 0;const n=r(27505),i=r(98089),o=new Uint8Array([7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8]),a=Uint8Array.from({length:16},((e,t)=>t)),s=a.map((e=>(9*e+5)%16));let u=[a],c=[s];for(let e=0;e<4;e++)for(let t of[u,c])t.push(t[e].map((e=>o[e])));const l=[[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8],[12,13,11,15,6,9,9,7,12,15,11,13,7,8,7,7],[13,15,14,11,7,7,6,8,13,14,13,12,5,5,6,9],[14,11,12,14,8,6,5,5,15,12,15,14,9,9,8,6],[15,12,13,13,9,5,8,6,14,11,12,11,8,6,5,5]].map((e=>new Uint8Array(e))),f=u.map(((e,t)=>e.map((e=>l[t][e])))),h=c.map(((e,t)=>e.map((e=>l[t][e])))),d=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),p=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),m=(e,t)=>e<>>32-t;function y(e,t,r,n){return 0===e?t^r^n:1===e?t&r|~t&n:2===e?(t|~r)^n:3===e?t&n|r&~n:t^(r|~n)}const g=new Uint32Array(16);class b extends n.SHA2{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){const{h0:e,h1:t,h2:r,h3:n,h4:i}=this;return[e,t,r,n,i]}set(e,t,r,n,i){this.h0=0|e,this.h1=0|t,this.h2=0|r,this.h3=0|n,this.h4=0|i}process(e,t){for(let r=0;r<16;r++,t+=4)g[r]=e.getUint32(t,!0);let r=0|this.h0,n=r,i=0|this.h1,o=i,a=0|this.h2,s=a,l=0|this.h3,b=l,v=0|this.h4,w=v;for(let e=0;e<5;e++){const t=4-e,A=d[e],S=p[e],k=u[e],E=c[e],_=f[e],M=h[e];for(let t=0;t<16;t++){const n=m(r+y(e,i,a,l)+g[k[t]]+A,_[t])+v|0;r=v,v=l,l=0|m(a,10),a=i,i=n}for(let e=0;e<16;e++){const r=m(n+y(t,o,s,b)+g[E[e]]+S,M[e])+w|0;n=w,w=b,b=0|m(s,10),s=o,o=r}}this.set(this.h1+a+b|0,this.h2+l+w|0,this.h3+v+n|0,this.h4+r+o|0,this.h0+i+s|0)}roundClean(){g.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}}t.RIPEMD160=b,t.ripemd160=(0,i.wrapConstructor)((()=>new b))},69514:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.scryptAsync=t.scrypt=void 0;const n=r(27320),i=r(23061),o=r(29023),a=r(98089),s=(e,t)=>e<>>32-t;function u(e,t,r,n,i,o){let a=e[t++]^r[n++],u=e[t++]^r[n++],c=e[t++]^r[n++],l=e[t++]^r[n++],f=e[t++]^r[n++],h=e[t++]^r[n++],d=e[t++]^r[n++],p=e[t++]^r[n++],m=e[t++]^r[n++],y=e[t++]^r[n++],g=e[t++]^r[n++],b=e[t++]^r[n++],v=e[t++]^r[n++],w=e[t++]^r[n++],A=e[t++]^r[n++],S=e[t++]^r[n++],k=a,E=u,_=c,M=l,T=f,x=h,P=d,I=p,O=m,R=y,C=g,B=b,N=v,L=w,U=A,F=S;for(let e=0;e<8;e+=2)T^=s(k+N|0,7),O^=s(T+k|0,9),N^=s(O+T|0,13),k^=s(N+O|0,18),R^=s(x+E|0,7),L^=s(R+x|0,9),E^=s(L+R|0,13),x^=s(E+L|0,18),U^=s(C+P|0,7),_^=s(U+C|0,9),P^=s(_+U|0,13),C^=s(P+_|0,18),M^=s(F+B|0,7),I^=s(M+F|0,9),B^=s(I+M|0,13),F^=s(B+I|0,18),E^=s(k+M|0,7),_^=s(E+k|0,9),M^=s(_+E|0,13),k^=s(M+_|0,18),P^=s(x+T|0,7),I^=s(P+x|0,9),T^=s(I+P|0,13),x^=s(T+I|0,18),B^=s(C+R|0,7),O^=s(B+C|0,9),R^=s(O+B|0,13),C^=s(R+O|0,18),N^=s(F+U|0,7),L^=s(N+F|0,9),U^=s(L+N|0,13),F^=s(U+L|0,18);i[o++]=a+k|0,i[o++]=u+E|0,i[o++]=c+_|0,i[o++]=l+M|0,i[o++]=f+T|0,i[o++]=h+x|0,i[o++]=d+P|0,i[o++]=p+I|0,i[o++]=m+O|0,i[o++]=y+R|0,i[o++]=g+C|0,i[o++]=b+B|0,i[o++]=v+N|0,i[o++]=w+L|0,i[o++]=A+U|0,i[o++]=S+F|0}function c(e,t,r,n,i){let o=n+0,a=n+16*i;for(let n=0;n<16;n++)r[a+n]=e[t+16*(2*i-1)+n];for(let n=0;n0&&(a+=16),u(r,o,e,t+=16,r,a)}function l(e,t,r){const s=(0,a.checkOpts)({dkLen:32,asyncTick:10,maxmem:1073742848},r),{N:u,r:c,p:l,dkLen:f,asyncTick:h,maxmem:d,onProgress:p}=s;if(n.default.number(u),n.default.number(c),n.default.number(l),n.default.number(f),n.default.number(h),n.default.number(d),void 0!==p&&"function"!=typeof p)throw new Error("progressCb should be function");const m=128*c,y=m/4;if(u<=1||0!=(u&u-1)||u>=2**(m/8)||u>2**32)throw new Error("Scrypt: N must be larger than 1, a power of 2, less than 2^(128 * r / 8) and less than 2^32");if(l<0||l>137438953440/m)throw new Error("Scrypt: p must be a positive integer less than or equal to ((2^32 - 1) * 32) / (128 * r)");if(f<0||f>137438953440)throw new Error("Scrypt: dkLen should be positive integer less than or equal to (2^32 - 1) * 32");const g=m*(u+l);if(g>d)throw new Error(`Scrypt: parameters too large, ${g} (128 * r * (N + p)) > ${d} (maxmem)`);const b=(0,o.pbkdf2)(i.sha256,e,t,{c:1,dkLen:m*l}),v=(0,a.u32)(b),w=(0,a.u32)(new Uint8Array(m*u)),A=(0,a.u32)(new Uint8Array(m));let S=()=>{};if(p){const e=2*u*l,t=Math.max(Math.floor(e/1e4),1);let r=0;S=()=>{r++,!p||r%t&&r!==e||p(r/e)}}return{N:u,r:c,p:l,dkLen:f,blockSize32:y,V:w,B32:v,B:b,tmp:A,blockMixCb:S,asyncTick:h}}function f(e,t,r,n,a){const s=(0,o.pbkdf2)(i.sha256,e,r,{c:1,dkLen:t});return r.fill(0),n.fill(0),a.fill(0),s}t.scrypt=function(e,t,r){const{N:n,r:i,p:o,dkLen:a,blockSize32:s,V:u,B32:h,B:d,tmp:p,blockMixCb:m}=l(e,t,r);for(let e=0;e{c(h,r,h,r+=u,i),y()})),c(h,(n-1)*u,d,t,i),y(),await(0,a.asyncLoop)(n,g,(e=>{const r=d[t+u-16]%n;for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha256=void 0;const n=r(27505),i=r(98089),o=(e,t,r)=>e&t^e&r^t&r,a=new Uint32Array([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]),s=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),u=new Uint32Array(64);class c extends n.SHA2{constructor(){super(64,32,8,!1),this.A=0|s[0],this.B=0|s[1],this.C=0|s[2],this.D=0|s[3],this.E=0|s[4],this.F=0|s[5],this.G=0|s[6],this.H=0|s[7]}get(){const{A:e,B:t,C:r,D:n,E:i,F:o,G:a,H:s}=this;return[e,t,r,n,i,o,a,s]}set(e,t,r,n,i,o,a,s){this.A=0|e,this.B=0|t,this.C=0|r,this.D=0|n,this.E=0|i,this.F=0|o,this.G=0|a,this.H=0|s}process(e,t){for(let r=0;r<16;r++,t+=4)u[r]=e.getUint32(t,!1);for(let e=16;e<64;e++){const t=u[e-15],r=u[e-2],n=(0,i.rotr)(t,7)^(0,i.rotr)(t,18)^t>>>3,o=(0,i.rotr)(r,17)^(0,i.rotr)(r,19)^r>>>10;u[e]=o+u[e-7]+n+u[e-16]|0}let{A:r,B:n,C:s,D:c,E:l,F:f,G:h,H:d}=this;for(let e=0;e<64;e++){const t=d+((0,i.rotr)(l,6)^(0,i.rotr)(l,11)^(0,i.rotr)(l,25))+((p=l)&f^~p&h)+a[e]+u[e]|0,m=((0,i.rotr)(r,2)^(0,i.rotr)(r,13)^(0,i.rotr)(r,22))+o(r,n,s)|0;d=h,h=f,f=l,l=c+t|0,c=s,s=n,n=r,r=t+m|0}var p;r=r+this.A|0,n=n+this.B|0,s=s+this.C|0,c=c+this.D|0,l=l+this.E|0,f=f+this.F|0,h=h+this.G|0,d=d+this.H|0,this.set(r,n,s,c,l,f,h,d)}roundClean(){u.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}t.sha256=(0,i.wrapConstructor)((()=>new c))},85426:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.shake256=t.shake128=t.keccak_512=t.keccak_384=t.keccak_256=t.keccak_224=t.sha3_512=t.sha3_384=t.sha3_256=t.sha3_224=t.Keccak=t.keccakP=void 0;const n=r(27320),i=r(6873),o=r(98089),[a,s,u]=[[],[],[]],c=BigInt(0),l=BigInt(1),f=BigInt(2),h=BigInt(7),d=BigInt(256),p=BigInt(113);for(let e=0,t=l,r=1,n=0;e<24;e++){[r,n]=[n,(2*r+3*n)%5],a.push(2*(5*n+r)),s.push((e+1)*(e+2)/2%64);let i=c;for(let e=0;e<7;e++)t=(t<>h)*p)%d,t&f&&(i^=l<<(l<r>32?i.default.rotlBH(e,t,r):i.default.rotlSH(e,t,r),b=(e,t,r)=>r>32?i.default.rotlBL(e,t,r):i.default.rotlSL(e,t,r);function v(e,t=24){const r=new Uint32Array(10);for(let n=24-t;n<24;n++){for(let t=0;t<10;t++)r[t]=e[t]^e[t+10]^e[t+20]^e[t+30]^e[t+40];for(let t=0;t<10;t+=2){const n=(t+8)%10,i=(t+2)%10,o=r[i],a=r[i+1],s=g(o,a,1)^r[n],u=b(o,a,1)^r[n+1];for(let r=0;r<50;r+=10)e[t+r]^=s,e[t+r+1]^=u}let t=e[2],i=e[3];for(let r=0;r<24;r++){const n=s[r],o=g(t,i,n),u=b(t,i,n),c=a[r];t=e[c],i=e[c+1],e[c]=o,e[c+1]=u}for(let t=0;t<50;t+=10){for(let n=0;n<10;n++)r[n]=e[t+n];for(let n=0;n<10;n++)e[t+n]^=~r[(n+2)%10]&r[(n+4)%10]}e[0]^=m[n],e[1]^=y[n]}r.fill(0)}t.keccakP=v;class w extends o.Hash{constructor(e,t,r,i=!1,a=24){if(super(),this.blockLen=e,this.suffix=t,this.outputLen=r,this.enableXOF=i,this.rounds=a,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,n.default.number(r),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=(0,o.u32)(this.state)}keccak(){v(this.state32,this.rounds),this.posOut=0,this.pos=0}update(e){n.default.exists(this);const{blockLen:t,state:r}=this,i=(e=(0,o.toBytes)(e)).length;for(let n=0;n=r&&this.keccak();const o=Math.min(r-this.posOut,i-n);e.set(t.subarray(this.posOut,this.posOut+o),n),this.posOut+=o,n+=o}return e}xofInto(e){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return n.default.number(e),this.xofInto(new Uint8Array(e))}digestInto(e){if(n.default.output(e,this),this.finished)throw new Error("digest() was already called");return this.writeInto(e),this.destroy(),e}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(e){const{blockLen:t,suffix:r,outputLen:n,rounds:i,enableXOF:o}=this;return e||(e=new w(t,r,n,o,i)),e.state32.set(this.state32),e.pos=this.pos,e.posOut=this.posOut,e.finished=this.finished,e.rounds=i,e.suffix=r,e.outputLen=n,e.enableXOF=o,e.destroyed=this.destroyed,e}}t.Keccak=w;const A=(e,t,r)=>(0,o.wrapConstructor)((()=>new w(t,e,r)));t.sha3_224=A(6,144,28),t.sha3_256=A(6,136,32),t.sha3_384=A(6,104,48),t.sha3_512=A(6,72,64),t.keccak_224=A(1,144,28),t.keccak_256=A(1,136,32),t.keccak_384=A(1,104,48),t.keccak_512=A(1,72,64);const S=(e,t,r)=>(0,o.wrapConstructorWithOpts)(((n={})=>new w(t,e,void 0===n.dkLen?r:n.dkLen,!0)));t.shake128=S(31,168,16),t.shake256=S(31,136,32)},98089:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.randomBytes=t.wrapConstructorWithOpts=t.wrapConstructor=t.checkOpts=t.Hash=t.concatBytes=t.toBytes=t.utf8ToBytes=t.asyncLoop=t.nextTick=t.hexToBytes=t.bytesToHex=t.isLE=t.rotr=t.createView=t.u32=t.u8=void 0;const n=r(64421);t.u8=e=>new Uint8Array(e.buffer,e.byteOffset,e.byteLength);t.u32=e=>new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4));t.createView=e=>new DataView(e.buffer,e.byteOffset,e.byteLength);if(t.rotr=(e,t)=>e<<32-t|e>>>t,t.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],!t.isLE)throw new Error("Non little-endian hardware is not supported");const i=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0")));t.bytesToHex=function(e){if(!(e instanceof Uint8Array))throw new Error("Uint8Array expected");let t="";for(let r=0;r{},t.asyncLoop=async function(e,r,n){let i=Date.now();for(let o=0;o=0&&ee instanceof Uint8Array)))throw new Error("Uint8Array list expected");if(1===e.length)return e[0];const t=e.reduce(((e,t)=>e+t.length),0),r=new Uint8Array(t);for(let t=0,n=0;te().update(a(t)).digest(),r=e();return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=()=>e(),t},t.wrapConstructorWithOpts=function(e){const t=(t,r)=>e(r).update(a(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t},t.randomBytes=function(e=32){if(n.crypto.web)return n.crypto.web.getRandomValues(new Uint8Array(e));if(n.crypto.node)return new Uint8Array(n.crypto.node.randomBytes(e).buffer);throw new Error("The environment doesn't have randomBytes function")}},79656:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utils=t.schnorr=t.verify=t.signSync=t.sign=t.getSharedSecret=t.recoverPublicKey=t.getPublicKey=t.Signature=t.Point=t.CURVE=void 0;const n=r(69159),i=BigInt(0),o=BigInt(1),a=BigInt(2),s=BigInt(3),u=BigInt(8),c=Object.freeze({a:i,b:BigInt(7),P:BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),n:BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),h:o,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee")});t.CURVE=c;const l=(e,t)=>(e+t/a)/t,f={beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar(e){const{n:t}=c,r=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),n=-o*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),i=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),a=r,s=BigInt("0x100000000000000000000000000000000"),u=l(a*e,t),f=l(-n*e,t);let h=U(e-u*r-f*i,t),d=U(-u*n-f*a,t);const p=h>s,m=d>s;if(p&&(h=t-h),m&&(d=t-d),h>s||d>s)throw new Error("splitScalarEndo: Endomorphism failed, k="+e);return{k1neg:p,k1:h,k2neg:m,k2:d}}},h=32,d=32;function p(e){const{a:t,b:r}=c,n=U(e*e),i=U(n*e);return U(i+t*e+r)}const m=c.a===i;class y extends Error{constructor(e){super(e)}}function g(e){if(!(e instanceof b))throw new TypeError("JacobianPoint expected")}class b{constructor(e,t,r){this.x=e,this.y=t,this.z=r}static fromAffine(e){if(!(e instanceof A))throw new TypeError("JacobianPoint#fromAffine: expected Point");return e.equals(A.ZERO)?b.ZERO:new b(e.x,e.y,o)}static toAffineBatch(e){const t=function(e,t=c.P){const r=new Array(e.length),n=D(e.reduce(((e,n,o)=>n===i?e:(r[o]=e,U(e*n,t))),o),t);return e.reduceRight(((e,n,o)=>n===i?e:(r[o]=U(e*r[o],t),U(e*n,t))),n),r}(e.map((e=>e.z)));return e.map(((e,r)=>e.toAffine(t[r])))}static normalizeZ(e){return b.toAffineBatch(e).map(b.fromAffine)}equals(e){g(e);const{x:t,y:r,z:n}=this,{x:i,y:o,z:a}=e,s=U(n*n),u=U(a*a),c=U(t*u),l=U(i*s),f=U(U(r*a)*u),h=U(U(o*n)*s);return c===l&&f===h}negate(){return new b(this.x,U(-this.y),this.z)}double(){const{x:e,y:t,z:r}=this,n=U(e*e),i=U(t*t),o=U(i*i),c=e+i,l=U(a*(U(c*c)-n-o)),f=U(s*n),h=U(f*f),d=U(h-a*l),p=U(f*(l-d)-u*o),m=U(a*t*r);return new b(d,p,m)}add(e){g(e);const{x:t,y:r,z:n}=this,{x:o,y:s,z:u}=e;if(o===i||s===i)return this;if(t===i||r===i)return e;const c=U(n*n),l=U(u*u),f=U(t*l),h=U(o*c),d=U(U(r*u)*l),p=U(U(s*n)*c),m=U(h-f),y=U(p-d);if(m===i)return y===i?this.double():b.ZERO;const v=U(m*m),w=U(m*v),A=U(f*v),S=U(y*y-w-a*A),k=U(y*(A-S)-d*w),E=U(n*u*m);return new b(S,k,E)}subtract(e){return this.add(e.negate())}multiplyUnsafe(e){const t=b.ZERO;if("bigint"==typeof e&&e===i)return t;let r=L(e);if(r===o)return this;if(!m){let e=t,n=this;for(;r>i;)r&o&&(e=e.add(n)),n=n.double(),r>>=o;return e}let{k1neg:n,k1:a,k2neg:s,k2:u}=f.splitScalar(r),c=t,l=t,h=this;for(;a>i||u>i;)a&o&&(c=c.add(h)),u&o&&(l=l.add(h)),h=h.double(),a>>=o,u>>=o;return n&&(c=c.negate()),s&&(l=l.negate()),l=new b(U(l.x*f.beta),l.y,l.z),c.add(l)}precomputeWindow(e){const t=m?128/e+1:256/e+1,r=[];let n=this,i=n;for(let o=0;o>=f,s>u&&(s-=l,e+=o);const h=r,d=r+Math.abs(s)-1,p=t%2!=0,m=s<0;0===s?a=a.add(v(p,n[h])):i=i.add(v(m,n[d]))}return{p:i,f:a}}multiply(e,t){let r,n,i=L(e);if(m){const{k1neg:e,k1:o,k2neg:a,k2:s}=f.splitScalar(i);let{p:u,f:c}=this.wNAF(o,t),{p:l,f:h}=this.wNAF(s,t);u=v(e,u),l=v(a,l),l=new b(U(l.x*f.beta),l.y,l.z),r=u.add(l),n=c.add(h)}else{const{p:e,f:o}=this.wNAF(i,t);r=e,n=o}return b.normalizeZ([r,n])[0]}toAffine(e){const{x:t,y:r,z:n}=this,i=this.equals(b.ZERO);null==e&&(e=i?u:D(n));const a=e,s=U(a*a),c=U(s*a),l=U(t*s),f=U(r*c),h=U(n*a);if(i)return A.ZERO;if(h!==o)throw new Error("invZ was invalid");return new A(l,f)}}function v(e,t){const r=t.negate();return e?r:t}b.BASE=new b(c.Gx,c.Gy,o),b.ZERO=new b(i,o,i);const w=new WeakMap;class A{constructor(e,t){this.x=e,this.y=t}_setWindowSize(e){this._WINDOW_SIZE=e,w.delete(this)}hasEvenY(){return this.y%a===i}static fromCompressedHex(e){const t=32===e.length,r=B(t?e:e.subarray(1));if(!q(r))throw new Error("Point is not on curve");let n=function(e){const{P:t}=c,r=BigInt(6),n=BigInt(11),i=BigInt(22),o=BigInt(23),u=BigInt(44),l=BigInt(88),f=e*e*e%t,h=f*f*e%t,d=F(h,s)*h%t,p=F(d,s)*h%t,m=F(p,a)*f%t,y=F(m,n)*m%t,g=F(y,i)*y%t,b=F(g,u)*g%t,v=F(b,l)*b%t,w=F(v,u)*g%t,A=F(w,s)*h%t,S=F(A,o)*y%t,k=F(S,r)*f%t,E=F(k,a);if(E*E%t!==e)throw new Error("Cannot find square root");return E}(p(r));const i=(n&o)===o;if(t)i&&(n=U(-n));else{1==(1&e[0])!==i&&(n=U(-n))}const u=new A(r,n);return u.assertValidity(),u}static fromUncompressedHex(e){const t=B(e.subarray(1,33)),r=B(e.subarray(33,65)),n=new A(t,r);return n.assertValidity(),n}static fromHex(e){const t=N(e),r=t.length,n=t[0];if(r===h)return this.fromCompressedHex(t);if(33===r&&(2===n||3===n))return this.fromCompressedHex(t);if(65===r&&4===n)return this.fromUncompressedHex(t);throw new Error(`Point.fromHex: received invalid point. Expected 32-33 compressed bytes or 65 uncompressed bytes, not ${r}`)}static fromPrivateKey(e){return A.BASE.multiply(V(e))}static fromSignature(e,t,r){const{r:n,s:i}=Q(t);if(![0,1,2,3].includes(r))throw new Error("Cannot recover: invalid recovery bit");const o=j(N(e)),{n:a}=c,s=2===r||3===r?n+a:n,u=D(s,a),l=U(-o*u,a),f=U(i*u,a),h=1&r?"03":"02",d=A.fromHex(h+P(s)),p=A.BASE.multiplyAndAddUnsafe(d,l,f);if(!p)throw new Error("Cannot recover signature: point at infinify");return p.assertValidity(),p}toRawBytes(e=!1){return C(this.toHex(e))}toHex(e=!1){const t=P(this.x);if(e){return`${this.hasEvenY()?"02":"03"}${t}`}return`04${t}${P(this.y)}`}toHexX(){return this.toHex(!0).slice(2)}toRawX(){return this.toRawBytes(!0).slice(1)}assertValidity(){const e="Point is not on elliptic curve",{x:t,y:r}=this;if(!q(t)||!q(r))throw new Error(e);const n=U(r*r);if(U(n-p(t))!==i)throw new Error(e)}equals(e){return this.x===e.x&&this.y===e.y}negate(){return new A(this.x,U(-this.y))}double(){return b.fromAffine(this).double().toAffine()}add(e){return b.fromAffine(this).add(b.fromAffine(e)).toAffine()}subtract(e){return this.add(e.negate())}multiply(e){return b.fromAffine(this).multiply(e,this).toAffine()}multiplyAndAddUnsafe(e,t,r){const n=b.fromAffine(this),a=t===i||t===o||this!==A.BASE?n.multiplyUnsafe(t):n.multiply(t),s=b.fromAffine(e).multiplyUnsafe(r),u=a.add(s);return u.equals(b.ZERO)?void 0:u.toAffine()}}function S(e){return Number.parseInt(e[0],16)>=8?"00"+e:e}function k(e){if(e.length<2||2!==e[0])throw new Error(`Invalid signature integer tag: ${T(e)}`);const t=e[1],r=e.subarray(2,t+2);if(!t||r.length!==t)throw new Error("Invalid signature integer: wrong length");if(0===r[0]&&r[1]<=127)throw new Error("Invalid signature integer: trailing length");return{data:B(r),left:e.subarray(t+2)}}t.Point=A,A.BASE=new A(c.Gx,c.Gy),A.ZERO=new A(i,i);class E{constructor(e,t){this.r=e,this.s=t,this.assertValidity()}static fromCompact(e){const t=e instanceof Uint8Array,r="Signature.fromCompact";if("string"!=typeof e&&!t)throw new TypeError(`${r}: Expected string or Uint8Array`);const n=t?T(e):e;if(128!==n.length)throw new Error(`${r}: Expected 64-byte hex`);return new E(R(n.slice(0,64)),R(n.slice(64,128)))}static fromDER(e){const t=e instanceof Uint8Array;if("string"!=typeof e&&!t)throw new TypeError("Signature.fromDER: Expected string or Uint8Array");const{r,s:n}=function(e){if(e.length<2||48!=e[0])throw new Error(`Invalid signature tag: ${T(e)}`);if(e[1]!==e.length-2)throw new Error("Invalid signature: incorrect length");const{data:t,left:r}=k(e.subarray(2)),{data:n,left:i}=k(r);if(i.length)throw new Error(`Invalid signature: left bytes after parsing: ${T(i)}`);return{r:t,s:n}}(t?e:C(e));return new E(r,n)}static fromHex(e){return this.fromDER(e)}assertValidity(){const{r:e,s:t}=this;if(!G(e))throw new Error("Invalid Signature: r must be 0 < r < n");if(!G(t))throw new Error("Invalid Signature: s must be 0 < s < n")}hasHighS(){const e=c.n>>o;return this.s>e}normalizeS(){return this.hasHighS()?new E(this.r,U(-this.s,c.n)):this}toDERRawBytes(){return C(this.toDERHex())}toDERHex(){const e=S(O(this.s)),t=S(O(this.r)),r=e.length/2,n=t.length/2,i=O(r),o=O(n);return`30${O(n+r+4)}02${o}${t}02${i}${e}`}toRawBytes(){return this.toDERRawBytes()}toHex(){return this.toDERHex()}toCompactRawBytes(){return C(this.toCompactHex())}toCompactHex(){return P(this.r)+P(this.s)}}function _(...e){if(!e.every((e=>e instanceof Uint8Array)))throw new Error("Uint8Array list expected");if(1===e.length)return e[0];const t=e.reduce(((e,t)=>e+t.length),0),r=new Uint8Array(t);for(let t=0,n=0;tt.toString(16).padStart(2,"0")));function T(e){if(!(e instanceof Uint8Array))throw new Error("Expected Uint8Array");let t="";for(let r=0;r0)return BigInt(e);if("bigint"==typeof e&&G(e))return e;throw new TypeError("Expected valid private scalar: 0 < scalar < curve.n")}function U(e,t=c.P){const r=e%t;return r>=i?r:t+r}function F(e,t){const{P:r}=c;let n=e;for(;t-- >i;)n*=n,n%=r;return n}function D(e,t=c.P){if(e===i||t<=i)throw new Error(`invert: expected positive integers, got n=${e} mod=${t}`);let r=U(e,t),n=t,a=i,s=o,u=o,l=i;for(;r!==i;){const e=n/r,t=n%r,i=a-u*e,o=s-l*e;n=r,r=t,a=u,s=l,u=i,l=o}if(n!==o)throw new Error("invert: does not exist");return U(a,t)}function j(e,t=!1){const r=function(e){const t=8*e.length-256,r=B(e);return t>0?r>>BigInt(t):r}(e);if(t)return r;const{n}=c;return r>=n?r-n:r}let H,J;class z{constructor(e,t){if(this.hashLen=e,this.qByteLen=t,"number"!=typeof e||e<2)throw new Error("hashLen must be a number");if("number"!=typeof t||t<2)throw new Error("qByteLen must be a number");this.v=new Uint8Array(e).fill(1),this.k=new Uint8Array(e).fill(0),this.counter=0}hmac(...e){return t.utils.hmacSha256(this.k,...e)}hmacSync(...e){return J(this.k,...e)}checkSync(){if("function"!=typeof J)throw new y("hmacSha256Sync needs to be set")}incr(){if(this.counter>=1e3)throw new Error("Tried 1,000 k values for sign(), all were invalid");this.counter+=1}async reseed(e=new Uint8Array){this.k=await this.hmac(this.v,Uint8Array.from([0]),e),this.v=await this.hmac(this.v),0!==e.length&&(this.k=await this.hmac(this.v,Uint8Array.from([1]),e),this.v=await this.hmac(this.v))}reseedSync(e=new Uint8Array){this.checkSync(),this.k=this.hmacSync(this.v,Uint8Array.from([0]),e),this.v=this.hmacSync(this.v),0!==e.length&&(this.k=this.hmacSync(this.v,Uint8Array.from([1]),e),this.v=this.hmacSync(this.v))}async generate(){this.incr();let e=0;const t=[];for(;e0)t=BigInt(e);else if("string"==typeof e){if(64!==e.length)throw new Error("Expected 32 bytes of private key");t=R(e)}else{if(!(e instanceof Uint8Array))throw new TypeError("Expected valid private key");if(e.length!==d)throw new Error("Expected 32 bytes of private key");t=B(e)}if(!G(t))throw new Error("Expected private key: 0 < key < n");return t}function X(e){return e instanceof A?(e.assertValidity(),e):A.fromHex(e)}function Q(e){if(e instanceof E)return e.assertValidity(),e;try{return E.fromDER(e)}catch(t){return E.fromCompact(e)}}function W(e){const t=e instanceof Uint8Array,r="string"==typeof e,n=(t||r)&&e.length;return t?33===n||65===n:r?66===n||130===n:e instanceof A}function Z(e){return B(e.length>h?e.slice(0,h):e)}function Y(e){const t=Z(e),r=U(t,c.n);return $(r{if((e=N(e)).length<40||e.length>1024)throw new Error("Expected valid bytes of private key as per FIPS 186");return I(U(B(e),c.n-o)+o)},randomBytes:(e=32)=>{if(le.web)return le.web.getRandomValues(new Uint8Array(e));if(le.node){const{randomBytes:t}=le.node;return Uint8Array.from(t(e))}throw new Error("The environment doesn't have randomBytes function")},randomPrivateKey:()=>t.utils.hashToPrivateKey(t.utils.randomBytes(40)),precompute(e=8,t=A.BASE){const r=t===A.BASE?t:new A(t.x,t.y);return r._setWindowSize(e),r.multiply(s),r},sha256:async(...e)=>{if(le.web){const t=await le.web.subtle.digest("SHA-256",_(...e));return new Uint8Array(t)}if(le.node){const{createHash:t}=le.node,r=t("sha256");return e.forEach((e=>r.update(e))),Uint8Array.from(r.digest())}throw new Error("The environment doesn't have sha256 function")},hmacSha256:async(e,...t)=>{if(le.web){const r=await le.web.subtle.importKey("raw",e,{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),n=_(...t),i=await le.web.subtle.sign("HMAC",r,n);return new Uint8Array(i)}if(le.node){const{createHmac:r}=le.node,n=r("sha256",e);return t.forEach((e=>n.update(e))),Uint8Array.from(n.digest())}throw new Error("The environment doesn't have hmac-sha256 function")},sha256Sync:void 0,hmacSha256Sync:void 0,taggedHash:async(e,...r)=>{let n=he[e];if(void 0===n){const r=await t.utils.sha256(Uint8Array.from(e,(e=>e.charCodeAt(0))));n=_(r,r),he[e]=n}return t.utils.sha256(n,...r)},taggedHashSync:(e,...t)=>{if("function"!=typeof H)throw new y("sha256Sync is undefined, you need to set it");let r=he[e];if(void 0===r){const t=H(Uint8Array.from(e,(e=>e.charCodeAt(0))));r=_(t,t),he[e]=r}return H(r,...t)},_JacobianPoint:b},Object.defineProperties(t.utils,{sha256Sync:{configurable:!1,get:()=>H,set(e){H||(H=e)}},hmacSha256Sync:{configurable:!1,get:()=>J,set(e){J||(J=e)}}})},39809:(e,t,r)=>{"use strict";const n=t;n.bignum=r(4590),n.define=r(22500).define,n.base=r(71979),n.constants=r(36826),n.decoders=r(78307),n.encoders=r(56579)},22500:(e,t,r)=>{"use strict";const n=r(56579),i=r(78307),o=r(35717);function a(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}t.define=function(e,t){return new a(e,t)},a.prototype._createNamed=function(e){const t=this.name;function r(e){this._initNamed(e,t)}return o(r,e),r.prototype._initNamed=function(t,r){e.call(this,t,r)},new r(this)},a.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(i[e])),this.decoders[e]},a.prototype.decode=function(e,t,r){return this._getDecoder(t).decode(e,r)},a.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(n[e])),this.encoders[e]},a.prototype.encode=function(e,t,r){return this._getEncoder(t).encode(e,r)}},36625:(e,t,r)=>{"use strict";const n=r(35717),i=r(98465).b,o=r(2399).Buffer;function a(e,t){i.call(this,t),o.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function s(e,t){if(Array.isArray(e))this.length=0,this.value=e.map((function(e){return s.isEncoderBuffer(e)||(e=new s(e,t)),this.length+=e.length,e}),this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=o.byteLength(e);else{if(!o.isBuffer(e))return t.error("Unsupported type: "+typeof e);this.value=e,this.length=e.length}}n(a,i),t.C=a,a.isDecoderBuffer=function(e){if(e instanceof a)return!0;return"object"==typeof e&&o.isBuffer(e.base)&&"DecoderBuffer"===e.constructor.name&&"number"==typeof e.offset&&"number"==typeof e.length&&"function"==typeof e.save&&"function"==typeof e.restore&&"function"==typeof e.isEmpty&&"function"==typeof e.readUInt8&&"function"==typeof e.skip&&"function"==typeof e.raw},a.prototype.save=function(){return{offset:this.offset,reporter:i.prototype.save.call(this)}},a.prototype.restore=function(e){const t=new a(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,i.prototype.restore.call(this,e.reporter),t},a.prototype.isEmpty=function(){return this.offset===this.length},a.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},a.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");const r=new a(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+e,this.offset+=e,r},a.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},t.R=s,s.isEncoderBuffer=function(e){if(e instanceof s)return!0;return"object"==typeof e&&"EncoderBuffer"===e.constructor.name&&"number"==typeof e.length&&"function"==typeof e.join},s.prototype.join=function(e,t){return e||(e=o.alloc(this.length)),t||(t=0),0===this.length||(Array.isArray(this.value)?this.value.forEach((function(r){r.join(e,t),t+=r.length})):("number"==typeof this.value?e[t]=this.value:"string"==typeof this.value?e.write(this.value,t):o.isBuffer(this.value)&&this.value.copy(e,t),t+=this.length)),e}},71979:(e,t,r)=>{"use strict";const n=t;n.Reporter=r(98465).b,n.DecoderBuffer=r(36625).C,n.EncoderBuffer=r(36625).R,n.Node=r(41949)},41949:(e,t,r)=>{"use strict";const n=r(98465).b,i=r(36625).R,o=r(36625).C,a=r(79746),s=["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"],u=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(s);function c(e,t,r){const n={};this._baseState=n,n.name=r,n.enc=e,n.parent=t||null,n.children=null,n.tag=null,n.args=null,n.reverseArgs=null,n.choice=null,n.optional=!1,n.any=!1,n.obj=!1,n.use=null,n.useDecoder=null,n.key=null,n.default=null,n.explicit=null,n.implicit=null,n.contains=null,n.parent||(n.children=[],this._wrap())}e.exports=c;const l=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];c.prototype.clone=function(){const e=this._baseState,t={};l.forEach((function(r){t[r]=e[r]}));const r=new this.constructor(t.parent);return r._baseState=t,r},c.prototype._wrap=function(){const e=this._baseState;u.forEach((function(t){this[t]=function(){const r=new this.constructor(this);return e.children.push(r),r[t].apply(r,arguments)}}),this)},c.prototype._init=function(e){const t=this._baseState;a(null===t.parent),e.call(this),t.children=t.children.filter((function(e){return e._baseState.parent===this}),this),a.equal(t.children.length,1,"Root node can have only one child")},c.prototype._useArgs=function(e){const t=this._baseState,r=e.filter((function(e){return e instanceof this.constructor}),this);e=e.filter((function(e){return!(e instanceof this.constructor)}),this),0!==r.length&&(a(null===t.children),t.children=r,r.forEach((function(e){e._baseState.parent=this}),this)),0!==e.length&&(a(null===t.args),t.args=e,t.reverseArgs=e.map((function(e){if("object"!=typeof e||e.constructor!==Object)return e;const t={};return Object.keys(e).forEach((function(r){r==(0|r)&&(r|=0);const n=e[r];t[n]=r})),t})))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach((function(e){c.prototype[e]=function(){const t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}})),s.forEach((function(e){c.prototype[e]=function(){const t=this._baseState,r=Array.prototype.slice.call(arguments);return a(null===t.tag),t.tag=e,this._useArgs(r),this}})),c.prototype.use=function(e){a(e);const t=this._baseState;return a(null===t.use),t.use=e,this},c.prototype.optional=function(){return this._baseState.optional=!0,this},c.prototype.def=function(e){const t=this._baseState;return a(null===t.default),t.default=e,t.optional=!0,this},c.prototype.explicit=function(e){const t=this._baseState;return a(null===t.explicit&&null===t.implicit),t.explicit=e,this},c.prototype.implicit=function(e){const t=this._baseState;return a(null===t.explicit&&null===t.implicit),t.implicit=e,this},c.prototype.obj=function(){const e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},c.prototype.key=function(e){const t=this._baseState;return a(null===t.key),t.key=e,this},c.prototype.any=function(){return this._baseState.any=!0,this},c.prototype.choice=function(e){const t=this._baseState;return a(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map((function(t){return e[t]}))),this},c.prototype.contains=function(e){const t=this._baseState;return a(null===t.use),t.contains=e,this},c.prototype._decode=function(e,t){const r=this._baseState;if(null===r.parent)return e.wrapResult(r.children[0]._decode(e,t));let n,i=r.default,a=!0,s=null;if(null!==r.key&&(s=e.enterKey(r.key)),r.optional){let n=null;if(null!==r.explicit?n=r.explicit:null!==r.implicit?n=r.implicit:null!==r.tag&&(n=r.tag),null!==n||r.any){if(a=this._peekTag(e,n,r.any),e.isError(a))return a}else{const n=e.save();try{null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),a=!0}catch(e){a=!1}e.restore(n)}}if(r.obj&&a&&(n=e.enterObject()),a){if(null!==r.explicit){const t=this._decodeTag(e,r.explicit);if(e.isError(t))return t;e=t}const n=e.offset;if(null===r.use&&null===r.choice){let t;r.any&&(t=e.save());const n=this._decodeTag(e,null!==r.implicit?r.implicit:r.tag,r.any);if(e.isError(n))return n;r.any?i=e.raw(t):e=n}if(t&&t.track&&null!==r.tag&&t.track(e.path(),n,e.length,"tagged"),t&&t.track&&null!==r.tag&&t.track(e.path(),e.offset,e.length,"content"),r.any||(i=null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t)),e.isError(i))return i;if(r.any||null!==r.choice||null===r.children||r.children.forEach((function(r){r._decode(e,t)})),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){const n=new o(i);i=this._getUse(r.contains,e._reporterState.obj)._decode(n,t)}}return r.obj&&a&&(i=e.leaveObject(n)),null===r.key||null===i&&!0!==a?null!==s&&e.exitKey(s):e.leaveKey(s,r.key,i),i},c.prototype._decodeGeneric=function(e,t,r){const n=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,n.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&n.args?this._decodeObjid(t,n.args[0],n.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,n.args&&n.args[0],r):null!==n.use?this._getUse(n.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},c.prototype._getUse=function(e,t){const r=this._baseState;return r.useDecoder=this._use(e,t),a(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},c.prototype._decodeChoice=function(e,t){const r=this._baseState;let n=null,i=!1;return Object.keys(r.choice).some((function(o){const a=e.save(),s=r.choice[o];try{const r=s._decode(e,t);if(e.isError(r))return!1;n={type:o,value:r},i=!0}catch(t){return e.restore(a),!1}return!0}),this),i?n:e.error("Choice not matched")},c.prototype._createEncoderBuffer=function(e){return new i(e,this.reporter)},c.prototype._encode=function(e,t,r){const n=this._baseState;if(null!==n.default&&n.default===e)return;const i=this._encodeValue(e,t,r);return void 0===i||this._skipDefault(i,t,r)?void 0:i},c.prototype._encodeValue=function(e,t,r){const i=this._baseState;if(null===i.parent)return i.children[0]._encode(e,t||new n);let o=null;if(this.reporter=t,i.optional&&void 0===e){if(null===i.default)return;e=i.default}let a=null,s=!1;if(i.any)o=this._createEncoderBuffer(e);else if(i.choice)o=this._encodeChoice(e,t);else if(i.contains)a=this._getUse(i.contains,r)._encode(e,t),s=!0;else if(i.children)a=i.children.map((function(r){if("null_"===r._baseState.tag)return r._encode(null,t,e);if(null===r._baseState.key)return t.error("Child should have a key");const n=t.enterKey(r._baseState.key);if("object"!=typeof e)return t.error("Child expected, but input is not object");const i=r._encode(e[r._baseState.key],t,e);return t.leaveKey(n),i}),this).filter((function(e){return e})),a=this._createEncoderBuffer(a);else if("seqof"===i.tag||"setof"===i.tag){if(!i.args||1!==i.args.length)return t.error("Too many args for : "+i.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");const r=this.clone();r._baseState.implicit=null,a=this._createEncoderBuffer(e.map((function(r){const n=this._baseState;return this._getUse(n.args[0],e)._encode(r,t)}),r))}else null!==i.use?o=this._getUse(i.use,r)._encode(e,t):(a=this._encodePrimitive(i.tag,e),s=!0);if(!i.any&&null===i.choice){const e=null!==i.implicit?i.implicit:i.tag,r=null===i.implicit?"universal":"context";null===e?null===i.use&&t.error("Tag could be omitted only for .use()"):null===i.use&&(o=this._encodeComposite(e,s,r,a))}return null!==i.explicit&&(o=this._encodeComposite(i.explicit,!1,"context",o)),o},c.prototype._encodeChoice=function(e,t){const r=this._baseState,n=r.choice[e.type];return n||a(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),n._encode(e.value,t)},c.prototype._encodePrimitive=function(e,t){const r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},c.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},c.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(e)}},98465:(e,t,r)=>{"use strict";const n=r(35717);function i(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function o(e,t){this.path=e,this.rethrow(t)}t.b=i,i.prototype.isError=function(e){return e instanceof o},i.prototype.save=function(){const e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},i.prototype.restore=function(e){const t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},i.prototype.enterKey=function(e){return this._reporterState.path.push(e)},i.prototype.exitKey=function(e){const t=this._reporterState;t.path=t.path.slice(0,e-1)},i.prototype.leaveKey=function(e,t,r){const n=this._reporterState;this.exitKey(e),null!==n.obj&&(n.obj[t]=r)},i.prototype.path=function(){return this._reporterState.path.join("/")},i.prototype.enterObject=function(){const e=this._reporterState,t=e.obj;return e.obj={},t},i.prototype.leaveObject=function(e){const t=this._reporterState,r=t.obj;return t.obj=e,r},i.prototype.error=function(e){let t;const r=this._reporterState,n=e instanceof o;if(t=n?e:new o(r.path.map((function(e){return"["+JSON.stringify(e)+"]"})).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},i.prototype.wrapResult=function(e){const t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},n(o,Error),o.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,o),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},70160:(e,t)=>{"use strict";function r(e){const t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);const n=e[r];t[n]=r})),t}t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=r(t.tagClass),t.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"},t.tagByName=r(t.tag)},36826:(e,t,r)=>{"use strict";const n=t;n._reverse=function(e){const t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);const n=e[r];t[n]=r})),t},n.der=r(70160)},41671:(e,t,r)=>{"use strict";const n=r(35717),i=r(4590),o=r(36625).C,a=r(41949),s=r(70160);function u(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new c,this.tree._init(e.body)}function c(e){a.call(this,"der",e)}function l(e,t){let r=e.readUInt8(t);if(e.isError(r))return r;const n=s.tagClass[r>>6],i=0==(32&r);if(31==(31&r)){let n=r;for(r=0;128==(128&n);){if(n=e.readUInt8(t),e.isError(n))return n;r<<=7,r|=127&n}}else r&=31;return{cls:n,primitive:i,tag:r,tagStr:s.tag[r]}}function f(e,t,r){let n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&128===n)return null;if(0==(128&n))return n;const i=127&n;if(i>4)return e.error("length octect is too long");n=0;for(let t=0;t{"use strict";const n=t;n.der=r(41671),n.pem=r(59631)},59631:(e,t,r)=>{"use strict";const n=r(35717),i=r(2399).Buffer,o=r(41671);function a(e){o.call(this,e),this.enc="pem"}n(a,o),e.exports=a,a.prototype.decode=function(e,t){const r=e.toString().split(/[\r\n]+/g),n=t.label.toUpperCase(),a=/^-----(BEGIN|END) ([^-]+)-----$/;let s=-1,u=-1;for(let e=0;e{"use strict";const n=r(35717),i=r(2399).Buffer,o=r(41949),a=r(70160);function s(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){o.call(this,"der",e)}function c(e){return e<10?"0"+e:e}e.exports=s,s.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},n(u,o),u.prototype._encodeComposite=function(e,t,r,n){const o=function(e,t,r,n){let i;"seqof"===e?e="seq":"setof"===e&&(e="set");if(a.tagByName.hasOwnProperty(e))i=a.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return n.error("Unknown tag: "+e);i=e}if(i>=31)return n.error("Multi-octet tag encoding unsupported");t||(i|=32);return i|=a.tagClassByName[r||"universal"]<<6,i}(e,t,r,this.reporter);if(n.length<128){const e=i.alloc(2);return e[0]=o,e[1]=n.length,this._createEncoderBuffer([e,n])}let s=1;for(let e=n.length;e>=256;e>>=8)s++;const u=i.alloc(2+s);u[0]=o,u[1]=128|s;for(let e=1+s,t=n.length;t>0;e--,t>>=8)u[e]=255&t;return this._createEncoderBuffer([u,n])},u.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){const t=i.alloc(2*e.length);for(let r=0;r=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}let n=0;for(let t=0;t=128;r>>=7)n++}const o=i.alloc(n);let a=o.length-1;for(let t=e.length-1;t>=0;t--){let r=e[t];for(o[a--]=127&r;(r>>=7)>0;)o[a--]=128|127&r}return this._createEncoderBuffer(o)},u.prototype._encodeTime=function(e,t){let r;const n=new Date(e);return"gentime"===t?r=[c(n.getUTCFullYear()),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[c(n.getUTCFullYear()%100),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},u.prototype._encodeNull=function(){return this._createEncoderBuffer("")},u.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!i.isBuffer(e)){const t=e.toArray();!e.sign&&128&t[0]&&t.unshift(0),e=i.from(t)}if(i.isBuffer(e)){let t=e.length;0===e.length&&t++;const r=i.alloc(t);return e.copy(r),0===e.length&&(r[0]=0),this._createEncoderBuffer(r)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);let r=1;for(let t=e;t>=256;t>>=8)r++;const n=new Array(r);for(let t=n.length-1;t>=0;t--)n[t]=255&e,e>>=8;return 128&n[0]&&n.unshift(0),this._createEncoderBuffer(i.from(n))},u.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},u.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},u.prototype._skipDefault=function(e,t,r){const n=this._baseState;let i;if(null===n.default)return!1;const o=e.join();if(void 0===n.defaultBuffer&&(n.defaultBuffer=this._encodeValue(n.default,t,r).join()),o.length!==n.defaultBuffer.length)return!1;for(i=0;i{"use strict";const n=t;n.der=r(66984),n.pem=r(2883)},2883:(e,t,r)=>{"use strict";const n=r(35717),i=r(66984);function o(e){i.call(this,e),this.enc="pem"}n(o,i),e.exports=o,o.prototype.encode=function(e,t){const r=i.prototype.encode.call(this,e).toString("base64"),n=["-----BEGIN "+t.label+"-----"];for(let e=0;e=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},44583:(e,t,r)=>{const n=r(36805);e.exports=async function(e,t){const r={algorithm:"URDNA2015",format:"application/n-quads"};t&&(r.inputFormat=t);const i=(await n.canonize(e,r)).split("\n").filter((e=>""!==e));if(i&&0===i.length)throw Error("File format is corrupted, no n-quads are extracted.");return i}},66302:e=>{e.exports={getAssertionSizeInBytes:function(e){const t=JSON.stringify(e);return(new TextEncoder).encode(t).length},getAssertionTriplesNumber:function(e){return e.length},getAssertionChunksNumber:function(e){return e.length}}},6025:(e,t,r)=>{const n=r(54099),{MerkleTree:i}=r(2162),o=r(25651);e.exports=function(e){e.sort();const t=e.map(((e,t)=>o(n.utils.solidityPack(["bytes32","uint256"],[o(e),t]))));return`0x${new i(t,o,{sortPairs:!0}).getRoot().toString("hex")}`}},75386:e=>{e.exports="https://ontology.origintrail.io/dkg/1.0#privateAssertionID"},94263:(e,t,r)=>{const n=r(54099),{MerkleTree:i}=r(2162),o=r(25651);e.exports=function(e,t){e.sort();const r=e.map(((e,t)=>o(n.utils.solidityPack(["bytes32","uint256"],[o(e),t])))),a=new i(r,o,{sortPairs:!0});return{leaf:o(e[t]),proof:a.getHexProof(r[t])}}},58735:(e,t,r)=>{const n=r(44583),i=r(6025),o=r(75386);function a(e){return 0===Object.keys(e).length&&e.constructor===Object}e.exports=async function(e){let t;e.private&&!a(e.private)&&(t=await n(e.private));const r={"@graph":[e.public&&!a(e.public)?e.public:null,e.private&&!a(e.private)?{[o]:t?i(t):null}:null]},s={public:await n(r)};return t&&(s.private=t),s}},50953:(e,t,r)=>{const n=r(66302),i=r(6025),o=r(44583),a=r(58735),s=r(94263),u=r(88459),c=r(25651);e.exports={calculateRoot:i,formatAssertion:o,formatGraph:a,getMerkleProof:s,peerId2Hash:u,keccak256:c,assertionMetadata:n}},25651:(e,t,r)=>{const n=r(54099);e.exports=function(e){let t=e;return n.utils.isBytesLike(e)||(t=n.utils.toUtf8Bytes(e)),n.utils.keccak256(t)}},54099:(e,t,r)=>{"use strict";r.r(t),r.d(t,{BaseContract:()=>Bn,BigNumber:()=>X,Contract:()=>Nn,ContractFactory:()=>Ln,FixedNumber:()=>Vn,Signer:()=>lr,VoidSigner:()=>fr,Wallet:()=>Eo,Wordlist:()=>Ei,constants:()=>i,errors:()=>y,ethers:()=>u,getDefaultProvider:()=>vu,logger:()=>Qu,providers:()=>o,utils:()=>s,version:()=>Xu,wordlists:()=>xi});var n={};r.r(n),r.d(n,{decode:()=>Te,encode:()=>Ee});var i={};r.r(i),r.d(i,{AddressZero:()=>To,EtherSymbol:()=>Po,HashZero:()=>xo,MaxInt256:()=>yt,MaxUint256:()=>pt,MinInt256:()=>mt,NegativeOne:()=>ct,One:()=>ft,Two:()=>ht,WeiPerEther:()=>dt,Zero:()=>lt});var o={};r.r(o),r.d(o,{AlchemyProvider:()=>_s,AlchemyWebSocketProvider:()=>Es,AnkrProvider:()=>Ps,BaseProvider:()=>$a,CloudflareProvider:()=>Rs,EtherscanProvider:()=>js,FallbackProvider:()=>ru,Formatter:()=>_a,InfuraProvider:()=>su,InfuraWebSocketProvider:()=>au,IpcProvider:()=>nu,JsonRpcBatchProvider:()=>uu,JsonRpcProvider:()=>hs,JsonRpcSigner:()=>cs,NodesmithProvider:()=>lu,PocketProvider:()=>du,Provider:()=>or,Resolver:()=>Wa,StaticJsonRpcProvider:()=>ws,UrlJsonRpcProvider:()=>As,Web3Provider:()=>gu,WebSocketProvider:()=>gs,getDefaultProvider:()=>vu,getNetwork:()=>Uo,isCommunityResourcable:()=>Ma,isCommunityResource:()=>Ta,showThrottleMessage:()=>Pa});var a={};r.r(a),r.d(a,{decode:()=>Fo,encode:()=>Do});var s={};r.r(s),r.d(s,{AbiCoder:()=>Kt,ConstructorFragment:()=>Nt,ErrorFragment:()=>Ft,EventFragment:()=>Ot,FormatTypes:()=>Mt,Fragment:()=>It,FunctionFragment:()=>Lt,HDNode:()=>Di,Indexed:()=>Yt,Interface:()=>tr,LogDescription:()=>Qt,Logger:()=>b,ParamType:()=>xt,RLP:()=>n,SigningKey:()=>$r,SupportedAlgorithm:()=>yi,TransactionDescription:()=>Wt,TransactionTypes:()=>nn,UnicodeNormalizationForm:()=>je,Utf8ErrorFuncs:()=>ze,Utf8ErrorReason:()=>He,_TypedDataEncoder:()=>di,_fetchData:()=>ba,_toEscapedUtf8String:()=>Ve,accessListify:()=>dn,arrayify:()=>_,base58:()=>mi,base64:()=>a,checkProperties:()=>ie,checkResultErrors:()=>de,commify:()=>zu,computeAddress:()=>cn,computeHmac:()=>Ai,computePublicKey:()=>tn,concat:()=>M,deepCopy:()=>ce,defaultAbiCoder:()=>Vt,defaultPath:()=>Fi,defineReadOnly:()=>te,dnsEncode:()=>fa,entropyToMnemonic:()=>Ji,fetchJson:()=>va,formatBytes32String:()=>Du,formatEther:()=>Ku,formatUnits:()=>Gu,getAccountPath:()=>Gi,getAddress:()=>Be,getContractAddress:()=>Ue,getCreate2Address:()=>Fe,getIcapAddress:()=>Le,getJsonWalletAddress:()=>vo,getStatic:()=>re,hashMessage:()=>Wn,hexConcat:()=>B,hexDataLength:()=>R,hexDataSlice:()=>C,hexStripZeros:()=>L,hexValue:()=>N,hexZeroPad:()=>U,hexlify:()=>O,id:()=>Ze,isAddress:()=>Ne,isBytes:()=>E,isBytesLike:()=>S,isHexString:()=>P,isValidMnemonic:()=>zi,isValidName:()=>ca,joinSignature:()=>D,keccak256:()=>ve,mnemonicToEntropy:()=>Hi,mnemonicToSeed:()=>ji,namehash:()=>la,nameprep:()=>Fu,parseBytes32String:()=>ju,parseEther:()=>Vu,parseTransaction:()=>vn,parseUnits:()=>qu,poll:()=>wa,randomBytes:()=>Xi,recoverAddress:()=>ln,recoverPublicKey:()=>en,resolveProperties:()=>ne,ripemd160:()=>bi,serializeTransaction:()=>gn,sha256:()=>vi,sha512:()=>wi,shallowCopy:()=>oe,shuffled:()=>Hs,solidityKeccak256:()=>Mu,solidityPack:()=>_u,soliditySha256:()=>Tu,splitSignature:()=>F,stripZeros:()=>T,toUtf8Bytes:()=>qe,toUtf8CodePoints:()=>We,toUtf8String:()=>Qe,verifyMessage:()=>_o,verifyTypedData:()=>Mo,zeroPad:()=>x});var u={};r.r(u),r.d(u,{BaseContract:()=>Bn,BigNumber:()=>X,Contract:()=>Nn,ContractFactory:()=>Ln,FixedNumber:()=>Vn,Signer:()=>lr,VoidSigner:()=>fr,Wallet:()=>Eo,Wordlist:()=>Ei,constants:()=>i,errors:()=>y,getDefaultProvider:()=>vu,logger:()=>Qu,providers:()=>o,utils:()=>s,version:()=>Xu,wordlists:()=>xi});let c=!1,l=!1;const f={debug:1,default:2,info:2,warning:3,error:4,off:5};let h=f.default,d=null;const p=function(){try{const e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((t=>{try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(e){return e.message}return null}();var m,y;!function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(m||(m={})),function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED",e.ACTION_REJECTED="ACTION_REJECTED"}(y||(y={}));const g="0123456789abcdef";class b{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,t){const r=e.toLowerCase();null==f[r]&&this.throwArgumentError("invalid log level name","logLevel",e),h>f[r]||console.log.apply(console,t)}debug(...e){this._log(b.levels.DEBUG,e)}info(...e){this._log(b.levels.INFO,e)}warn(...e){this._log(b.levels.WARNING,e)}makeError(e,t,r){if(l)return this.makeError("censored error",t,{});t||(t=b.errors.UNKNOWN_ERROR),r||(r={});const n=[];Object.keys(r).forEach((e=>{const t=r[e];try{if(t instanceof Uint8Array){let r="";for(let e=0;e>4],r+=g[15&t[e]];n.push(e+"=Uint8Array(0x"+r+")")}else n.push(e+"="+JSON.stringify(t))}catch(t){n.push(e+"="+JSON.stringify(r[e].toString()))}})),n.push(`code=${t}`),n.push(`version=${this.version}`);const i=e;let o="";switch(t){case y.NUMERIC_FAULT:{o="NUMERIC_FAULT";const t=e;switch(t){case"overflow":case"underflow":case"division-by-zero":o+="-"+t;break;case"negative-power":case"negative-width":o+="-unsupported";break;case"unbound-bitwise-result":o+="-unbound-result"}break}case y.CALL_EXCEPTION:case y.INSUFFICIENT_FUNDS:case y.MISSING_NEW:case y.NONCE_EXPIRED:case y.REPLACEMENT_UNDERPRICED:case y.TRANSACTION_REPLACED:case y.UNPREDICTABLE_GAS_LIMIT:o=t}o&&(e+=" [ See: https://links.ethers.org/v5-errors-"+o+" ]"),n.length&&(e+=" ("+n.join(", ")+")");const a=new Error(e);return a.reason=i,a.code=t,Object.keys(r).forEach((function(e){a[e]=r[e]})),a}throwError(e,t,r){throw this.makeError(e,t,r)}throwArgumentError(e,t,r){return this.throwError(e,b.errors.INVALID_ARGUMENT,{argument:t,value:r})}assert(e,t,r,n){e||this.throwError(t,r,n)}assertArgument(e,t,r,n){e||this.throwArgumentError(t,r,n)}checkNormalize(e){null==e&&(e="platform missing String.prototype.normalize"),p&&this.throwError("platform missing String.prototype.normalize",b.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:p})}checkSafeUint53(e,t){"number"==typeof e&&(null==t&&(t="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(t,b.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(t,b.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,t,r){r=r?": "+r:"",et&&this.throwError("too many arguments"+r,b.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:t})}checkNew(e,t){e!==Object&&null!=e||this.throwError("missing new",b.errors.MISSING_NEW,{name:t.name})}checkAbstract(e,t){e===t?this.throwError("cannot instantiate abstract class "+JSON.stringify(t.name)+" directly; use a sub-class",b.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):e!==Object&&null!=e||this.throwError("missing new",b.errors.MISSING_NEW,{name:t.name})}static globalLogger(){return d||(d=new b("logger/5.7.0")),d}static setCensorship(e,t){if(!e&&t&&this.globalLogger().throwError("cannot permanently disable censorship",b.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),c){if(!e)return;this.globalLogger().throwError("error censorship permanent",b.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}l=!!e,c=!!t}static setLogLevel(e){const t=f[e.toLowerCase()];null!=t?h=t:b.globalLogger().warn("invalid log level - "+e)}static from(e){return new b(e)}}b.errors=y,b.levels=m;const v=new b("bytes/5.7.0");function w(e){return!!e.toHexString}function A(e){return e.slice||(e.slice=function(){const t=Array.prototype.slice.call(arguments);return A(new Uint8Array(Array.prototype.slice.apply(e,t)))}),e}function S(e){return P(e)&&!(e.length%2)||E(e)}function k(e){return"number"==typeof e&&e==e&&e%1==0}function E(e){if(null==e)return!1;if(e.constructor===Uint8Array)return!0;if("string"==typeof e)return!1;if(!k(e.length)||e.length<0)return!1;for(let t=0;t=256)return!1}return!0}function _(e,t){if(t||(t={}),"number"==typeof e){v.checkSafeUint53(e,"invalid arrayify value");const t=[];for(;e;)t.unshift(255&e),e=parseInt(String(e/256));return 0===t.length&&t.push(0),A(new Uint8Array(t))}if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),w(e)&&(e=e.toHexString()),P(e)){let r=e.substring(2);r.length%2&&("left"===t.hexPad?r="0"+r:"right"===t.hexPad?r+="0":v.throwArgumentError("hex data is odd-length","value",e));const n=[];for(let e=0;e_(e))),r=t.reduce(((e,t)=>e+t.length),0),n=new Uint8Array(r);return t.reduce(((e,t)=>(n.set(t,e),e+t.length)),0),A(n)}function T(e){let t=_(e);if(0===t.length)return t;let r=0;for(;rt&&v.throwArgumentError("value out of range","value",arguments[0]);const r=new Uint8Array(t);return r.set(e,t-e.length),A(r)}function P(e,t){return!("string"!=typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&(!t||e.length===2+2*t)}const I="0123456789abcdef";function O(e,t){if(t||(t={}),"number"==typeof e){v.checkSafeUint53(e,"invalid hexlify value");let t="";for(;e;)t=I[15&e]+t,e=Math.floor(e/16);return t.length?(t.length%2&&(t="0"+t),"0x"+t):"0x00"}if("bigint"==typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),w(e))return e.toHexString();if(P(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":v.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(E(e)){let t="0x";for(let r=0;r>4]+I[15&n]}return t}return v.throwArgumentError("invalid hexlify value","value",e)}function R(e){if("string"!=typeof e)e=O(e);else if(!P(e)||e.length%2)return null;return(e.length-2)/2}function C(e,t,r){return"string"!=typeof e?e=O(e):(!P(e)||e.length%2)&&v.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)}function B(e){let t="0x";return e.forEach((e=>{t+=O(e).substring(2)})),t}function N(e){const t=L(O(e,{hexPad:"left"}));return"0x"===t?"0x0":t}function L(e){"string"!=typeof e&&(e=O(e)),P(e)||v.throwArgumentError("invalid hex string","value",e),e=e.substring(2);let t=0;for(;t2*t+2&&v.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function F(e){const t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(S(e)){let r=_(e);64===r.length?(t.v=27+(r[32]>>7),r[32]&=127,t.r=O(r.slice(0,32)),t.s=O(r.slice(32,64))):65===r.length?(t.r=O(r.slice(0,32)),t.s=O(r.slice(32,64)),t.v=r[64]):v.throwArgumentError("invalid signature string","signature",e),t.v<27&&(0===t.v||1===t.v?t.v+=27:v.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=O(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){const r=x(_(t._vs),32);t._vs=O(r);const n=r[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=n:t.recoveryParam!==n&&v.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),r[0]&=127;const i=O(r);null==t.s?t.s=i:t.s!==i&&v.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?v.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{const r=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==r&&v.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&P(t.r)?t.r=U(t.r,32):v.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&P(t.s)?t.s=U(t.s,32):v.throwArgumentError("signature missing or invalid s","signature",e);const r=_(t.s);r[0]>=128&&v.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(r[0]|=128);const n=O(r);t._vs&&(P(t._vs)||v.throwArgumentError("signature invalid _vs","signature",e),t._vs=U(t._vs,32)),null==t._vs?t._vs=n:t._vs!==n&&v.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t.yParityAndS=t._vs,t.compact=t.r+t.yParityAndS.substring(2),t}function D(e){return O(M([(e=F(e)).r,e.s,e.recoveryParam?"0x1c":"0x1b"]))}var j=r(13550),H=r.n(j);const J="bignumber/5.7.0";var z=H().BN;const G=new b(J),q={},K=9007199254740991;let V=!1;class X{constructor(e,t){e!==q&&G.throwError("cannot call constructor directly; use BigNumber.from",b.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=t,this._isBigNumber=!0,Object.freeze(this)}fromTwos(e){return W(Z(this).fromTwos(e))}toTwos(e){return W(Z(this).toTwos(e))}abs(){return"-"===this._hex[0]?X.from(this._hex.substring(1)):this}add(e){return W(Z(this).add(Z(e)))}sub(e){return W(Z(this).sub(Z(e)))}div(e){return X.from(e).isZero()&&Y("division-by-zero","div"),W(Z(this).div(Z(e)))}mul(e){return W(Z(this).mul(Z(e)))}mod(e){const t=Z(e);return t.isNeg()&&Y("division-by-zero","mod"),W(Z(this).umod(t))}pow(e){const t=Z(e);return t.isNeg()&&Y("negative-power","pow"),W(Z(this).pow(t))}and(e){const t=Z(e);return(this.isNegative()||t.isNeg())&&Y("unbound-bitwise-result","and"),W(Z(this).and(t))}or(e){const t=Z(e);return(this.isNegative()||t.isNeg())&&Y("unbound-bitwise-result","or"),W(Z(this).or(t))}xor(e){const t=Z(e);return(this.isNegative()||t.isNeg())&&Y("unbound-bitwise-result","xor"),W(Z(this).xor(t))}mask(e){return(this.isNegative()||e<0)&&Y("negative-width","mask"),W(Z(this).maskn(e))}shl(e){return(this.isNegative()||e<0)&&Y("negative-width","shl"),W(Z(this).shln(e))}shr(e){return(this.isNegative()||e<0)&&Y("negative-width","shr"),W(Z(this).shrn(e))}eq(e){return Z(this).eq(Z(e))}lt(e){return Z(this).lt(Z(e))}lte(e){return Z(this).lte(Z(e))}gt(e){return Z(this).gt(Z(e))}gte(e){return Z(this).gte(Z(e))}isNegative(){return"-"===this._hex[0]}isZero(){return Z(this).isZero()}toNumber(){try{return Z(this).toNumber()}catch(e){Y("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch(e){}return G.throwError("this platform does not support BigInt",b.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(10===arguments[0]?V||(V=!0,G.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?G.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",b.errors.UNEXPECTED_ARGUMENT,{}):G.throwError("BigNumber.toString does not accept parameters",b.errors.UNEXPECTED_ARGUMENT,{})),Z(this).toString(10)}toHexString(){return this._hex}toJSON(e){return{type:"BigNumber",hex:this.toHexString()}}static from(e){if(e instanceof X)return e;if("string"==typeof e)return e.match(/^-?0x[0-9a-f]+$/i)?new X(q,Q(e)):e.match(/^-?[0-9]+$/)?new X(q,Q(new z(e))):G.throwArgumentError("invalid BigNumber string","value",e);if("number"==typeof e)return e%1&&Y("underflow","BigNumber.from",e),(e>=K||e<=-K)&&Y("overflow","BigNumber.from",e),X.from(String(e));const t=e;if("bigint"==typeof t)return X.from(t.toString());if(E(t))return X.from(O(t));if(t)if(t.toHexString){const e=t.toHexString();if("string"==typeof e)return X.from(e)}else{let e=t._hex;if(null==e&&"BigNumber"===t.type&&(e=t.hex),"string"==typeof e&&(P(e)||"-"===e[0]&&P(e.substring(1))))return X.from(e)}return G.throwArgumentError("invalid BigNumber value","value",e)}static isBigNumber(e){return!(!e||!e._isBigNumber)}}function Q(e){if("string"!=typeof e)return Q(e.toString(16));if("-"===e[0])return"-"===(e=e.substring(1))[0]&&G.throwArgumentError("invalid hex","value",e),"0x00"===(e=Q(e))?e:"-"+e;if("0x"!==e.substring(0,2)&&(e="0x"+e),"0x"===e)return"0x00";for(e.length%2&&(e="0x0"+e.substring(2));e.length>4&&"0x00"===e.substring(0,4);)e="0x"+e.substring(4);return e}function W(e){return X.from(Q(e))}function Z(e){const t=X.from(e).toHexString();return"-"===t[0]?new z("-"+t.substring(3),16):new z(t.substring(2),16)}function Y(e,t,r){const n={fault:e,operation:t};return null!=r&&(n.value=r),G.throwError(e,b.errors.NUMERIC_FAULT,n)}var $=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ee=new b("properties/5.7.0");function te(e,t,r){Object.defineProperty(e,t,{enumerable:!0,value:r,writable:!1})}function re(e,t){for(let r=0;r<32;r++){if(e[t])return e[t];if(!e.prototype||"object"!=typeof e.prototype)break;e=Object.getPrototypeOf(e.prototype).constructor}return null}function ne(e){return $(this,void 0,void 0,(function*(){const t=Object.keys(e).map((t=>{const r=e[t];return Promise.resolve(r).then((e=>({key:t,value:e})))}));return(yield Promise.all(t)).reduce(((e,t)=>(e[t.key]=t.value,e)),{})}))}function ie(e,t){e&&"object"==typeof e||ee.throwArgumentError("invalid object","object",e),Object.keys(e).forEach((r=>{t[r]||ee.throwArgumentError("invalid object key - "+r,"transaction:"+r,e)}))}function oe(e){const t={};for(const r in e)t[r]=e[r];return t}const ae={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function se(e){if(null==e||ae[typeof e])return!0;if(Array.isArray(e)||"object"==typeof e){if(!Object.isFrozen(e))return!1;const t=Object.keys(e);for(let r=0;rce(e))));if("object"==typeof e){const t={};for(const r in e){const n=e[r];void 0!==n&&te(t,r,ce(n))}return t}return ee.throwArgumentError("Cannot deepCopy "+typeof e,"object",e)}function ce(e){return ue(e)}class le{constructor(e){for(const t in e)this[t]=ce(e[t])}}const fe="abi/5.7.0",he=new b(fe);function de(e){const t=[],r=function(e,n){if(Array.isArray(n))for(let i in n){const o=e.slice();o.push(i);try{r(o,n[i])}catch(e){t.push({path:o,error:e})}}};return r([],e),t}class pe{constructor(e,t,r,n){this.name=e,this.type=t,this.localName=r,this.dynamic=n}_throwError(e,t){he.throwArgumentError(e,this.localName,t)}}class me{constructor(e){te(this,"wordSize",e||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(e)}get data(){return B(this._data)}get length(){return this._dataLength}_writeData(e){return this._data.push(e),this._dataLength+=e.length,e.length}appendWriter(e){return this._writeData(M(e._data))}writeBytes(e){let t=_(e);const r=t.length%this.wordSize;return r&&(t=M([t,this._padding.slice(r)])),this._writeData(t)}_getValue(e){let t=_(X.from(e));return t.length>this.wordSize&&he.throwError("value out-of-bounds",b.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=M([this._padding.slice(t.length%this.wordSize),t])),t}writeValue(e){return this._writeData(this._getValue(e))}writeUpdatableValue(){const e=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,t=>{this._data[e]=this._getValue(t)}}}class ye{constructor(e,t,r,n){te(this,"_data",_(e)),te(this,"wordSize",t||32),te(this,"_coerceFunc",r),te(this,"allowLoose",n),this._offset=0}get data(){return O(this._data)}get consumed(){return this._offset}static coerce(e,t){let r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}coerce(e,t){return this._coerceFunc?this._coerceFunc(e,t):ye.coerce(e,t)}_peekBytes(e,t,r){let n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:he.throwError("data out-of-bounds",b.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}subReader(e){return new ye(this._data.slice(this._offset+e),this.wordSize,this._coerceFunc,this.allowLoose)}readBytes(e,t){let r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}readValue(){return X.from(this.readBytes(this.wordSize))}}var ge=r(91094),be=r.n(ge);function ve(e){return"0x"+be().keccak_256(_(e))}const we=new b("rlp/5.7.0");function Ae(e){const t=[];for(;e;)t.unshift(255&e),e>>=8;return t}function Se(e,t,r){let n=0;for(let i=0;it+1+n&&we.throwError("child data too short",b.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:i}}function Me(e,t){if(0===e.length&&we.throwError("data too short",b.errors.BUFFER_OVERRUN,{}),e[t]>=248){const r=e[t]-247;t+1+r>e.length&&we.throwError("data short segment too short",b.errors.BUFFER_OVERRUN,{});const n=Se(e,t+1,r);return t+1+r+n>e.length&&we.throwError("data long segment too short",b.errors.BUFFER_OVERRUN,{}),_e(e,t,t+1+r,r+n)}if(e[t]>=192){const r=e[t]-192;return t+1+r>e.length&&we.throwError("data array too short",b.errors.BUFFER_OVERRUN,{}),_e(e,t,t+1,r)}if(e[t]>=184){const r=e[t]-183;t+1+r>e.length&&we.throwError("data array too short",b.errors.BUFFER_OVERRUN,{});const n=Se(e,t+1,r);t+1+r+n>e.length&&we.throwError("data array too short",b.errors.BUFFER_OVERRUN,{});return{consumed:1+r+n,result:O(e.slice(t+1+r,t+1+r+n))}}if(e[t]>=128){const r=e[t]-128;t+1+r>e.length&&we.throwError("data too short",b.errors.BUFFER_OVERRUN,{});return{consumed:1+r,result:O(e.slice(t+1,t+1+r))}}return{consumed:1,result:O(e[t])}}function Te(e){const t=_(e),r=Me(t,0);return r.consumed!==t.length&&we.throwArgumentError("invalid rlp data","data",e),r.result}const xe=new b("address/5.7.0");function Pe(e){P(e,20)||xe.throwArgumentError("invalid address","address",e);const t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40);for(let e=0;e<40;e++)r[e]=t[e].charCodeAt(0);const n=_(ve(r));for(let e=0;e<40;e+=2)n[e>>1]>>4>=8&&(t[e]=t[e].toUpperCase()),(15&n[e>>1])>=8&&(t[e+1]=t[e+1].toUpperCase());return"0x"+t.join("")}const Ie={};for(let e=0;e<10;e++)Ie[String(e)]=String(e);for(let e=0;e<26;e++)Ie[String.fromCharCode(65+e)]=String(10+e);const Oe=Math.floor((Re=9007199254740991,Math.log10?Math.log10(Re):Math.log(Re)/Math.LN10));var Re;function Ce(e){let t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((e=>Ie[e])).join("");for(;t.length>=Oe;){let e=t.substring(0,Oe);t=parseInt(e,10)%97+t.substring(e.length)}let r=String(98-parseInt(t,10)%97);for(;r.length<2;)r="0"+r;return r}function Be(e){let t=null;if("string"!=typeof e&&xe.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=Pe(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&xe.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==Ce(e)&&xe.throwArgumentError("bad icap checksum","address",e),r=e.substring(4),t=new z(r,36).toString(16);t.length<40;)t="0"+t;t=Pe("0x"+t)}else xe.throwArgumentError("invalid address","address",e);var r;return t}function Ne(e){try{return Be(e),!0}catch(e){}return!1}function Le(e){let t=(r=Be(e).substring(2),new z(r,16).toString(36)).toUpperCase();for(var r;t.length<30;)t="0"+t;return"XE"+Ce("XE00"+t)+t}function Ue(e){let t=null;try{t=Be(e.from)}catch(t){xe.throwArgumentError("missing from address","transaction",e)}return Be(C(ve(Ee([t,T(_(X.from(e.nonce).toHexString()))])),12))}function Fe(e,t,r){return 32!==R(t)&&xe.throwArgumentError("salt must be 32 bytes","salt",t),32!==R(r)&&xe.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),Be(C(ve(M(["0xff",Be(e),t,r])),12))}const De=new b("strings/5.7.0");var je,He;function Je(e,t,r,n,i){if(e===He.BAD_PREFIX||e===He.UNEXPECTED_CONTINUE){let e=0;for(let n=t+1;n>6==2;n++)e++;return e}return e===He.OVERRUN?r.length-t-1:0}!function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(je||(je={})),function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(He||(He={}));const ze=Object.freeze({error:function(e,t,r,n,i){return De.throwArgumentError(`invalid codepoint at offset ${t}; ${e}`,"bytes",r)},ignore:Je,replace:function(e,t,r,n,i){return e===He.OVERLONG?(n.push(i),0):(n.push(65533),Je(e,t,r))}});function Ge(e,t){null==t&&(t=ze.error),e=_(e);const r=[];let n=0;for(;n>7==0){r.push(i);continue}let o=null,a=null;if(192==(224&i))o=1,a=127;else if(224==(240&i))o=2,a=2047;else{if(240!=(248&i)){n+=t(128==(192&i)?He.UNEXPECTED_CONTINUE:He.BAD_PREFIX,n-1,e,r);continue}o=3,a=65535}if(n-1+o>=e.length){n+=t(He.OVERRUN,n-1,e,r);continue}let s=i&(1<<8-o-1)-1;for(let i=0;i1114111?n+=t(He.OUT_OF_RANGE,n-1-o,e,r,s):s>=55296&&s<=57343?n+=t(He.UTF16_SURROGATE,n-1-o,e,r,s):s<=a?n+=t(He.OVERLONG,n-1-o,e,r,s):r.push(s))}return r}function qe(e,t=je.current){t!=je.current&&(De.checkNormalize(),e=e.normalize(t));let r=[];for(let t=0;t>6|192),r.push(63&n|128);else if(55296==(64512&n)){t++;const i=e.charCodeAt(t);if(t>=e.length||56320!=(64512&i))throw new Error("invalid utf-8 string");const o=65536+((1023&n)<<10)+(1023&i);r.push(o>>18|240),r.push(o>>12&63|128),r.push(o>>6&63|128),r.push(63&o|128)}else r.push(n>>12|224),r.push(n>>6&63|128),r.push(63&n|128)}return _(r)}function Ke(e){const t="0000"+e.toString(16);return"\\u"+t.substring(t.length-4)}function Ve(e,t){return'"'+Ge(e,t).map((e=>{if(e<256){switch(e){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(e>=32&&e<127)return String.fromCharCode(e)}return e<=65535?Ke(e):Ke(55296+((e-=65536)>>10&1023))+Ke(56320+(1023&e))})).join("")+'"'}function Xe(e){return e.map((e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e))))).join("")}function Qe(e,t){return Xe(Ge(e,t))}function We(e,t=je.current){return Ge(qe(e,t))}function Ze(e){return ve(qe(e))}class Ye extends pe{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,t){try{t=Be(t)}catch(e){this._throwError(e.message,t)}return e.writeValue(t)}decode(e){return Be(U(e.readValue().toHexString(),20))}}class $e extends pe{constructor(e){super(e.name,e.type,void 0,e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,t){return this.coder.encode(e,t)}decode(e){return this.coder.decode(e)}}const et=new b(fe);function tt(e,t,r){let n=null;if(Array.isArray(r))n=r;else if(r&&"object"==typeof r){let e={};n=t.map((t=>{const n=t.localName;return n||et.throwError("cannot encode object for signature with missing names",b.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]&&et.throwError("cannot encode object for signature with duplicate names",b.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]=!0,r[n]}))}else et.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&et.throwArgumentError("types/value length mismatch","tuple",r);let i=new me(e.wordSize),o=new me(e.wordSize),a=[];t.forEach(((e,t)=>{let r=n[t];if(e.dynamic){let t=o.length;e.encode(o,r);let n=i.writeUpdatableValue();a.push((e=>{n(e+t)}))}else e.encode(i,r)})),a.forEach((e=>{e(i.length)}));let s=e.appendWriter(i);return s+=e.appendWriter(o),s}function rt(e,t){let r=[],n=e.subReader(0);t.forEach((t=>{let i=null;if(t.dynamic){let r=e.readValue(),o=n.subReader(r.toNumber());try{i=t.decode(o)}catch(e){if(e.code===b.errors.BUFFER_OVERRUN)throw e;i=e,i.baseType=t.name,i.name=t.localName,i.type=t.type}}else try{i=t.decode(e)}catch(e){if(e.code===b.errors.BUFFER_OVERRUN)throw e;i=e,i.baseType=t.name,i.name=t.localName,i.type=t.type}null!=i&&r.push(i)}));const i=t.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach(((e,t)=>{let n=e.localName;if(!n||1!==i[n])return;if("length"===n&&(n="_length"),null!=r[n])return;const o=r[t];o instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:()=>{throw o}}):r[n]=o}));for(let e=0;e{throw t}})}return Object.freeze(r)}class nt extends pe{constructor(e,t,r){super("array",e.type+"["+(t>=0?t:"")+"]",r,-1===t||e.dynamic),this.coder=e,this.length=t}defaultValue(){const e=this.coder.defaultValue(),t=[];for(let r=0;re._data.length&&et.throwError("insufficient data length",b.errors.BUFFER_OVERRUN,{length:e._data.length,count:t}));let r=[];for(let e=0;e{e.dynamic&&(r=!0),n.push(e.type)}));super("tuple","tuple("+n.join(",")+")",t,r),this.coders=e}defaultValue(){const e=[];this.coders.forEach((t=>{e.push(t.defaultValue())}));const t=this.coders.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach(((r,n)=>{let i=r.localName;i&&1===t[i]&&("length"===i&&(i="_length"),null==e[i]&&(e[i]=e[n]))})),Object.freeze(e)}encode(e,t){return tt(e,this.coders,t)}decode(e){return e.coerce(this.name,rt(e,this.coders))}}const wt=new b(fe),At={};let St={calldata:!0,memory:!0,storage:!0},kt={calldata:!0,memory:!0};function Et(e,t){if("bytes"===e||"string"===e){if(St[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&kt[t])return!0;return(St[t]||"payable"===t)&&wt.throwArgumentError("invalid modifier","name",t),!1}function _t(e,t){for(let r in t)te(e,r,t[r])}const Mt=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),Tt=new RegExp(/^(.*)\[([0-9]*)\]$/);class xt{constructor(e,t){e!==At&&wt.throwError("use fromString",b.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),_t(this,t);let r=this.type.match(Tt);_t(this,r?{arrayLength:parseInt(r[2]||"-1"),arrayChildren:xt.fromObject({type:r[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json){let t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((t=>JSON.parse(t.format(e))))),JSON.stringify(t)}let t="";return"array"===this.baseType?(t+=this.arrayChildren.format(e),t+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==Mt.sighash&&(t+=this.type),t+="("+this.components.map((t=>t.format(e))).join(e===Mt.full?", ":",")+")"):t+=this.type,e!==Mt.sighash&&(!0===this.indexed&&(t+=" indexed"),e===Mt.full&&this.name&&(t+=" "+this.name)),t}static from(e,t){return"string"==typeof e?xt.fromString(e,t):xt.fromObject(e)}static fromObject(e){return xt.isParamType(e)?e:new xt(At,{name:e.name||null,type:Dt(e.type),indexed:null==e.indexed?null:!!e.indexed,components:e.components?e.components.map(xt.fromObject):null})}static fromString(e,t){return r=function(e,t){let r=e;function n(t){wt.throwArgumentError(`unexpected character at position ${t}`,"param",e)}function i(e){let r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");let o={type:"",name:"",state:{allowType:!0}},a=o;for(let r=0;rxt.fromString(e,t)))}class It{constructor(e,t){e!==At&&wt.throwError("use a static from method",b.errors.UNSUPPORTED_OPERATION,{operation:"new Fragment()"}),_t(this,t),this._isFragment=!0,Object.freeze(this)}static from(e){return It.isFragment(e)?e:"string"==typeof e?It.fromString(e):It.fromObject(e)}static fromObject(e){if(It.isFragment(e))return e;switch(e.type){case"function":return Lt.fromObject(e);case"event":return Ot.fromObject(e);case"constructor":return Nt.fromObject(e);case"error":return Ft.fromObject(e);case"fallback":case"receive":return null}return wt.throwArgumentError("invalid fragment object","value",e)}static fromString(e){return"event"===(e=(e=(e=e.replace(/\s/g," ")).replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," ")).trim()).split(" ")[0]?Ot.fromString(e.substring(5).trim()):"function"===e.split(" ")[0]?Lt.fromString(e.substring(8).trim()):"constructor"===e.split("(")[0].trim()?Nt.fromString(e.trim()):"error"===e.split(" ")[0]?Ft.fromString(e.substring(5).trim()):wt.throwArgumentError("unsupported fragment","value",e)}static isFragment(e){return!(!e||!e._isFragment)}}class Ot extends It{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Mt.sighash&&(t+="event "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ",e!==Mt.sighash&&this.anonymous&&(t+="anonymous "),t.trim()}static from(e){return"string"==typeof e?Ot.fromString(e):Ot.fromObject(e)}static fromObject(e){if(Ot.isEventFragment(e))return e;"event"!==e.type&&wt.throwArgumentError("invalid event object","value",e);const t={name:Ht(e.name),anonymous:e.anonymous,inputs:e.inputs?e.inputs.map(xt.fromObject):[],type:"event"};return new Ot(At,t)}static fromString(e){let t=e.match(Jt);t||wt.throwArgumentError("invalid event string","value",e);let r=!1;return t[3].split(" ").forEach((e=>{switch(e.trim()){case"anonymous":r=!0;break;case"":break;default:wt.warn("unknown modifier: "+e)}})),Ot.fromObject({name:t[1].trim(),anonymous:r,inputs:Pt(t[2],!0),type:"event"})}static isEventFragment(e){return e&&e._isFragment&&"event"===e.type}}function Rt(e,t){t.gas=null;let r=e.split("@");return 1!==r.length?(r.length>2&&wt.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||wt.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=X.from(r[1]),r[0]):e}function Ct(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((e=>{switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function Bt(e){let t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&wt.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&wt.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||wt.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&wt.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&wt.throwArgumentError("unable to determine stateMutability","value",e),t}class Nt extends It{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});e===Mt.sighash&&wt.throwError("cannot format a constructor for sighash",b.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});let t="constructor("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}static from(e){return"string"==typeof e?Nt.fromString(e):Nt.fromObject(e)}static fromObject(e){if(Nt.isConstructorFragment(e))return e;"constructor"!==e.type&&wt.throwArgumentError("invalid constructor object","value",e);let t=Bt(e);t.constant&&wt.throwArgumentError("constructor cannot be constant","value",e);const r={name:null,type:e.type,inputs:e.inputs?e.inputs.map(xt.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?X.from(e.gas):null};return new Nt(At,r)}static fromString(e){let t={type:"constructor"},r=(e=Rt(e,t)).match(Jt);return r&&"constructor"===r[1].trim()||wt.throwArgumentError("invalid constructor string","value",e),t.inputs=Pt(r[2].trim(),!1),Ct(r[3].trim(),t),Nt.fromObject(t)}static isConstructorFragment(e){return e&&e._isFragment&&"constructor"===e.type}}class Lt extends Nt{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e)))),outputs:this.outputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Mt.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ",e!==Mt.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((t=>t.format(e))).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}static from(e){return"string"==typeof e?Lt.fromString(e):Lt.fromObject(e)}static fromObject(e){if(Lt.isFunctionFragment(e))return e;"function"!==e.type&&wt.throwArgumentError("invalid function object","value",e);let t=Bt(e);const r={type:e.type,name:Ht(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(xt.fromObject):[],outputs:e.outputs?e.outputs.map(xt.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?X.from(e.gas):null};return new Lt(At,r)}static fromString(e){let t={type:"function"},r=(e=Rt(e,t)).split(" returns ");r.length>2&&wt.throwArgumentError("invalid function string","value",e);let n=r[0].match(Jt);if(n||wt.throwArgumentError("invalid function signature","value",e),t.name=n[1].trim(),t.name&&Ht(t.name),t.inputs=Pt(n[2],!1),Ct(n[3].trim(),t),r.length>1){let n=r[1].match(Jt);""==n[1].trim()&&""==n[3].trim()||wt.throwArgumentError("unexpected tokens","value",e),t.outputs=Pt(n[2],!1)}else t.outputs=[];return Lt.fromObject(t)}static isFunctionFragment(e){return e&&e._isFragment&&"function"===e.type}}function Ut(e){const t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||wt.throwArgumentError(`cannot specify user defined ${t} error`,"fragment",e),e}class Ft extends It{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Mt.sighash&&(t+="error "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ",t.trim()}static from(e){return"string"==typeof e?Ft.fromString(e):Ft.fromObject(e)}static fromObject(e){if(Ft.isErrorFragment(e))return e;"error"!==e.type&&wt.throwArgumentError("invalid error object","value",e);const t={type:e.type,name:Ht(e.name),inputs:e.inputs?e.inputs.map(xt.fromObject):[]};return Ut(new Ft(At,t))}static fromString(e){let t={type:"error"},r=e.match(Jt);return r||wt.throwArgumentError("invalid error signature","value",e),t.name=r[1].trim(),t.name&&Ht(t.name),t.inputs=Pt(r[2],!1),Ut(Ft.fromObject(t))}static isErrorFragment(e){return e&&e._isFragment&&"error"===e.type}}function Dt(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}const jt=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function Ht(e){return e&&e.match(jt)||wt.throwArgumentError(`invalid identifier "${e}"`,"value",e),e}const Jt=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");const zt=new b(fe),Gt=new RegExp(/^bytes([0-9]*)$/),qt=new RegExp(/^(u?int)([0-9]*)$/);class Kt{constructor(e){te(this,"coerceFunc",e||null)}_getCoder(e){switch(e.baseType){case"address":return new Ye(e.name);case"bool":return new it(e.name);case"string":return new bt(e.name);case"bytes":return new at(e.name);case"array":return new nt(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new vt((e.components||[]).map((e=>this._getCoder(e))),e.name);case"":return new ut(e.name)}let t=e.type.match(qt);if(t){let r=parseInt(t[2]||"256");return(0===r||r>256||r%8!=0)&&zt.throwArgumentError("invalid "+t[1]+" bit length","param",e),new gt(r/8,"int"===t[1],e.name)}if(t=e.type.match(Gt),t){let r=parseInt(t[1]);return(0===r||r>32)&&zt.throwArgumentError("invalid bytes length","param",e),new st(r,e.name)}return zt.throwArgumentError("invalid type","type",e.type)}_getWordSize(){return 32}_getReader(e,t){return new ye(e,this._getWordSize(),this.coerceFunc,t)}_getWriter(){return new me(this._getWordSize())}getDefaultValue(e){const t=e.map((e=>this._getCoder(xt.from(e))));return new vt(t,"_").defaultValue()}encode(e,t){e.length!==t.length&&zt.throwError("types/values length mismatch",b.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});const r=e.map((e=>this._getCoder(xt.from(e)))),n=new vt(r,"_"),i=this._getWriter();return n.encode(i,t),i.data}decode(e,t,r){const n=e.map((e=>this._getCoder(xt.from(e))));return new vt(n,"_").decode(this._getReader(_(t),r))}}const Vt=new Kt,Xt=new b(fe);class Qt extends le{}class Wt extends le{}class Zt extends le{}class Yt extends le{static isIndexed(e){return!(!e||!e._isIndexed)}}const $t={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function er(e,t){const r=new Error(`deferred error during ABI decoding triggered accessing ${e}`);return r.error=t,r}class tr{constructor(e){let t=[];t="string"==typeof e?JSON.parse(e):e,te(this,"fragments",t.map((e=>It.from(e))).filter((e=>null!=e))),te(this,"_abiCoder",re(new.target,"getAbiCoder")()),te(this,"functions",{}),te(this,"errors",{}),te(this,"events",{}),te(this,"structs",{}),this.fragments.forEach((e=>{let t=null;switch(e.type){case"constructor":return this.deploy?void Xt.warn("duplicate definition - constructor"):void te(this,"deploy",e);case"function":t=this.functions;break;case"event":t=this.events;break;case"error":t=this.errors;break;default:return}let r=e.format();t[r]?Xt.warn("duplicate definition - "+r):t[r]=e})),this.deploy||te(this,"deploy",Nt.from({payable:!1,type:"constructor"})),te(this,"_isInterface",!0)}format(e){e||(e=Mt.full),e===Mt.sighash&&Xt.throwArgumentError("interface does not support formatting sighash","format",e);const t=this.fragments.map((t=>t.format(e)));return e===Mt.json?JSON.stringify(t.map((e=>JSON.parse(e)))):t}static getAbiCoder(){return Vt}static getAddress(e){return Be(e)}static getSighash(e){return C(Ze(e.format()),0,4)}static getEventTopic(e){return Ze(e.format())}getFunction(e){if(P(e)){for(const t in this.functions)if(e===this.getSighash(t))return this.functions[t];Xt.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.functions).filter((e=>e.split("(")[0]===t));return 0===r.length?Xt.throwArgumentError("no matching function","name",t):r.length>1&&Xt.throwArgumentError("multiple matching functions","name",t),this.functions[r[0]]}const t=this.functions[Lt.fromString(e).format()];return t||Xt.throwArgumentError("no matching function","signature",e),t}getEvent(e){if(P(e)){const t=e.toLowerCase();for(const e in this.events)if(t===this.getEventTopic(e))return this.events[e];Xt.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.events).filter((e=>e.split("(")[0]===t));return 0===r.length?Xt.throwArgumentError("no matching event","name",t):r.length>1&&Xt.throwArgumentError("multiple matching events","name",t),this.events[r[0]]}const t=this.events[Ot.fromString(e).format()];return t||Xt.throwArgumentError("no matching event","signature",e),t}getError(e){if(P(e)){const t=re(this.constructor,"getSighash");for(const r in this.errors){if(e===t(this.errors[r]))return this.errors[r]}Xt.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.errors).filter((e=>e.split("(")[0]===t));return 0===r.length?Xt.throwArgumentError("no matching error","name",t):r.length>1&&Xt.throwArgumentError("multiple matching errors","name",t),this.errors[r[0]]}const t=this.errors[Lt.fromString(e).format()];return t||Xt.throwArgumentError("no matching error","signature",e),t}getSighash(e){if("string"==typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(e){throw t}}return re(this.constructor,"getSighash")(e)}getEventTopic(e){return"string"==typeof e&&(e=this.getEvent(e)),re(this.constructor,"getEventTopic")(e)}_decodeParams(e,t){return this._abiCoder.decode(e,t)}_encodeParams(e,t){return this._abiCoder.encode(e,t)}encodeDeploy(e){return this._encodeParams(this.deploy.inputs,e||[])}decodeErrorResult(e,t){"string"==typeof e&&(e=this.getError(e));const r=_(t);return O(r.slice(0,4))!==this.getSighash(e)&&Xt.throwArgumentError(`data signature does not match error ${e.name}.`,"data",O(r)),this._decodeParams(e.inputs,r.slice(4))}encodeErrorResult(e,t){return"string"==typeof e&&(e=this.getError(e)),O(M([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionData(e,t){"string"==typeof e&&(e=this.getFunction(e));const r=_(t);return O(r.slice(0,4))!==this.getSighash(e)&&Xt.throwArgumentError(`data signature does not match function ${e.name}.`,"data",O(r)),this._decodeParams(e.inputs,r.slice(4))}encodeFunctionData(e,t){return"string"==typeof e&&(e=this.getFunction(e)),O(M([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionResult(e,t){"string"==typeof e&&(e=this.getFunction(e));let r=_(t),n=null,i="",o=null,a=null,s=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(e){}break;case 4:{const e=O(r.slice(0,4)),t=$t[e];if(t)o=this._abiCoder.decode(t.inputs,r.slice(4)),a=t.name,s=t.signature,t.reason&&(n=o[0]),"Error"===a?i=`; VM Exception while processing transaction: reverted with reason string ${JSON.stringify(o[0])}`:"Panic"===a&&(i=`; VM Exception while processing transaction: reverted with panic code ${o[0]}`);else try{const t=this.getError(e);o=this._abiCoder.decode(t.inputs,r.slice(4)),a=t.name,s=t.format()}catch(e){}break}}return Xt.throwError("call revert exception"+i,b.errors.CALL_EXCEPTION,{method:e.format(),data:O(t),errorArgs:o,errorName:a,errorSignature:s,reason:n})}encodeFunctionResult(e,t){return"string"==typeof e&&(e=this.getFunction(e)),O(this._abiCoder.encode(e.outputs,t||[]))}encodeFilterTopics(e,t){"string"==typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&Xt.throwError("too many arguments for "+e.format(),b.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});let r=[];e.anonymous||r.push(this.getEventTopic(e));const n=(e,t)=>"string"===e.type?Ze(t):"bytes"===e.type?ve(O(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=X.from(t).toHexString()),"address"===e.type&&this._abiCoder.encode(["address"],[t]),U(O(t),32));for(t.forEach(((t,i)=>{let o=e.inputs[i];o.indexed?null==t?r.push(null):"array"===o.baseType||"tuple"===o.baseType?Xt.throwArgumentError("filtering with tuples or arrays not supported","contract."+o.name,t):Array.isArray(t)?r.push(t.map((e=>n(o,e)))):r.push(n(o,t)):null!=t&&Xt.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+o.name,t)}));r.length&&null===r[r.length-1];)r.pop();return r}encodeEventLog(e,t){"string"==typeof e&&(e=this.getEvent(e));const r=[],n=[],i=[];return e.anonymous||r.push(this.getEventTopic(e)),t.length!==e.inputs.length&&Xt.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach(((e,o)=>{const a=t[o];if(e.indexed)if("string"===e.type)r.push(Ze(a));else if("bytes"===e.type)r.push(ve(a));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");r.push(this._abiCoder.encode([e.type],[a]))}else n.push(e),i.push(a)})),{data:this._abiCoder.encode(n,i),topics:r}}decodeEventLog(e,t,r){if("string"==typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){let t=this.getEventTopic(e);P(r[0],32)&&r[0].toLowerCase()===t||Xt.throwError("fragment/topic mismatch",b.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:t,value:r[0]}),r=r.slice(1)}let n=[],i=[],o=[];e.inputs.forEach(((e,t)=>{e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(n.push(xt.fromObject({type:"bytes32",name:e.name})),o.push(!0)):(n.push(e),o.push(!1)):(i.push(e),o.push(!1))}));let a=null!=r?this._abiCoder.decode(n,M(r)):null,s=this._abiCoder.decode(i,t,!0),u=[],c=0,l=0;e.inputs.forEach(((e,t)=>{if(e.indexed)if(null==a)u[t]=new Yt({_isIndexed:!0,hash:null});else if(o[t])u[t]=new Yt({_isIndexed:!0,hash:a[l++]});else try{u[t]=a[l++]}catch(e){u[t]=e}else try{u[t]=s[c++]}catch(e){u[t]=e}if(e.name&&null==u[e.name]){const r=u[t];r instanceof Error?Object.defineProperty(u,e.name,{enumerable:!0,get:()=>{throw er(`property ${JSON.stringify(e.name)}`,r)}}):u[e.name]=r}}));for(let e=0;e{throw er(`index ${e}`,t)}})}return Object.freeze(u)}parseTransaction(e){let t=this.getFunction(e.data.substring(0,10).toLowerCase());return t?new Wt({args:this._abiCoder.decode(t.inputs,"0x"+e.data.substring(10)),functionFragment:t,name:t.name,signature:t.format(),sighash:this.getSighash(t),value:X.from(e.value||"0")}):null}parseLog(e){let t=this.getEvent(e.topics[0]);return!t||t.anonymous?null:new Qt({eventFragment:t,name:t.name,signature:t.format(),topic:this.getEventTopic(t),args:this.decodeEventLog(t,e.data,e.topics)})}parseError(e){const t=O(e);let r=this.getError(t.substring(0,10).toLowerCase());return r?new Zt({args:this._abiCoder.decode(r.inputs,"0x"+t.substring(10)),errorFragment:r,name:r.name,signature:r.format(),sighash:this.getSighash(r)}):null}static isInterface(e){return!(!e||!e._isInterface)}}var rr=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const nr=new b("abstract-provider/5.7.0");class ir extends le{static isForkEvent(e){return!(!e||!e._isForkEvent)}}class or{constructor(){nr.checkAbstract(new.target,or),te(this,"_isProvider",!0)}getFeeData(){return rr(this,void 0,void 0,(function*(){const{block:e,gasPrice:t}=yield ne({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch((e=>null))});let r=null,n=null,i=null;return e&&e.baseFeePerGas&&(r=e.baseFeePerGas,i=X.from("1500000000"),n=e.baseFeePerGas.mul(2).add(i)),{lastBaseFeePerGas:r,maxFeePerGas:n,maxPriorityFeePerGas:i,gasPrice:t}}))}addListener(e,t){return this.on(e,t)}removeListener(e,t){return this.off(e,t)}static isProvider(e){return!(!e||!e._isProvider)}}var ar=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const sr=new b("abstract-signer/5.7.0"),ur=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],cr=[b.errors.INSUFFICIENT_FUNDS,b.errors.NONCE_EXPIRED,b.errors.REPLACEMENT_UNDERPRICED];class lr{constructor(){sr.checkAbstract(new.target,lr),te(this,"_isSigner",!0)}getBalance(e){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),e)}))}getTransactionCount(e){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),e)}))}estimateGas(e){return ar(this,void 0,void 0,(function*(){this._checkProvider("estimateGas");const t=yield ne(this.checkTransaction(e));return yield this.provider.estimateGas(t)}))}call(e,t){return ar(this,void 0,void 0,(function*(){this._checkProvider("call");const r=yield ne(this.checkTransaction(e));return yield this.provider.call(r,t)}))}sendTransaction(e){return ar(this,void 0,void 0,(function*(){this._checkProvider("sendTransaction");const t=yield this.populateTransaction(e),r=yield this.signTransaction(t);return yield this.provider.sendTransaction(r)}))}getChainId(){return ar(this,void 0,void 0,(function*(){this._checkProvider("getChainId");return(yield this.provider.getNetwork()).chainId}))}getGasPrice(){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()}))}getFeeData(){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()}))}resolveName(e){return ar(this,void 0,void 0,(function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(e)}))}checkTransaction(e){for(const t in e)-1===ur.indexOf(t)&&sr.throwArgumentError("invalid transaction key: "+t,"transaction",e);const t=oe(e);return null==t.from?t.from=this.getAddress():t.from=Promise.all([Promise.resolve(t.from),this.getAddress()]).then((t=>(t[0].toLowerCase()!==t[1].toLowerCase()&&sr.throwArgumentError("from address mismatch","transaction",e),t[0]))),t}populateTransaction(e){return ar(this,void 0,void 0,(function*(){const t=yield ne(this.checkTransaction(e));null!=t.to&&(t.to=Promise.resolve(t.to).then((e=>ar(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.resolveName(e);return null==t&&sr.throwArgumentError("provided ENS name resolves to null","tx.to",e),t})))),t.to.catch((e=>{})));const r=null!=t.maxFeePerGas||null!=t.maxPriorityFeePerGas;if(null==t.gasPrice||2!==t.type&&!r?0!==t.type&&1!==t.type||!r||sr.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",e):sr.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",e),2!==t.type&&null!=t.type||null==t.maxFeePerGas||null==t.maxPriorityFeePerGas)if(0===t.type||1===t.type)null==t.gasPrice&&(t.gasPrice=this.getGasPrice());else{const e=yield this.getFeeData();if(null==t.type)if(null!=e.maxFeePerGas&&null!=e.maxPriorityFeePerGas)if(t.type=2,null!=t.gasPrice){const e=t.gasPrice;delete t.gasPrice,t.maxFeePerGas=e,t.maxPriorityFeePerGas=e}else null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas);else null!=e.gasPrice?(r&&sr.throwError("network does not support EIP-1559",b.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),null==t.gasPrice&&(t.gasPrice=e.gasPrice),t.type=0):sr.throwError("failed to get consistent fee data",b.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"});else 2===t.type&&(null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas))}else t.type=2;return null==t.nonce&&(t.nonce=this.getTransactionCount("pending")),null==t.gasLimit&&(t.gasLimit=this.estimateGas(t).catch((e=>{if(cr.indexOf(e.code)>=0)throw e;return sr.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,tx:t})}))),null==t.chainId?t.chainId=this.getChainId():t.chainId=Promise.all([Promise.resolve(t.chainId),this.getChainId()]).then((t=>(0!==t[1]&&t[0]!==t[1]&&sr.throwArgumentError("chainId address mismatch","transaction",e),t[0]))),yield ne(t)}))}_checkProvider(e){this.provider||sr.throwError("missing provider",b.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}static isSigner(e){return!(!e||!e._isSigner)}}class fr extends lr{constructor(e,t){super(),te(this,"address",e),te(this,"provider",t||null)}getAddress(){return Promise.resolve(this.address)}_fail(e,t){return Promise.resolve().then((()=>{sr.throwError(e,b.errors.UNSUPPORTED_OPERATION,{operation:t})}))}signMessage(e){return this._fail("VoidSigner cannot sign messages","signMessage")}signTransaction(e){return this._fail("VoidSigner cannot sign transactions","signTransaction")}_signTypedData(e,t,r){return this._fail("VoidSigner cannot sign typed data","signTypedData")}connect(e){return new fr(this.address,e)}}var hr=r(33715),dr=r.n(hr);"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==r.g?r.g:"undefined"!=typeof self&&self;function pr(e,t,r){return r={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&r.path)}},e(r,r.exports),r.exports}var mr=yr;function yr(e,t){if(!e)throw new Error(t||"Assertion failed")}yr.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var gr=pr((function(e,t){var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}})),br=pr((function(e,t){var r=t;r.assert=mr,r.toArray=gr.toArray,r.zero2=gr.zero2,r.toHex=gr.toHex,r.encode=gr.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!==(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!==(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"==typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new(H())(e,"hex","le")}})),vr=br.getNAF,wr=br.getJSF,Ar=br.assert;function Sr(e,t){this.type=e,this.p=new(H())(t.p,16),this.red=t.prime?H().red(t.prime):H().mont(this.p),this.zero=new(H())(0).toRed(this.red),this.one=new(H())(1).toRed(this.red),this.two=new(H())(2).toRed(this.red),this.n=t.n&&new(H())(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var kr=Sr;function Er(e,t){this.curve=e,this.type=t,this.precomputed=null}Sr.prototype.point=function(){throw new Error("Not implemented")},Sr.prototype.validate=function(){throw new Error("Not implemented")},Sr.prototype._fixedNafMul=function(e,t){Ar(e.precomputed);var r=e._getDoubles(),n=vr(t,1,this._bitLength),i=(1<=o;u--)a=(a<<1)+n[u];s.push(a)}for(var c=this.jpoint(null,null,null),l=this.jpoint(null,null,null),f=i;f>0;f--){for(o=0;o=0;s--){for(var u=0;s>=0&&0===o[s];s--)u++;if(s>=0&&u++,a=a.dblp(u),s<0)break;var c=o[s];Ar(0!==c),a="affine"===e.type?c>0?a.mixedAdd(i[c-1>>1]):a.mixedAdd(i[-c-1>>1].neg()):c>0?a.add(i[c-1>>1]):a.add(i[-c-1>>1].neg())}return"affine"===e.type?a.toP():a},Sr.prototype._wnafMulAdd=function(e,t,r,n,i){var o,a,s,u=this._wnafT1,c=this._wnafT2,l=this._wnafT3,f=0;for(o=0;o=1;o-=2){var d=o-1,p=o;if(1===u[d]&&1===u[p]){var m=[t[d],null,null,t[p]];0===t[d].y.cmp(t[p].y)?(m[1]=t[d].add(t[p]),m[2]=t[d].toJ().mixedAdd(t[p].neg())):0===t[d].y.cmp(t[p].y.redNeg())?(m[1]=t[d].toJ().mixedAdd(t[p]),m[2]=t[d].add(t[p].neg())):(m[1]=t[d].toJ().mixedAdd(t[p]),m[2]=t[d].toJ().mixedAdd(t[p].neg()));var y=[-3,-1,-5,-7,0,7,5,1,3],g=wr(r[d],r[p]);for(f=Math.max(g[0].length,f),l[d]=new Array(f),l[p]=new Array(f),a=0;a=0;o--){for(var S=0;o>=0;){var k=!0;for(a=0;a=0&&S++,w=w.dblp(S),o<0)break;for(a=0;a0?s=c[a][E-1>>1]:E<0&&(s=c[a][-E-1>>1].neg()),w="affine"===s.type?w.mixedAdd(s):w.add(s))}}for(o=0;o=Math.ceil((e.bitLength()+1)/t.step)},Er.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i=0&&(o=t,a=r),n.negative&&(n=n.neg(),i=i.neg()),o.negative&&(o=o.neg(),a=a.neg()),[{a:n,b:i},{a:o,b:a}]},Tr.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},Tr.prototype.pointFromX=function(e,t){(e=new(H())(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},Tr.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},Tr.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},Pr.prototype.isInfinity=function(){return this.inf},Pr.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},Pr.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},Pr.prototype.getX=function(){return this.x.fromRed()},Pr.prototype.getY=function(){return this.y.fromRed()},Pr.prototype.mul=function(e){return e=new(H())(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},Pr.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},Pr.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},Pr.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},Pr.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},Pr.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},_r(Ir,kr.BasePoint),Tr.prototype.jpoint=function(e,t,r){return new Ir(this,e,t,r)},Ir.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},Ir.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},Ir.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},Ir.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},Ir.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},Ir.prototype.inspect=function(){return this.isInfinity()?"":""},Ir.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var Or=pr((function(e,t){var r=t;r.base=kr,r.short=xr,r.mont=null,r.edwards=null})),Rr=pr((function(e,t){var r,n=t,i=br.assert;function o(e){"short"===e.type?this.curve=new Or.short(e):"edwards"===e.type?this.curve=new Or.edwards(e):this.curve=new Or.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,i(this.g.validate(),"Invalid curve"),i(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function a(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new o(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=o,a("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:dr().sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),a("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:dr().sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),a("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:dr().sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),a("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:dr().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"]}),a("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:dr().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"]}),a("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:dr().sha256,gRed:!1,g:["9"]}),a("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:dr().sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(e){r=void 0}a("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:dr().sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function Cr(e){if(!(this instanceof Cr))return new Cr(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=gr.toArray(e.entropy,e.entropyEnc||"hex"),r=gr.toArray(e.nonce,e.nonceEnc||"hex"),n=gr.toArray(e.pers,e.persEnc||"hex");mr(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var Br=Cr;Cr.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},Cr.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=gr.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length"};var Fr=br.assert;function Dr(e,t){if(e instanceof Dr)return e;this._importDER(e,t)||(Fr(e.r&&e.s,"Signature without r or s"),this.r=new(H())(e.r,16),this.s=new(H())(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var jr=Dr;function Hr(){this.place=0}function Jr(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function zr(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}Dr.prototype._importDER=function(e,t){e=br.toArray(e,t);var r=new Hr;if(48!==e[r.place++])return!1;var n=Jr(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var i=Jr(e,r);if(!1===i)return!1;var o=e.slice(r.place,i+r.place);if(r.place+=i,2!==e[r.place++])return!1;var a=Jr(e,r);if(!1===a)return!1;if(e.length!==a+r.place)return!1;var s=e.slice(r.place,a+r.place);if(0===o[0]){if(!(128&o[1]))return!1;o=o.slice(1)}if(0===s[0]){if(!(128&s[1]))return!1;s=s.slice(1)}return this.r=new(H())(o),this.s=new(H())(s),this.recoveryParam=null,!0},Dr.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=zr(t),r=zr(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];Gr(n,t.length),(n=n.concat(t)).push(2),Gr(n,r.length);var i=n.concat(r),o=[48];return Gr(o,i.length),o=o.concat(i),br.encode(o,e)};var qr=function(){throw new Error("unsupported")},Kr=br.assert;function Vr(e){if(!(this instanceof Vr))return new Vr(e);"string"==typeof e&&(Kr(Object.prototype.hasOwnProperty.call(Rr,e),"Unknown curve "+e),e=Rr[e]),e instanceof Rr.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var Xr=Vr;Vr.prototype.keyPair=function(e){return new Ur(this,e)},Vr.prototype.keyFromPrivate=function(e,t){return Ur.fromPrivate(this,e,t)},Vr.prototype.keyFromPublic=function(e,t){return Ur.fromPublic(this,e,t)},Vr.prototype.genKeyPair=function(e){e||(e={});for(var t=new Br({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||qr(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new(H())(2));;){var i=new(H())(t.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},Vr.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},Vr.prototype.sign=function(e,t,r,n){"object"==typeof r&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new(H())(e,16));for(var i=this.n.byteLength(),o=t.getPrivate().toArray("be",i),a=e.toArray("be",i),s=new Br({hash:this.hash,entropy:o,nonce:a,pers:n.pers,persEnc:n.persEnc||"utf8"}),u=this.n.sub(new(H())(1)),c=0;;c++){var l=n.k?n.k(c):new(H())(s.generate(this.n.byteLength()));if(!((l=this._truncateToN(l,!0)).cmpn(1)<=0||l.cmp(u)>=0)){var f=this.g.mul(l);if(!f.isInfinity()){var h=f.getX(),d=h.umod(this.n);if(0!==d.cmpn(0)){var p=l.invm(this.n).mul(d.mul(t.getPrivate()).iadd(e));if(0!==(p=p.umod(this.n)).cmpn(0)){var m=(f.getY().isOdd()?1:0)|(0!==h.cmp(d)?2:0);return n.canonical&&p.cmp(this.nh)>0&&(p=this.n.sub(p),m^=1),new jr({r:d,s:p,recoveryParam:m})}}}}}},Vr.prototype.verify=function(e,t,r,n){e=this._truncateToN(new(H())(e,16)),r=this.keyFromPublic(r,n);var i=(t=new jr(t,"hex")).r,o=t.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var a,s=o.invm(this.n),u=s.mul(e).umod(this.n),c=s.mul(i).umod(this.n);return this.curve._maxwellTrick?!(a=this.g.jmulAdd(u,r.getPublic(),c)).isInfinity()&&a.eqXToP(i):!(a=this.g.mulAdd(u,r.getPublic(),c)).isInfinity()&&0===a.getX().umod(this.n).cmp(i)},Vr.prototype.recoverPubKey=function(e,t,r,n){Kr((3&r)===r,"The recovery param is more than two bits"),t=new jr(t,n);var i=this.n,o=new(H())(e),a=t.r,s=t.s,u=1&r,c=r>>1;if(a.cmp(this.curve.p.umod(this.curve.n))>=0&&c)throw new Error("Unable to find sencond key candinate");a=c?this.curve.pointFromX(a.add(this.curve.n),u):this.curve.pointFromX(a,u);var l=t.r.invm(i),f=i.sub(o).mul(l).umod(i),h=s.mul(l).umod(i);return this.g.mulAdd(f,a,h)},Vr.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new jr(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")};var Qr=pr((function(e,t){var r=t;r.version="6.5.4",r.utils=br,r.rand=function(){throw new Error("unsupported")},r.curve=Or,r.curves=Rr,r.ec=Xr,r.eddsa=null})).ec;const Wr=new b("signing-key/5.7.0");let Zr=null;function Yr(){return Zr||(Zr=new Qr("secp256k1")),Zr}class $r{constructor(e){te(this,"curve","secp256k1"),te(this,"privateKey",O(e)),32!==R(this.privateKey)&&Wr.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");const t=Yr().keyFromPrivate(_(this.privateKey));te(this,"publicKey","0x"+t.getPublic(!1,"hex")),te(this,"compressedPublicKey","0x"+t.getPublic(!0,"hex")),te(this,"_isSigningKey",!0)}_addPoint(e){const t=Yr().keyFromPublic(_(this.publicKey)),r=Yr().keyFromPublic(_(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}signDigest(e){const t=Yr().keyFromPrivate(_(this.privateKey)),r=_(e);32!==r.length&&Wr.throwArgumentError("bad digest length","digest",e);const n=t.sign(r,{canonical:!0});return F({recoveryParam:n.recoveryParam,r:U("0x"+n.r.toString(16),32),s:U("0x"+n.s.toString(16),32)})}computeSharedSecret(e){const t=Yr().keyFromPrivate(_(this.privateKey)),r=Yr().keyFromPublic(_(tn(e)));return U("0x"+t.derive(r.getPublic()).toString(16),32)}static isSigningKey(e){return!(!e||!e._isSigningKey)}}function en(e,t){const r=F(t),n={r:_(r.r),s:_(r.s)};return"0x"+Yr().recoverPubKey(_(e),n,r.recoveryParam).encode("hex",!1)}function tn(e,t){const r=_(e);if(32===r.length){const e=new $r(r);return t?"0x"+Yr().keyFromPrivate(r).getPublic(!0,"hex"):e.publicKey}return 33===r.length?t?O(r):"0x"+Yr().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+Yr().keyFromPublic(r).getPublic(!0,"hex"):O(r):Wr.throwArgumentError("invalid public or private key","key","[REDACTED]")}const rn=new b("transactions/5.7.0");var nn;function on(e){return"0x"===e?null:Be(e)}function an(e){return"0x"===e?lt:X.from(e)}!function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(nn||(nn={}));const sn=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],un={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function cn(e){return Be(C(ve(C(tn(e),1)),12))}function ln(e,t){return cn(en(_(e),t))}function fn(e,t){const r=T(X.from(e).toHexString());return r.length>32&&rn.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function hn(e,t){return{address:Be(e),storageKeys:(t||[]).map(((t,r)=>(32!==R(t)&&rn.throwArgumentError("invalid access list storageKey",`accessList[${e}:${r}]`,t),t.toLowerCase())))}}function dn(e){if(Array.isArray(e))return e.map(((e,t)=>Array.isArray(e)?(e.length>2&&rn.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${t}]`,e),hn(e[0],e[1])):hn(e.address,e.storageKeys)));const t=Object.keys(e).map((t=>{const r=e[t].reduce(((e,t)=>(e[t]=!0,e)),{});return hn(t,Object.keys(r).sort())}));return t.sort(((e,t)=>e.address.localeCompare(t.address))),t}function pn(e){return dn(e).map((e=>[e.address,e.storageKeys]))}function mn(e,t){if(null!=e.gasPrice){const t=X.from(e.gasPrice),r=X.from(e.maxFeePerGas||0);t.eq(r)||rn.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:t,maxFeePerGas:r})}const r=[fn(e.chainId||0,"chainId"),fn(e.nonce||0,"nonce"),fn(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),fn(e.maxFeePerGas||0,"maxFeePerGas"),fn(e.gasLimit||0,"gasLimit"),null!=e.to?Be(e.to):"0x",fn(e.value||0,"value"),e.data||"0x",pn(e.accessList||[])];if(t){const e=F(t);r.push(fn(e.recoveryParam,"recoveryParam")),r.push(T(e.r)),r.push(T(e.s))}return B(["0x02",Ee(r)])}function yn(e,t){const r=[fn(e.chainId||0,"chainId"),fn(e.nonce||0,"nonce"),fn(e.gasPrice||0,"gasPrice"),fn(e.gasLimit||0,"gasLimit"),null!=e.to?Be(e.to):"0x",fn(e.value||0,"value"),e.data||"0x",pn(e.accessList||[])];if(t){const e=F(t);r.push(fn(e.recoveryParam,"recoveryParam")),r.push(T(e.r)),r.push(T(e.s))}return B(["0x01",Ee(r)])}function gn(e,t){if(null==e.type||0===e.type)return null!=e.accessList&&rn.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",e),function(e,t){ie(e,un);const r=[];sn.forEach((function(t){let n=e[t.name]||[];const i={};t.numeric&&(i.hexPad="left"),n=_(O(n,i)),t.length&&n.length!==t.length&&n.length>0&&rn.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),t.maxLength&&(n=T(n),n.length>t.maxLength&&rn.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n)),r.push(O(n))}));let n=0;if(null!=e.chainId?(n=e.chainId,"number"!=typeof n&&rn.throwArgumentError("invalid transaction.chainId","transaction",e)):t&&!S(t)&&t.v>28&&(n=Math.floor((t.v-35)/2)),0!==n&&(r.push(O(n)),r.push("0x"),r.push("0x")),!t)return Ee(r);const i=F(t);let o=27+i.recoveryParam;return 0!==n?(r.pop(),r.pop(),r.pop(),o+=2*n+8,i.v>28&&i.v!==o&&rn.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t)):i.v!==o&&rn.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t),r.push(O(o)),r.push(T(_(i.r))),r.push(T(_(i.s))),Ee(r)}(e,t);switch(e.type){case 1:return yn(e,t);case 2:return mn(e,t)}return rn.throwError(`unsupported transaction type: ${e.type}`,b.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:e.type})}function bn(e,t,r){try{const r=an(t[0]).toNumber();if(0!==r&&1!==r)throw new Error("bad recid");e.v=r}catch(e){rn.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=U(t[1],32),e.s=U(t[2],32);try{const t=ve(r(e));e.from=ln(t,{r:e.r,s:e.s,recoveryParam:e.v})}catch(e){}}function vn(e){const t=_(e);if(t[0]>127)return function(e){const t=Te(e);9!==t.length&&6!==t.length&&rn.throwArgumentError("invalid raw transaction","rawTransaction",e);const r={nonce:an(t[0]).toNumber(),gasPrice:an(t[1]),gasLimit:an(t[2]),to:on(t[3]),value:an(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=X.from(t[6]).toNumber()}catch(e){return r}if(r.r=U(t[7],32),r.s=U(t[8],32),X.from(r.r).isZero()&&X.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);let n=r.v-27;const i=t.slice(0,6);0!==r.chainId&&(i.push(O(r.chainId)),i.push("0x"),i.push("0x"),n-=2*r.chainId+8);const o=ve(Ee(i));try{r.from=ln(o,{r:O(r.r),s:O(r.s),recoveryParam:n})}catch(e){}r.hash=ve(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){const t=Te(e.slice(1));8!==t.length&&11!==t.length&&rn.throwArgumentError("invalid component count for transaction type: 1","payload",O(e));const r={type:1,chainId:an(t[0]).toNumber(),nonce:an(t[1]).toNumber(),gasPrice:an(t[2]),gasLimit:an(t[3]),to:on(t[4]),value:an(t[5]),data:t[6],accessList:dn(t[7])};return 8===t.length||(r.hash=ve(e),bn(r,t.slice(8),yn)),r}(t);case 2:return function(e){const t=Te(e.slice(1));9!==t.length&&12!==t.length&&rn.throwArgumentError("invalid component count for transaction type: 2","payload",O(e));const r=an(t[2]),n=an(t[3]),i={type:2,chainId:an(t[0]).toNumber(),nonce:an(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:an(t[4]),to:on(t[5]),value:an(t[6]),data:t[7],accessList:dn(t[8])};return 9===t.length||(i.hash=ve(e),bn(i,t.slice(9),mn)),i}(t)}return rn.throwError(`unsupported transaction type: ${t[0]}`,b.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})}var wn=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const An=new b("contracts/5.7.0"),Sn={chainId:!0,data:!0,from:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0,customData:!0,ccipReadEnabled:!0};function kn(e,t){return wn(this,void 0,void 0,(function*(){const r=yield t;"string"!=typeof r&&An.throwArgumentError("invalid address or ENS name","name",r);try{return Be(r)}catch(e){}e||An.throwError("a provider or signer is needed to resolve ENS names",b.errors.UNSUPPORTED_OPERATION,{operation:"resolveName"});const n=yield e.resolveName(r);return null==n&&An.throwArgumentError("resolver or addr is not configured for ENS name","name",r),n}))}function En(e,t,r){return wn(this,void 0,void 0,(function*(){return Array.isArray(r)?yield Promise.all(r.map(((r,n)=>En(e,Array.isArray(t)?t[n]:t[r.name],r)))):"address"===r.type?yield kn(e,t):"tuple"===r.type?yield En(e,t,r.components):"array"===r.baseType?Array.isArray(t)?yield Promise.all(t.map((t=>En(e,t,r.arrayChildren)))):Promise.reject(An.makeError("invalid value for array",b.errors.INVALID_ARGUMENT,{argument:"value",value:t})):t}))}function _n(e,t,r){return wn(this,void 0,void 0,(function*(){let n={};r.length===t.inputs.length+1&&"object"==typeof r[r.length-1]&&(n=oe(r.pop())),An.checkArgumentCount(r.length,t.inputs.length,"passed to contract"),e.signer?n.from?n.from=ne({override:kn(e.signer,n.from),signer:e.signer.getAddress()}).then((e=>wn(this,void 0,void 0,(function*(){return Be(e.signer)!==e.override&&An.throwError("Contract with a Signer cannot override from",b.errors.UNSUPPORTED_OPERATION,{operation:"overrides.from"}),e.override})))):n.from=e.signer.getAddress():n.from&&(n.from=kn(e.provider,n.from));const i=yield ne({args:En(e.signer||e.provider,r,t.inputs),address:e.resolvedAddress,overrides:ne(n)||{}}),o=e.interface.encodeFunctionData(t,i.args),a={data:o,to:i.address},s=i.overrides;if(null!=s.nonce&&(a.nonce=X.from(s.nonce).toNumber()),null!=s.gasLimit&&(a.gasLimit=X.from(s.gasLimit)),null!=s.gasPrice&&(a.gasPrice=X.from(s.gasPrice)),null!=s.maxFeePerGas&&(a.maxFeePerGas=X.from(s.maxFeePerGas)),null!=s.maxPriorityFeePerGas&&(a.maxPriorityFeePerGas=X.from(s.maxPriorityFeePerGas)),null!=s.from&&(a.from=s.from),null!=s.type&&(a.type=s.type),null!=s.accessList&&(a.accessList=dn(s.accessList)),null==a.gasLimit&&null!=t.gas){let e=21e3;const r=_(o);for(let t=0;tnull!=n[e]));return u.length&&An.throwError(`cannot override ${u.map((e=>JSON.stringify(e))).join(",")}`,b.errors.UNSUPPORTED_OPERATION,{operation:"overrides",overrides:u}),a}))}function Mn(e,t){const r=t.wait.bind(t);t.wait=t=>r(t).then((t=>(t.events=t.logs.map((r=>{let n=ce(r),i=null;try{i=e.interface.parseLog(r)}catch(e){}return i&&(n.args=i.args,n.decode=(t,r)=>e.interface.decodeEventLog(i.eventFragment,t,r),n.event=i.name,n.eventSignature=i.signature),n.removeListener=()=>e.provider,n.getBlock=()=>e.provider.getBlock(t.blockHash),n.getTransaction=()=>e.provider.getTransaction(t.transactionHash),n.getTransactionReceipt=()=>Promise.resolve(t),n})),t)))}function Tn(e,t,r){const n=e.signer||e.provider;return function(...i){return wn(this,void 0,void 0,(function*(){let o;if(i.length===t.inputs.length+1&&"object"==typeof i[i.length-1]){const e=oe(i.pop());null!=e.blockTag&&(o=yield e.blockTag),delete e.blockTag,i.push(e)}null!=e.deployTransaction&&(yield e._deployed(o));const a=yield _n(e,t,i),s=yield n.call(a,o);try{let n=e.interface.decodeFunctionResult(t,s);return r&&1===t.outputs.length&&(n=n[0]),n}catch(t){throw t.code===b.errors.CALL_EXCEPTION&&(t.address=e.address,t.args=i,t.transaction=a),t}}))}}function xn(e,t,r){return t.constant?Tn(e,t,r):function(e,t){return function(...r){return wn(this,void 0,void 0,(function*(){e.signer||An.throwError("sending a transaction requires a signer",b.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction"}),null!=e.deployTransaction&&(yield e._deployed());const n=yield _n(e,t,r),i=yield e.signer.sendTransaction(n);return Mn(e,i),i}))}}(e,t)}function Pn(e){return!e.address||null!=e.topics&&0!==e.topics.length?(e.address||"*")+"@"+(e.topics?e.topics.map((e=>Array.isArray(e)?e.join("|"):e)).join(":"):""):"*"}class In{constructor(e,t){te(this,"tag",e),te(this,"filter",t),this._listeners=[]}addListener(e,t){this._listeners.push({listener:e,once:t})}removeListener(e){let t=!1;this._listeners=this._listeners.filter((r=>!(!t&&r.listener===e)||(t=!0,!1)))}removeAllListeners(){this._listeners=[]}listeners(){return this._listeners.map((e=>e.listener))}listenerCount(){return this._listeners.length}run(e){const t=this.listenerCount();return this._listeners=this._listeners.filter((t=>{const r=e.slice();return setTimeout((()=>{t.listener.apply(this,r)}),0),!t.once})),t}prepareEvent(e){}getEmit(e){return[e]}}class On extends In{constructor(){super("error",null)}}class Rn extends In{constructor(e,t,r,n){const i={address:e};let o=t.getEventTopic(r);n?(o!==n[0]&&An.throwArgumentError("topic mismatch","topics",n),i.topics=n.slice()):i.topics=[o],super(Pn(i),i),te(this,"address",e),te(this,"interface",t),te(this,"fragment",r)}prepareEvent(e){super.prepareEvent(e),e.event=this.fragment.name,e.eventSignature=this.fragment.format(),e.decode=(e,t)=>this.interface.decodeEventLog(this.fragment,e,t);try{e.args=this.interface.decodeEventLog(this.fragment,e.data,e.topics)}catch(t){e.args=null,e.decodeError=t}}getEmit(e){const t=de(e.args);if(t.length)throw t[0].error;const r=(e.args||[]).slice();return r.push(e),r}}class Cn extends In{constructor(e,t){super("*",{address:e}),te(this,"address",e),te(this,"interface",t)}prepareEvent(e){super.prepareEvent(e);try{const t=this.interface.parseLog(e);e.event=t.name,e.eventSignature=t.signature,e.decode=(e,r)=>this.interface.decodeEventLog(t.eventFragment,e,r),e.args=t.args}catch(e){}}}class Bn{constructor(e,t,r){te(this,"interface",re(new.target,"getInterface")(t)),null==r?(te(this,"provider",null),te(this,"signer",null)):lr.isSigner(r)?(te(this,"provider",r.provider||null),te(this,"signer",r)):or.isProvider(r)?(te(this,"provider",r),te(this,"signer",null)):An.throwArgumentError("invalid signer or provider","signerOrProvider",r),te(this,"callStatic",{}),te(this,"estimateGas",{}),te(this,"functions",{}),te(this,"populateTransaction",{}),te(this,"filters",{});{const e={};Object.keys(this.interface.events).forEach((t=>{const r=this.interface.events[t];te(this.filters,t,((...e)=>({address:this.address,topics:this.interface.encodeFilterTopics(r,e)}))),e[r.name]||(e[r.name]=[]),e[r.name].push(t)})),Object.keys(e).forEach((t=>{const r=e[t];1===r.length?te(this.filters,t,this.filters[r[0]]):An.warn(`Duplicate definition of ${t} (${r.join(", ")})`)}))}if(te(this,"_runningEvents",{}),te(this,"_wrappedEmits",{}),null==e&&An.throwArgumentError("invalid contract address or ENS name","addressOrName",e),te(this,"address",e),this.provider)te(this,"resolvedAddress",kn(this.provider,e));else try{te(this,"resolvedAddress",Promise.resolve(Be(e)))}catch(e){An.throwError("provider is required to use ENS name as contract address",b.errors.UNSUPPORTED_OPERATION,{operation:"new Contract"})}this.resolvedAddress.catch((e=>{}));const n={},i={};Object.keys(this.interface.functions).forEach((e=>{const t=this.interface.functions[e];if(i[e])An.warn(`Duplicate ABI entry for ${JSON.stringify(e)}`);else{i[e]=!0;{const r=t.name;n[`%${r}`]||(n[`%${r}`]=[]),n[`%${r}`].push(e)}null==this[e]&&te(this,e,xn(this,t,!0)),null==this.functions[e]&&te(this.functions,e,xn(this,t,!1)),null==this.callStatic[e]&&te(this.callStatic,e,Tn(this,t,!0)),null==this.populateTransaction[e]&&te(this.populateTransaction,e,function(e,t){return function(...r){return _n(e,t,r)}}(this,t)),null==this.estimateGas[e]&&te(this.estimateGas,e,function(e,t){const r=e.signer||e.provider;return function(...n){return wn(this,void 0,void 0,(function*(){r||An.throwError("estimate require a provider or signer",b.errors.UNSUPPORTED_OPERATION,{operation:"estimateGas"});const i=yield _n(e,t,n);return yield r.estimateGas(i)}))}}(this,t))}})),Object.keys(n).forEach((e=>{const t=n[e];if(t.length>1)return;e=e.substring(1);const r=t[0];try{null==this[e]&&te(this,e,this[r])}catch(e){}null==this.functions[e]&&te(this.functions,e,this.functions[r]),null==this.callStatic[e]&&te(this.callStatic,e,this.callStatic[r]),null==this.populateTransaction[e]&&te(this.populateTransaction,e,this.populateTransaction[r]),null==this.estimateGas[e]&&te(this.estimateGas,e,this.estimateGas[r])}))}static getContractAddress(e){return Ue(e)}static getInterface(e){return tr.isInterface(e)?e:new tr(e)}deployed(){return this._deployed()}_deployed(e){return this._deployedPromise||(this.deployTransaction?this._deployedPromise=this.deployTransaction.wait().then((()=>this)):this._deployedPromise=this.provider.getCode(this.address,e).then((e=>("0x"===e&&An.throwError("contract not deployed",b.errors.UNSUPPORTED_OPERATION,{contractAddress:this.address,operation:"getDeployed"}),this)))),this._deployedPromise}fallback(e){this.signer||An.throwError("sending a transactions require a signer",b.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction(fallback)"});const t=oe(e||{});return["from","to"].forEach((function(e){null!=t[e]&&An.throwError("cannot override "+e,b.errors.UNSUPPORTED_OPERATION,{operation:e})})),t.to=this.resolvedAddress,this.deployed().then((()=>this.signer.sendTransaction(t)))}connect(e){"string"==typeof e&&(e=new fr(e,this.provider));const t=new this.constructor(this.address,this.interface,e);return this.deployTransaction&&te(t,"deployTransaction",this.deployTransaction),t}attach(e){return new this.constructor(e,this.interface,this.signer||this.provider)}static isIndexed(e){return Yt.isIndexed(e)}_normalizeRunningEvent(e){return this._runningEvents[e.tag]?this._runningEvents[e.tag]:e}_getRunningEvent(e){if("string"==typeof e){if("error"===e)return this._normalizeRunningEvent(new On);if("event"===e)return this._normalizeRunningEvent(new In("event",null));if("*"===e)return this._normalizeRunningEvent(new Cn(this.address,this.interface));const t=this.interface.getEvent(e);return this._normalizeRunningEvent(new Rn(this.address,this.interface,t))}if(e.topics&&e.topics.length>0){try{const t=e.topics[0];if("string"!=typeof t)throw new Error("invalid topic");const r=this.interface.getEvent(t);return this._normalizeRunningEvent(new Rn(this.address,this.interface,r,e.topics))}catch(e){}const t={address:this.address,topics:e.topics};return this._normalizeRunningEvent(new In(Pn(t),t))}return this._normalizeRunningEvent(new Cn(this.address,this.interface))}_checkRunningEvents(e){if(0===e.listenerCount()){delete this._runningEvents[e.tag];const t=this._wrappedEmits[e.tag];t&&e.filter&&(this.provider.off(e.filter,t),delete this._wrappedEmits[e.tag])}}_wrapEvent(e,t,r){const n=ce(t);return n.removeListener=()=>{r&&(e.removeListener(r),this._checkRunningEvents(e))},n.getBlock=()=>this.provider.getBlock(t.blockHash),n.getTransaction=()=>this.provider.getTransaction(t.transactionHash),n.getTransactionReceipt=()=>this.provider.getTransactionReceipt(t.transactionHash),e.prepareEvent(n),n}_addEventListener(e,t,r){if(this.provider||An.throwError("events require a provider or a signer with a provider",b.errors.UNSUPPORTED_OPERATION,{operation:"once"}),e.addListener(t,r),this._runningEvents[e.tag]=e,!this._wrappedEmits[e.tag]){const r=r=>{let n=this._wrapEvent(e,r,t);if(null==n.decodeError)try{const t=e.getEmit(n);this.emit(e.filter,...t)}catch(e){n.decodeError=e.error}null!=e.filter&&this.emit("event",n),null!=n.decodeError&&this.emit("error",n.decodeError,n)};this._wrappedEmits[e.tag]=r,null!=e.filter&&this.provider.on(e.filter,r)}}queryFilter(e,t,r){const n=this._getRunningEvent(e),i=oe(n.filter);return"string"==typeof t&&P(t,32)?(null!=r&&An.throwArgumentError("cannot specify toBlock with blockhash","toBlock",r),i.blockHash=t):(i.fromBlock=null!=t?t:0,i.toBlock=null!=r?r:"latest"),this.provider.getLogs(i).then((e=>e.map((e=>this._wrapEvent(n,e,null)))))}on(e,t){return this._addEventListener(this._getRunningEvent(e),t,!1),this}once(e,t){return this._addEventListener(this._getRunningEvent(e),t,!0),this}emit(e,...t){if(!this.provider)return!1;const r=this._getRunningEvent(e),n=r.run(t)>0;return this._checkRunningEvents(r),n}listenerCount(e){return this.provider?null==e?Object.keys(this._runningEvents).reduce(((e,t)=>e+this._runningEvents[t].listenerCount()),0):this._getRunningEvent(e).listenerCount():0}listeners(e){if(!this.provider)return[];if(null==e){const e=[];for(let t in this._runningEvents)this._runningEvents[t].listeners().forEach((t=>{e.push(t)}));return e}return this._getRunningEvent(e).listeners()}removeAllListeners(e){if(!this.provider)return this;if(null==e){for(const e in this._runningEvents){const t=this._runningEvents[e];t.removeAllListeners(),this._checkRunningEvents(t)}return this}const t=this._getRunningEvent(e);return t.removeAllListeners(),this._checkRunningEvents(t),this}off(e,t){if(!this.provider)return this;const r=this._getRunningEvent(e);return r.removeListener(t),this._checkRunningEvents(r),this}removeListener(e,t){return this.off(e,t)}}class Nn extends Bn{}class Ln{constructor(e,t,r){let n=null;n="string"==typeof t?t:E(t)?O(t):t&&"string"==typeof t.object?t.object:"!","0x"!==n.substring(0,2)&&(n="0x"+n),(!P(n)||n.length%2)&&An.throwArgumentError("invalid bytecode","bytecode",t),r&&!lr.isSigner(r)&&An.throwArgumentError("invalid signer","signer",r),te(this,"bytecode",n),te(this,"interface",re(new.target,"getInterface")(e)),te(this,"signer",r||null)}getDeployTransaction(...e){let t={};if(e.length===this.interface.deploy.inputs.length+1&&"object"==typeof e[e.length-1]){t=oe(e.pop());for(const e in t)if(!Sn[e])throw new Error("unknown transaction override "+e)}if(["data","from","to"].forEach((e=>{null!=t[e]&&An.throwError("cannot override "+e,b.errors.UNSUPPORTED_OPERATION,{operation:e})})),t.value){X.from(t.value).isZero()||this.interface.deploy.payable||An.throwError("non-payable constructor cannot override value",b.errors.UNSUPPORTED_OPERATION,{operation:"overrides.value",value:t.value})}return An.checkArgumentCount(e.length,this.interface.deploy.inputs.length," in Contract constructor"),t.data=O(M([this.bytecode,this.interface.encodeDeploy(e)])),t}deploy(...e){return wn(this,void 0,void 0,(function*(){let t={};e.length===this.interface.deploy.inputs.length+1&&(t=e.pop()),An.checkArgumentCount(e.length,this.interface.deploy.inputs.length," in Contract constructor");const r=yield En(this.signer,e,this.interface.deploy.inputs);r.push(t);const n=this.getDeployTransaction(...r),i=yield this.signer.sendTransaction(n),o=re(this.constructor,"getContractAddress")(i),a=re(this.constructor,"getContract")(o,this.interface,this.signer);return Mn(a,i),te(a,"deployTransaction",i),a}))}attach(e){return this.constructor.getContract(e,this.interface,this.signer)}connect(e){return new this.constructor(this.interface,this.bytecode,e)}static fromSolidity(e,t){null==e&&An.throwError("missing compiler output",b.errors.MISSING_ARGUMENT,{argument:"compilerOutput"}),"string"==typeof e&&(e=JSON.parse(e));const r=e.abi;let n=null;return e.bytecode?n=e.bytecode:e.evm&&e.evm.bytecode&&(n=e.evm.bytecode),new this(r,n,t)}static getInterface(e){return Nn.getInterface(e)}static getContractAddress(e){return Ue(e)}static getContract(e,t,r){return new Nn(e,t,r)}}const Un=new b(J),Fn={},Dn=X.from(0),jn=X.from(-1);function Hn(e,t,r,n){const i={fault:t,operation:r};return void 0!==n&&(i.value=n),Un.throwError(e,b.errors.NUMERIC_FAULT,i)}let Jn="0";for(;Jn.length<256;)Jn+=Jn;function zn(e){if("number"!=typeof e)try{e=X.from(e).toNumber()}catch(e){}return"number"==typeof e&&e>=0&&e<=256&&!(e%1)?"1"+Jn.substring(0,e):Un.throwArgumentError("invalid decimal size","decimals",e)}function Gn(e,t){null==t&&(t=0);const r=zn(t),n=(e=X.from(e)).lt(Dn);n&&(e=e.mul(jn));let i=e.mod(r).toString();for(;i.length2&&Un.throwArgumentError("too many decimal points","value",e);let o=i[0],a=i[1];for(o||(o="0"),a||(a="0");"0"===a[a.length-1];)a=a.substring(0,a.length-1);for(a.length>r.length-1&&Hn("fractional component exceeds decimals","underflow","parseFixed"),""===a&&(a="0");a.lengthnull==e[t]?n:(typeof e[t]!==r&&Un.throwArgumentError("invalid fixed format ("+t+" not "+r+")","format."+t,e[t]),e[t]);t=i("signed","boolean",t),r=i("width","number",r),n=i("decimals","number",n)}return r%8&&Un.throwArgumentError("invalid fixed format width (not byte aligned)","format.width",r),n>80&&Un.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",n),new Kn(Fn,t,r,n)}}class Vn{constructor(e,t,r,n){e!==Fn&&Un.throwError("cannot use FixedNumber constructor; use FixedNumber.from",b.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=n,this._hex=t,this._value=r,this._isFixedNumber=!0,Object.freeze(this)}_checkFormat(e){this.format.name!==e.format.name&&Un.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}addUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.add(r),this.format.decimals,this.format)}subUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.sub(r),this.format.decimals,this.format)}mulUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.mul(r).div(this.format._multiplier),this.format.decimals,this.format)}divUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.mul(this.format._multiplier).div(r),this.format.decimals,this.format)}floor(){const e=this.toString().split(".");1===e.length&&e.push("0");let t=Vn.from(e[0],this.format);const r=!e[1].match(/^(0*)$/);return this.isNegative()&&r&&(t=t.subUnsafe(Xn.toFormat(t.format))),t}ceiling(){const e=this.toString().split(".");1===e.length&&e.push("0");let t=Vn.from(e[0],this.format);const r=!e[1].match(/^(0*)$/);return!this.isNegative()&&r&&(t=t.addUnsafe(Xn.toFormat(t.format))),t}round(e){null==e&&(e=0);const t=this.toString().split(".");if(1===t.length&&t.push("0"),(e<0||e>80||e%1)&&Un.throwArgumentError("invalid decimal count","decimals",e),t[1].length<=e)return this;const r=Vn.from("1"+Jn.substring(0,e),this.format),n=Qn.toFormat(this.format);return this.mulUnsafe(r).addUnsafe(n).floor().divUnsafe(r)}isZero(){return"0.0"===this._value||"0"===this._value}isNegative(){return"-"===this._value[0]}toString(){return this._value}toHexString(e){if(null==e)return this._hex;e%8&&Un.throwArgumentError("invalid byte width","width",e);return U(X.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString(),e/8)}toUnsafeFloat(){return parseFloat(this.toString())}toFormat(e){return Vn.fromString(this._value,e)}static fromValue(e,t,r){return null!=r||null==t||function(e){return null!=e&&(X.isBigNumber(e)||"number"==typeof e&&e%1==0||"string"==typeof e&&!!e.match(/^-?[0-9]+$/)||P(e)||"bigint"==typeof e||E(e))}(t)||(r=t,t=null),null==t&&(t=0),null==r&&(r="fixed"),Vn.fromString(Gn(e,t),Kn.from(r))}static fromString(e,t){null==t&&(t="fixed");const r=Kn.from(t),n=qn(e,r.decimals);!r.signed&&n.lt(Dn)&&Hn("unsigned value cannot be negative","overflow","value",e);let i=null;r.signed?i=n.toTwos(r.width).toHexString():(i=n.toHexString(),i=U(i,r.width/8));const o=Gn(n,r.decimals);return new Vn(Fn,i,o,r)}static fromBytes(e,t){null==t&&(t="fixed");const r=Kn.from(t);if(_(e).length>r.width/8)throw new Error("overflow");let n=X.from(e);r.signed&&(n=n.fromTwos(r.width));const i=n.toTwos((r.signed?0:1)+r.width).toHexString(),o=Gn(n,r.decimals);return new Vn(Fn,i,o,r)}static from(e,t){if("string"==typeof e)return Vn.fromString(e,t);if(E(e))return Vn.fromBytes(e,t);try{return Vn.fromValue(e,0,t)}catch(e){if(e.code!==b.errors.INVALID_ARGUMENT)throw e}return Un.throwArgumentError("invalid FixedNumber value","value",e)}static isFixedNumber(e){return!(!e||!e._isFixedNumber)}}const Xn=Vn.from(1),Qn=Vn.from("0.5");function Wn(e){return"string"==typeof e&&(e=qe(e)),ve(M([qe("Ethereum Signed Message:\n"),qe(String(e.length)),e]))}const Zn="hash/5.7.0";var Yn=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const $n=new b(Zn),ei=new Uint8Array(32);ei.fill(0);const ti=X.from(-1),ri=X.from(0),ni=X.from(1),ii=X.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");const oi=U(ni.toHexString(),32),ai=U(ri.toHexString(),32),si={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},ui=["name","version","chainId","verifyingContract","salt"];function ci(e){return function(t){return"string"!=typeof t&&$n.throwArgumentError(`invalid domain value for ${JSON.stringify(e)}`,`domain.${e}`,t),t}}const li={name:ci("name"),version:ci("version"),chainId:function(e){try{return X.from(e).toString()}catch(e){}return $n.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",e)},verifyingContract:function(e){try{return Be(e).toLowerCase()}catch(e){}return $n.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){try{const t=_(e);if(32!==t.length)throw new Error("bad length");return O(t)}catch(e){}return $n.throwArgumentError('invalid domain value "salt"',"domain.salt",e)}};function fi(e){{const t=e.match(/^(u?)int(\d*)$/);if(t){const r=""===t[1],n=parseInt(t[2]||"256");(n%8!=0||n>256||t[2]&&t[2]!==String(n))&&$n.throwArgumentError("invalid numeric width","type",e);const i=ii.mask(r?n-1:n),o=r?i.add(ni).mul(ti):ri;return function(t){const r=X.from(t);return(r.lt(o)||r.gt(i))&&$n.throwArgumentError(`value out-of-bounds for ${e}`,"value",t),U(r.toTwos(256).toHexString(),32)}}}{const t=e.match(/^bytes(\d+)$/);if(t){const r=parseInt(t[1]);return(0===r||r>32||t[1]!==String(r))&&$n.throwArgumentError("invalid bytes width","type",e),function(t){return _(t).length!==r&&$n.throwArgumentError(`invalid length for ${e}`,"value",t),function(e){const t=_(e),r=t.length%32;return r?B([t,ei.slice(r)]):O(t)}(t)}}}switch(e){case"address":return function(e){return U(Be(e),32)};case"bool":return function(e){return e?oi:ai};case"bytes":return function(e){return ve(e)};case"string":return function(e){return Ze(e)}}return null}function hi(e,t){return`${e}(${t.map((({name:e,type:t})=>t+" "+e)).join(",")})`}class di{constructor(e){te(this,"types",Object.freeze(ce(e))),te(this,"_encoderCache",{}),te(this,"_types",{});const t={},r={},n={};Object.keys(e).forEach((e=>{t[e]={},r[e]=[],n[e]={}}));for(const n in e){const i={};e[n].forEach((o=>{i[o.name]&&$n.throwArgumentError(`duplicate variable name ${JSON.stringify(o.name)} in ${JSON.stringify(n)}`,"types",e),i[o.name]=!0;const a=o.type.match(/^([^\x5b]*)(\x5b|$)/)[1];a===n&&$n.throwArgumentError(`circular type reference to ${JSON.stringify(a)}`,"types",e);fi(a)||(r[a]||$n.throwArgumentError(`unknown type ${JSON.stringify(a)}`,"types",e),r[a].push(n),t[n][a]=!0)}))}const i=Object.keys(r).filter((e=>0===r[e].length));0===i.length?$n.throwArgumentError("missing primary type","types",e):i.length>1&&$n.throwArgumentError(`ambiguous primary types or unused types: ${i.map((e=>JSON.stringify(e))).join(", ")}`,"types",e),te(this,"primaryType",i[0]),function i(o,a){a[o]&&$n.throwArgumentError(`circular type reference to ${JSON.stringify(o)}`,"types",e),a[o]=!0,Object.keys(t[o]).forEach((e=>{r[e]&&(i(e,a),Object.keys(a).forEach((t=>{n[t][e]=!0})))})),delete a[o]}(this.primaryType,{});for(const t in n){const r=Object.keys(n[t]);r.sort(),this._types[t]=hi(t,e[t])+r.map((t=>hi(t,e[t]))).join("")}}getEncoder(e){let t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}_getEncoder(e){{const t=fi(e);if(t)return t}const t=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(t){const e=t[1],r=this.getEncoder(e),n=parseInt(t[3]);return t=>{n>=0&&t.length!==n&&$n.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t);let i=t.map(r);return this._types[e]&&(i=i.map(ve)),ve(B(i))}}const r=this.types[e];if(r){const t=Ze(this._types[e]);return e=>{const n=r.map((({name:t,type:r})=>{const n=this.getEncoder(r)(e[t]);return this._types[r]?ve(n):n}));return n.unshift(t),B(n)}}return $n.throwArgumentError(`unknown type: ${e}`,"type",e)}encodeType(e){const t=this._types[e];return t||$n.throwArgumentError(`unknown type: ${JSON.stringify(e)}`,"name",e),t}encodeData(e,t){return this.getEncoder(e)(t)}hashStruct(e,t){return ve(this.encodeData(e,t))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,t,r){if(fi(e))return r(e,t);const n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){const e=n[1],i=parseInt(n[3]);return i>=0&&t.length!==i&&$n.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((t=>this._visit(e,t,r)))}const i=this.types[e];return i?i.reduce(((e,{name:n,type:i})=>(e[n]=this._visit(i,t[n],r),e)),{}):$n.throwArgumentError(`unknown type: ${e}`,"type",e)}visit(e,t){return this._visit(this.primaryType,e,t)}static from(e){return new di(e)}static getPrimaryType(e){return di.from(e).primaryType}static hashStruct(e,t,r){return di.from(t).hashStruct(e,r)}static hashDomain(e){const t=[];for(const r in e){const n=si[r];n||$n.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(r)}`,"domain",e),t.push({name:r,type:n})}return t.sort(((e,t)=>ui.indexOf(e.name)-ui.indexOf(t.name))),di.hashStruct("EIP712Domain",{EIP712Domain:t},e)}static encode(e,t,r){return B(["0x1901",di.hashDomain(e),di.from(t).hash(r)])}static hash(e,t,r){return ve(di.encode(e,t,r))}static resolveNames(e,t,r,n){return Yn(this,void 0,void 0,(function*(){e=oe(e);const i={};e.verifyingContract&&!P(e.verifyingContract,20)&&(i[e.verifyingContract]="0x");const o=di.from(t);o.visit(r,((e,t)=>("address"!==e||P(t,20)||(i[t]="0x"),t)));for(const e in i)i[e]=yield n(e);return e.verifyingContract&&i[e.verifyingContract]&&(e.verifyingContract=i[e.verifyingContract]),r=o.visit(r,((e,t)=>"address"===e&&i[t]?i[t]:t)),{domain:e,value:r}}))}static getPayload(e,t,r){di.hashDomain(e);const n={},i=[];ui.forEach((t=>{const r=e[t];null!=r&&(n[t]=li[t](r),i.push({name:t,type:si[t]}))}));const o=di.from(t),a=oe(t);return a.EIP712Domain?$n.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",t):a.EIP712Domain=i,o.encode(r),{types:a,domain:n,primaryType:o.primaryType,message:o.visit(r,((e,t)=>{if(e.match(/^bytes(\d*)/))return O(_(t));if(e.match(/^u?int/))return X.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!=typeof t&&$n.throwArgumentError("invalid string","value",t),t}return $n.throwArgumentError("unsupported type","type",e)}))}}}class pi{constructor(e){te(this,"alphabet",e),te(this,"base",e.length),te(this,"_alphabetMap",{}),te(this,"_leader",e.charAt(0));for(let t=0;t0;)r.push(n%this.base),n=n/this.base|0}let n="";for(let e=0;0===t[e]&&e=0;--e)n+=this.alphabet[r[e]];return n}decode(e){if("string"!=typeof e)throw new TypeError("Expected String");let t=[];if(0===e.length)return new Uint8Array(t);t.push(0);for(let r=0;r>=8;for(;i>0;)t.push(255&i),i>>=8}for(let r=0;e[r]===this._leader&&r>24&255,u[t.length+1]=f>>16&255,u[t.length+2]=f>>8&255,u[t.length+3]=255&f;let h=_(Ai(i,e,u));o||(o=h.length,l=new Uint8Array(o),a=Math.ceil(n/o),c=n-(a-1)*o),l.set(h);for(let t=1;t=256)throw new Error("Depth too large!");return Ni(M([null!=this.privateKey?"0x0488ADE4":"0x0488B21E",O(this.depth),this.parentFingerprint,U(O(this.index),4),this.chainCode,null!=this.privateKey?M(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new Di(Ui,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(2147483647&e));const r=new Uint8Array(37);if(e&Ri){if(!this.privateKey)throw new Error("cannot derive child of neutered node");r.set(_(this.privateKey),1),t&&(t+="'")}else r.set(_(this.publicKey));for(let t=24;t>=0;t-=8)r[33+(t>>3)]=e>>24-t&255;const n=_(Ai(yi.sha512,this.chainCode,r)),i=n.slice(0,32),o=n.slice(32);let a=null,s=null;if(this.privateKey)a=Bi(X.from(i).add(this.privateKey).mod(Ii));else{s=new $r(O(i))._addPoint(this.publicKey)}let u=t;const c=this.mnemonic;return c&&(u=Object.freeze({phrase:c.phrase,path:t,locale:c.locale||"en"})),new Di(Ui,a,s,this.fingerprint,Bi(o),e,this.depth+1,u)}derivePath(e){const t=e.split("/");if(0===t.length||"m"===t[0]&&0!==this.depth)throw new Error("invalid path - "+e);"m"===t[0]&&t.shift();let r=this;for(let e=0;e=Ri)throw new Error("invalid path index - "+n);r=r._derive(Ri+e)}else{if(!n.match(/^[0-9]+$/))throw new Error("invalid path component - "+n);{const e=parseInt(n);if(e>=Ri)throw new Error("invalid path index - "+n);r=r._derive(e)}}}return r}static _fromSeed(e,t){const r=_(e);if(r.length<16||r.length>64)throw new Error("invalid seed");const n=_(Ai(yi.sha512,Oi,r));return new Di(Ui,Bi(n.slice(0,32)),null,"0x00000000",Bi(n.slice(32)),0,0,t)}static fromMnemonic(e,t,r){return e=Ji(Hi(e,r=Li(r)),r),Di._fromSeed(ji(e,t),{phrase:e,path:"m",locale:r.locale})}static fromSeed(e){return Di._fromSeed(e,null)}static fromExtendedKey(e){const t=mi.decode(e);82===t.length&&Ni(t.slice(0,78))===e||Pi.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");const r=t[4],n=O(t.slice(5,9)),i=parseInt(O(t.slice(9,13)).substring(2),16),o=O(t.slice(13,45)),a=t.slice(45,78);switch(O(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new Di(Ui,null,O(a),n,o,i,r,null);case"0x0488ade4":case"0x04358394 ":if(0!==a[0])break;return new Di(Ui,O(a.slice(1)),null,n,o,i,r,null)}return Pi.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}}function ji(e,t){t||(t="");const r=qe("mnemonic"+t,je.NFKD);return Si(qe(e,je.NFKD),r,2048,64,"sha512")}function Hi(e,t){t=Li(t),Pi.checkNormalize();const r=t.split(e);if(r.length%3!=0)throw new Error("invalid mnemonic");const n=_(new Uint8Array(Math.ceil(11*r.length/8)));let i=0;for(let e=0;e>3]|=1<<7-i%8),i++}const o=32*r.length/3,a=Ci(r.length/3);if((_(vi(n.slice(0,o/8)))[0]&a)!==(n[n.length-1]&a))throw new Error("invalid checksum");return O(n.slice(0,o/8))}function Ji(e,t){if(t=Li(t),(e=_(e)).length%4!=0||e.length<16||e.length>32)throw new Error("invalid entropy");const r=[0];let n=11;for(let t=0;t8?(r[r.length-1]<<=8,r[r.length-1]|=e[t],n-=8):(r[r.length-1]<<=n,r[r.length-1]|=e[t]>>8-n,r.push(e[t]&(1<<8-n)-1),n+=3);const i=e.length/4,o=_(vi(e))[0]&Ci(i);return r[r.length-1]<<=i,r[r.length-1]|=o>>8-i,t.join(r.map((e=>t.getWord(e))))}function zi(e,t){try{return Hi(e,t),!0}catch(e){}return!1}function Gi(e){return("number"!=typeof e||e<0||e>=Ri||e%1)&&Pi.throwArgumentError("invalid account index","index",e),`m/44'/60'/${e}'/0/0`}const qi=new b("random/5.7.0");const Ki=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r.g)return r.g;throw new Error("unable to locate global object")}();let Vi=Ki.crypto||Ki.msCrypto;function Xi(e){(e<=0||e>1024||e%1||e!=e)&&qi.throwArgumentError("invalid length","length",e);const t=new Uint8Array(e);return Vi.getRandomValues(t),_(t)}Vi&&Vi.getRandomValues||(qi.warn("WARNING: Missing strong random number source"),Vi={getRandomValues:function(e){return qi.throwError("no secure random source avaialble",b.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});var Qi=r(48709),Wi=r.n(Qi),Zi=r(17635),Yi=r.n(Zi);function $i(e){return"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),_(e)}function eo(e,t){for(e=String(e);e.lengtht)),te(this,"address",cn(this.publicKey)),this.address!==Be(e.address)&&ko.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),function(e){const t=e.mnemonic;return t&&t.phrase}(e)){const t=e.mnemonic;te(this,"_mnemonic",(()=>({phrase:t.phrase,path:t.path||Fi,locale:t.locale||"en"})));const r=this.mnemonic;cn(Di.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path).privateKey)!==this.address&&ko.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else te(this,"_mnemonic",(()=>null))}else{if($r.isSigningKey(e))"secp256k1"!==e.curve&&ko.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),te(this,"_signingKey",(()=>e));else{"string"==typeof e&&e.match(/^[0-9a-f]*$/i)&&64===e.length&&(e="0x"+e);const t=new $r(e);te(this,"_signingKey",(()=>t))}te(this,"_mnemonic",(()=>null)),te(this,"address",cn(this.publicKey))}var r;t&&!or.isProvider(t)&&ko.throwArgumentError("invalid provider","provider",t),te(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Eo(this,e)}signTransaction(e){return ne(e).then((t=>{null!=t.from&&(Be(t.from)!==this.address&&ko.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);const r=this._signingKey().signDigest(ve(gn(t)));return gn(t,r)}))}signMessage(e){return So(this,void 0,void 0,(function*(){return D(this._signingKey().signDigest(Wn(e)))}))}_signTypedData(e,t,r){return So(this,void 0,void 0,(function*(){const n=yield di.resolveNames(e,t,r,(e=>(null==this.provider&&ko.throwError("cannot resolve ENS names without a provider",b.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:e}),this.provider.resolveName(e))));return D(this._signingKey().signDigest(di.hash(n.domain,t,n.value)))}))}encrypt(e,t,r){if("function"!=typeof t||r||(r=t,t={}),r&&"function"!=typeof r)throw new Error("invalid callback");return t||(t={}),function(e,t,r,n){try{if(Be(e.address)!==cn(e.privateKey))throw new Error("address/privateKey mismatch");if(so(e)){const t=e.mnemonic;if(Di.fromMnemonic(t.phrase,null,t.locale).derivePath(t.path||Fi).privateKey!=e.privateKey)throw new Error("mnemonic mismatch")}}catch(e){return Promise.reject(e)}"function"!=typeof r||n||(n=r,r={}),r||(r={});const i=_(e.privateKey),o=to(t);let a=null,s=null,u=null;if(so(e)){const t=e.mnemonic;a=_(Hi(t.phrase,t.locale||"en")),s=t.path||Fi,u=t.locale||"en"}let c=r.client;c||(c="ethers.js");let l=null;l=r.salt?_(r.salt):Xi(32);let f=null;if(r.iv){if(f=_(r.iv),16!==f.length)throw new Error("invalid iv")}else f=Xi(16);let h=null;if(r.uuid){if(h=_(r.uuid),16!==h.length)throw new Error("invalid uuid")}else h=Xi(16);let d=1<<17,p=8,m=1;return r.scrypt&&(r.scrypt.N&&(d=r.scrypt.N),r.scrypt.r&&(p=r.scrypt.r),r.scrypt.p&&(m=r.scrypt.p)),Yi().scrypt(o,l,d,p,m,64,n).then((t=>{const r=(t=_(t)).slice(0,16),n=t.slice(16,32),o=t.slice(32,64),y=new(Wi().Counter)(f),g=_(new(Wi().ModeOfOperation.ctr)(r,y).encrypt(i)),b=ve(M([n,g])),v={address:e.address.substring(2).toLowerCase(),id:no(h),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:O(f).substring(2)},ciphertext:O(g).substring(2),kdf:"scrypt",kdfparams:{salt:O(l).substring(2),n:d,dklen:32,p:m,r:p},mac:b.substring(2)}};if(a){const e=Xi(16),t=new(Wi().Counter)(e),r=_(new(Wi().ModeOfOperation.ctr)(o,t).encrypt(a)),n=new Date,i=n.getUTCFullYear()+"-"+eo(n.getUTCMonth()+1,2)+"-"+eo(n.getUTCDate(),2)+"T"+eo(n.getUTCHours(),2)+"-"+eo(n.getUTCMinutes(),2)+"-"+eo(n.getUTCSeconds(),2)+".0Z";v["x-ethers"]={client:c,gethFilename:"UTC--"+i+"--"+v.address,mnemonicCounter:O(e).substring(2),mnemonicCiphertext:O(r).substring(2),path:s,locale:u,version:"0.1"}}return JSON.stringify(v)}))}(this,e,t,r)}static createRandom(e){let t=Xi(16);e||(e={}),e.extraEntropy&&(t=_(C(ve(M([t,e.extraEntropy])),0,16)));const r=Ji(t,e.locale);return Eo.fromMnemonic(r,e.path,e.locale)}static fromEncryptedJson(e,t,r){return wo(e,t,r).then((e=>new Eo(e)))}static fromEncryptedJsonSync(e,t){return new Eo(Ao(e,t))}static fromMnemonic(e,t,r){return t||(t=Fi),new Eo(Di.fromMnemonic(e,null,r).derivePath(t))}}function _o(e,t){return ln(Wn(e),t)}function Mo(e,t,r,n){return ln(di.hash(e,t,r),n)}const To="0x0000000000000000000000000000000000000000",xo="0x0000000000000000000000000000000000000000000000000000000000000000",Po="Ξ",Io=new b("networks/5.7.1");function Oo(e){const t=function(t,r){null==r&&(r={});const n=[];if(t.InfuraProvider&&"-"!==r.infura)try{n.push(new t.InfuraProvider(e,r.infura))}catch(e){}if(t.EtherscanProvider&&"-"!==r.etherscan)try{n.push(new t.EtherscanProvider(e,r.etherscan))}catch(e){}if(t.AlchemyProvider&&"-"!==r.alchemy)try{n.push(new t.AlchemyProvider(e,r.alchemy))}catch(e){}if(t.PocketProvider&&"-"!==r.pocket){const i=["goerli","ropsten","rinkeby","sepolia"];try{const o=new t.PocketProvider(e,r.pocket);o.network&&-1===i.indexOf(o.network.name)&&n.push(o)}catch(e){}}if(t.CloudflareProvider&&"-"!==r.cloudflare)try{n.push(new t.CloudflareProvider(e))}catch(e){}if(t.AnkrProvider&&"-"!==r.ankr)try{const i=["ropsten"],o=new t.AnkrProvider(e,r.ankr);o.network&&-1===i.indexOf(o.network.name)&&n.push(o)}catch(e){}if(0===n.length)return null;if(t.FallbackProvider){let i=1;return null!=r.quorum?i=r.quorum:"homestead"===e&&(i=2),new t.FallbackProvider(n,i)}return n[0]};return t.renetwork=function(e){return Oo(e)},t}function Ro(e,t){const r=function(r,n){return r.JsonRpcProvider?new r.JsonRpcProvider(e,t):null};return r.renetwork=function(t){return Ro(e,t)},r}const Co={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:Oo("homestead")},Bo={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:Oo("ropsten")},No={chainId:63,name:"classicMordor",_defaultProvider:Ro("https://www.ethercluster.com/mordor","classicMordor")},Lo={unspecified:{chainId:0,name:"unspecified"},homestead:Co,mainnet:Co,morden:{chainId:2,name:"morden"},ropsten:Bo,testnet:Bo,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:Oo("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:Oo("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:Oo("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:Oo("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Ro("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:No,classicTestnet:No,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Ro("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:Oo("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:Oo("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function Uo(e){if(null==e)return null;if("number"==typeof e){for(const t in Lo){const r=Lo[t];if(r.chainId===e)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:e,name:"unknown"}}if("string"==typeof e){const t=Lo[e];return null==t?null:{name:t.name,chainId:t.chainId,ensAddress:t.ensAddress,_defaultProvider:t._defaultProvider||null}}const t=Lo[e.name];if(!t)return"number"!=typeof e.chainId&&Io.throwArgumentError("invalid network chainId","network",e),e;0!==e.chainId&&e.chainId!==t.chainId&&Io.throwArgumentError("network chainId mismatch","network",e);let r=e._defaultProvider||null;var n;return null==r&&t._defaultProvider&&(r=(n=t._defaultProvider)&&"function"==typeof n.renetwork?t._defaultProvider.renetwork(e):t._defaultProvider),{name:e.name,chainId:t.chainId,ensAddress:e.ensAddress||t.ensAddress||null,_defaultProvider:r}}function Fo(e){e=atob(e);const t=[];for(let r=0;r0&&Array.isArray(e)?i(e,t-1):r.push(e)}))};return i(e,t),r}function Ho(e){return function(e){let t=0;return()=>e[t++]}(function(e){let t=0;function r(){return e[t++]<<8|e[t++]}let n=r(),i=1,o=[0,1];for(let e=1;e>--u&1}const f=Math.pow(2,31),h=f>>>1,d=h>>1,p=f-1;let m=0;for(let e=0;e<31;e++)m=m<<1|l();let y=[],g=0,b=f;for(;;){let e=Math.floor(((m-g+1)*i-1)/b),t=0,r=n;for(;r-t>1;){let n=t+r>>>1;e>>1|l(),a=a<<1^h,s=(s^h)<<1|h|1;g=a,b=1+s-a}let v=n-4;return y.map((t=>{switch(t-v){case 3:return v+65792+(e[s++]<<16|e[s++]<<8|e[s++]);case 2:return v+256+(e[s++]<<8|e[s++]);case 1:return v+e[s++];default:return t-1}}))}(e))}function Jo(e){return 1&e?~e>>1:e>>1}function zo(e,t){let r=Array(e);for(let n=0,i=-1;nt[e])):r}function Ko(e,t,r){let n=Array(e).fill(void 0).map((()=>[]));for(let i=0;in[t].push(e)));return n}function Vo(e,t){let r=1+t(),n=t(),i=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(r)}return t}(t);return jo(Ko(i.length,1+e,t).map(((e,t)=>{const o=e[0],a=e.slice(1);return Array(i[t]).fill(void 0).map(((e,t)=>{let i=t*n;return[o+t*r,a.map((e=>e+i))]}))})))}function Xo(e,t){return Ko(1+t(),1+e,t).map((e=>[e[0],e.slice(1)]))}const Qo=Ho(Fo("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA==")),Wo=new Set(qo(Qo)),Zo=new Set(qo(Qo)),Yo=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(Vo(r,e))}for(;;){let r=e()-1;if(r<0)break;t.push(Xo(r,e))}return function(e){const t={};for(let r=0;re-t));return function r(){let n=[];for(;;){let i=qo(e,t);if(0==i.length)break;n.push({set:new Set(i),node:r()})}n.sort(((e,t)=>t.set.size-e.set.size));let i=e(),o=i%3;i=i/3|0;let a=!!(1&i);return i>>=1,{branches:n,valid:o,fe0f:a,save:1==i,check:2==i}}()}(Qo);function ea(e){return We(e)}function ta(e){return e.filter((e=>65039!=e))}function ra(e){for(let t of e.split(".")){let e=ea(t);try{for(let t=e.lastIndexOf(95)-1;t>=0;t--)if(95!==e[t])throw new Error("underscore only allowed at start");if(e.length>=4&&e.every((e=>e<128))&&45===e[2]&&45===e[3])throw new Error("invalid label extension")}catch(e){throw new Error(`Invalid label "${t}": ${e.message}`)}}return e}function na(e){return ra(function(e,t){let r=ea(e).reverse(),n=[];for(;r.length;){let e=ia(r);if(e){n.push(...t(e));continue}let i=r.pop();if(Wo.has(i)){n.push(i);continue}if(Zo.has(i))continue;let o=Yo[i];if(!o)throw new Error(`Disallowed codepoint: 0x${i.toString(16).toUpperCase()}`);n.push(...o)}return ra((i=String.fromCodePoint(...n),i.normalize("NFC")));var i}(e,ta))}function ia(e,t){var r;let n,i,o=$o,a=[],s=e.length;for(t&&(t.length=0);s;){let u=e[--s];if(o=null===(r=o.branches.find((e=>e.set.has(u))))||void 0===r?void 0:r.node,!o)break;if(o.save)i=u;else if(o.check&&u===i)break;a.push(u),o.fe0f&&(a.push(65039),s>0&&65039==e[s-1]&&s--),o.valid&&(n=a.slice(),2==o.valid&&n.splice(1,1),t&&t.push(...e.slice(s).reverse()),e.length=s)}return n}const oa=new b(Zn),aa=new Uint8Array(32);function sa(e){if(0===e.length)throw new Error("invalid ENS name; empty component");return e}function ua(e){const t=qe(na(e)),r=[];if(0===e.length)return r;let n=0;for(let e=0;e=t.length)throw new Error("invalid ENS name; empty component");return r.push(sa(t.slice(n))),r}function ca(e){try{return 0!==ua(e).length}catch(e){}return!1}function la(e){"string"!=typeof e&&oa.throwArgumentError("invalid ENS name; not a string","name",e);let t=aa;const r=ua(e);for(;r.length;)t=ve(M([t,ve(r.pop())]));return O(t)}function fa(e){return O(M(ua(e).map((e=>{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"}aa.fill(0);var ha=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};function da(e,t){return ha(this,void 0,void 0,(function*(){null==t&&(t={});const r={method:t.method||"GET",headers:t.headers||{},body:t.body||void 0};if(!0!==t.skipFetchSetup&&(r.mode="cors",r.cache="no-cache",r.credentials="same-origin",r.redirect="follow",r.referrer="client"),null!=t.fetchOptions){const e=t.fetchOptions;e.mode&&(r.mode=e.mode),e.cache&&(r.cache=e.cache),e.credentials&&(r.credentials=e.credentials),e.redirect&&(r.redirect=e.redirect),e.referrer&&(r.referrer=e.referrer)}const n=yield fetch(e,r),i=yield n.arrayBuffer(),o={};return n.headers.forEach?n.headers.forEach(((e,t)=>{o[t.toLowerCase()]=e})):n.headers.keys().forEach((e=>{o[e.toLowerCase()]=n.headers.get(e)})),{headers:o,statusCode:n.status,statusMessage:n.statusText,body:_(new Uint8Array(i))}}))}var pa=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ma=new b("web/5.7.1");function ya(e){return new Promise((t=>{setTimeout(t,e)}))}function ga(e,t){if(null==e)return null;if("string"==typeof e)return e;if(S(e)){if(t&&("text"===t.split("/")[0]||"application/json"===t.split(";")[0].trim()))try{return Qe(e)}catch(e){}return O(e)}return e}function ba(e,t,r){const n="object"==typeof e&&null!=e.throttleLimit?e.throttleLimit:12;ma.assertArgument(n>0&&n%1==0,"invalid connection throttle limit","connection.throttleLimit",n);const i="object"==typeof e?e.throttleCallback:null,o="object"==typeof e&&"number"==typeof e.throttleSlotInterval?e.throttleSlotInterval:100;ma.assertArgument(o>0&&o%1==0,"invalid connection throttle slot interval","connection.throttleSlotInterval",o);const a="object"==typeof e&&!!e.errorPassThrough,s={};let u=null;const c={method:"GET"};let l=!1,f=12e4;if("string"==typeof e)u=e;else if("object"==typeof e){if(null!=e&&null!=e.url||ma.throwArgumentError("missing URL","connection.url",e),u=e.url,"number"==typeof e.timeout&&e.timeout>0&&(f=e.timeout),e.headers)for(const t in e.headers)s[t.toLowerCase()]={key:t,value:String(e.headers[t])},["if-none-match","if-modified-since"].indexOf(t.toLowerCase())>=0&&(l=!0);if(c.allowGzip=!!e.allowGzip,null!=e.user&&null!=e.password){"https:"!==u.substring(0,6)&&!0!==e.allowInsecureAuthentication&&ma.throwError("basic authentication requires a secure https url",b.errors.INVALID_ARGUMENT,{argument:"url",url:u,user:e.user,password:"[REDACTED]"});const t=e.user+":"+e.password;s.authorization={key:"Authorization",value:"Basic "+Do(qe(t))}}null!=e.skipFetchSetup&&(c.skipFetchSetup=!!e.skipFetchSetup),null!=e.fetchOptions&&(c.fetchOptions=oe(e.fetchOptions))}const h=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),d=u?u.match(h):null;if(d)try{const e={statusCode:200,statusMessage:"OK",headers:{"content-type":d[1]||"text/plain"},body:d[2]?Fo(d[3]):(p=d[3],qe(p.replace(/%([0-9a-f][0-9a-f])/gi,((e,t)=>String.fromCharCode(parseInt(t,16))))))};let t=e.body;return r&&(t=r(e.body,e)),Promise.resolve(t)}catch(e){ma.throwError("processing response error",b.errors.SERVER_ERROR,{body:ga(d[1],d[2]),error:e,requestBody:null,requestMethod:"GET",url:u})}var p;t&&(c.method="POST",c.body=t,null==s["content-type"]&&(s["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==s["content-length"]&&(s["content-length"]={key:"Content-Length",value:String(t.length)}));const m={};Object.keys(s).forEach((e=>{const t=s[e];m[t.key]=t.value})),c.headers=m;const y=function(){let e=null;return{promise:new Promise((function(t,r){f&&(e=setTimeout((()=>{null!=e&&(e=null,r(ma.makeError("timeout",b.errors.TIMEOUT,{requestBody:ga(c.body,m["content-type"]),requestMethod:c.method,timeout:f,url:u})))}),f))})),cancel:function(){null!=e&&(clearTimeout(e),e=null)}}}(),g=function(){return pa(this,void 0,void 0,(function*(){for(let e=0;e=300)&&(y.cancel(),ma.throwError("bad response",b.errors.SERVER_ERROR,{status:t.statusCode,headers:t.headers,body:ga(s,t.headers?t.headers["content-type"]:null),requestBody:ga(c.body,m["content-type"]),requestMethod:c.method,url:u})),r)try{const e=yield r(s,t);return y.cancel(),e}catch(r){if(r.throttleRetry&&e"content-type"===e.toLowerCase())).length||(r.headers=oe(r.headers),r.headers["content-type"]="application/json")}else r.headers={"content-type":"application/json"};e=r}return ba(e,n,((e,t)=>{let n=null;if(null!=e)try{n=JSON.parse(Qe(e))}catch(t){ma.throwError("invalid JSON",b.errors.SERVER_ERROR,{body:e,error:t})}return r&&(n=r(n,t)),n}))}function wa(e,t){return t||(t={}),null==(t=oe(t)).floor&&(t.floor=0),null==t.ceiling&&(t.ceiling=1e4),null==t.interval&&(t.interval=250),new Promise((function(r,n){let i=null,o=!1;const a=()=>!o&&(o=!0,i&&clearTimeout(i),!0);t.timeout&&(i=setTimeout((()=>{a()&&n(new Error("timeout"))}),t.timeout));const s=t.retryLimit;let u=0;!function i(){return e().then((function(e){if(void 0!==e)a()&&r(e);else if(t.oncePoll)t.oncePoll.once("poll",i);else if(t.onceBlock)t.onceBlock.once("block",i);else if(!o){if(u++,u>s)return void(a()&&n(new Error("retry limit reached")));let e=t.interval*parseInt(String(Math.random()*Math.pow(2,u)));et.ceiling&&(e=t.ceiling),setTimeout(i,e)}return null}),(function(e){a()&&n(e)}))}()}))}var Aa=r(92882),Sa=r.n(Aa);const ka="providers/5.7.2",Ea=new b(ka);class _a{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){const e={},t=this.address.bind(this),r=this.bigNumber.bind(this),n=this.blockTag.bind(this),i=this.data.bind(this),o=this.hash.bind(this),a=this.hex.bind(this),s=this.number.bind(this),u=this.type.bind(this);return e.transaction={hash:o,type:u,accessList:_a.allowNull(this.accessList.bind(this),null),blockHash:_a.allowNull(o,null),blockNumber:_a.allowNull(s,null),transactionIndex:_a.allowNull(s,null),confirmations:_a.allowNull(s,null),from:t,gasPrice:_a.allowNull(r),maxPriorityFeePerGas:_a.allowNull(r),maxFeePerGas:_a.allowNull(r),gasLimit:r,to:_a.allowNull(t,null),value:r,nonce:s,data:i,r:_a.allowNull(this.uint256),s:_a.allowNull(this.uint256),v:_a.allowNull(s),creates:_a.allowNull(t,null),raw:_a.allowNull(i)},e.transactionRequest={from:_a.allowNull(t),nonce:_a.allowNull(s),gasLimit:_a.allowNull(r),gasPrice:_a.allowNull(r),maxPriorityFeePerGas:_a.allowNull(r),maxFeePerGas:_a.allowNull(r),to:_a.allowNull(t),value:_a.allowNull(r),data:_a.allowNull((e=>this.data(e,!0))),type:_a.allowNull(s),accessList:_a.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:s,blockNumber:s,transactionHash:o,address:t,topics:_a.arrayOf(o),data:i,logIndex:s,blockHash:o},e.receipt={to:_a.allowNull(this.address,null),from:_a.allowNull(this.address,null),contractAddress:_a.allowNull(t,null),transactionIndex:s,root:_a.allowNull(a),gasUsed:r,logsBloom:_a.allowNull(i),blockHash:o,transactionHash:o,logs:_a.arrayOf(this.receiptLog.bind(this)),blockNumber:s,confirmations:_a.allowNull(s,null),cumulativeGasUsed:r,effectiveGasPrice:_a.allowNull(r),status:_a.allowNull(s),type:u},e.block={hash:_a.allowNull(o),parentHash:o,number:s,timestamp:s,nonce:_a.allowNull(a),difficulty:this.difficulty.bind(this),gasLimit:r,gasUsed:r,miner:_a.allowNull(t),extraData:i,transactions:_a.allowNull(_a.arrayOf(o)),baseFeePerGas:_a.allowNull(r)},e.blockWithTransactions=oe(e.block),e.blockWithTransactions.transactions=_a.allowNull(_a.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:_a.allowNull(n,void 0),toBlock:_a.allowNull(n,void 0),blockHash:_a.allowNull(o,void 0),address:_a.allowNull(t,void 0),topics:_a.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:_a.allowNull(s),blockHash:_a.allowNull(o),transactionIndex:s,removed:_a.allowNull(this.boolean.bind(this)),address:t,data:_a.allowFalsish(i,"0x"),topics:_a.arrayOf(o),transactionHash:o,logIndex:s},e}accessList(e){return dn(e||[])}number(e){return"0x"===e?0:X.from(e).toNumber()}type(e){return"0x"===e||null==e?0:X.from(e).toNumber()}bigNumber(e){return X.from(e)}boolean(e){if("boolean"==typeof e)return e;if("string"==typeof e){if("true"===(e=e.toLowerCase()))return!0;if("false"===e)return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return"string"==typeof e&&(t||"0x"===e.substring(0,2)||(e="0x"+e),P(e))?e.toLowerCase():Ea.throwArgumentError("invalid hash","value",e)}data(e,t){const r=this.hex(e,t);if(r.length%2!=0)throw new Error("invalid data; odd-length - "+e);return r}address(e){return Be(e)}callAddress(e){if(!P(e,32))return null;const t=Be(C(e,12));return t===To?null:t}contractAddress(e){return Ue(e)}blockTag(e){if(null==e)return"latest";if("earliest"===e)return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if("number"==typeof e||P(e))return N(e);throw new Error("invalid blockTag")}hash(e,t){const r=this.hex(e,t);return 32!==R(r)?Ea.throwArgumentError("invalid hash","value",e):r}difficulty(e){if(null==e)return null;const t=X.from(e);try{return t.toNumber()}catch(e){}return null}uint256(e){if(!P(e))throw new Error("invalid uint256");return U(e,32)}_block(e,t){null!=e.author&&null==e.miner&&(e.miner=e.author);const r=null!=e._difficulty?e._difficulty:e.difficulty,n=_a.check(t,e);return n._difficulty=null==r?null:X.from(r),n}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return _a.check(this.formats.transactionRequest,e)}transactionResponse(e){null!=e.gas&&null==e.gasLimit&&(e.gasLimit=e.gas),e.to&&X.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),null!=e.input&&null==e.data&&(e.data=e.input),null==e.to&&null==e.creates&&(e.creates=this.contractAddress(e)),1!==e.type&&2!==e.type||null!=e.accessList||(e.accessList=[]);const t=_a.check(this.formats.transaction,e);if(null!=e.chainId){let r=e.chainId;P(r)&&(r=X.from(r).toNumber()),t.chainId=r}else{let r=e.networkId;null==r&&null==t.v&&(r=e.chainId),P(r)&&(r=X.from(r).toNumber()),"number"!=typeof r&&null!=t.v&&(r=(t.v-35)/2,r<0&&(r=0),r=parseInt(r)),"number"!=typeof r&&(r=0),t.chainId=r}return t.blockHash&&"x"===t.blockHash.replace(/0/g,"")&&(t.blockHash=null),t}transaction(e){return vn(e)}receiptLog(e){return _a.check(this.formats.receiptLog,e)}receipt(e){const t=_a.check(this.formats.receipt,e);if(null!=t.root)if(t.root.length<=4){const e=X.from(t.root).toNumber();0===e||1===e?(null!=t.status&&t.status!==e&&Ea.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=e,delete t.root):Ea.throwArgumentError("invalid alt-root-status","value.root",t.root)}else 66!==t.root.length&&Ea.throwArgumentError("invalid root hash","value.root",t.root);return null!=t.status&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map((e=>this.topics(e))):null!=e?this.hash(e,!0):null}filter(e){return _a.check(this.formats.filter,e)}filterLog(e){return _a.check(this.formats.filterLog,e)}static check(e,t){const r={};for(const n in e)try{const i=e[n](t[n]);void 0!==i&&(r[n]=i)}catch(e){throw e.checkKey=n,e.checkValue=t[n],e}return r}static allowNull(e,t){return function(r){return null==r?t:e(r)}}static allowFalsish(e,t){return function(r){return r?e(r):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");const r=[];return t.forEach((function(t){r.push(e(t))})),r}}}function Ma(e){return e&&"function"==typeof e.isCommunityResource}function Ta(e){return Ma(e)&&e.isCommunityResource()}let xa=!1;function Pa(){xa||(xa=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var Ia=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const Oa=new b(ka);function Ra(e){return null==e?"null":(32!==R(e)&&Oa.throwArgumentError("invalid topic","topic",e),e.toLowerCase())}function Ca(e){for(e=e.slice();e.length>0&&null==e[e.length-1];)e.pop();return e.map((e=>{if(Array.isArray(e)){const t={};e.forEach((e=>{t[Ra(e)]=!0}));const r=Object.keys(t);return r.sort(),r.join("|")}return Ra(e)})).join("&")}function Ba(e){if("string"==typeof e){if(32===R(e=e.toLowerCase()))return"tx:"+e;if(-1===e.indexOf(":"))return e}else{if(Array.isArray(e))return"filter:*:"+Ca(e);if(ir.isForkEvent(e))throw Oa.warn("not implemented"),new Error("not implemented");if(e&&"object"==typeof e)return"filter:"+(e.address||"*")+":"+Ca(e.topics||[])}throw new Error("invalid event - "+e)}function Na(){return(new Date).getTime()}function La(e){return new Promise((t=>{setTimeout(t,e)}))}const Ua=["block","network","pending","poll"];class Fa{constructor(e,t,r){te(this,"tag",e),te(this,"listener",t),te(this,"once",r),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){const e=this.tag.split(":");return"tx"!==e[0]?null:e[1]}get filter(){const e=this.tag.split(":");if("filter"!==e[0])return null;const t=e[1],r=""===(n=e[2])?[]:n.split(/&/g).map((e=>{if(""===e)return[];const t=e.split("|").map((e=>"null"===e?null:e));return 1===t.length?t[0]:t}));var n;const i={};return r.length>0&&(i.topics=r),t&&"*"!==t&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||Ua.indexOf(this.tag)>=0}}const Da={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function ja(e){return U(X.from(e).toHexString(),32)}function Ha(e){return mi.encode(M([e,C(vi(vi(e)),0,4)]))}const Ja=new RegExp("^(ipfs)://(.*)$","i"),za=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Ja,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Ga(e,t){try{return Qe(qa(e,t))}catch(e){}return null}function qa(e,t){if("0x"===e)return null;const r=X.from(C(e,t,t+32)).toNumber(),n=X.from(C(e,r,r+32)).toNumber();return C(e,r+32,r+32+n)}function Ka(e){return e.match(/^ipfs:\/\/ipfs\//i)?e=e.substring(12):e.match(/^ipfs:\/\//i)?e=e.substring(7):Oa.throwArgumentError("unsupported IPFS format","link",e),`https://gateway.ipfs.io/ipfs/${e}`}function Va(e){const t=_(e);if(t.length>32)throw new Error("internal; should not happen");const r=new Uint8Array(32);return r.set(t,32-t.length),r}function Xa(e){if(e.length%32==0)return e;const t=new Uint8Array(32*Math.ceil(e.length/32));return t.set(e),t}function Qa(e){const t=[];let r=0;for(let n=0;nX.from(e).eq(1))).catch((e=>{if(e.code===b.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e}))),this._supportsEip2544}_fetch(e,t){return Ia(this,void 0,void 0,(function*(){const r={to:this.address,ccipReadEnabled:!0,data:B([e,la(this.name),t||"0x"])};let n=!1;(yield this.supportsWildcard())&&(n=!0,r.data=B(["0x9061b923",Qa([fa(this.name),r.data])]));try{let e=yield this.provider.call(r);return _(e).length%32==4&&Oa.throwError("resolver threw error",b.errors.CALL_EXCEPTION,{transaction:r,data:e}),n&&(e=qa(e,0)),e}catch(e){if(e.code===b.errors.CALL_EXCEPTION)return null;throw e}}))}_fetchBytes(e,t){return Ia(this,void 0,void 0,(function*(){const r=yield this._fetch(e,t);return null!=r?qa(r,0):null}))}_getAddress(e,t){const r=Da[String(e)];if(null==r&&Oa.throwError(`unsupported coin type: ${e}`,b.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),"eth"===r.ilk)return this.provider.formatter.address(t);const n=_(t);if(null!=r.p2pkh){const e=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Ha(M([[r.p2pkh],"0x"+e[2]]))}}if(null!=r.p2sh){const e=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Ha(M([[r.p2sh],"0x"+e[2]]))}}if(null!=r.prefix){const e=n[1];let t=n[0];if(0===t?20!==e&&32!==e&&(t=-1):t=-1,t>=0&&n.length===2+e&&e>=1&&e<=75){const e=Sa().toWords(n.slice(2));return e.unshift(t),Sa().encode(r.prefix,e)}}return null}getAddress(e){return Ia(this,void 0,void 0,(function*(){if(null==e&&(e=60),60===e)try{const e=yield this._fetch("0x3b3b57de");return"0x"===e||e===xo?null:this.provider.formatter.callAddress(e)}catch(e){if(e.code===b.errors.CALL_EXCEPTION)return null;throw e}const t=yield this._fetchBytes("0xf1cb7e06",ja(e));if(null==t||"0x"===t)return null;const r=this._getAddress(e,t);return null==r&&Oa.throwError("invalid or unsupported coin data",b.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),r}))}getAvatar(){return Ia(this,void 0,void 0,(function*(){const e=[{type:"name",content:this.name}];try{const t=yield this.getText("avatar");if(null==t)return null;for(let r=0;re[t]))}return Oa.throwError("invalid or unsupported content hash data",b.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})}))}getText(e){return Ia(this,void 0,void 0,(function*(){let t=qe(e);t=M([ja(64),ja(t.length),t]),t.length%32!=0&&(t=M([t,U("0x",32-e.length%32)]));const r=yield this._fetchBytes("0x59d1d43c",O(t));return null==r||"0x"===r?null:Qe(r)}))}}let Za=null,Ya=1;class $a extends or{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),te(this,"anyNetwork","any"===e),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch((e=>{})),this._ready().catch((e=>{}));else{const t=re(new.target,"getNetwork")(e);t?(te(this,"_network",t),this.emit("network",t,null)):Oa.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return Ia(this,void 0,void 0,(function*(){if(null==this._network){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch(e){}null==e&&(e=yield this.detectNetwork()),e||Oa.throwError("no network detected",b.errors.UNKNOWN_ERROR,{}),null==this._network&&(this.anyNetwork?this._network=e:te(this,"_network",e),this.emit("network",e,null))}return this._network}))}get ready(){return wa((()=>this._ready().then((e=>e),(e=>{if(e.code!==b.errors.NETWORK_ERROR||"noNetwork"!==e.event)throw e}))))}static getFormatter(){return null==Za&&(Za=new _a),Za}static getNetwork(e){return Uo(null==e?"homestead":e)}ccipReadFetch(e,t,r){return Ia(this,void 0,void 0,(function*(){if(this.disableCcipRead||0===r.length)return null;const n=e.to.toLowerCase(),i=t.toLowerCase(),o=[];for(let e=0;e=0?null:JSON.stringify({data:i,sender:n}),u=yield va({url:a,errorPassThrough:!0},s,((e,t)=>(e.status=t.statusCode,e)));if(u.data)return u.data;const c=u.message||"unknown error";if(u.status>=400&&u.status<500)return Oa.throwError(`response not found during CCIP fetch: ${c}`,b.errors.SERVER_ERROR,{url:t,errorMessage:c});o.push(c)}return Oa.throwError(`error encountered during CCIP fetch: ${o.map((e=>JSON.stringify(e))).join(", ")}`,b.errors.SERVER_ERROR,{urls:r,errorMessages:o})}))}_getInternalBlockNumber(e){return Ia(this,void 0,void 0,(function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){const t=this._internalBlockNumber;try{const r=yield t;if(Na()-r.respTime<=e)return r.blockNumber;break}catch(e){if(this._internalBlockNumber===t)break}}const t=Na(),r=ne({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then((e=>null),(e=>e))}).then((({blockNumber:e,networkError:n})=>{if(n)throw this._internalBlockNumber===r&&(this._internalBlockNumber=null),n;const i=Na();return(e=X.from(e).toNumber()){this._internalBlockNumber===r&&(this._internalBlockNumber=null)})),(yield r).blockNumber}))}poll(){return Ia(this,void 0,void 0,(function*(){const e=Ya++,t=[];let r=null;try{r=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(e){return void this.emit("error",e)}if(this._setFastBlockNumber(r),this.emit("poll",e,r),r!==this._lastBlockNumber){if(-2===this._emitted.block&&(this._emitted.block=r-1),Math.abs(this._emitted.block-r)>1e3)Oa.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${r})`),this.emit("error",Oa.makeError("network block skew detected",b.errors.NETWORK_ERROR,{blockNumber:r,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",r);else for(let e=this._emitted.block+1;e<=r;e++)this.emit("block",e);this._emitted.block!==r&&(this._emitted.block=r,Object.keys(this._emitted).forEach((e=>{if("block"===e)return;const t=this._emitted[e];"pending"!==t&&r-t>12&&delete this._emitted[e]}))),-2===this._lastBlockNumber&&(this._lastBlockNumber=r-1),this._events.forEach((e=>{switch(e.type){case"tx":{const r=e.hash;let n=this.getTransactionReceipt(r).then((e=>e&&null!=e.blockNumber?(this._emitted["t:"+r]=e.blockNumber,this.emit(r,e),null):null)).catch((e=>{this.emit("error",e)}));t.push(n);break}case"filter":if(!e._inflight){e._inflight=!0,-2===e._lastBlockNumber&&(e._lastBlockNumber=r-1);const n=e.filter;n.fromBlock=e._lastBlockNumber+1,n.toBlock=r;const i=n.toBlock-this._maxFilterBlockRange;i>n.fromBlock&&(n.fromBlock=i),n.fromBlock<0&&(n.fromBlock=0);const o=this.getLogs(n).then((t=>{e._inflight=!1,0!==t.length&&t.forEach((t=>{t.blockNumber>e._lastBlockNumber&&(e._lastBlockNumber=t.blockNumber),this._emitted["b:"+t.blockHash]=t.blockNumber,this._emitted["t:"+t.transactionHash]=t.blockNumber,this.emit(n,t)}))})).catch((t=>{this.emit("error",t),e._inflight=!1}));t.push(o)}}})),this._lastBlockNumber=r,Promise.all(t).then((()=>{this.emit("didPoll",e)})).catch((e=>{this.emit("error",e)}))}else this.emit("didPoll",e)}))}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return Ia(this,void 0,void 0,(function*(){return Oa.throwError("provider does not support network detection",b.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})}))}getNetwork(){return Ia(this,void 0,void 0,(function*(){const e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield La(0),this._network;const r=Oa.makeError("underlying network changed",b.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",r),r}return e}))}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then((e=>{this._setFastBlockNumber(e)}),(e=>{})),null!=this._fastBlockNumber?this._fastBlockNumber:-1}get polling(){return null!=this._poller}set polling(e){e&&!this._poller?(this._poller=setInterval((()=>{this.poll()}),this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout((()=>{this.poll(),this._bootstrapPoll=setTimeout((()=>{this._poller||this.poll(),this._bootstrapPoll=null}),this.pollingInterval)}),0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if("number"!=typeof e||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval((()=>{this.poll()}),this._pollingInterval))}_getFastBlockNumber(){const e=Na();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then((e=>((null==this._fastBlockNumber||e>this._fastBlockNumber)&&(this._fastBlockNumber=e),this._fastBlockNumber)))),this._fastBlockNumberPromise}_setFastBlockNumber(e){null!=this._fastBlockNumber&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,r){return Ia(this,void 0,void 0,(function*(){return this._waitForTransaction(e,null==t?1:t,r||0,null)}))}_waitForTransaction(e,t,r,n){return Ia(this,void 0,void 0,(function*(){const i=yield this.getTransactionReceipt(e);return(i?i.confirmations:0)>=t?i:new Promise(((i,o)=>{const a=[];let s=!1;const u=function(){return!!s||(s=!0,a.forEach((e=>{e()})),!1)},c=e=>{e.confirmations{this.removeListener(e,c)})),n){let r=n.startBlock,i=null;const c=a=>Ia(this,void 0,void 0,(function*(){s||(yield La(1e3),this.getTransactionCount(n.from).then((l=>Ia(this,void 0,void 0,(function*(){if(!s){if(l<=n.nonce)r=a;else{{const t=yield this.getTransaction(e);if(t&&null!=t.blockNumber)return}for(null==i&&(i=r-3,i{s||this.once("block",c)})))}));if(s)return;this.once("block",c),a.push((()=>{this.removeListener("block",c)}))}if("number"==typeof r&&r>0){const e=setTimeout((()=>{u()||o(Oa.makeError("timeout exceeded",b.errors.TIMEOUT,{timeout:r}))}),r);e.unref&&e.unref(),a.push((()=>{clearTimeout(e)}))}}))}))}getBlockNumber(){return Ia(this,void 0,void 0,(function*(){return this._getInternalBlockNumber(0)}))}getGasPrice(){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const e=yield this.perform("getGasPrice",{});try{return X.from(e)}catch(t){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}}))}getBalance(e,t){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getBalance",r);try{return X.from(n)}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getBalance",params:r,result:n,error:e})}}))}getTransactionCount(e,t){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getTransactionCount",r);try{return X.from(n).toNumber()}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getTransactionCount",params:r,result:n,error:e})}}))}getCode(e,t){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getCode",r);try{return O(n)}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getCode",params:r,result:n,error:e})}}))}getStorageAt(e,t,r){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const n=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(r),position:Promise.resolve(t).then((e=>N(e)))}),i=yield this.perform("getStorageAt",n);try{return O(i)}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getStorageAt",params:n,result:i,error:e})}}))}_wrapTransaction(e,t,r){if(null!=t&&32!==R(t))throw new Error("invalid response - sendTransaction");const n=e;return null!=t&&e.hash!==t&&Oa.throwError("Transaction hash mismatch from Provider.sendTransaction.",b.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),n.wait=(t,n)=>Ia(this,void 0,void 0,(function*(){let i;null==t&&(t=1),null==n&&(n=0),0!==t&&null!=r&&(i={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:r});const o=yield this._waitForTransaction(e.hash,t,n,i);return null==o&&0===t?null:(this._emitted["t:"+e.hash]=o.blockNumber,0===o.status&&Oa.throwError("transaction failed",b.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:o}),o)})),n}sendTransaction(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Promise.resolve(e).then((e=>O(e))),r=this.formatter.transaction(e);null==r.confirmations&&(r.confirmations=0);const n=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{const e=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(r,e,n)}catch(e){throw e.transaction=r,e.transactionHash=r.hash,e}}))}_getTransactionRequest(e){return Ia(this,void 0,void 0,(function*(){const t=yield e,r={};return["from","to"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?this._getAddress(e):null)))})),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?X.from(e):null)))})),["type"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>null!=e?e:null)))})),t.accessList&&(r.accessList=this.formatter.accessList(t.accessList)),["data"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?O(e):null)))})),this.formatter.transactionRequest(yield ne(r))}))}_getFilter(e){return Ia(this,void 0,void 0,(function*(){e=yield e;const t={};return null!=e.address&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach((r=>{null!=e[r]&&(t[r]=e[r])})),["fromBlock","toBlock"].forEach((r=>{null!=e[r]&&(t[r]=this._getBlockTag(e[r]))})),this.formatter.filter(yield ne(t))}))}_call(e,t,r){return Ia(this,void 0,void 0,(function*(){r>=10&&Oa.throwError("CCIP read exceeded maximum redirections",b.errors.SERVER_ERROR,{redirects:r,transaction:e});const n=e.to,i=yield this.perform("call",{transaction:e,blockTag:t});if(r>=0&&"latest"===t&&null!=n&&"0x556f1830"===i.substring(0,10)&&R(i)%32==4)try{const o=C(i,4),a=C(o,0,32);X.from(a).eq(n)||Oa.throwError("CCIP Read sender did not match",b.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:i});const s=[],u=X.from(C(o,32,64)).toNumber(),c=X.from(C(o,u,u+32)).toNumber(),l=C(o,u+32);for(let t=0;tIa(this,void 0,void 0,(function*(){const e=yield this.perform("getBlock",n);if(null==e)return null!=n.blockHash&&null==this._emitted["b:"+n.blockHash]||null!=n.blockTag&&r>this._emitted.block?null:void 0;if(t){let t=null;for(let r=0;rthis._wrapTransaction(e))),r}return this.formatter.block(e)}))),{oncePoll:this})}))}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return wa((()=>Ia(this,void 0,void 0,(function*(){const r=yield this.perform("getTransaction",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;const n=this.formatter.transactionResponse(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return this._wrapTransaction(n)}))),{oncePoll:this})}))}getTransactionReceipt(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return wa((()=>Ia(this,void 0,void 0,(function*(){const r=yield this.perform("getTransactionReceipt",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;if(null==r.blockHash)return;const n=this.formatter.receipt(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return n}))),{oncePoll:this})}))}getLogs(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield ne({filter:this._getFilter(e)}),r=yield this.perform("getLogs",t);return r.forEach((e=>{null==e.removed&&(e.removed=!1)})),_a.arrayOf(this.formatter.filterLog.bind(this.formatter))(r)}))}getEtherPrice(){return Ia(this,void 0,void 0,(function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})}))}_getBlockTag(e){return Ia(this,void 0,void 0,(function*(){if("number"==typeof(e=yield e)&&e<0){e%1&&Oa.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)}))}getResolver(e){return Ia(this,void 0,void 0,(function*(){let t=e;for(;;){if(""===t||"."===t)return null;if("eth"!==e&&"eth"===t)return null;const r=yield this._getResolver(t,"getResolver");if(null!=r){const n=new Wa(this,r,e);return t===e||(yield n.supportsWildcard())?n:null}t=t.split(".").slice(1).join(".")}}))}_getResolver(e,t){return Ia(this,void 0,void 0,(function*(){null==t&&(t="ENS");const r=yield this.getNetwork();r.ensAddress||Oa.throwError("network does not support ENS",b.errors.UNSUPPORTED_OPERATION,{operation:t,network:r.name});try{const t=yield this.call({to:r.ensAddress,data:"0x0178b8bf"+la(e).substring(2)});return this.formatter.callAddress(t)}catch(e){}return null}))}resolveName(e){return Ia(this,void 0,void 0,(function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(t){if(P(e))throw t}"string"!=typeof e&&Oa.throwArgumentError("invalid ENS name","name",e);const t=yield this.getResolver(e);return t?yield t.getAddress():null}))}lookupAddress(e){return Ia(this,void 0,void 0,(function*(){e=yield e;const t=(e=this.formatter.address(e)).substring(2).toLowerCase()+".addr.reverse",r=yield this._getResolver(t,"lookupAddress");if(null==r)return null;const n=Ga(yield this.call({to:r,data:"0x691f3431"+la(t).substring(2)}),0);return(yield this.resolveName(n))!=e?null:n}))}getAvatar(e){return Ia(this,void 0,void 0,(function*(){let t=null;if(P(e)){const r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(r,"getAvatar");if(!n)return null;t=new Wa(this,n,r);try{const e=yield t.getAvatar();if(e)return e.url}catch(e){if(e.code!==b.errors.CALL_EXCEPTION)throw e}try{const e=Ga(yield this.call({to:n,data:"0x691f3431"+la(r).substring(2)}),0);t=yield this.getResolver(e)}catch(e){if(e.code!==b.errors.CALL_EXCEPTION)throw e;return null}}else if(t=yield this.getResolver(e),!t)return null;const r=yield t.getAvatar();return null==r?null:r.url}))}perform(e,t){return Oa.throwError(e+" not implemented",b.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_stopEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_addEventListener(e,t,r){const n=new Fa(Ba(e),t,r);return this._events.push(n),this._startEvent(n),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let r=!1,n=[],i=Ba(e);return this._events=this._events.filter((e=>e.tag!==i||(setTimeout((()=>{e.listener.apply(this,t)}),0),r=!0,!e.once||(n.push(e),!1)))),n.forEach((e=>{this._stopEvent(e)})),r}listenerCount(e){if(!e)return this._events.length;let t=Ba(e);return this._events.filter((e=>e.tag===t)).length}listeners(e){if(null==e)return this._events.map((e=>e.listener));let t=Ba(e);return this._events.filter((e=>e.tag===t)).map((e=>e.listener))}off(e,t){if(null==t)return this.removeAllListeners(e);const r=[];let n=!1,i=Ba(e);return this._events=this._events.filter((e=>e.tag!==i||e.listener!=t||(!!n||(n=!0,r.push(e),!1)))),r.forEach((e=>{this._stopEvent(e)})),this}removeAllListeners(e){let t=[];if(null==e)t=this._events,this._events=[];else{const r=Ba(e);this._events=this._events.filter((e=>e.tag!==r||(t.push(e),!1)))}return t.forEach((e=>{this._stopEvent(e)})),this}}var es=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ts=new b(ka),rs=["call","estimateGas"];function ns(e,t){if(null==e)return null;if("string"==typeof e.message&&e.message.match("reverted")){const r=P(e.data)?e.data:null;if(!t||r)return{message:e.message,data:r}}if("object"==typeof e){for(const r in e){const n=ns(e[r],t);if(n)return n}return null}if("string"==typeof e)try{return ns(JSON.parse(e),t)}catch(e){}return null}function is(e,t,r){const n=r.transaction||r.signedTransaction;if("call"===e){const e=ns(t,!0);if(e)return e.data;ts.throwError("missing revert data in call exception; Transaction reverted without a reason string",b.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:t})}if("estimateGas"===e){let r=ns(t.body,!1);null==r&&(r=ns(t,!1)),r&&ts.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:e,transaction:n,error:t})}let i=t.message;throw t.code===b.errors.SERVER_ERROR&&t.error&&"string"==typeof t.error.message?i=t.error.message:"string"==typeof t.body?i=t.body:"string"==typeof t.responseText&&(i=t.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&ts.throwError("insufficient funds for intrinsic transaction cost",b.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:n}),i.match(/nonce (is )?too low/i)&&ts.throwError("nonce has already been used",b.errors.NONCE_EXPIRED,{error:t,method:e,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&ts.throwError("replacement fee too low",b.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:n}),i.match(/only replay-protected/i)&&ts.throwError("legacy pre-eip-155 transactions not supported",b.errors.UNSUPPORTED_OPERATION,{error:t,method:e,transaction:n}),rs.indexOf(e)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&ts.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:n}),t}function os(e){return new Promise((function(t){setTimeout(t,e)}))}function as(e){if(e.error){const t=new Error(e.error.message);throw t.code=e.error.code,t.data=e.error.data,t}return e.result}function ss(e){return e?e.toLowerCase():e}const us={};class cs extends lr{constructor(e,t,r){if(super(),e!==us)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");te(this,"provider",t),null==r&&(r=0),"string"==typeof r?(te(this,"_address",this.provider.formatter.address(r)),te(this,"_index",null)):"number"==typeof r?(te(this,"_index",r),te(this,"_address",null)):ts.throwArgumentError("invalid address or index","addressOrIndex",r)}connect(e){return ts.throwError("cannot alter JSON-RPC Signer connection",b.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new ls(us,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then((e=>(e.length<=this._index&&ts.throwError("unknown account #"+this._index,b.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index]))))}sendUncheckedTransaction(e){e=oe(e);const t=this.getAddress().then((e=>(e&&(e=e.toLowerCase()),e)));if(null==e.gasLimit){const r=oe(e);r.from=t,e.gasLimit=this.provider.estimateGas(r)}return null!=e.to&&(e.to=Promise.resolve(e.to).then((e=>es(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.provider.resolveName(e);return null==t&&ts.throwArgumentError("provided ENS name resolves to null","tx.to",e),t}))))),ne({tx:ne(e),sender:t}).then((({tx:t,sender:r})=>{null!=t.from?t.from.toLowerCase()!==r&&ts.throwArgumentError("from address mismatch","transaction",e):t.from=r;const n=this.provider.constructor.hexlifyTransaction(t,{from:!0});return this.provider.send("eth_sendTransaction",[n]).then((e=>e),(e=>("string"==typeof e.message&&e.message.match(/user denied/i)&&ts.throwError("user rejected transaction",b.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:t}),is("sendTransaction",e,n))))}))}signTransaction(e){return ts.throwError("signing transactions is unsupported",b.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return es(this,void 0,void 0,(function*(){const t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),r=yield this.sendUncheckedTransaction(e);try{return yield wa((()=>es(this,void 0,void 0,(function*(){const e=yield this.provider.getTransaction(r);if(null!==e)return this.provider._wrapTransaction(e,r,t)}))),{oncePoll:this.provider})}catch(e){throw e.transactionHash=r,e}}))}signMessage(e){return es(this,void 0,void 0,(function*(){const t="string"==typeof e?qe(e):e,r=yield this.getAddress();try{return yield this.provider.send("personal_sign",[O(t),r.toLowerCase()])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&ts.throwError("user rejected signing",b.errors.ACTION_REJECTED,{action:"signMessage",from:r,messageData:e}),t}}))}_legacySignMessage(e){return es(this,void 0,void 0,(function*(){const t="string"==typeof e?qe(e):e,r=yield this.getAddress();try{return yield this.provider.send("eth_sign",[r.toLowerCase(),O(t)])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&ts.throwError("user rejected signing",b.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:r,messageData:e}),t}}))}_signTypedData(e,t,r){return es(this,void 0,void 0,(function*(){const n=yield di.resolveNames(e,t,r,(e=>this.provider.resolveName(e))),i=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[i.toLowerCase(),JSON.stringify(di.getPayload(n.domain,t,n.value))])}catch(e){throw"string"==typeof e.message&&e.message.match(/user denied/i)&&ts.throwError("user rejected signing",b.errors.ACTION_REJECTED,{action:"_signTypedData",from:i,messageData:{domain:n.domain,types:t,value:n.value}}),e}}))}unlock(e){return es(this,void 0,void 0,(function*(){const t=this.provider,r=yield this.getAddress();return t.send("personal_unlockAccount",[r.toLowerCase(),e,null])}))}}class ls extends cs{sendTransaction(e){return this.sendUncheckedTransaction(e).then((e=>({hash:e,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:t=>this.provider.waitForTransaction(e,t)})))}}const fs={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0};class hs extends $a{constructor(e,t){let r=t;null==r&&(r=new Promise(((e,t)=>{setTimeout((()=>{this.detectNetwork().then((t=>{e(t)}),(e=>{t(e)}))}),0)}))),super(r),e||(e=re(this.constructor,"defaultUrl")()),te(this,"connection","string"==typeof e?Object.freeze({url:e}):Object.freeze(oe(e))),this._nextId=42}get _cache(){return null==this._eventLoopCache&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout((()=>{this._cache.detectNetwork=null}),0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return es(this,void 0,void 0,(function*(){yield os(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch(t){try{e=yield this.send("net_version",[])}catch(e){}}if(null!=e){const t=re(this.constructor,"getNetwork");try{return t(X.from(e).toNumber())}catch(t){return ts.throwError("could not detect network",b.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:t})}}return ts.throwError("could not detect network",b.errors.NETWORK_ERROR,{event:"noNetwork"})}))}getSigner(e){return new cs(us,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then((e=>e.map((e=>this.formatter.address(e)))))}send(e,t){const r={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:ce(r),provider:this});const n=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(n&&this._cache[e])return this._cache[e];const i=va(this.connection,JSON.stringify(r),as).then((e=>(this.emit("debug",{action:"response",request:r,response:e,provider:this}),e)),(e=>{throw this.emit("debug",{action:"response",error:e,request:r,provider:this}),e}));return n&&(this._cache[e]=i,setTimeout((()=>{this._cache[e]=null}),0)),i}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[ss(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[ss(t.address),t.blockTag]];case"getCode":return["eth_getCode",[ss(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[ss(t.address),U(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":return["eth_call",[re(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0}),t.blockTag]];case"estimateGas":return["eth_estimateGas",[re(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0})]];case"getLogs":return t.filter&&null!=t.filter.address&&(t.filter.address=ss(t.filter.address)),["eth_getLogs",[t.filter]]}return null}perform(e,t){return es(this,void 0,void 0,(function*(){if("call"===e||"estimateGas"===e){const e=t.transaction;if(e&&null!=e.type&&X.from(e.type).isZero()&&null==e.maxFeePerGas&&null==e.maxPriorityFeePerGas){const r=yield this.getFeeData();null==r.maxFeePerGas&&null==r.maxPriorityFeePerGas&&((t=oe(t)).transaction=oe(e),delete t.transaction.type)}}const r=this.prepareRequest(e,t);null==r&&ts.throwError(e+" not implemented",b.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(r[0],r[1])}catch(r){return is(e,r,t)}}))}_startEvent(e){"pending"===e.tag&&this._startPending(),super._startEvent(e)}_startPending(){if(null!=this._pendingFilter)return;const e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then((function(r){return function n(){e.send("eth_getFilterChanges",[r]).then((function(r){if(e._pendingFilter!=t)return null;let n=Promise.resolve();return r.forEach((function(t){e._emitted["t:"+t.toLowerCase()]="pending",n=n.then((function(){return e.getTransaction(t).then((function(t){return e.emit("pending",t),null}))}))})),n.then((function(){return os(1e3)}))})).then((function(){if(e._pendingFilter==t)return setTimeout((function(){n()}),0),null;e.send("eth_uninstallFilter",[r])})).catch((e=>{}))}(),r})).catch((e=>{}))}_stopEvent(e){"pending"===e.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){const r=oe(fs);if(t)for(const e in t)t[e]&&(r[e]=!0);ie(e,r);const n={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach((function(t){if(null==e[t])return;const r=N(X.from(e[t]));"gasLimit"===t&&(t="gas"),n[t]=r})),["from","to","data"].forEach((function(t){null!=e[t]&&(n[t]=O(e[t]))})),e.accessList&&(n.accessList=dn(e.accessList)),n}}let ds=null;try{if(ds=WebSocket,null==ds)throw new Error("inject please")}catch(e){const t=new b(ka);ds=function(){t.throwError("WebSockets not supported in this environment",b.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var ps=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ms=new b(ka);let ys=1;class gs extends hs{constructor(e,t){"any"===t&&ms.throwError("WebSocketProvider does not support 'any' network yet",b.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),super("string"==typeof e?e:"_websocket",t),this._pollingInterval=-1,this._wsReady=!1,te(this,"_websocket","string"==typeof e?new ds(this.connection.url):e),te(this,"_requests",{}),te(this,"_subs",{}),te(this,"_subIds",{}),te(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach((e=>{this.websocket.send(this._requests[e].payload)}))},this.websocket.onmessage=e=>{const t=e.data,r=JSON.parse(t);if(null!=r.id){const e=String(r.id),n=this._requests[e];if(delete this._requests[e],void 0!==r.result)n.callback(null,r.result),this.emit("debug",{action:"response",request:JSON.parse(n.payload),response:r.result,provider:this});else{let e=null;r.error?(e=new Error(r.error.message||"unknown error"),te(e,"code",r.error.code||null),te(e,"response",t)):e=new Error("unknown error"),n.callback(e,void 0),this.emit("debug",{action:"response",error:e,request:JSON.parse(n.payload),provider:this})}}else if("eth_subscription"===r.method){const e=this._subs[r.params.subscription];e&&e.processFunc(r.params.result)}else console.warn("this should not happen")};const r=setInterval((()=>{this.emit("poll")}),1e3);r.unref&&r.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){ms.throwError("cannot reset events block on WebSocketProvider",b.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){ms.throwError("cannot set polling interval on WebSocketProvider",b.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return ps(this,void 0,void 0,(function*(){return null}))}set polling(e){e&&ms.throwError("cannot set polling on WebSocketProvider",b.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){const r=ys++;return new Promise(((n,i)=>{const o=JSON.stringify({method:e,params:t,id:r,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(r)]={callback:function(e,t){return e?i(e):n(t)},payload:o},this._wsReady&&this.websocket.send(o)}))}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,r){return ps(this,void 0,void 0,(function*(){let n=this._subIds[e];null==n&&(n=Promise.all(t).then((e=>this.send("eth_subscribe",e))),this._subIds[e]=n);const i=yield n;this._subs[i]={tag:e,processFunc:r}}))}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],(e=>{const t=X.from(e.number).toNumber();this._emitted.block=t,this.emit("block",t)}));break;case"pending":this._subscribe("pending",["newPendingTransactions"],(e=>{this.emit("pending",e)}));break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],(t=>{null==t.removed&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))}));break;case"tx":{const t=e=>{const t=e.hash;this.getTransactionReceipt(t).then((e=>{e&&this.emit(t,e)}))};t(e),this._subscribe("tx",["newHeads"],(e=>{this._events.filter((e=>"tx"===e.type)).forEach(t)}));break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e)}}_stopEvent(e){let t=e.tag;if("tx"===e.type){if(this._events.filter((e=>"tx"===e.type)).length)return;t="tx"}else if(this.listenerCount(e.event))return;const r=this._subIds[t];r&&(delete this._subIds[t],r.then((e=>{this._subs[e]&&(delete this._subs[e],this.send("eth_unsubscribe",[e]))})))}destroy(){return ps(this,void 0,void 0,(function*(){this.websocket.readyState===ds.CONNECTING&&(yield new Promise((e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}}))),this.websocket.close(1e3)}))}}var bs=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const vs=new b(ka);class ws extends hs{detectNetwork(){const e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return bs(this,void 0,void 0,(function*(){let t=this.network;return null==t&&(t=yield e.detectNetwork.call(this),t||vs.throwError("no network detected",b.errors.UNKNOWN_ERROR,{}),null==this._network&&(te(this,"_network",t),this.emit("network",t,null))),t}))}}class As extends ws{constructor(e,t){vs.checkAbstract(new.target,As),e=re(new.target,"getNetwork")(e),t=re(new.target,"getApiKey")(t);super(re(new.target,"getUrl")(e,t),e),"string"==typeof t?te(this,"apiKey",t):null!=t&&Object.keys(t).forEach((e=>{te(this,e,t[e])}))}_startPending(){vs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return vs.throwError("API provider does not support signing",b.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return vs.throwError("not implemented; sub-classes must override getUrl",b.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}}const Ss=new b(ka),ks="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC";class Es extends gs{constructor(e,t){const r=new _s(e,t);super(r.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi."),r.network),te(this,"apiKey",r.apiKey)}isCommunityResource(){return this.apiKey===ks}}class _s extends As{static getWebSocketProvider(e,t){return new Es(e,t)}static getApiKey(e){return null==e?ks:(e&&"string"!=typeof e&&Ss.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let r=null;switch(e.name){case"homestead":r="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":r="eth-goerli.g.alchemy.com/v2/";break;case"matic":r="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":r="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":r="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":r="arb-goerli.g.alchemy.com/v2/";break;case"optimism":r="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":r="opt-goerli.g.alchemy.com/v2/";break;default:Ss.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+r+t,throttleCallback:(e,r)=>(t===ks&&Pa(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===ks}}const Ms=new b(ka),Ts="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function xs(e){switch(e){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return Ms.throwArgumentError("unsupported network","name",e)}class Ps extends As{isCommunityResource(){return this.apiKey===Ts}static getApiKey(e){return null==e?Ts:e}static getUrl(e,t){null==t&&(t=Ts);const r={allowGzip:!0,url:"https://"+xs(e.name)+t,throttleCallback:(e,r)=>(t.apiKey===Ts&&Pa(),Promise.resolve(!0))};return null!=t.projectSecret&&(r.user="",r.password=t.projectSecret),r}}var Is=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const Os=new b(ka);class Rs extends As{static getApiKey(e){return null!=e&&Os.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let r=null;if("homestead"===e.name)r="https://cloudflare-eth.com/";else Os.throwArgumentError("unsupported network","network",arguments[0]);return r}perform(e,t){const r=Object.create(null,{perform:{get:()=>super.perform}});return Is(this,void 0,void 0,(function*(){if("getBlockNumber"===e){return(yield r.perform.call(this,"getBlock",{blockTag:"latest"})).number}return r.perform.call(this,e,t)}))}}var Cs=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const Bs=new b(ka);function Ns(e){const t={};for(let r in e){if(null==e[r])continue;let n=e[r];"type"===r&&0===n||(n={type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[r]?N(O(n)):"accessList"===r?"["+dn(n).map((e=>`{address:"${e.address}",storageKeys:["${e.storageKeys.join('","')}"]}`)).join(",")+"]":O(n),t[r]=n)}return t}function Ls(e){if(0==e.status&&("No records found"===e.message||"No transactions found"===e.message))return e.result;if(1!=e.status||"string"!=typeof e.message||!e.message.match(/^OK/)){const t=new Error("invalid response");throw t.result=JSON.stringify(e),(e.result||"").toLowerCase().indexOf("rate limit")>=0&&(t.throttleRetry=!0),t}return e.result}function Us(e){if(e&&0==e.status&&"NOTOK"==e.message&&(e.result||"").toLowerCase().indexOf("rate limit")>=0){const t=new Error("throttled response");throw t.result=JSON.stringify(e),t.throttleRetry=!0,t}if("2.0"!=e.jsonrpc){const t=new Error("invalid response");throw t.result=JSON.stringify(e),t}if(e.error){const t=new Error(e.error.message||"unknown error");throw e.error.code&&(t.code=e.error.code),e.error.data&&(t.data=e.error.data),t}return e.result}function Fs(e){if("pending"===e)throw new Error("pending not supported");return"latest"===e?e:parseInt(e.substring(2),16)}function Ds(e,t,r){if("call"===e&&t.code===b.errors.SERVER_ERROR){const e=t.error;if(e&&(e.message.match(/reverted/i)||e.message.match(/VM execution error/i))){let r=e.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),P(r))return r;Bs.throwError("missing revert data in call exception",b.errors.CALL_EXCEPTION,{error:t,data:"0x"})}}let n=t.message;throw t.code===b.errors.SERVER_ERROR&&(t.error&&"string"==typeof t.error.message?n=t.error.message:"string"==typeof t.body?n=t.body:"string"==typeof t.responseText&&(n=t.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Bs.throwError("insufficient funds for intrinsic transaction cost",b.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:r}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Bs.throwError("nonce has already been used",b.errors.NONCE_EXPIRED,{error:t,method:e,transaction:r}),n.match(/another transaction with same nonce/)&&Bs.throwError("replacement fee too low",b.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:r}),n.match(/execution failed due to an exception|execution reverted/)&&Bs.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:r}),t}class js extends $a{constructor(e,t){super(e),te(this,"baseUrl",this.getBaseUrl()),te(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io"}return Bs.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){const r=Object.keys(t).reduce(((e,r)=>{const n=t[r];return null!=n&&(e+=`&${r}=${n}`),e}),""),n=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${r}${n}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,r){return Cs(this,void 0,void 0,(function*(){const n=r?this.getPostUrl():this.getUrl(e,t),i=r?this.getPostData(e,t):null,o="proxy"===e?Us:Ls;this.emit("debug",{action:"request",request:n,provider:this});const a={url:n,throttleSlotInterval:1e3,throttleCallback:(e,t)=>(this.isCommunityResource()&&Pa(),Promise.resolve(!0))};let s=null;i&&(a.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},s=Object.keys(i).map((e=>`${e}=${i[e]}`)).join("&"));const u=yield va(a,s,o||Us);return this.emit("debug",{action:"response",request:n,response:ce(u),provider:this}),u}))}detectNetwork(){return Cs(this,void 0,void 0,(function*(){return this.network}))}perform(e,t){const r=Object.create(null,{perform:{get:()=>super.perform}});return Cs(this,void 0,void 0,(function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch((e=>Ds("sendTransaction",e,t.signedTransaction)));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if("latest"!==t.blockTag)throw new Error("EtherscanProvider does not support blockTag for call");const e=Ns(t.transaction);e.module="proxy",e.action="eth_call";try{return yield this.fetch("proxy",e,!0)}catch(e){return Ds("call",e,t.transaction)}}case"estimateGas":{const e=Ns(t.transaction);e.module="proxy",e.action="eth_estimateGas";try{return yield this.fetch("proxy",e,!0)}catch(e){return Ds("estimateGas",e,t.transaction)}}case"getLogs":{const e={action:"getLogs"};if(t.filter.fromBlock&&(e.fromBlock=Fs(t.filter.fromBlock)),t.filter.toBlock&&(e.toBlock=Fs(t.filter.toBlock)),t.filter.address&&(e.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Bs.throwError("unsupported topic count",b.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),1===t.filter.topics.length)){const r=t.filter.topics[0];"string"==typeof r&&66===r.length||Bs.throwError("unsupported topic format",b.errors.UNSUPPORTED_OPERATION,{topic0:r}),e.topic0=r}const r=yield this.fetch("logs",e);let n={};for(let e=0;e{["contractAddress","to"].forEach((function(t){""==e[t]&&delete e[t]})),null==e.creates&&null!=e.contractAddress&&(e.creates=e.contractAddress);const t=this.formatter.transactionResponse(e);return e.timeStamp&&(t.timestamp=parseInt(e.timeStamp)),t}))}))}isCommunityResource(){return null==this.apiKey}}function Hs(e){for(let t=(e=e.slice()).length-1;t>0;t--){const r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}return e}var Js=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const zs=new b(ka);function Gs(){return(new Date).getTime()}function qs(e){let t=null;for(let r=0;rt?null:(n+i)/2}function Vs(e){if(null===e)return"null";if("number"==typeof e||"boolean"==typeof e)return JSON.stringify(e);if("string"==typeof e)return e;if(X.isBigNumber(e))return e.toString();if(Array.isArray(e))return JSON.stringify(e.map((e=>Vs(e))));if("object"==typeof e){const t=Object.keys(e);return t.sort(),"{"+t.map((t=>{let r=e[t];return r="function"==typeof r?"[function]":Vs(r),JSON.stringify(t)+":"+r})).join(",")+"}"}throw new Error("unknown value type: "+typeof e)}let Xs=1;function Qs(e){let t=null,r=null,n=new Promise((n=>{t=function(){r&&(clearTimeout(r),r=null),n()},r=setTimeout(t,e)}));return{cancel:t,getPromise:function(){return n},wait:e=>(n=n.then(e),n)}}const Ws=[b.errors.CALL_EXCEPTION,b.errors.INSUFFICIENT_FUNDS,b.errors.NONCE_EXPIRED,b.errors.REPLACEMENT_UNDERPRICED,b.errors.UNPREDICTABLE_GAS_LIMIT],Zs=["address","args","errorArgs","errorSignature","method","transaction"];function Ys(e,t){const r={weight:e.weight};return Object.defineProperty(r,"provider",{get:()=>e.provider}),e.start&&(r.start=e.start),t&&(r.duration=t-e.start),e.done&&(e.error?r.error=e.error:r.result=e.result||null),r}function $s(e,t,r){let n=Vs;switch(t){case"getBlockNumber":return function(t){const r=t.map((e=>e.result));let n=Ks(t.map((e=>e.result)),2);if(null!=n)return n=Math.ceil(n),r.indexOf(n+1)>=0&&n++,n>=e._highestBlockNumber&&(e._highestBlockNumber=n),e._highestBlockNumber};case"getGasPrice":return function(e){const t=e.map((e=>e.result));return t.sort(),t[Math.floor(t.length/2)]};case"getEtherPrice":return function(e){return Ks(e.map((e=>e.result)))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(e){return null==e?null:((e=oe(e)).confirmations=-1,Vs(e))};break;case"getBlock":n=r.includeTransactions?function(e){return null==e?null:((e=oe(e)).transactions=e.transactions.map((e=>((e=oe(e)).confirmations=-1,e))),Vs(e))}:function(e){return null==e?null:Vs(e)};break;default:throw new Error("unknown method: "+t)}return function(e,t){return function(r){const n={};r.forEach((t=>{const r=e(t.result);n[r]||(n[r]={count:0,result:t.result}),n[r].count++}));const i=Object.keys(n);for(let e=0;e=t)return r.result}}}(n,e.quorum)}function eu(e,t){return Js(this,void 0,void 0,(function*(){const r=e.provider;return null!=r.blockNumber&&r.blockNumber>=t||-1===t?r:wa((()=>new Promise(((n,i)=>{setTimeout((function(){return r.blockNumber>=t?n(r):e.cancelled?n(null):n(void 0)}),0)}))),{oncePoll:r})}))}function tu(e,t,r,n){return Js(this,void 0,void 0,(function*(){let i=e.provider;switch(r){case"getBlockNumber":case"getGasPrice":return i[r]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),i[r](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),"call"===r&&n.blockTag?i[r](n.transaction,n.blockTag):i[r](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[r](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&P(r.fromBlock)||r.toBlock&&P(r.toBlock))&&(i=yield eu(e,t)),i.getLogs(r)}}return zs.throwError("unknown method error",b.errors.UNKNOWN_ERROR,{method:r,params:n})}))}class ru extends $a{constructor(e,t){0===e.length&&zs.throwArgumentError("missing providers","providers",e);const r=e.map(((e,t)=>{if(or.isProvider(e)){const t=Ta(e)?2e3:750,r=1;return Object.freeze({provider:e,weight:1,stallTimeout:t,priority:r})}const r=oe(e);null==r.priority&&(r.priority=1),null==r.stallTimeout&&(r.stallTimeout=Ta(e)?2e3:750),null==r.weight&&(r.weight=1);const n=r.weight;return(n%1||n>512||n<1)&&zs.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${t}].weight`,n),Object.freeze(r)})),n=r.reduce(((e,t)=>e+t.weight),0);null==t?t=n/2:t>n&&zs.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let i=qs(r.map((e=>e.provider.network)));null==i&&(i=new Promise(((e,t)=>{setTimeout((()=>{this.detectNetwork().then(e,t)}),0)}))),super(i),te(this,"providerConfigs",Object.freeze(r)),te(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return Js(this,void 0,void 0,(function*(){return qs(yield Promise.all(this.providerConfigs.map((e=>e.provider.getNetwork()))))}))}perform(e,t){return Js(this,void 0,void 0,(function*(){if("sendTransaction"===e){const e=yield Promise.all(this.providerConfigs.map((e=>e.provider.sendTransaction(t.signedTransaction).then((e=>e.hash),(e=>e)))));for(let t=0;te.priority-t.priority));const i=this._highestBlockNumber;let o=0,a=!0;for(;;){const s=Gs();let u=n.filter((e=>e.runner&&s-e.starte+t.weight),0);for(;u{r.staller=null})),r.runner=tu(r,i,e,t).then((n=>{r.done=!0,r.result=n,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:a,backend:Ys(r,Gs()),request:{method:e,params:ce(t)},provider:this})}),(n=>{r.done=!0,r.error=n,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:a,backend:Ys(r,Gs()),request:{method:e,params:ce(t)},provider:this})})),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:a,backend:Ys(r,null),request:{method:e,params:ce(t)},provider:this}),u+=r.weight}const c=[];n.forEach((e=>{!e.done&&e.runner&&(c.push(e.runner),e.staller&&c.push(e.staller.getPromise()))})),c.length&&(yield Promise.race(c));const l=n.filter((e=>e.done&&null==e.error));if(l.length>=this.quorum){const e=r(l);if(void 0!==e)return n.forEach((e=>{e.staller&&e.staller.cancel(),e.cancelled=!0})),e;a||(yield Qs(100).getPromise()),a=!1}const f=n.reduce(((e,t)=>{if(!t.done||null==t.error)return e;const r=t.error.code;return Ws.indexOf(r)>=0&&(e[r]||(e[r]={error:t.error,weight:0}),e[r].weight+=t.weight),e}),{});if(Object.keys(f).forEach((e=>{const t=f[e];if(t.weight{e.staller&&e.staller.cancel(),e.cancelled=!0}));const r=t.error,i={};Zs.forEach((e=>{null!=r[e]&&(i[e]=r[e])})),zs.throwError(r.reason||r.message,e,i)})),0===n.filter((e=>!e.done)).length)break}return n.forEach((e=>{e.staller&&e.staller.cancel(),e.cancelled=!0})),zs.throwError("failed to meet quorum",b.errors.SERVER_ERROR,{method:e,params:t,results:n.map((e=>Ys(e))),provider:this})}))}}const nu=null,iu=new b(ka),ou="84842078b09946638c03157f83405213";class au extends gs{constructor(e,t){const r=new su(e,t),n=r.connection;n.password&&iu.throwError("INFURA WebSocket project secrets unsupported",b.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});super(n.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/"),e),te(this,"apiKey",r.projectId),te(this,"projectId",r.projectId),te(this,"projectSecret",r.projectSecret)}isCommunityResource(){return this.projectId===ou}}class su extends As{static getWebSocketProvider(e,t){return new au(e,t)}static getApiKey(e){const t={apiKey:ou,projectId:ou,projectSecret:null};return null==e||("string"==typeof e?t.projectId=e:null!=e.projectSecret?(iu.assertArgument("string"==typeof e.projectId,"projectSecret requires a projectId","projectId",e.projectId),iu.assertArgument("string"==typeof e.projectSecret,"invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let r=null;switch(e?e.name:"unknown"){case"homestead":r="mainnet.infura.io";break;case"goerli":r="goerli.infura.io";break;case"sepolia":r="sepolia.infura.io";break;case"matic":r="polygon-mainnet.infura.io";break;case"maticmum":r="polygon-mumbai.infura.io";break;case"optimism":r="optimism-mainnet.infura.io";break;case"optimism-goerli":r="optimism-goerli.infura.io";break;case"arbitrum":r="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":r="arbitrum-goerli.infura.io";break;default:iu.throwError("unsupported network",b.errors.INVALID_ARGUMENT,{argument:"network",value:e})}const n={allowGzip:!0,url:"https://"+r+"/v3/"+t.projectId,throttleCallback:(e,r)=>(t.projectId===ou&&Pa(),Promise.resolve(!0))};return null!=t.projectSecret&&(n.user="",n.password=t.projectSecret),n}isCommunityResource(){return this.projectId===ou}}class uu extends hs{send(e,t){const r={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};null==this._pendingBatch&&(this._pendingBatch=[]);const n={request:r,resolve:null,reject:null},i=new Promise(((e,t)=>{n.resolve=e,n.reject=t}));return this._pendingBatch.push(n),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout((()=>{const e=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;const t=e.map((e=>e.request));return this.emit("debug",{action:"requestBatch",request:ce(t),provider:this}),va(this.connection,JSON.stringify(t)).then((r=>{this.emit("debug",{action:"response",request:t,response:r,provider:this}),e.forEach(((e,t)=>{const n=r[t];if(n.error){const t=new Error(n.error.message);t.code=n.error.code,t.data=n.error.data,e.reject(t)}else e.resolve(n.result)}))}),(r=>{this.emit("debug",{action:"response",error:r,request:t,provider:this}),e.forEach((e=>{e.reject(r)}))}))}),10)),i}}const cu=new b(ka);class lu extends As{static getApiKey(e){return e&&"string"!=typeof e&&cu.throwArgumentError("invalid apiKey","apiKey",e),e||"ETHERS_JS_SHARED"}static getUrl(e,t){cu.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let r=null;switch(e.name){case"homestead":r="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":r="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":r="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":r="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":r="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:cu.throwArgumentError("unsupported network","network",arguments[0])}return r+"?apiKey="+t}}const fu=new b(ka),hu="62e1ad51b37b8e00394bda3b";class du extends As{static getApiKey(e){const t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return null==e?t.applicationId=hu:"string"==typeof e?t.applicationId=e:null!=e.applicationSecretKey?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:fu.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let r=null;switch(e?e.name:"unknown"){case"goerli":r="eth-goerli.gateway.pokt.network";break;case"homestead":r="eth-mainnet.gateway.pokt.network";break;case"kovan":r="poa-kovan.gateway.pokt.network";break;case"matic":r="poly-mainnet.gateway.pokt.network";break;case"maticmum":r="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":r="eth-rinkeby.gateway.pokt.network";break;case"ropsten":r="eth-ropsten.gateway.pokt.network";break;default:fu.throwError("unsupported network",b.errors.INVALID_ARGUMENT,{argument:"network",value:e})}const n={headers:{},url:`https://${r}/v1/lb/${t.applicationId}`};return null!=t.applicationSecretKey&&(n.user="",n.password=t.applicationSecretKey),n}isCommunityResource(){return this.applicationId===hu}}const pu=new b(ka);let mu=1;function yu(e,t){const r="Web3LegacyFetcher";return function(e,n){const i={method:e,params:n,id:mu++,jsonrpc:"2.0"};return new Promise(((e,n)=>{this.emit("debug",{action:"request",fetcher:r,request:ce(i),provider:this}),t(i,((t,o)=>{if(t)return this.emit("debug",{action:"response",fetcher:r,error:t,request:i,provider:this}),n(t);if(this.emit("debug",{action:"response",fetcher:r,request:i,response:o,provider:this}),o.error){const e=new Error(o.error.message);return e.code=o.error.code,e.data=o.error.data,n(e)}e(o.result)}))}))}}class gu extends hs{constructor(e,t){null==e&&pu.throwArgumentError("missing provider","provider",e);let r=null,n=null,i=null;"function"==typeof e?(r="unknown:",n=e):(r=e.host||e.path||"",!r&&e.isMetaMask&&(r="metamask"),i=e,e.request?(""===r&&(r="eip-1193:"),n=function(e){return function(t,r){null==r&&(r=[]);const n={method:t,params:r};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:ce(n),provider:this}),e.request(n).then((e=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:e,provider:this}),e)),(e=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:e,provider:this}),e}))}}(e)):e.sendAsync?n=yu(0,e.sendAsync.bind(e)):e.send?n=yu(0,e.send.bind(e)):pu.throwArgumentError("unsupported provider","provider",e),r||(r="unknown:")),super(r,t),te(this,"jsonRpcFetchFunc",n),te(this,"provider",i)}send(e,t){return this.jsonRpcFetchFunc(e,t)}}const bu=new b(ka);function vu(e,t){if(null==e&&(e="homestead"),"string"==typeof e){const t=e.match(/^(ws|http)s?:/i);if(t)switch(t[1].toLowerCase()){case"http":case"https":return new hs(e);case"ws":case"wss":return new gs(e);default:bu.throwArgumentError("unsupported URL scheme","network",e)}}const r=Uo(e);return r&&r._defaultProvider||bu.throwError("unsupported getDefaultProvider network",b.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:e}),r._defaultProvider({FallbackProvider:ru,AlchemyProvider:_s,AnkrProvider:Ps,CloudflareProvider:Rs,EtherscanProvider:js,InfuraProvider:su,JsonRpcProvider:hs,NodesmithProvider:lu,PocketProvider:du,Web3Provider:gu,IpcProvider:nu},t)}const wu=new RegExp("^bytes([0-9]+)$"),Au=new RegExp("^(u?int)([0-9]*)$"),Su=new RegExp("^(.*)\\[([0-9]*)\\]$"),ku=new b("solidity/5.7.0");function Eu(e,t,r){switch(e){case"address":return r?x(t,32):_(t);case"string":return qe(t);case"bytes":return _(t);case"bool":return t=t?"0x01":"0x00",r?x(t,32):_(t)}let n=e.match(Au);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!=0||0===i||i>256)&&ku.throwArgumentError("invalid number type","type",e),r&&(i=256),x(t=X.from(t).toTwos(i),i/8)}if(n=e.match(wu),n){const i=parseInt(n[1]);return(String(i)!==n[1]||0===i||i>32)&&ku.throwArgumentError("invalid bytes type","type",e),_(t).byteLength!==i&&ku.throwArgumentError(`invalid value for ${e}`,"value",t),r?_((t+"0000000000000000000000000000000000000000000000000000000000000000").substring(0,66)):t}if(n=e.match(Su),n&&Array.isArray(t)){const r=n[1];parseInt(n[2]||String(t.length))!=t.length&&ku.throwArgumentError(`invalid array length for ${e}`,"value",t);const i=[];return t.forEach((function(e){i.push(Eu(r,e,!0))})),M(i)}return ku.throwArgumentError("invalid type","type",e)}function _u(e,t){e.length!=t.length&&ku.throwArgumentError("wrong number of values; expected ${ types.length }","values",t);const r=[];return e.forEach((function(e,n){r.push(Eu(e,t[n]))})),O(M(r))}function Mu(e,t){return ve(_u(e,t))}function Tu(e,t){return vi(_u(e,t))}function xu(e,t){t||(t=function(e){return[parseInt(e,16)]});let r=0,n={};return e.split(",").forEach((e=>{let i=e.split(":");r+=parseInt(i[0],16),n[r]=t(i[1])})),n}function Pu(e){let t=0;return e.split(",").map((e=>{let r=e.split("-");1===r.length?r[1]="0":""===r[1]&&(r[1]="1");let n=t+parseInt(r[0],16);return t=parseInt(r[1],16),{l:n,h:t}}))}function Iu(e,t){let r=0;for(let n=0;n=r&&e<=r+i.h&&(e-r)%(i.d||1)==0){if(i.e&&-1!==i.e.indexOf(e-r))continue;return i}}return null}const Ou=Pu("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),Ru="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((e=>parseInt(e,16))),Cu=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],Bu=xu("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),Nu=xu("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),Lu=xu("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",(function(e){if(e.length%4!=0)throw new Error("bad data");let t=[];for(let r=0;r{if(Ru.indexOf(e)>=0)return[];if(e>=65024&&e<=65039)return[];let t=function(e){let t=Iu(e,Cu);if(t)return[e+t.s];let r=Bu[e];if(r)return r;let n=Nu[e];return n?[e+n[0]]:Lu[e]||null}(e);return t||[e]})),t=r.reduce(((e,t)=>(t.forEach((t=>{e.push(t)})),e)),[]),t=We(Xe(t),je.NFKC),t.forEach((e=>{if(Iu(e,Uu))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),t.forEach((e=>{if(Iu(e,Ou))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));let n=Xe(t);if("-"===n.substring(0,1)||"--"===n.substring(2,4)||"-"===n.substring(n.length-1))throw new Error("invalid hyphen");return n}function Du(e){const t=qe(e);if(t.length>31)throw new Error("bytes32 string must be less than 32 bytes");return O(M([t,xo]).slice(0,32))}function ju(e){const t=_(e);if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");let r=31;for(;0===t[r-1];)r--;return Qe(t.slice(0,r))}const Hu=new b("units/5.7.0"),Ju=["wei","kwei","mwei","gwei","szabo","finney","ether"];function zu(e){const t=String(e).split(".");(t.length>2||!t[0].match(/^-?[0-9]*$/)||t[1]&&!t[1].match(/^[0-9]*$/)||"."===e||"-."===e)&&Hu.throwArgumentError("invalid value","value",e);let r=t[0],n="";for("-"===r.substring(0,1)&&(n="-",r=r.substring(1));"0"===r.substring(0,1);)r=r.substring(1);""===r&&(r="0");let i="";for(2===t.length&&(i="."+(t[1]||"0"));i.length>2&&"0"===i[i.length-1];)i=i.substring(0,i.length-1);const o=[];for(;r.length;){if(r.length<=3){o.unshift(r);break}{const e=r.length-3;o.unshift(r.substring(e)),r=r.substring(0,e)}}return n+o.join(",")+i}function Gu(e,t){if("string"==typeof t){const e=Ju.indexOf(t);-1!==e&&(t=3*e)}return Gn(e,null!=t?t:18)}function qu(e,t){if("string"!=typeof e&&Hu.throwArgumentError("value must be a string","value",e),"string"==typeof t){const e=Ju.indexOf(t);-1!==e&&(t=3*e)}return qn(e,null!=t?t:18)}function Ku(e){return Gu(e,18)}function Vu(e){return qu(e,18)}const Xu="ethers/5.7.2",Qu=new b(Xu);try{const e=window;null==e._ethers&&(e._ethers=u)}catch(e){}},88459:(e,t,r)=>{const n=r(54099);e.exports=async function(e){return n.utils.sha256(n.utils.toUtf8Bytes(e))}},9669:(e,t,r)=>{e.exports=r(51609)},55448:(e,t,r)=>{"use strict";var n=r(64867),i=r(36026),o=r(4372),a=r(15327),s=r(94097),u=r(84109),c=r(67985),l=r(77874),f=r(82648),h=r(60644),d=r(90205);e.exports=function(e){return new Promise((function(t,r){var p,m=e.data,y=e.headers,g=e.responseType;function b(){e.cancelToken&&e.cancelToken.unsubscribe(p),e.signal&&e.signal.removeEventListener("abort",p)}n.isFormData(m)&&n.isStandardBrowserEnv()&&delete y["Content-Type"];var v=new XMLHttpRequest;if(e.auth){var w=e.auth.username||"",A=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";y.Authorization="Basic "+btoa(w+":"+A)}var S=s(e.baseURL,e.url);function k(){if(v){var n="getAllResponseHeaders"in v?u(v.getAllResponseHeaders()):null,o={data:g&&"text"!==g&&"json"!==g?v.response:v.responseText,status:v.status,statusText:v.statusText,headers:n,config:e,request:v};i((function(e){t(e),b()}),(function(e){r(e),b()}),o),v=null}}if(v.open(e.method.toUpperCase(),a(S,e.params,e.paramsSerializer),!0),v.timeout=e.timeout,"onloadend"in v?v.onloadend=k:v.onreadystatechange=function(){v&&4===v.readyState&&(0!==v.status||v.responseURL&&0===v.responseURL.indexOf("file:"))&&setTimeout(k)},v.onabort=function(){v&&(r(new f("Request aborted",f.ECONNABORTED,e,v)),v=null)},v.onerror=function(){r(new f("Network Error",f.ERR_NETWORK,e,v,v)),v=null},v.ontimeout=function(){var t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded",n=e.transitional||l;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),r(new f(t,n.clarifyTimeoutError?f.ETIMEDOUT:f.ECONNABORTED,e,v)),v=null},n.isStandardBrowserEnv()){var E=(e.withCredentials||c(S))&&e.xsrfCookieName?o.read(e.xsrfCookieName):void 0;E&&(y[e.xsrfHeaderName]=E)}"setRequestHeader"in v&&n.forEach(y,(function(e,t){void 0===m&&"content-type"===t.toLowerCase()?delete y[t]:v.setRequestHeader(t,e)})),n.isUndefined(e.withCredentials)||(v.withCredentials=!!e.withCredentials),g&&"json"!==g&&(v.responseType=e.responseType),"function"==typeof e.onDownloadProgress&&v.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&v.upload&&v.upload.addEventListener("progress",e.onUploadProgress),(e.cancelToken||e.signal)&&(p=function(e){v&&(r(!e||e&&e.type?new h:e),v.abort(),v=null)},e.cancelToken&&e.cancelToken.subscribe(p),e.signal&&(e.signal.aborted?p():e.signal.addEventListener("abort",p))),m||(m=null);var _=d(S);_&&-1===["http","https","file"].indexOf(_)?r(new f("Unsupported protocol "+_+":",f.ERR_BAD_REQUEST,e)):v.send(m)}))}},51609:(e,t,r)=>{"use strict";var n=r(64867),i=r(91849),o=r(30321),a=r(47185);var s=function e(t){var r=new o(t),s=i(o.prototype.request,r);return n.extend(s,o.prototype,r),n.extend(s,r),s.create=function(r){return e(a(t,r))},s}(r(45546));s.Axios=o,s.CanceledError=r(60644),s.CancelToken=r(14972),s.isCancel=r(26502),s.VERSION=r(97288).version,s.toFormData=r(47675),s.AxiosError=r(82648),s.Cancel=s.CanceledError,s.all=function(e){return Promise.all(e)},s.spread=r(8713),s.isAxiosError=r(16268),e.exports=s,e.exports.default=s},14972:(e,t,r)=>{"use strict";var n=r(60644);function i(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var r=this;this.promise.then((function(e){if(r._listeners){var t,n=r._listeners.length;for(t=0;t{"use strict";var n=r(82648);function i(e){n.call(this,null==e?"canceled":e,n.ERR_CANCELED),this.name="CanceledError"}r(64867).inherits(i,n,{__CANCEL__:!0}),e.exports=i},26502:e=>{"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},30321:(e,t,r)=>{"use strict";var n=r(64867),i=r(15327),o=r(80782),a=r(13572),s=r(47185),u=r(94097),c=r(54875),l=c.validators;function f(e){this.defaults=e,this.interceptors={request:new o,response:new o}}f.prototype.request=function(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},(t=s(this.defaults,t)).method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var r=t.transitional;void 0!==r&&c.assertOptions(r,{silentJSONParsing:l.transitional(l.boolean),forcedJSONParsing:l.transitional(l.boolean),clarifyTimeoutError:l.transitional(l.boolean)},!1);var n=[],i=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(i=i&&e.synchronous,n.unshift(e.fulfilled,e.rejected))}));var o,u=[];if(this.interceptors.response.forEach((function(e){u.push(e.fulfilled,e.rejected)})),!i){var f=[a,void 0];for(Array.prototype.unshift.apply(f,n),f=f.concat(u),o=Promise.resolve(t);f.length;)o=o.then(f.shift(),f.shift());return o}for(var h=t;n.length;){var d=n.shift(),p=n.shift();try{h=d(h)}catch(e){p(e);break}}try{o=a(h)}catch(e){return Promise.reject(e)}for(;u.length;)o=o.then(u.shift(),u.shift());return o},f.prototype.getUri=function(e){e=s(this.defaults,e);var t=u(e.baseURL,e.url);return i(t,e.params,e.paramsSerializer)},n.forEach(["delete","get","head","options"],(function(e){f.prototype[e]=function(t,r){return this.request(s(r||{},{method:e,url:t,data:(r||{}).data}))}})),n.forEach(["post","put","patch"],(function(e){function t(t){return function(r,n,i){return this.request(s(i||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:n}))}}f.prototype[e]=t(),f.prototype[e+"Form"]=t(!0)})),e.exports=f},82648:(e,t,r)=>{"use strict";var n=r(64867);function i(e,t,r,n,i){Error.call(this),this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i)}n.inherits(i,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var o=i.prototype,a={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach((function(e){a[e]={value:e}})),Object.defineProperties(i,a),Object.defineProperty(o,"isAxiosError",{value:!0}),i.from=function(e,t,r,a,s,u){var c=Object.create(o);return n.toFlatObject(e,c,(function(e){return e!==Error.prototype})),i.call(c,e.message,t,r,a,s),c.name=e.name,u&&Object.assign(c,u),c},e.exports=i},80782:(e,t,r)=>{"use strict";var n=r(64867);function i(){this.handlers=[]}i.prototype.use=function(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1},i.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},i.prototype.forEach=function(e){n.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=i},94097:(e,t,r)=>{"use strict";var n=r(91793),i=r(7303);e.exports=function(e,t){return e&&!n(t)?i(e,t):t}},13572:(e,t,r)=>{"use strict";var n=r(64867),i=r(18527),o=r(26502),a=r(45546),s=r(60644);function u(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new s}e.exports=function(e){return u(e),e.headers=e.headers||{},e.data=i.call(e,e.data,e.headers,e.transformRequest),e.headers=n.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),n.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]})),(e.adapter||a.adapter)(e).then((function(t){return u(e),t.data=i.call(e,t.data,t.headers,e.transformResponse),t}),(function(t){return o(t)||(u(e),t&&t.response&&(t.response.data=i.call(e,t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},47185:(e,t,r)=>{"use strict";var n=r(64867);e.exports=function(e,t){t=t||{};var r={};function i(e,t){return n.isPlainObject(e)&&n.isPlainObject(t)?n.merge(e,t):n.isPlainObject(t)?n.merge({},t):n.isArray(t)?t.slice():t}function o(r){return n.isUndefined(t[r])?n.isUndefined(e[r])?void 0:i(void 0,e[r]):i(e[r],t[r])}function a(e){if(!n.isUndefined(t[e]))return i(void 0,t[e])}function s(r){return n.isUndefined(t[r])?n.isUndefined(e[r])?void 0:i(void 0,e[r]):i(void 0,t[r])}function u(r){return r in t?i(e[r],t[r]):r in e?i(void 0,e[r]):void 0}var c={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:u};return n.forEach(Object.keys(e).concat(Object.keys(t)),(function(e){var t=c[e]||o,i=t(e);n.isUndefined(i)&&t!==u||(r[e]=i)})),r}},36026:(e,t,r)=>{"use strict";var n=r(82648);e.exports=function(e,t,r){var i=r.config.validateStatus;r.status&&i&&!i(r.status)?t(new n("Request failed with status code "+r.status,[n.ERR_BAD_REQUEST,n.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r)):e(r)}},18527:(e,t,r)=>{"use strict";var n=r(64867),i=r(45546);e.exports=function(e,t,r){var o=this||i;return n.forEach(r,(function(r){e=r.call(o,e,t)})),e}},45546:(e,t,r)=>{"use strict";var n=r(34155),i=r(64867),o=r(16016),a=r(82648),s=r(77874),u=r(47675),c={"Content-Type":"application/x-www-form-urlencoded"};function l(e,t){!i.isUndefined(e)&&i.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var f,h={transitional:s,adapter:(("undefined"!=typeof XMLHttpRequest||void 0!==n&&"[object process]"===Object.prototype.toString.call(n))&&(f=r(55448)),f),transformRequest:[function(e,t){if(o(t,"Accept"),o(t,"Content-Type"),i.isFormData(e)||i.isArrayBuffer(e)||i.isBuffer(e)||i.isStream(e)||i.isFile(e)||i.isBlob(e))return e;if(i.isArrayBufferView(e))return e.buffer;if(i.isURLSearchParams(e))return l(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString();var r,n=i.isObject(e),a=t&&t["Content-Type"];if((r=i.isFileList(e))||n&&"multipart/form-data"===a){var s=this.env&&this.env.FormData;return u(r?{"files[]":e}:e,s&&new s)}return n||"application/json"===a?(l(t,"application/json"),function(e,t,r){if(i.isString(e))try{return(t||JSON.parse)(e),i.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(r||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){var t=this.transitional||h.transitional,r=t&&t.silentJSONParsing,n=t&&t.forcedJSONParsing,o=!r&&"json"===this.responseType;if(o||n&&i.isString(e)&&e.length)try{return JSON.parse(e)}catch(e){if(o){if("SyntaxError"===e.name)throw a.from(e,a.ERR_BAD_RESPONSE,this,null,this.response);throw e}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:r(91623)},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};i.forEach(["delete","get","head"],(function(e){h.headers[e]={}})),i.forEach(["post","put","patch"],(function(e){h.headers[e]=i.merge(c)})),e.exports=h},77874:e=>{"use strict";e.exports={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1}},97288:e=>{e.exports={version:"0.27.2"}},91849:e=>{"use strict";e.exports=function(e,t){return function(){for(var r=new Array(arguments.length),n=0;n{"use strict";var n=r(64867);function i(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}e.exports=function(e,t,r){if(!t)return e;var o;if(r)o=r(t);else if(n.isURLSearchParams(t))o=t.toString();else{var a=[];n.forEach(t,(function(e,t){null!=e&&(n.isArray(e)?t+="[]":e=[e],n.forEach(e,(function(e){n.isDate(e)?e=e.toISOString():n.isObject(e)&&(e=JSON.stringify(e)),a.push(i(t)+"="+i(e))})))})),o=a.join("&")}if(o){var s=e.indexOf("#");-1!==s&&(e=e.slice(0,s)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}},7303:e=>{"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},4372:(e,t,r)=>{"use strict";var n=r(64867);e.exports=n.isStandardBrowserEnv()?{write:function(e,t,r,i,o,a){var s=[];s.push(e+"="+encodeURIComponent(t)),n.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),n.isString(i)&&s.push("path="+i),n.isString(o)&&s.push("domain="+o),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},91793:e=>{"use strict";e.exports=function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}},16268:(e,t,r)=>{"use strict";var n=r(64867);e.exports=function(e){return n.isObject(e)&&!0===e.isAxiosError}},67985:(e,t,r)=>{"use strict";var n=r(64867);e.exports=n.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");function i(e){var n=e;return t&&(r.setAttribute("href",n),n=r.href),r.setAttribute("href",n),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:"/"===r.pathname.charAt(0)?r.pathname:"/"+r.pathname}}return e=i(window.location.href),function(t){var r=n.isString(t)?i(t):t;return r.protocol===e.protocol&&r.host===e.host}}():function(){return!0}},16016:(e,t,r)=>{"use strict";var n=r(64867);e.exports=function(e,t){n.forEach(e,(function(r,n){n!==t&&n.toUpperCase()===t.toUpperCase()&&(e[t]=r,delete e[n])}))}},91623:e=>{e.exports=null},84109:(e,t,r)=>{"use strict";var n=r(64867),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,r,o,a={};return e?(n.forEach(e.split("\n"),(function(e){if(o=e.indexOf(":"),t=n.trim(e.substr(0,o)).toLowerCase(),r=n.trim(e.substr(o+1)),t){if(a[t]&&i.indexOf(t)>=0)return;a[t]="set-cookie"===t?(a[t]?a[t]:[]).concat([r]):a[t]?a[t]+", "+r:r}})),a):a}},90205:e=>{"use strict";e.exports=function(e){var t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}},8713:e=>{"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},47675:(e,t,r)=>{"use strict";var n=r(48764).Buffer,i=r(64867);e.exports=function(e,t){t=t||new FormData;var r=[];function o(e){return null===e?"":i.isDate(e)?e.toISOString():i.isArrayBuffer(e)||i.isTypedArray(e)?"function"==typeof Blob?new Blob([e]):n.from(e):e}return function e(n,a){if(i.isPlainObject(n)||i.isArray(n)){if(-1!==r.indexOf(n))throw Error("Circular reference detected in "+a);r.push(n),i.forEach(n,(function(r,n){if(!i.isUndefined(r)){var s,u=a?a+"."+n:n;if(r&&!a&&"object"==typeof r)if(i.endsWith(n,"{}"))r=JSON.stringify(r);else if(i.endsWith(n,"[]")&&(s=i.toArray(r)))return void s.forEach((function(e){!i.isUndefined(e)&&t.append(u,o(e))}));e(r,u)}})),r.pop()}else t.append(a,o(n))}(e),t}},54875:(e,t,r)=>{"use strict";var n=r(97288).version,i=r(82648),o={};["object","boolean","number","function","string","symbol"].forEach((function(e,t){o[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}}));var a={};o.transitional=function(e,t,r){function o(e,t){return"[Axios v"+n+"] Transitional option '"+e+"'"+t+(r?". "+r:"")}return function(r,n,s){if(!1===e)throw new i(o(n," has been removed"+(t?" in "+t:"")),i.ERR_DEPRECATED);return t&&!a[n]&&(a[n]=!0,console.warn(o(n," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(r,n,s)}},e.exports={assertOptions:function(e,t,r){if("object"!=typeof e)throw new i("options must be an object",i.ERR_BAD_OPTION_VALUE);for(var n=Object.keys(e),o=n.length;o-- >0;){var a=n[o],s=t[a];if(s){var u=e[a],c=void 0===u||s(u,a,e);if(!0!==c)throw new i("option "+a+" must be "+c,i.ERR_BAD_OPTION_VALUE)}else if(!0!==r)throw new i("Unknown option "+a,i.ERR_BAD_OPTION)}},validators:o}},64867:(e,t,r)=>{"use strict";var n,i=r(91849),o=Object.prototype.toString,a=(n=Object.create(null),function(e){var t=o.call(e);return n[t]||(n[t]=t.slice(8,-1).toLowerCase())});function s(e){return e=e.toLowerCase(),function(t){return a(t)===e}}function u(e){return Array.isArray(e)}function c(e){return void 0===e}var l=s("ArrayBuffer");function f(e){return null!==e&&"object"==typeof e}function h(e){if("object"!==a(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}var d=s("Date"),p=s("File"),m=s("Blob"),y=s("FileList");function g(e){return"[object Function]"===o.call(e)}var b=s("URLSearchParams");function v(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),u(e))for(var r=0,n=e.length;r0;)a[o=n[i]]||(t[o]=e[o],a[o]=!0);e=Object.getPrototypeOf(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},kindOf:a,kindOfTest:s,endsWith:function(e,t,r){e=String(e),(void 0===r||r>e.length)&&(r=e.length),r-=t.length;var n=e.indexOf(t,r);return-1!==n&&n===r},toArray:function(e){if(!e)return null;var t=e.length;if(c(t))return null;for(var r=new Array(t);t-- >0;)r[t]=e[t];return r},isTypedArray:A,isFileList:y}},79742:(e,t)=>{"use strict";t.byteLength=function(e){var t=u(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,o=u(e),a=o[0],s=o[1],c=new i(function(e,t,r){return 3*(t+r)/4-r}(0,a,s)),l=0,f=s>0?a-4:a;for(r=0;r>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===s&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,c[l++]=255&t);1===s&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],a=16383,s=0,u=n-i;su?u:s+a));1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return o.join("")};for(var r=[],n=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=o.length;a0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function c(e,t,n){for(var i,o,a=[],s=t;s>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},92882:e=>{"use strict";for(var t="qpzry9x8gf2tvdw0s3jn54khce6mua7l",r={},n=0;n>25;return(33554431&e)<<5^996825010&-(t>>0&1)^642813549&-(t>>1&1)^513874426&-(t>>2&1)^1027748829&-(t>>3&1)^705979059&-(t>>4&1)}function a(e){for(var t=1,r=0;r126)return"Invalid prefix ("+e+")";t=o(t)^n>>5}for(t=o(t),r=0;rt)return"Exceeds length limit";var n=e.toLowerCase(),i=e.toUpperCase();if(e!==n&&e!==i)return"Mixed-case string "+e;var s=(e=n).lastIndexOf("1");if(-1===s)return"No separator character for "+e;if(0===s)return"Missing prefix for "+e;var u=e.slice(0,s),c=e.slice(s+1);if(c.length<6)return"Data too short";var l=a(u);if("string"==typeof l)return l;for(var f=[],h=0;h=c.length||f.push(p)}return 1!==l?"Invalid checksum for "+e:{prefix:u,words:f}}function u(e,t,r,n){for(var i=0,o=0,a=(1<=r;)o-=r,s.push(i>>o&a);if(n)o>0&&s.push(i<=t)return"Excess padding";if(i<n)throw new TypeError("Exceeds length limit");var i=a(e=e.toLowerCase());if("string"==typeof i)throw new Error(i);for(var s=e+"1",u=0;u>5!=0)throw new Error("Non 5-bit word");i=o(i)^c,s+=t.charAt(c)}for(u=0;u<6;++u)i=o(i);for(i^=1,u=0;u<6;++u){s+=t.charAt(i>>5*(5-u)&31)}return s},toWordsUnsafe:function(e){var t=u(e,8,5,!0);if(Array.isArray(t))return t},toWords:function(e){var t=u(e,8,5,!0);if(Array.isArray(t))return t;throw new Error(t)},fromWordsUnsafe:function(e){var t=u(e,5,8,!1);if(Array.isArray(t))return t},fromWords:function(e){var t=u(e,5,8,!1);if(Array.isArray(t))return t;throw new Error(t)}}},13550:function(e,t,r){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(46601).Buffer}catch(e){}function s(e,t){var r=e.charCodeAt(t);return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void n(!1,"Invalid character in "+e)}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,i){for(var o=0,a=0,s=Math.min(e.length,r),u=t;u=49?c-49+10:c>=17?c-17+10:c,n(c>=0&&a0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this._strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this._strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{o.prototype[Symbol.for("nodejs.util.inspect.custom")]=f}catch(e){o.prototype.inspect=f}else o.prototype.inspect=f;function f(){return(this.red?""}var h=["","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"],d=[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],p=[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];o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215,(i+=2)>=26&&(i-=26,a--),r=0!==o||a!==this.length-1?h[6-u.length]+u+r:u+r}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=d[e],l=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modrn(l).toString(e);r=(f=f.idivn(l)).isZero()?m+r:h[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16,2)},a&&(o.prototype.toBuffer=function(e,t){return this.toArrayLike(a,e,t)}),o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)};function m(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r._strip()}o.prototype.toArrayLike=function(e,t,r){this._strip();var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0");var a=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,o);return this["_toArrayLike"+("le"===t?"LE":"BE")](a,i),a},o.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,i=0,o=0;i>8&255),r>16&255),6===o?(r>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r=0&&(e[r--]=a>>8&255),r>=0&&(e[r--]=a>>16&255),6===o?(r>=0&&(e[r--]=a>>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this._strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function g(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r._strip()}function b(e,t,r){return g(e,t,r)}function v(e,t){this.x=e,this.y=t}Math.imul||(y=m),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?y(this,e,t):r<63?m(this,e,t):r<1024?g(this,e,t):b(this,e,t)},v.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},v.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,r+=o/67108864|0,r+=a>>>26,this.words[i]=67108863&a}return 0!==r&&(this.words[i]=r,this.length++),t?this.ineg():this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i&1}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this._strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this._strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modrn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modrn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=(1<<26)%e,i=0,o=this.length-1;o>=0;o--)i=(r*i+(0|this.words[o]))%e;return t?-i:i},o.prototype.modn=function(e){return this.modrn(e)},o.prototype.idivn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=0,i=this.length-1;i>=0;i--){var o=(0|this.words[i])+67108864*r;this.words[i]=o/e|0,r=o%e}return this._strip(),t?this.ineg():this},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new M(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var w={k256:null,p224:null,p192:null,p25519:null};function A(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function S(){A.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function k(){A.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function E(){A.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){A.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function T(e){M.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}A.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},A.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},A.prototype.split=function(e,t){e.iushrn(this.n,0,t)},A.prototype.imulK=function(e){return e.imul(this.k)},i(S,A),S.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},S.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(w[e])return w[e];var t;if("k256"===e)t=new S;else if("p224"===e)t=new k;else if("p192"===e)t=new E;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new _}return w[e]=t,t},M.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},M.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},M.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(l(e,e.umod(this.m)._forceRed(this)),e)},M.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},M.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},M.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},M.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},M.prototype.isqr=function(e){return this.imul(e,e.clone())},M.prototype.sqr=function(e){return this.mul(e,e)},M.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},M.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},M.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new T(e)},i(T,M),T.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},T.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},T.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},T.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},T.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},29931:(e,t,r)=>{var n;function i(e){this.rand=e}if(e.exports=function(e){return n||(n=new i(null)),n.generate(e)},e.exports.Rand=i,i.prototype.generate=function(e){return this._rand(e)},i.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r{var n=r(89509).Buffer;function i(e){n.isBuffer(e)||(e=n.from(e));for(var t=e.length/4|0,r=new Array(t),i=0;i>>24]^l[p>>>16&255]^f[m>>>8&255]^h[255&y]^t[g++],a=c[p>>>24]^l[m>>>16&255]^f[y>>>8&255]^h[255&d]^t[g++],s=c[m>>>24]^l[y>>>16&255]^f[d>>>8&255]^h[255&p]^t[g++],u=c[y>>>24]^l[d>>>16&255]^f[p>>>8&255]^h[255&m]^t[g++],d=o,p=a,m=s,y=u;return o=(n[d>>>24]<<24|n[p>>>16&255]<<16|n[m>>>8&255]<<8|n[255&y])^t[g++],a=(n[p>>>24]<<24|n[m>>>16&255]<<16|n[y>>>8&255]<<8|n[255&d])^t[g++],s=(n[m>>>24]<<24|n[y>>>16&255]<<16|n[d>>>8&255]<<8|n[255&p])^t[g++],u=(n[y>>>24]<<24|n[d>>>16&255]<<16|n[p>>>8&255]<<8|n[255&m])^t[g++],[o>>>=0,a>>>=0,s>>>=0,u>>>=0]}var s=[0,1,2,4,8,16,32,64,128,27,54],u=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],o=[[],[],[],[]],a=0,s=0,u=0;u<256;++u){var c=s^s<<1^s<<2^s<<3^s<<4;c=c>>>8^255&c^99,r[a]=c,n[c]=a;var l=e[a],f=e[l],h=e[f],d=257*e[c]^16843008*c;i[0][a]=d<<24|d>>>8,i[1][a]=d<<16|d>>>16,i[2][a]=d<<8|d>>>24,i[3][a]=d,d=16843009*h^65537*f^257*l^16843008*a,o[0][c]=d<<24|d>>>8,o[1][c]=d<<16|d>>>16,o[2][c]=d<<8|d>>>24,o[3][c]=d,0===a?a=s=1:(a=l^e[e[e[h^l]]],s^=e[e[s]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:o}}();function c(e){this._key=i(e),this._reset()}c.blockSize=16,c.keySize=32,c.prototype.blockSize=c.blockSize,c.prototype.keySize=c.keySize,c.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=4*(r+1),i=[],o=0;o>>24,a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a],a^=s[o/t|0]<<24):t>6&&o%t==4&&(a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a]),i[o]=i[o-t]^a}for(var c=[],l=0;l>>24]]^u.INV_SUB_MIX[1][u.SBOX[h>>>16&255]]^u.INV_SUB_MIX[2][u.SBOX[h>>>8&255]]^u.INV_SUB_MIX[3][u.SBOX[255&h]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=c},c.prototype.encryptBlockRaw=function(e){return a(e=i(e),this._keySchedule,u.SUB_MIX,u.SBOX,this._nRounds)},c.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=n.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},c.prototype.decryptBlock=function(e){var t=(e=i(e))[1];e[1]=e[3],e[3]=t;var r=a(e,this._invKeySchedule,u.INV_SUB_MIX,u.INV_SBOX,this._nRounds),o=n.allocUnsafe(16);return o.writeUInt32BE(r[0],0),o.writeUInt32BE(r[3],4),o.writeUInt32BE(r[2],8),o.writeUInt32BE(r[1],12),o},c.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},e.exports.AES=c},62422:(e,t,r)=>{var n=r(74497),i=r(89509).Buffer,o=r(71027),a=r(35717),s=r(83288),u=r(67295),c=r(20685);function l(e,t,r,a){o.call(this);var u=i.alloc(4,0);this._cipher=new n.AES(t);var l=this._cipher.encryptBlock(u);this._ghash=new s(l),r=function(e,t,r){if(12===t.length)return e._finID=i.concat([t,i.from([0,0,0,1])]),i.concat([t,i.from([0,0,0,2])]);var n=new s(r),o=t.length,a=o%16;n.update(t),a&&(a=16-a,n.update(i.alloc(a,0))),n.update(i.alloc(8,0));var u=8*o,l=i.alloc(8);l.writeUIntBE(u,0,8),n.update(l),e._finID=n.state;var f=i.from(e._finID);return c(f),f}(this,r,l),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}a(l,o),l.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=i.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},l.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=u(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i{var n=r(71494),i=r(66193),o=r(44946);t.createCipher=t.Cipher=n.createCipher,t.createCipheriv=t.Cipheriv=n.createCipheriv,t.createDecipher=t.Decipher=i.createDecipher,t.createDecipheriv=t.Decipheriv=i.createDecipheriv,t.listCiphers=t.getCiphers=function(){return Object.keys(o)}},66193:(e,t,r)=>{var n=r(62422),i=r(89509).Buffer,o=r(45),a=r(25969),s=r(71027),u=r(74497),c=r(13048);function l(e,t,r){s.call(this),this._cache=new f,this._last=void 0,this._cipher=new u.AES(t),this._prev=i.from(r),this._mode=e,this._autopadding=!0}function f(){this.cache=i.allocUnsafe(0)}function h(e,t,r){var s=o[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=i.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=i.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===s.type?new a(s.module,t,r,!0):"auth"===s.type?new n(s.module,t,r,!0):new l(s.module,t,r)}r(35717)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return i.concat(n)},l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");var r=-1;for(;++r16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},f.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=function(e,t){var r=o[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=c(t,!1,r.key,r.iv);return h(e,n.key,n.iv)},t.createDecipheriv=h},71494:(e,t,r)=>{var n=r(45),i=r(62422),o=r(89509).Buffer,a=r(25969),s=r(71027),u=r(74497),c=r(13048);function l(e,t,r){s.call(this),this._cache=new h,this._cipher=new u.AES(t),this._prev=o.from(r),this._mode=e,this._autopadding=!0}r(35717)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return o.concat(n)};var f=o.alloc(16,16);function h(){this.cache=o.allocUnsafe(0)}function d(e,t,r){var s=n[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=o.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof r&&(r=o.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);return"stream"===s.type?new a(s.module,t,r):"auth"===s.type?new i(s.module,t,r):new l(s.module,t,r)}l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(f))throw this._cipher.scrub(),new Error("data not multiple of block length")},l.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},h.prototype.add=function(e){this.cache=o.concat([this.cache,e])},h.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},h.prototype.flush=function(){for(var e=16-this.cache.length,t=o.allocUnsafe(e),r=-1;++r{var n=r(89509).Buffer,i=n.alloc(16,0);function o(e){var t=n.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function a(e){this.h=e,this.state=n.alloc(16,0),this.cache=n.allocUnsafe(0)}a.prototype.ghash=function(e){for(var t=-1;++t0;t--)n[t]=n[t]>>>1|(1&n[t-1])<<31;n[0]=n[0]>>>1,r&&(n[0]=n[0]^225<<24)}this.state=o(i)},a.prototype.update=function(e){var t;for(this.cache=n.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},a.prototype.final=function(e,t){return this.cache.length&&this.ghash(n.concat([this.cache,i],16)),this.ghash(o([0,e,0,t])),this.state},e.exports=a},20685:e=>{e.exports=function(e){for(var t,r=e.length;r--;){if(255!==(t=e.readUInt8(r))){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}},25292:(e,t,r)=>{var n=r(67295);t.encrypt=function(e,t){var r=n(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},t.decrypt=function(e,t){var r=e._prev;e._prev=t;var i=e._cipher.decryptBlock(t);return n(i,r)}},86311:(e,t,r)=>{var n=r(89509).Buffer,i=r(67295);function o(e,t,r){var o=t.length,a=i(t,e._cache);return e._cache=e._cache.slice(o),e._prev=n.concat([e._prev,r?t:a]),a}t.encrypt=function(e,t,r){for(var i,a=n.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=n.allocUnsafe(0)),!(e._cache.length<=t.length)){a=n.concat([a,o(e,t,r)]);break}i=e._cache.length,a=n.concat([a,o(e,t.slice(0,i),r)]),t=t.slice(i)}return a}},21510:(e,t,r)=>{var n=r(89509).Buffer;function i(e,t,r){for(var n,i,a=-1,s=0;++a<8;)n=t&1<<7-a?128:0,s+=(128&(i=e._cipher.encryptBlock(e._prev)[0]^n))>>a%8,e._prev=o(e._prev,r?n:i);return s}function o(e,t){var r=e.length,i=-1,o=n.allocUnsafe(e.length);for(e=n.concat([e,n.from([t])]);++i>7;return o}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{var n=r(89509).Buffer;function i(e,t,r){var i=e._cipher.encryptBlock(e._prev)[0]^t;return e._prev=n.concat([e._prev.slice(1),n.from([r?t:i])]),i}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{var n=r(67295),i=r(89509).Buffer,o=r(20685);function a(e){var t=e._cipher.encryptBlockRaw(e._prev);return o(e._prev),t}t.encrypt=function(e,t){var r=Math.ceil(t.length/16),o=e._cache.length;e._cache=i.concat([e._cache,i.allocUnsafe(16*r)]);for(var s=0;s{t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},45:(e,t,r)=>{var n={ECB:r(11084),CBC:r(25292),CFB:r(86311),CFB8:r(71964),CFB1:r(21510),OFB:r(18861),CTR:r(96009),GCM:r(96009)},i=r(44946);for(var o in i)i[o].module=n[i[o].mode];e.exports=i},18861:(e,t,r)=>{var n=r(48764).Buffer,i=r(67295);function o(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(e,t){for(;e._cache.length{var n=r(74497),i=r(89509).Buffer,o=r(71027);function a(e,t,r,a){o.call(this),this._cipher=new n.AES(t),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._mode=e}r(35717)(a,o),a.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},a.prototype._final=function(){this._cipher.scrub()},e.exports=a},53614:(e,t,r)=>{var n=r(47667),i=r(44696),o=r(45),a=r(99715),s=r(13048);function u(e,t,r){if(e=e.toLowerCase(),o[e])return i.createCipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function c(e,t,r){if(e=e.toLowerCase(),o[e])return i.createDecipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}t.createCipher=t.Cipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return u(e,i.key,i.iv)},t.createCipheriv=t.Cipheriv=u,t.createDecipher=t.Decipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return c(e,i.key,i.iv)},t.createDecipheriv=t.Decipheriv=c,t.listCiphers=t.getCiphers=function(){return Object.keys(a).concat(i.getCiphers())}},47667:(e,t,r)=>{var n=r(71027),i=r(15251),o=r(35717),a=r(89509).Buffer,s={"des-ede3-cbc":i.CBC.instantiate(i.EDE),"des-ede3":i.EDE,"des-ede-cbc":i.CBC.instantiate(i.EDE),"des-ede":i.EDE,"des-cbc":i.CBC.instantiate(i.DES),"des-ecb":i.DES};function u(e){n.call(this);var t,r=e.mode.toLowerCase(),i=s[r];t=e.decrypt?"decrypt":"encrypt";var o=e.key;a.isBuffer(o)||(o=a.from(o)),"des-ede"!==r&&"des-ede-cbc"!==r||(o=a.concat([o,o.slice(0,8)]));var u=e.iv;a.isBuffer(u)||(u=a.from(u)),this._des=i.create({key:o,iv:u,type:t})}s.des=s["des-cbc"],s.des3=s["des-ede3-cbc"],e.exports=u,o(u,n),u.prototype._update=function(e){return a.from(this._des.update(e))},u.prototype._final=function(){return a.from(this._des.final())}},99715:(e,t)=>{t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}},23663:(e,t,r)=>{var n=r(48764).Buffer,i=r(13550),o=r(61798);function a(e){var t,r=e.modulus.byteLength();do{t=new i(o(r))}while(t.cmp(e.modulus)>=0||!t.umod(e.prime1)||!t.umod(e.prime2));return t}function s(e,t){var r=function(e){var t=a(e);return{blinder:t.toRed(i.mont(e.modulus)).redPow(new i(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(t),o=t.modulus.byteLength(),s=new i(e).mul(r.blinder).umod(t.modulus),u=s.toRed(i.mont(t.prime1)),c=s.toRed(i.mont(t.prime2)),l=t.coefficient,f=t.prime1,h=t.prime2,d=u.redPow(t.exponent1).fromRed(),p=c.redPow(t.exponent2).fromRed(),m=d.isub(p).imul(l).umod(f).imul(h);return p.iadd(m).imul(r.unblinder).umod(t.modulus).toArrayLike(n,"be",o)}s.getr=a,e.exports=s},56042:(e,t,r)=>{e.exports=r(75207)},64743:(e,t,r)=>{var n=r(89509).Buffer,i=r(23482),o=r(88473),a=r(35717),s=r(82957),u=r(47753),c=r(75207);function l(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function f(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function h(e){return new l(e)}function d(e){return new f(e)}Object.keys(c).forEach((function(e){c[e].id=n.from(c[e].id,"hex"),c[e.toLowerCase()]=c[e]})),a(l,o.Writable),l.prototype._write=function(e,t,r){this._hash.update(e),r()},l.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},l.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),n=s(r,e,this._hashType,this._signType,this._tag);return t?n.toString(t):n},a(f,o.Writable),f.prototype._write=function(e,t,r){this._hash.update(e),r()},f.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},f.prototype.verify=function(e,t,r){"string"==typeof t&&(t=n.from(t,r)),this.end();var i=this._hash.digest();return u(t,i,e,this._signType,this._tag)},e.exports={Sign:h,Verify:d,createSign:h,createVerify:d}},82957:(e,t,r)=>{var n=r(89509).Buffer,i=r(58355),o=r(23663),a=r(86266).ec,s=r(13550),u=r(70980),c=r(1308);function l(e,t,r,o){if((e=n.from(e.toArray())).length0&&r.ishrn(n),r}function h(e,t,r){var o,a;do{for(o=n.alloc(0);8*o.length{var n=r(89509).Buffer,i=r(13550),o=r(86266).ec,a=r(70980),s=r(1308);function u(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=t)throw new Error("invalid sig")}e.exports=function(e,t,r,c,l){var f=a(r);if("ec"===f.type){if("ecdsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=s[r.data.algorithm.curve.join(".")];if(!n)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var i=new o(n),a=r.data.subjectPrivateKey.data;return i.verify(t,e,a)}(e,t,f)}if("dsa"===f.type){if("dsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=r.data.p,o=r.data.q,s=r.data.g,c=r.data.pub_key,l=a.signature.decode(e,"der"),f=l.s,h=l.r;u(f,o),u(h,o);var d=i.mont(n),p=f.invm(o);return 0===s.toRed(d).redPow(new i(t).mul(p).mod(o)).fromRed().mul(c.toRed(d).redPow(h.mul(p).mod(o)).fromRed()).mod(n).mod(o).cmp(h)}(e,t,f)}if("rsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");t=n.concat([l,t]);for(var h=f.modulus.byteLength(),d=[1],p=0;t.length+d.length+2{var n=r(48764).Buffer;e.exports=function(e){for(var t=new n(e.length),r=0,i=e.length-1;r<=i;++r,--i)t[r]=e[i],t[i]=e[r];return t}},67295:(e,t,r)=>{var n=r(48764).Buffer;e.exports=function(e,t){for(var r=Math.min(e.length,t.length),i=new n(r),o=0;o{"use strict";const n=r(79742),i=r(80645),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=u,t.SlowBuffer=function(e){+e!=e&&(e=0);return u.alloc(+e)},t.INSPECT_MAX_BYTES=50;const a=2147483647;function s(e){if(e>a)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,u.prototype),t}function u(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return f(e)}return c(e,t,r)}function c(e,t,r){if("string"==typeof e)return function(e,t){"string"==typeof t&&""!==t||(t="utf8");if(!u.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|m(e,t);let n=s(r);const i=n.write(e,t);i!==r&&(n=n.slice(0,i));return n}(e,t);if(ArrayBuffer.isView(e))return function(e){if(Q(e,Uint8Array)){const t=new Uint8Array(e);return d(t.buffer,t.byteOffset,t.byteLength)}return h(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(Q(e,ArrayBuffer)||e&&Q(e.buffer,ArrayBuffer))return d(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(Q(e,SharedArrayBuffer)||e&&Q(e.buffer,SharedArrayBuffer)))return d(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return u.from(n,t,r);const i=function(e){if(u.isBuffer(e)){const t=0|p(e.length),r=s(t);return 0===r.length||e.copy(r,0,0,t),r}if(void 0!==e.length)return"number"!=typeof e.length||W(e.length)?s(0):h(e);if("Buffer"===e.type&&Array.isArray(e.data))return h(e.data)}(e);if(i)return i;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return u.from(e[Symbol.toPrimitive]("string"),t,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function f(e){return l(e),s(e<0?0:0|p(e))}function h(e){const t=e.length<0?0:0|p(e.length),r=s(t);for(let n=0;n=a)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a.toString(16)+" bytes");return 0|e}function m(e,t){if(u.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||Q(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const r=e.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let i=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return K(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return V(e).length;default:if(i)return n?-1:K(e).length;t=(""+t).toLowerCase(),i=!0}}function y(e,t,r){let n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return I(this,t,r);case"utf8":case"utf-8":return M(this,t,r);case"ascii":return x(this,t,r);case"latin1":case"binary":return P(this,t,r);case"base64":return _(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function g(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function b(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),W(r=+r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=u.from(t,n)),u.isBuffer(t))return 0===t.length?-1:v(e,t,r,n,i);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):v(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function v(e,t,r,n,i){let o,a=1,s=e.length,u=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,r/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){let n=-1;for(o=r;os&&(r=s-u),o=r;o>=0;o--){let r=!0;for(let n=0;ni&&(n=i):n=i;const o=t.length;let a;for(n>o/2&&(n=o/2),a=0;a>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function _(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function M(e,t,r){r=Math.min(e.length,r);const n=[];let i=t;for(;i239?4:t>223?3:t>191?2:1;if(i+a<=r){let r,n,s,u;switch(a){case 1:t<128&&(o=t);break;case 2:r=e[i+1],128==(192&r)&&(u=(31&t)<<6|63&r,u>127&&(o=u));break;case 3:r=e[i+1],n=e[i+2],128==(192&r)&&128==(192&n)&&(u=(15&t)<<12|(63&r)<<6|63&n,u>2047&&(u<55296||u>57343)&&(o=u));break;case 4:r=e[i+1],n=e[i+2],s=e[i+3],128==(192&r)&&128==(192&n)&&128==(192&s)&&(u=(15&t)<<18|(63&r)<<12|(63&n)<<6|63&s,u>65535&&u<1114112&&(o=u))}}null===o?(o=65533,a=1):o>65535&&(o-=65536,n.push(o>>>10&1023|55296),o=56320|1023&o),n.push(o),i+=a}return function(e){const t=e.length;if(t<=T)return String.fromCharCode.apply(String,e);let r="",n=0;for(;nn.length?(u.isBuffer(t)||(t=u.from(t)),t.copy(n,i)):Uint8Array.prototype.set.call(n,t,i);else{if(!u.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(n,i)}i+=t.length}return n},u.byteLength=m,u.prototype._isBuffer=!0,u.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tr&&(e+=" ... "),""},o&&(u.prototype[o]=u.prototype.inspect),u.prototype.compare=function(e,t,r,n,i){if(Q(e,Uint8Array)&&(e=u.from(e,e.offset,e.byteLength)),!u.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;let o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0);const s=Math.min(o,a),c=this.slice(n,i),l=e.slice(t,r);for(let e=0;e>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const i=this.length-t;if((void 0===r||r>i)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let o=!1;for(;;)switch(n){case"hex":return w(this,e,t,r);case"utf8":case"utf-8":return A(this,e,t,r);case"ascii":case"latin1":case"binary":return S(this,e,t,r);case"base64":return k(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const T=4096;function x(e,t,r){let n="";r=Math.min(e.length,r);for(let i=t;in)&&(r=n);let i="";for(let n=t;nr)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,r,n,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function B(e,t,r,n,i){J(t,n,i,e,r,7);let o=Number(t&BigInt(4294967295));e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,r}function N(e,t,r,n,i){J(t,n,i,e,r,7);let o=Number(t&BigInt(4294967295));e[r+7]=o,o>>=8,e[r+6]=o,o>>=8,e[r+5]=o,o>>=8,e[r+4]=o;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=a,a>>=8,e[r+2]=a,a>>=8,e[r+1]=a,a>>=8,e[r]=a,r+8}function L(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function U(e,t,r,n,o){return t=+t,r>>>=0,o||L(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function F(e,t,r,n,o){return t=+t,r>>>=0,o||L(e,0,r,8),i.write(e,t,r,n,52,8),r+8}u.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t>>=0,t>>>=0,r||R(e,t,this.length);let n=this[e],i=1,o=0;for(;++o>>=0,t>>>=0,r||R(e,t,this.length);let n=this[e+--t],i=1;for(;t>0&&(i*=256);)n+=this[e+--t]*i;return n},u.prototype.readUint8=u.prototype.readUInt8=function(e,t){return e>>>=0,t||R(e,1,this.length),this[e]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(e,t){return e>>>=0,t||R(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(e,t){return e>>>=0,t||R(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(e,t){return e>>>=0,t||R(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(e,t){return e>>>=0,t||R(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readBigUInt64LE=Y((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,i=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(n)+(BigInt(i)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=t*2**24+65536*this[++e]+256*this[++e]+this[++e],i=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(n)<>>=0,t>>>=0,r||R(e,t,this.length);let n=this[e],i=1,o=0;for(;++o=i&&(n-=Math.pow(2,8*t)),n},u.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||R(e,t,this.length);let n=t,i=1,o=this[e+--n];for(;n>0&&(i*=256);)o+=this[e+--n]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return e>>>=0,t||R(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){e>>>=0,t||R(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(e,t){e>>>=0,t||R(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(e,t){return e>>>=0,t||R(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return e>>>=0,t||R(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readBigInt64LE=Y((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(n)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(n)<>>=0,t||R(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return e>>>=0,t||R(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return e>>>=0,t||R(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return e>>>=0,t||R(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUintLE=u.prototype.writeUIntLE=function(e,t,r,n){if(e=+e,t>>>=0,r>>>=0,!n){C(this,e,t,r,Math.pow(2,8*r)-1,0)}let i=1,o=0;for(this[t]=255&e;++o>>=0,r>>>=0,!n){C(this,e,t,r,Math.pow(2,8*r)-1,0)}let i=r-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+r},u.prototype.writeUint8=u.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,1,255,0),this[t]=255&e,t+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},u.prototype.writeBigUInt64LE=Y((function(e,t=0){return B(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeBigUInt64BE=Y((function(e,t=0){return N(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);C(this,e,t,r,n-1,-n)}let i=0,o=1,a=0;for(this[t]=255&e;++i>0)-a&255;return t+r},u.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);C(this,e,t,r,n-1,-n)}let i=r-1,o=1,a=0;for(this[t+i]=255&e;--i>=0&&(o*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/o>>0)-a&255;return t+r},u.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},u.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},u.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},u.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},u.prototype.writeBigInt64LE=Y((function(e,t=0){return B(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeBigInt64BE=Y((function(e,t=0){return N(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeFloatLE=function(e,t,r){return U(this,e,t,!0,r)},u.prototype.writeFloatBE=function(e,t,r){return U(this,e,t,!1,r)},u.prototype.writeDoubleLE=function(e,t,r){return F(this,e,t,!0,r)},u.prototype.writeDoubleBE=function(e,t,r){return F(this,e,t,!1,r)},u.prototype.copy=function(e,t,r,n){if(!u.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(i=t;i=n+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function J(e,t,r,n,i,o){if(e>r||e3?0===t||t===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(o+1)}${n}`:`>= -(2${n} ** ${8*(o+1)-1}${n}) and < 2 ** ${8*(o+1)-1}${n}`:`>= ${t}${n} and <= ${r}${n}`,new D.ERR_OUT_OF_RANGE("value",i,e)}!function(e,t,r){z(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||G(t,e.length-(r+1))}(n,i,o)}function z(e,t){if("number"!=typeof e)throw new D.ERR_INVALID_ARG_TYPE(t,"number",e)}function G(e,t,r){if(Math.floor(e)!==e)throw z(e,r),new D.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new D.ERR_BUFFER_OUT_OF_BOUNDS;throw new D.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${t}`,e)}j("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),j("ERR_INVALID_ARG_TYPE",(function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`}),TypeError),j("ERR_OUT_OF_RANGE",(function(e,t,r){let n=`The value of "${e}" is out of range.`,i=r;return Number.isInteger(r)&&Math.abs(r)>2**32?i=H(String(r)):"bigint"==typeof r&&(i=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(i=H(i)),i+="n"),n+=` It must be ${t}. Received ${i}`,n}),RangeError);const q=/[^+/0-9A-Za-z-_]/g;function K(e,t){let r;t=t||1/0;const n=e.length;let i=null;const o=[];for(let a=0;a55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function V(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(q,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function X(e,t,r,n){let i;for(i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}function Q(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function W(e){return e!=e}const Z=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let i=0;i<16;++i)t[n+i]=e[r]+e[i]}return t}();function Y(e){return"undefined"==typeof BigInt?$:e}function $(){throw new Error("BigInt not supported")}},39376:e=>{"use strict";e.exports={mask:(e,t,r,n,i)=>{for(var o=0;o{const r=e.length;for(var n=0;n{"use strict";try{e.exports=r(19516)("/")}catch(t){e.exports=r(39376)}},50584:e=>{e.exports={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}},21924:(e,t,r)=>{"use strict";var n=r(40210),i=r(55559),o=i(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&o(e,".prototype.")>-1?i(r):r}},55559:(e,t,r)=>{"use strict";var n=r(58612),i=r(40210),o=i("%Function.prototype.apply%"),a=i("%Function.prototype.call%"),s=i("%Reflect.apply%",!0)||n.call(a,o),u=i("%Object.getOwnPropertyDescriptor%",!0),c=i("%Object.defineProperty%",!0),l=i("%Math.max%");if(c)try{c({},"a",{value:1})}catch(e){c=null}e.exports=function(e){var t=s(n,a,arguments);if(u&&c){var r=u(t,"length");r.configurable&&c(t,"length",{value:1+l(0,e.length-(arguments.length-1))})}return t};var f=function(){return s(n,o,arguments)};c?c(e.exports,"apply",{value:f}):e.exports.apply=f},95456:e=>{"use strict";e.exports=function e(t){return null===t||"object"!=typeof t||null!=t.toJSON?JSON.stringify(t):Array.isArray(t)?"["+t.reduce(((t,r,n)=>t+(0===n?"":",")+e(void 0===r||"symbol"==typeof r?null:r)),"")+"]":"{"+Object.keys(t).sort().reduce(((r,n,i)=>{if(void 0===t[n]||"symbol"==typeof t[n])return r;return r+(0===r.length?"":",")+e(n)+":"+e(t[n])}),"")+"}"}},71027:(e,t,r)=>{var n=r(89509).Buffer,i=r(42830).Transform,o=r(32553).s;function a(e){i.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(35717)(a,i),a.prototype.update=function(e,t,r){"string"==typeof e&&(e=n.from(e,t));var i=this._update(e);return this.hashMode?this:(r&&(i=this._toString(i,r)),i)},a.prototype.setAutoPadding=function(){},a.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},a.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},a.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},a.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){n=e}finally{r(n)}},a.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},a.prototype._finalOrDigest=function(e){var t=this.__final()||n.alloc(0);return e&&(t=this._toString(t,e,!0)),t},a.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new o(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n},e.exports=a},76393:(e,t,r)=>{var n=r(48764).Buffer,i=r(86266),o=r(16426);e.exports=function(e){return new s(e)};var a={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function s(e){this.curveType=a[e],this.curveType||(this.curveType={name:e}),this.curve=new i.ec(this.curveType.name),this.keys=void 0}function u(e,t,r){Array.isArray(e)||(e=e.toArray());var i=new n(e);if(r&&i.length=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},23482:(e,t,r)=>{"use strict";var n=r(35717),i=r(62318),o=r(79785),a=r(89072),s=r(71027);function u(e){s.call(this,"digest"),this._hash=e}n(u,s),u.prototype._update=function(e){this._hash.update(e)},u.prototype._final=function(){return this._hash.digest()},e.exports=function(e){return"md5"===(e=e.toLowerCase())?new i:"rmd160"===e||"ripemd160"===e?new o:new u(a(e))}},78028:(e,t,r)=>{var n=r(62318);e.exports=function(e){return(new n).update(e).digest()}},58355:(e,t,r)=>{"use strict";var n=r(35717),i=r(51031),o=r(71027),a=r(89509).Buffer,s=r(78028),u=r(79785),c=r(89072),l=a.alloc(128);function f(e,t){o.call(this,"digest"),"string"==typeof t&&(t=a.from(t));var r="sha512"===e||"sha384"===e?128:64;(this._alg=e,this._key=t,t.length>r)?t=("rmd160"===e?new u:c(e)).update(t).digest():t.length{"use strict";var n=r(35717),i=r(89509).Buffer,o=r(71027),a=i.alloc(128),s=64;function u(e,t){o.call(this,"digest"),"string"==typeof t&&(t=i.from(t)),this._alg=e,this._key=t,t.length>s?t=e(t):t.length{"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=r(61798),t.createHash=t.Hash=r(23482),t.createHmac=t.Hmac=r(58355);var n=r(56042),i=Object.keys(n),o=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(i);t.getHashes=function(){return o};var a=r(25632);t.pbkdf2=a.pbkdf2,t.pbkdf2Sync=a.pbkdf2Sync;var s=r(53614);t.Cipher=s.Cipher,t.createCipher=s.createCipher,t.Cipheriv=s.Cipheriv,t.createCipheriv=s.createCipheriv,t.Decipher=s.Decipher,t.createDecipher=s.createDecipher,t.Decipheriv=s.Decipheriv,t.createDecipheriv=s.createDecipheriv,t.getCiphers=s.getCiphers,t.listCiphers=s.listCiphers;var u=r(62607);t.DiffieHellmanGroup=u.DiffieHellmanGroup,t.createDiffieHellmanGroup=u.createDiffieHellmanGroup,t.getDiffieHellman=u.getDiffieHellman,t.createDiffieHellman=u.createDiffieHellman,t.DiffieHellman=u.DiffieHellman;var c=r(64743);t.createSign=c.createSign,t.Sign=c.Sign,t.createVerify=c.createVerify,t.Verify=c.Verify,t.createECDH=r(76393);var l=r(7900);t.publicEncrypt=l.publicEncrypt,t.privateEncrypt=l.privateEncrypt,t.publicDecrypt=l.publicDecrypt,t.privateDecrypt=l.privateDecrypt;var f=r(77963);t.randomFill=f.randomFill,t.randomFillSync=f.randomFillSync,t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},40452:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib.BlockCipher,r=e.algo,i=[],o=[],a=[],s=[],u=[],c=[],l=[],f=[],h=[],d=[];!function(){for(var e=[],t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;var r=0,n=0;for(t=0;t<256;t++){var p=n^n<<1^n<<2^n<<3^n<<4;p=p>>>8^255&p^99,i[r]=p,o[p]=r;var m=e[r],y=e[m],g=e[y],b=257*e[p]^16843008*p;a[r]=b<<24|b>>>8,s[r]=b<<16|b>>>16,u[r]=b<<8|b>>>24,c[r]=b,b=16843009*g^65537*y^257*m^16843008*r,l[p]=b<<24|b>>>8,f[p]=b<<16|b>>>16,h[p]=b<<8|b>>>24,d[p]=b,r?(r=m^e[e[e[g^m]]],n^=e[e[n]]):r=n=1}}();var p=[0,1,2,4,8,16,32,64,128,27,54],m=r.AES=t.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var e=this._keyPriorReset=this._key,t=e.words,r=e.sigBytes/4,n=4*((this._nRounds=r+6)+1),o=this._keySchedule=[],a=0;a6&&a%r==4&&(s=i[s>>>24]<<24|i[s>>>16&255]<<16|i[s>>>8&255]<<8|i[255&s]):(s=i[(s=s<<8|s>>>24)>>>24]<<24|i[s>>>16&255]<<16|i[s>>>8&255]<<8|i[255&s],s^=p[a/r|0]<<24),o[a]=o[a-r]^s}for(var u=this._invKeySchedule=[],c=0;c>>24]]^f[i[s>>>16&255]]^h[i[s>>>8&255]]^d[i[255&s]]}},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,a,s,u,c,i)},decryptBlock:function(e,t){var r=e[t+1];e[t+1]=e[t+3],e[t+3]=r,this._doCryptBlock(e,t,this._invKeySchedule,l,f,h,d,o),r=e[t+1],e[t+1]=e[t+3],e[t+3]=r},_doCryptBlock:function(e,t,r,n,i,o,a,s){for(var u=this._nRounds,c=e[t]^r[0],l=e[t+1]^r[1],f=e[t+2]^r[2],h=e[t+3]^r[3],d=4,p=1;p>>24]^i[l>>>16&255]^o[f>>>8&255]^a[255&h]^r[d++],y=n[l>>>24]^i[f>>>16&255]^o[h>>>8&255]^a[255&c]^r[d++],g=n[f>>>24]^i[h>>>16&255]^o[c>>>8&255]^a[255&l]^r[d++],b=n[h>>>24]^i[c>>>16&255]^o[l>>>8&255]^a[255&f]^r[d++];c=m,l=y,f=g,h=b}m=(s[c>>>24]<<24|s[l>>>16&255]<<16|s[f>>>8&255]<<8|s[255&h])^r[d++],y=(s[l>>>24]<<24|s[f>>>16&255]<<16|s[h>>>8&255]<<8|s[255&c])^r[d++],g=(s[f>>>24]<<24|s[h>>>16&255]<<16|s[c>>>8&255]<<8|s[255&l])^r[d++],b=(s[h>>>24]<<24|s[c>>>16&255]<<16|s[l>>>8&255]<<8|s[255&f])^r[d++],e[t]=m,e[t+1]=y,e[t+2]=g,e[t+3]=b},keySize:8});e.AES=t._createHelper(m)}(),n.AES)},75109:function(e,t,r){var n;e.exports=(n=r(78249),r(90888),void(n.lib.Cipher||function(e){var t=n,r=t.lib,i=r.Base,o=r.WordArray,a=r.BufferedBlockAlgorithm,s=t.enc,u=(s.Utf8,s.Base64),c=t.algo.EvpKDF,l=r.Cipher=a.extend({cfg:i.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,r){this.cfg=this.cfg.extend(r),this._xformMode=e,this._key=t,this.reset()},reset:function(){a.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){return e&&this._append(e),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function e(e){return"string"==typeof e?v:g}return function(t){return{encrypt:function(r,n,i){return e(n).encrypt(t,r,n,i)},decrypt:function(r,n,i){return e(n).decrypt(t,r,n,i)}}}}()}),f=(r.StreamCipher=l.extend({_doFinalize:function(){return this._process(!0)},blockSize:1}),t.mode={}),h=r.BlockCipherMode=i.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}}),d=f.CBC=function(){var t=h.extend();function r(t,r,n){var i=this._iv;if(i){var o=i;this._iv=e}else o=this._prevBlock;for(var a=0;a>>2];e.sigBytes-=t}},m=(r.BlockCipher=l.extend({cfg:l.cfg.extend({mode:d,padding:p}),reset:function(){l.reset.call(this);var e=this.cfg,t=e.iv,r=e.mode;if(this._xformMode==this._ENC_XFORM_MODE)var n=r.createEncryptor;else n=r.createDecryptor,this._minBufferSize=1;this._mode&&this._mode.__creator==n?this._mode.init(this,t&&t.words):(this._mode=n.call(r,this,t&&t.words),this._mode.__creator=n)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){e.pad(this._data,this.blockSize);var t=this._process(!0)}else t=this._process(!0),e.unpad(t);return t},blockSize:4}),r.CipherParams=i.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}})),y=(t.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext,r=e.salt;if(r)var n=o.create([1398893684,1701076831]).concat(r).concat(t);else n=t;return n.toString(u)},parse:function(e){var t=u.parse(e),r=t.words;if(1398893684==r[0]&&1701076831==r[1]){var n=o.create(r.slice(2,4));r.splice(0,4),t.sigBytes-=16}return m.create({ciphertext:t,salt:n})}},g=r.SerializableCipher=i.extend({cfg:i.extend({format:y}),encrypt:function(e,t,r,n){n=this.cfg.extend(n);var i=e.createEncryptor(r,n),o=i.finalize(t),a=i.cfg;return m.create({ciphertext:o,key:r,iv:a.iv,algorithm:e,mode:a.mode,padding:a.padding,blockSize:e.blockSize,formatter:n.format})},decrypt:function(e,t,r,n){return n=this.cfg.extend(n),t=this._parse(t,n.format),e.createDecryptor(r,n).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),b=(t.kdf={}).OpenSSL={execute:function(e,t,r,n){n||(n=o.random(8));var i=c.create({keySize:t+r}).compute(e,n),a=o.create(i.words.slice(t),4*r);return i.sigBytes=4*t,m.create({key:i,iv:a,salt:n})}},v=r.PasswordBasedCipher=g.extend({cfg:g.cfg.extend({kdf:b}),encrypt:function(e,t,r,n){var i=(n=this.cfg.extend(n)).kdf.execute(r,e.keySize,e.ivSize);n.iv=i.iv;var o=g.encrypt.call(this,e,t,i.key,n);return o.mixIn(i),o},decrypt:function(e,t,r,n){n=this.cfg.extend(n),t=this._parse(t,n.format);var i=n.kdf.execute(r,e.keySize,e.ivSize,t.salt);return n.iv=i.iv,g.decrypt.call(this,e,t,i.key,n)}})}()))},78249:function(e,t){var r;e.exports=(r=r||function(e,t){var r=Object.create||function(){function e(){}return function(t){var r;return e.prototype=t,r=new e,e.prototype=null,r}}(),n={},i=n.lib={},o=i.Base={extend:function(e){var t=r(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},a=i.WordArray=o.extend({init:function(e,r){e=this.words=e||[],this.sigBytes=r!=t?r:4*e.length},toString:function(e){return(e||u).stringify(this)},concat:function(e){var t=this.words,r=e.words,n=this.sigBytes,i=e.sigBytes;if(this.clamp(),n%4)for(var o=0;o>>2]>>>24-o%4*8&255;t[n+o>>>2]|=a<<24-(n+o)%4*8}else for(o=0;o>>2]=r[o>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,r=this.sigBytes;t[r>>>2]&=4294967295<<32-r%4*8,t.length=e.ceil(r/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var r,n=[],i=function(t){var r=987654321,n=4294967295;return function(){var i=((r=36969*(65535&r)+(r>>16)&n)<<16)+(t=18e3*(65535&t)+(t>>16)&n)&n;return i/=4294967296,(i+=.5)*(e.random()>.5?1:-1)}},o=0;o>>2]>>>24-i%4*8&255;n.push((o>>>4).toString(16)),n.push((15&o).toString(16))}return n.join("")},parse:function(e){for(var t=e.length,r=[],n=0;n>>3]|=parseInt(e.substr(n,2),16)<<24-n%8*4;return new a.init(r,t/2)}},c=s.Latin1={stringify:function(e){for(var t=e.words,r=e.sigBytes,n=[],i=0;i>>2]>>>24-i%4*8&255;n.push(String.fromCharCode(o))}return n.join("")},parse:function(e){for(var t=e.length,r=[],n=0;n>>2]|=(255&e.charCodeAt(n))<<24-n%4*8;return new a.init(r,t)}},l=s.Utf8={stringify:function(e){try{return decodeURIComponent(escape(c.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return c.parse(unescape(encodeURIComponent(e)))}},f=i.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new a.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=l.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var r=this._data,n=r.words,i=r.sigBytes,o=this.blockSize,s=i/(4*o),u=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*o,c=e.min(4*u,i);if(u){for(var l=0;l>>6-a%4*2;i[o>>>2]|=(s|u)<<24-o%4*8,o++}return t.create(i,o)}e.enc.Base64={stringify:function(e){var t=e.words,r=e.sigBytes,n=this._map;e.clamp();for(var i=[],o=0;o>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,s=0;s<4&&o+.75*s>>6*(3-s)&63));var u=n.charAt(64);if(u)for(;i.length%4;)i.push(u);return i.join("")},parse:function(e){var t=e.length,n=this._map,i=this._reverseMap;if(!i){i=this._reverseMap=[];for(var o=0;o>>8&16711935}r.Utf16=r.Utf16BE={stringify:function(e){for(var t=e.words,r=e.sigBytes,n=[],i=0;i>>2]>>>16-i%4*8&65535;n.push(String.fromCharCode(o))}return n.join("")},parse:function(e){for(var r=e.length,n=[],i=0;i>>1]|=e.charCodeAt(i)<<16-i%2*16;return t.create(n,2*r)}},r.Utf16LE={stringify:function(e){for(var t=e.words,r=e.sigBytes,n=[],o=0;o>>2]>>>16-o%4*8&65535);n.push(String.fromCharCode(a))}return n.join("")},parse:function(e){for(var r=e.length,n=[],o=0;o>>1]|=i(e.charCodeAt(o)<<16-o%2*16);return t.create(n,2*r)}}}(),n.enc.Utf16)},90888:function(e,t,r){var n,i,o,a,s,u,c,l;e.exports=(l=r(78249),r(62783),r(89824),i=(n=l).lib,o=i.Base,a=i.WordArray,s=n.algo,u=s.MD5,c=s.EvpKDF=o.extend({cfg:o.extend({keySize:4,hasher:u,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var r=this.cfg,n=r.hasher.create(),i=a.create(),o=i.words,s=r.keySize,u=r.iterations;o.lengthn&&(t=e.finalize(t)),t.clamp();for(var i=this._oKey=t.clone(),o=this._iKey=t.clone(),s=i.words,u=o.words,c=0;c>>2]|=e[i]<<24-i%4*8;t.call(this,n,r)}else t.apply(this,arguments)};r.prototype=e}}(),n.lib.WordArray)},68214:function(e,t,r){var n;e.exports=(n=r(78249),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=[];!function(){for(var t=0;t<64;t++)s[t]=4294967296*e.abs(e.sin(t+1))|0}();var u=a.MD5=o.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var r=0;r<16;r++){var n=t+r,i=e[n];e[n]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o=this._hash.words,a=e[t+0],u=e[t+1],d=e[t+2],p=e[t+3],m=e[t+4],y=e[t+5],g=e[t+6],b=e[t+7],v=e[t+8],w=e[t+9],A=e[t+10],S=e[t+11],k=e[t+12],E=e[t+13],_=e[t+14],M=e[t+15],T=o[0],x=o[1],P=o[2],I=o[3];T=c(T,x,P,I,a,7,s[0]),I=c(I,T,x,P,u,12,s[1]),P=c(P,I,T,x,d,17,s[2]),x=c(x,P,I,T,p,22,s[3]),T=c(T,x,P,I,m,7,s[4]),I=c(I,T,x,P,y,12,s[5]),P=c(P,I,T,x,g,17,s[6]),x=c(x,P,I,T,b,22,s[7]),T=c(T,x,P,I,v,7,s[8]),I=c(I,T,x,P,w,12,s[9]),P=c(P,I,T,x,A,17,s[10]),x=c(x,P,I,T,S,22,s[11]),T=c(T,x,P,I,k,7,s[12]),I=c(I,T,x,P,E,12,s[13]),P=c(P,I,T,x,_,17,s[14]),T=l(T,x=c(x,P,I,T,M,22,s[15]),P,I,u,5,s[16]),I=l(I,T,x,P,g,9,s[17]),P=l(P,I,T,x,S,14,s[18]),x=l(x,P,I,T,a,20,s[19]),T=l(T,x,P,I,y,5,s[20]),I=l(I,T,x,P,A,9,s[21]),P=l(P,I,T,x,M,14,s[22]),x=l(x,P,I,T,m,20,s[23]),T=l(T,x,P,I,w,5,s[24]),I=l(I,T,x,P,_,9,s[25]),P=l(P,I,T,x,p,14,s[26]),x=l(x,P,I,T,v,20,s[27]),T=l(T,x,P,I,E,5,s[28]),I=l(I,T,x,P,d,9,s[29]),P=l(P,I,T,x,b,14,s[30]),T=f(T,x=l(x,P,I,T,k,20,s[31]),P,I,y,4,s[32]),I=f(I,T,x,P,v,11,s[33]),P=f(P,I,T,x,S,16,s[34]),x=f(x,P,I,T,_,23,s[35]),T=f(T,x,P,I,u,4,s[36]),I=f(I,T,x,P,m,11,s[37]),P=f(P,I,T,x,b,16,s[38]),x=f(x,P,I,T,A,23,s[39]),T=f(T,x,P,I,E,4,s[40]),I=f(I,T,x,P,a,11,s[41]),P=f(P,I,T,x,p,16,s[42]),x=f(x,P,I,T,g,23,s[43]),T=f(T,x,P,I,w,4,s[44]),I=f(I,T,x,P,k,11,s[45]),P=f(P,I,T,x,M,16,s[46]),T=h(T,x=f(x,P,I,T,d,23,s[47]),P,I,a,6,s[48]),I=h(I,T,x,P,b,10,s[49]),P=h(P,I,T,x,_,15,s[50]),x=h(x,P,I,T,y,21,s[51]),T=h(T,x,P,I,k,6,s[52]),I=h(I,T,x,P,p,10,s[53]),P=h(P,I,T,x,A,15,s[54]),x=h(x,P,I,T,u,21,s[55]),T=h(T,x,P,I,v,6,s[56]),I=h(I,T,x,P,M,10,s[57]),P=h(P,I,T,x,g,15,s[58]),x=h(x,P,I,T,E,21,s[59]),T=h(T,x,P,I,m,6,s[60]),I=h(I,T,x,P,S,10,s[61]),P=h(P,I,T,x,d,15,s[62]),x=h(x,P,I,T,w,21,s[63]),o[0]=o[0]+T|0,o[1]=o[1]+x|0,o[2]=o[2]+P|0,o[3]=o[3]+I|0},_doFinalize:function(){var t=this._data,r=t.words,n=8*this._nDataBytes,i=8*t.sigBytes;r[i>>>5]|=128<<24-i%32;var o=e.floor(n/4294967296),a=n;r[15+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),r[14+(i+64>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),t.sigBytes=4*(r.length+1),this._process();for(var s=this._hash,u=s.words,c=0;c<4;c++){var l=u[c];u[c]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}return s},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function c(e,t,r,n,i,o,a){var s=e+(t&r|~t&n)+i+a;return(s<>>32-o)+t}function l(e,t,r,n,i,o,a){var s=e+(t&n|r&~n)+i+a;return(s<>>32-o)+t}function f(e,t,r,n,i,o,a){var s=e+(t^r^n)+i+a;return(s<>>32-o)+t}function h(e,t,r,n,i,o,a){var s=e+(r^(t|~n))+i+a;return(s<>>32-o)+t}t.MD5=o._createHelper(u),t.HmacMD5=o._createHmacHelper(u)}(Math),n.MD5)},8568:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.mode.CFB=function(){var e=n.lib.BlockCipherMode.extend();function t(e,t,r,n){var i=this._iv;if(i){var o=i.slice(0);this._iv=void 0}else o=this._prevBlock;n.encryptBlock(o,0);for(var a=0;a>24&255)){var t=e>>16&255,r=e>>8&255,n=255&e;255===t?(t=0,255===r?(r=0,255===n?n=0:++n):++r):++t,e=0,e+=t<<16,e+=r<<8,e+=n}else e+=1<<24;return e}function r(e){return 0===(e[0]=t(e[0]))&&(e[1]=t(e[1])),e}var i=e.Encryptor=e.extend({processBlock:function(e,t){var n=this._cipher,i=n.blockSize,o=this._iv,a=this._counter;o&&(a=this._counter=o.slice(0),this._iv=void 0),r(a);var s=a.slice(0);n.encryptBlock(s,0);for(var u=0;u>>2]|=i<<24-o%4*8,e.sigBytes+=i},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},n.pad.Ansix923)},92807:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.Iso10126={pad:function(e,t){var r=4*t,i=r-e.sigBytes%r;e.concat(n.lib.WordArray.random(i-1)).concat(n.lib.WordArray.create([i<<24],1))},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},n.pad.Iso10126)},71077:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.Iso97971={pad:function(e,t){e.concat(n.lib.WordArray.create([2147483648],1)),n.pad.ZeroPadding.pad(e,t)},unpad:function(e){n.pad.ZeroPadding.unpad(e),e.sigBytes--}},n.pad.Iso97971)},16991:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.NoPadding={pad:function(){},unpad:function(){}},n.pad.NoPadding)},56475:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.ZeroPadding={pad:function(e,t){var r=4*t;e.clamp(),e.sigBytes+=r-(e.sigBytes%r||r)},unpad:function(e){for(var t=e.words,r=e.sigBytes-1;!(t[r>>>2]>>>24-r%4*8&255);)r--;e.sigBytes=r+1}},n.pad.ZeroPadding)},2112:function(e,t,r){var n,i,o,a,s,u,c,l,f;e.exports=(f=r(78249),r(62783),r(89824),i=(n=f).lib,o=i.Base,a=i.WordArray,s=n.algo,u=s.SHA1,c=s.HMAC,l=s.PBKDF2=o.extend({cfg:o.extend({keySize:4,hasher:u,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var r=this.cfg,n=c.create(r.hasher,e),i=a.create(),o=a.create([1]),s=i.words,u=o.words,l=r.keySize,f=r.iterations;s.length>>16,e[1],e[0]<<16|e[3]>>>16,e[2],e[1]<<16|e[0]>>>16,e[3],e[2]<<16|e[1]>>>16],n=this._C=[e[2]<<16|e[2]>>>16,4294901760&e[0]|65535&e[1],e[3]<<16|e[3]>>>16,4294901760&e[1]|65535&e[2],e[0]<<16|e[0]>>>16,4294901760&e[2]|65535&e[3],e[1]<<16|e[1]>>>16,4294901760&e[3]|65535&e[0]];this._b=0;for(var i=0;i<4;i++)u.call(this);for(i=0;i<8;i++)n[i]^=r[i+4&7];if(t){var o=t.words,a=o[0],s=o[1],c=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),l=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),f=c>>>16|4294901760&l,h=l<<16|65535&c;for(n[0]^=c,n[1]^=f,n[2]^=l,n[3]^=h,n[4]^=c,n[5]^=f,n[6]^=l,n[7]^=h,i=0;i<4;i++)u.call(this)}},_doProcessBlock:function(e,t){var r=this._X;u.call(this),i[0]=r[0]^r[5]>>>16^r[3]<<16,i[1]=r[2]^r[7]>>>16^r[5]<<16,i[2]=r[4]^r[1]>>>16^r[7]<<16,i[3]=r[6]^r[3]>>>16^r[1]<<16;for(var n=0;n<4;n++)i[n]=16711935&(i[n]<<8|i[n]>>>24)|4278255360&(i[n]<<24|i[n]>>>8),e[t+n]^=i[n]},blockSize:4,ivSize:2});function u(){for(var e=this._X,t=this._C,r=0;r<8;r++)o[r]=t[r];for(t[0]=t[0]+1295307597+this._b|0,t[1]=t[1]+3545052371+(t[0]>>>0>>0?1:0)|0,t[2]=t[2]+886263092+(t[1]>>>0>>0?1:0)|0,t[3]=t[3]+1295307597+(t[2]>>>0>>0?1:0)|0,t[4]=t[4]+3545052371+(t[3]>>>0>>0?1:0)|0,t[5]=t[5]+886263092+(t[4]>>>0>>0?1:0)|0,t[6]=t[6]+1295307597+(t[5]>>>0>>0?1:0)|0,t[7]=t[7]+3545052371+(t[6]>>>0>>0?1:0)|0,this._b=t[7]>>>0>>0?1:0,r=0;r<8;r++){var n=e[r]+t[r],i=65535&n,s=n>>>16,u=((i*i>>>17)+i*s>>>15)+s*s,c=((4294901760&n)*n|0)+((65535&n)*n|0);a[r]=u^c}e[0]=a[0]+(a[7]<<16|a[7]>>>16)+(a[6]<<16|a[6]>>>16)|0,e[1]=a[1]+(a[0]<<8|a[0]>>>24)+a[7]|0,e[2]=a[2]+(a[1]<<16|a[1]>>>16)+(a[0]<<16|a[0]>>>16)|0,e[3]=a[3]+(a[2]<<8|a[2]>>>24)+a[1]|0,e[4]=a[4]+(a[3]<<16|a[3]>>>16)+(a[2]<<16|a[2]>>>16)|0,e[5]=a[5]+(a[4]<<8|a[4]>>>24)+a[3]|0,e[6]=a[6]+(a[5]<<16|a[5]>>>16)+(a[4]<<16|a[4]>>>16)|0,e[7]=a[7]+(a[6]<<8|a[6]>>>24)+a[5]|0}e.RabbitLegacy=t._createHelper(s)}(),n.RabbitLegacy)},84454:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib.StreamCipher,r=e.algo,i=[],o=[],a=[],s=r.Rabbit=t.extend({_doReset:function(){for(var e=this._key.words,t=this.cfg.iv,r=0;r<4;r++)e[r]=16711935&(e[r]<<8|e[r]>>>24)|4278255360&(e[r]<<24|e[r]>>>8);var n=this._X=[e[0],e[3]<<16|e[2]>>>16,e[1],e[0]<<16|e[3]>>>16,e[2],e[1]<<16|e[0]>>>16,e[3],e[2]<<16|e[1]>>>16],i=this._C=[e[2]<<16|e[2]>>>16,4294901760&e[0]|65535&e[1],e[3]<<16|e[3]>>>16,4294901760&e[1]|65535&e[2],e[0]<<16|e[0]>>>16,4294901760&e[2]|65535&e[3],e[1]<<16|e[1]>>>16,4294901760&e[3]|65535&e[0]];for(this._b=0,r=0;r<4;r++)u.call(this);for(r=0;r<8;r++)i[r]^=n[r+4&7];if(t){var o=t.words,a=o[0],s=o[1],c=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),l=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),f=c>>>16|4294901760&l,h=l<<16|65535&c;for(i[0]^=c,i[1]^=f,i[2]^=l,i[3]^=h,i[4]^=c,i[5]^=f,i[6]^=l,i[7]^=h,r=0;r<4;r++)u.call(this)}},_doProcessBlock:function(e,t){var r=this._X;u.call(this),i[0]=r[0]^r[5]>>>16^r[3]<<16,i[1]=r[2]^r[7]>>>16^r[5]<<16,i[2]=r[4]^r[1]>>>16^r[7]<<16,i[3]=r[6]^r[3]>>>16^r[1]<<16;for(var n=0;n<4;n++)i[n]=16711935&(i[n]<<8|i[n]>>>24)|4278255360&(i[n]<<24|i[n]>>>8),e[t+n]^=i[n]},blockSize:4,ivSize:2});function u(){for(var e=this._X,t=this._C,r=0;r<8;r++)o[r]=t[r];for(t[0]=t[0]+1295307597+this._b|0,t[1]=t[1]+3545052371+(t[0]>>>0>>0?1:0)|0,t[2]=t[2]+886263092+(t[1]>>>0>>0?1:0)|0,t[3]=t[3]+1295307597+(t[2]>>>0>>0?1:0)|0,t[4]=t[4]+3545052371+(t[3]>>>0>>0?1:0)|0,t[5]=t[5]+886263092+(t[4]>>>0>>0?1:0)|0,t[6]=t[6]+1295307597+(t[5]>>>0>>0?1:0)|0,t[7]=t[7]+3545052371+(t[6]>>>0>>0?1:0)|0,this._b=t[7]>>>0>>0?1:0,r=0;r<8;r++){var n=e[r]+t[r],i=65535&n,s=n>>>16,u=((i*i>>>17)+i*s>>>15)+s*s,c=((4294901760&n)*n|0)+((65535&n)*n|0);a[r]=u^c}e[0]=a[0]+(a[7]<<16|a[7]>>>16)+(a[6]<<16|a[6]>>>16)|0,e[1]=a[1]+(a[0]<<8|a[0]>>>24)+a[7]|0,e[2]=a[2]+(a[1]<<16|a[1]>>>16)+(a[0]<<16|a[0]>>>16)|0,e[3]=a[3]+(a[2]<<8|a[2]>>>24)+a[1]|0,e[4]=a[4]+(a[3]<<16|a[3]>>>16)+(a[2]<<16|a[2]>>>16)|0,e[5]=a[5]+(a[4]<<8|a[4]>>>24)+a[3]|0,e[6]=a[6]+(a[5]<<16|a[5]>>>16)+(a[4]<<16|a[4]>>>16)|0,e[7]=a[7]+(a[6]<<8|a[6]>>>24)+a[5]|0}e.Rabbit=t._createHelper(s)}(),n.Rabbit)},51857:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib.StreamCipher,r=e.algo,i=r.RC4=t.extend({_doReset:function(){for(var e=this._key,t=e.words,r=e.sigBytes,n=this._S=[],i=0;i<256;i++)n[i]=i;i=0;for(var o=0;i<256;i++){var a=i%r,s=t[a>>>2]>>>24-a%4*8&255;o=(o+n[i]+s)%256;var u=n[i];n[i]=n[o],n[o]=u}this._i=this._j=0},_doProcessBlock:function(e,t){e[t]^=o.call(this)},keySize:8,ivSize:0});function o(){for(var e=this._S,t=this._i,r=this._j,n=0,i=0;i<4;i++){r=(r+e[t=(t+1)%256])%256;var o=e[t];e[t]=e[r],e[r]=o,n|=e[(e[t]+e[r])%256]<<24-8*i}return this._i=t,this._j=r,n}e.RC4=t._createHelper(i);var a=r.RC4Drop=i.extend({cfg:i.cfg.extend({drop:192}),_doReset:function(){i._doReset.call(this);for(var e=this.cfg.drop;e>0;e--)o.call(this)}});e.RC4Drop=t._createHelper(a)}(),n.RC4)},30706:function(e,t,r){var n;e.exports=(n=r(78249),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=i.create([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]),u=i.create([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]),c=i.create([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]),l=i.create([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]),f=i.create([0,1518500249,1859775393,2400959708,2840853838]),h=i.create([1352829926,1548603684,1836072691,2053994217,0]),d=a.RIPEMD160=o.extend({_doReset:function(){this._hash=i.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var r=0;r<16;r++){var n=t+r,i=e[n];e[n]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o,a,d,w,A,S,k,E,_,M,T,x=this._hash.words,P=f.words,I=h.words,O=s.words,R=u.words,C=c.words,B=l.words;for(S=o=x[0],k=a=x[1],E=d=x[2],_=w=x[3],M=A=x[4],r=0;r<80;r+=1)T=o+e[t+O[r]]|0,T+=r<16?p(a,d,w)+P[0]:r<32?m(a,d,w)+P[1]:r<48?y(a,d,w)+P[2]:r<64?g(a,d,w)+P[3]:b(a,d,w)+P[4],T=(T=v(T|=0,C[r]))+A|0,o=A,A=w,w=v(d,10),d=a,a=T,T=S+e[t+R[r]]|0,T+=r<16?b(k,E,_)+I[0]:r<32?g(k,E,_)+I[1]:r<48?y(k,E,_)+I[2]:r<64?m(k,E,_)+I[3]:p(k,E,_)+I[4],T=(T=v(T|=0,B[r]))+M|0,S=M,M=_,_=v(E,10),E=k,k=T;T=x[1]+d+_|0,x[1]=x[2]+w+M|0,x[2]=x[3]+A+S|0,x[3]=x[4]+o+k|0,x[4]=x[0]+a+E|0,x[0]=T},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;t[n>>>5]|=128<<24-n%32,t[14+(n+64>>>9<<4)]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8),e.sigBytes=4*(t.length+1),this._process();for(var i=this._hash,o=i.words,a=0;a<5;a++){var s=o[a];o[a]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8)}return i},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function p(e,t,r){return e^t^r}function m(e,t,r){return e&t|~e&r}function y(e,t,r){return(e|~t)^r}function g(e,t,r){return e&r|t&~r}function b(e,t,r){return e^(t|~r)}function v(e,t){return e<>>32-t}t.RIPEMD160=o._createHelper(d),t.HmacRIPEMD160=o._createHmacHelper(d)}(Math),n.RIPEMD160)},62783:function(e,t,r){var n,i,o,a,s,u,c,l;e.exports=(l=r(78249),i=(n=l).lib,o=i.WordArray,a=i.Hasher,s=n.algo,u=[],c=s.SHA1=a.extend({_doReset:function(){this._hash=new o.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],c=0;c<80;c++){if(c<16)u[c]=0|e[t+c];else{var l=u[c-3]^u[c-8]^u[c-14]^u[c-16];u[c]=l<<1|l>>>31}var f=(n<<5|n>>>27)+s+u[c];f+=c<20?1518500249+(i&o|~i&a):c<40?1859775393+(i^o^a):c<60?(i&o|i&a|o&a)-1894007588:(i^o^a)-899497514,s=a,a=o,o=i<<30|i>>>2,i=n,n=f}r[0]=r[0]+n|0,r[1]=r[1]+i|0,r[2]=r[2]+o|0,r[3]=r[3]+a|0,r[4]=r[4]+s|0},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;return t[n>>>5]|=128<<24-n%32,t[14+(n+64>>>9<<4)]=Math.floor(r/4294967296),t[15+(n+64>>>9<<4)]=r,e.sigBytes=4*t.length,this._process(),this._hash},clone:function(){var e=a.clone.call(this);return e._hash=this._hash.clone(),e}}),n.SHA1=a._createHelper(c),n.HmacSHA1=a._createHmacHelper(c),l.SHA1)},87792:function(e,t,r){var n,i,o,a,s,u;e.exports=(u=r(78249),r(52153),i=(n=u).lib.WordArray,o=n.algo,a=o.SHA256,s=o.SHA224=a.extend({_doReset:function(){this._hash=new i.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var e=a._doFinalize.call(this);return e.sigBytes-=4,e}}),n.SHA224=a._createHelper(s),n.HmacSHA224=a._createHmacHelper(s),u.SHA224)},52153:function(e,t,r){var n;e.exports=(n=r(78249),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=[],u=[];!function(){function t(t){for(var r=e.sqrt(t),n=2;n<=r;n++)if(!(t%n))return!1;return!0}function r(e){return 4294967296*(e-(0|e))|0}for(var n=2,i=0;i<64;)t(n)&&(i<8&&(s[i]=r(e.pow(n,.5))),u[i]=r(e.pow(n,1/3)),i++),n++}();var c=[],l=a.SHA256=o.extend({_doReset:function(){this._hash=new i.init(s.slice(0))},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],l=r[5],f=r[6],h=r[7],d=0;d<64;d++){if(d<16)c[d]=0|e[t+d];else{var p=c[d-15],m=(p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3,y=c[d-2],g=(y<<15|y>>>17)^(y<<13|y>>>19)^y>>>10;c[d]=m+c[d-7]+g+c[d-16]}var b=n&i^n&o^i&o,v=(n<<30|n>>>2)^(n<<19|n>>>13)^(n<<10|n>>>22),w=h+((s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25))+(s&l^~s&f)+u[d]+c[d];h=f,f=l,l=s,s=a+w|0,a=o,o=i,i=n,n=w+(v+b)|0}r[0]=r[0]+n|0,r[1]=r[1]+i|0,r[2]=r[2]+o|0,r[3]=r[3]+a|0,r[4]=r[4]+s|0,r[5]=r[5]+l|0,r[6]=r[6]+f|0,r[7]=r[7]+h|0},_doFinalize:function(){var t=this._data,r=t.words,n=8*this._nDataBytes,i=8*t.sigBytes;return r[i>>>5]|=128<<24-i%32,r[14+(i+64>>>9<<4)]=e.floor(n/4294967296),r[15+(i+64>>>9<<4)]=n,t.sigBytes=4*r.length,this._process(),this._hash},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=o._createHelper(l),t.HmacSHA256=o._createHmacHelper(l)}(Math),n.SHA256)},13327:function(e,t,r){var n;e.exports=(n=r(78249),r(64938),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.x64.Word,s=t.algo,u=[],c=[],l=[];!function(){for(var e=1,t=0,r=0;r<24;r++){u[e+5*t]=(r+1)*(r+2)/2%64;var n=(2*e+3*t)%5;e=t%5,t=n}for(e=0;e<5;e++)for(t=0;t<5;t++)c[e+5*t]=t+(2*e+3*t)%5*5;for(var i=1,o=0;o<24;o++){for(var s=0,f=0,h=0;h<7;h++){if(1&i){var d=(1<>>24)|4278255360&(o<<24|o>>>8),a=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),(x=r[i]).high^=a,x.low^=o}for(var s=0;s<24;s++){for(var h=0;h<5;h++){for(var d=0,p=0,m=0;m<5;m++)d^=(x=r[h+5*m]).high,p^=x.low;var y=f[h];y.high=d,y.low=p}for(h=0;h<5;h++){var g=f[(h+4)%5],b=f[(h+1)%5],v=b.high,w=b.low;for(d=g.high^(v<<1|w>>>31),p=g.low^(w<<1|v>>>31),m=0;m<5;m++)(x=r[h+5*m]).high^=d,x.low^=p}for(var A=1;A<25;A++){var S=(x=r[A]).high,k=x.low,E=u[A];E<32?(d=S<>>32-E,p=k<>>32-E):(d=k<>>64-E,p=S<>>64-E);var _=f[c[A]];_.high=d,_.low=p}var M=f[0],T=r[0];for(M.high=T.high,M.low=T.low,h=0;h<5;h++)for(m=0;m<5;m++){var x=r[A=h+5*m],P=f[A],I=f[(h+1)%5+5*m],O=f[(h+2)%5+5*m];x.high=P.high^~I.high&O.high,x.low=P.low^~I.low&O.low}x=r[0];var R=l[s];x.high^=R.high,x.low^=R.low}},_doFinalize:function(){var t=this._data,r=t.words,n=(this._nDataBytes,8*t.sigBytes),o=32*this.blockSize;r[n>>>5]|=1<<24-n%32,r[(e.ceil((n+1)/o)*o>>>5)-1]|=128,t.sigBytes=4*r.length,this._process();for(var a=this._state,s=this.cfg.outputLength/8,u=s/8,c=[],l=0;l>>24)|4278255360&(h<<24|h>>>8),d=16711935&(d<<8|d>>>24)|4278255360&(d<<24|d>>>8),c.push(d),c.push(h)}return new i.init(c,s)},clone:function(){for(var e=o.clone.call(this),t=e._state=this._state.slice(0),r=0;r<25;r++)t[r]=t[r].clone();return e}});t.SHA3=o._createHelper(h),t.HmacSHA3=o._createHmacHelper(h)}(Math),n.SHA3)},17460:function(e,t,r){var n,i,o,a,s,u,c,l;e.exports=(l=r(78249),r(64938),r(70034),i=(n=l).x64,o=i.Word,a=i.WordArray,s=n.algo,u=s.SHA512,c=s.SHA384=u.extend({_doReset:function(){this._hash=new a.init([new o.init(3418070365,3238371032),new o.init(1654270250,914150663),new o.init(2438529370,812702999),new o.init(355462360,4144912697),new o.init(1731405415,4290775857),new o.init(2394180231,1750603025),new o.init(3675008525,1694076839),new o.init(1203062813,3204075428)])},_doFinalize:function(){var e=u._doFinalize.call(this);return e.sigBytes-=16,e}}),n.SHA384=u._createHelper(c),n.HmacSHA384=u._createHmacHelper(c),l.SHA384)},70034:function(e,t,r){var n;e.exports=(n=r(78249),r(64938),function(){var e=n,t=e.lib.Hasher,r=e.x64,i=r.Word,o=r.WordArray,a=e.algo;function s(){return i.create.apply(i,arguments)}var u=[s(1116352408,3609767458),s(1899447441,602891725),s(3049323471,3964484399),s(3921009573,2173295548),s(961987163,4081628472),s(1508970993,3053834265),s(2453635748,2937671579),s(2870763221,3664609560),s(3624381080,2734883394),s(310598401,1164996542),s(607225278,1323610764),s(1426881987,3590304994),s(1925078388,4068182383),s(2162078206,991336113),s(2614888103,633803317),s(3248222580,3479774868),s(3835390401,2666613458),s(4022224774,944711139),s(264347078,2341262773),s(604807628,2007800933),s(770255983,1495990901),s(1249150122,1856431235),s(1555081692,3175218132),s(1996064986,2198950837),s(2554220882,3999719339),s(2821834349,766784016),s(2952996808,2566594879),s(3210313671,3203337956),s(3336571891,1034457026),s(3584528711,2466948901),s(113926993,3758326383),s(338241895,168717936),s(666307205,1188179964),s(773529912,1546045734),s(1294757372,1522805485),s(1396182291,2643833823),s(1695183700,2343527390),s(1986661051,1014477480),s(2177026350,1206759142),s(2456956037,344077627),s(2730485921,1290863460),s(2820302411,3158454273),s(3259730800,3505952657),s(3345764771,106217008),s(3516065817,3606008344),s(3600352804,1432725776),s(4094571909,1467031594),s(275423344,851169720),s(430227734,3100823752),s(506948616,1363258195),s(659060556,3750685593),s(883997877,3785050280),s(958139571,3318307427),s(1322822218,3812723403),s(1537002063,2003034995),s(1747873779,3602036899),s(1955562222,1575990012),s(2024104815,1125592928),s(2227730452,2716904306),s(2361852424,442776044),s(2428436474,593698344),s(2756734187,3733110249),s(3204031479,2999351573),s(3329325298,3815920427),s(3391569614,3928383900),s(3515267271,566280711),s(3940187606,3454069534),s(4118630271,4000239992),s(116418474,1914138554),s(174292421,2731055270),s(289380356,3203993006),s(460393269,320620315),s(685471733,587496836),s(852142971,1086792851),s(1017036298,365543100),s(1126000580,2618297676),s(1288033470,3409855158),s(1501505948,4234509866),s(1607167915,987167468),s(1816402316,1246189591)],c=[];!function(){for(var e=0;e<80;e++)c[e]=s()}();var l=a.SHA512=t.extend({_doReset:function(){this._hash=new o.init([new i.init(1779033703,4089235720),new i.init(3144134277,2227873595),new i.init(1013904242,4271175723),new i.init(2773480762,1595750129),new i.init(1359893119,2917565137),new i.init(2600822924,725511199),new i.init(528734635,4215389547),new i.init(1541459225,327033209)])},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],l=r[5],f=r[6],h=r[7],d=n.high,p=n.low,m=i.high,y=i.low,g=o.high,b=o.low,v=a.high,w=a.low,A=s.high,S=s.low,k=l.high,E=l.low,_=f.high,M=f.low,T=h.high,x=h.low,P=d,I=p,O=m,R=y,C=g,B=b,N=v,L=w,U=A,F=S,D=k,j=E,H=_,J=M,z=T,G=x,q=0;q<80;q++){var K=c[q];if(q<16)var V=K.high=0|e[t+2*q],X=K.low=0|e[t+2*q+1];else{var Q=c[q-15],W=Q.high,Z=Q.low,Y=(W>>>1|Z<<31)^(W>>>8|Z<<24)^W>>>7,$=(Z>>>1|W<<31)^(Z>>>8|W<<24)^(Z>>>7|W<<25),ee=c[q-2],te=ee.high,re=ee.low,ne=(te>>>19|re<<13)^(te<<3|re>>>29)^te>>>6,ie=(re>>>19|te<<13)^(re<<3|te>>>29)^(re>>>6|te<<26),oe=c[q-7],ae=oe.high,se=oe.low,ue=c[q-16],ce=ue.high,le=ue.low;V=(V=(V=Y+ae+((X=$+se)>>>0<$>>>0?1:0))+ne+((X+=ie)>>>0>>0?1:0))+ce+((X+=le)>>>0>>0?1:0),K.high=V,K.low=X}var fe,he=U&D^~U&H,de=F&j^~F&J,pe=P&O^P&C^O&C,me=I&R^I&B^R&B,ye=(P>>>28|I<<4)^(P<<30|I>>>2)^(P<<25|I>>>7),ge=(I>>>28|P<<4)^(I<<30|P>>>2)^(I<<25|P>>>7),be=(U>>>14|F<<18)^(U>>>18|F<<14)^(U<<23|F>>>9),ve=(F>>>14|U<<18)^(F>>>18|U<<14)^(F<<23|U>>>9),we=u[q],Ae=we.high,Se=we.low,ke=z+be+((fe=G+ve)>>>0>>0?1:0),Ee=ge+me;z=H,G=J,H=D,J=j,D=U,j=F,U=N+(ke=(ke=(ke=ke+he+((fe+=de)>>>0>>0?1:0))+Ae+((fe+=Se)>>>0>>0?1:0))+V+((fe+=X)>>>0>>0?1:0))+((F=L+fe|0)>>>0>>0?1:0)|0,N=C,L=B,C=O,B=R,O=P,R=I,P=ke+(ye+pe+(Ee>>>0>>0?1:0))+((I=fe+Ee|0)>>>0>>0?1:0)|0}p=n.low=p+I,n.high=d+P+(p>>>0>>0?1:0),y=i.low=y+R,i.high=m+O+(y>>>0>>0?1:0),b=o.low=b+B,o.high=g+C+(b>>>0>>0?1:0),w=a.low=w+L,a.high=v+N+(w>>>0>>0?1:0),S=s.low=S+F,s.high=A+U+(S>>>0>>0?1:0),E=l.low=E+j,l.high=k+D+(E>>>0>>0?1:0),M=f.low=M+J,f.high=_+H+(M>>>0>>0?1:0),x=h.low=x+G,h.high=T+z+(x>>>0>>0?1:0)},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;return t[n>>>5]|=128<<24-n%32,t[30+(n+128>>>10<<5)]=Math.floor(r/4294967296),t[31+(n+128>>>10<<5)]=r,e.sigBytes=4*t.length,this._process(),this._hash.toX32()},clone:function(){var e=t.clone.call(this);return e._hash=this._hash.clone(),e},blockSize:32});e.SHA512=t._createHelper(l),e.HmacSHA512=t._createHmacHelper(l)}(),n.SHA512)},94253:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib,r=t.WordArray,i=t.BlockCipher,o=e.algo,a=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],s=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],u=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],c=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],l=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],f=o.DES=i.extend({_doReset:function(){for(var e=this._key.words,t=[],r=0;r<56;r++){var n=a[r]-1;t[r]=e[n>>>5]>>>31-n%32&1}for(var i=this._subKeys=[],o=0;o<16;o++){var c=i[o]=[],l=u[o];for(r=0;r<24;r++)c[r/6|0]|=t[(s[r]-1+l)%28]<<31-r%6,c[4+(r/6|0)]|=t[28+(s[r+24]-1+l)%28]<<31-r%6;for(c[0]=c[0]<<1|c[0]>>>31,r=1;r<7;r++)c[r]=c[r]>>>4*(r-1)+3;c[7]=c[7]<<5|c[7]>>>27}var f=this._invSubKeys=[];for(r=0;r<16;r++)f[r]=i[15-r]},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._subKeys)},decryptBlock:function(e,t){this._doCryptBlock(e,t,this._invSubKeys)},_doCryptBlock:function(e,t,r){this._lBlock=e[t],this._rBlock=e[t+1],h.call(this,4,252645135),h.call(this,16,65535),d.call(this,2,858993459),d.call(this,8,16711935),h.call(this,1,1431655765);for(var n=0;n<16;n++){for(var i=r[n],o=this._lBlock,a=this._rBlock,s=0,u=0;u<8;u++)s|=c[u][((a^i[u])&l[u])>>>0];this._lBlock=a,this._rBlock=o^s}var f=this._lBlock;this._lBlock=this._rBlock,this._rBlock=f,h.call(this,1,1431655765),d.call(this,8,16711935),d.call(this,2,858993459),h.call(this,16,65535),h.call(this,4,252645135),e[t]=this._lBlock,e[t+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});function h(e,t){var r=(this._lBlock>>>e^this._rBlock)&t;this._rBlock^=r,this._lBlock^=r<>>e^this._lBlock)&t;this._lBlock^=r,this._rBlock^=r<{"use strict";t.utils=r(11278),t.Cipher=r(55756),t.DES=r(70778),t.CBC=r(39051),t.EDE=r(50651)},39051:(e,t,r)=>{"use strict";var n=r(79746),i=r(35717),o={};function a(e){n.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t{"use strict";var n=r(79746);function i(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}e.exports=i,i.prototype._init=function(){},i.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},i.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n0;n--)t+=this._buffer(e,t),r+=this._flushBuffer(i,r);return t+=this._buffer(e,t),i},i.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},i.prototype._pad=function(e,t){if(0===t)return!1;for(;t{"use strict";var n=r(79746),i=r(35717),o=r(11278),a=r(55756);function s(){this.tmp=new Array(2),this.keys=null}function u(e){a.call(this,e);var t=new s;this._desState=t,this.deriveKeys(t,e.key)}i(u,a),e.exports=u,u.create=function(e){return new u(e)};var c=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];u.prototype.deriveKeys=function(e,t){e.keys=new Array(32),n.equal(t.length,this.blockSize,"Invalid key length");var r=o.readUInt32BE(t,0),i=o.readUInt32BE(t,4);o.pc1(r,i,e.tmp,0),r=e.tmp[0],i=e.tmp[1];for(var a=0;a>>1];r=o.r28shl(r,s),i=o.r28shl(i,s),o.pc2(r,i,e.keys,a)}},u.prototype._update=function(e,t,r,n){var i=this._desState,a=o.readUInt32BE(e,t),s=o.readUInt32BE(e,t+4);o.ip(a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],"encrypt"===this.type?this._encrypt(i,a,s,i.tmp,0):this._decrypt(i,a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],o.writeUInt32BE(r,a,n),o.writeUInt32BE(r,s,n+4)},u.prototype._pad=function(e,t){for(var r=e.length-t,n=t;n>>0,a=h}o.rip(s,a,n,i)},u.prototype._decrypt=function(e,t,r,n,i){for(var a=r,s=t,u=e.keys.length-2;u>=0;u-=2){var c=e.keys[u],l=e.keys[u+1];o.expand(a,e.tmp,0),c^=e.tmp[0],l^=e.tmp[1];var f=o.substitute(c,l),h=a;a=(s^o.permute(f))>>>0,s=h}o.rip(a,s,n,i)}},50651:(e,t,r)=>{"use strict";var n=r(79746),i=r(35717),o=r(55756),a=r(70778);function s(e,t){n.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),i=t.slice(8,16),o=t.slice(16,24);this.ciphers="encrypt"===e?[a.create({type:"encrypt",key:r}),a.create({type:"decrypt",key:i}),a.create({type:"encrypt",key:o})]:[a.create({type:"decrypt",key:o}),a.create({type:"encrypt",key:i}),a.create({type:"decrypt",key:r})]}function u(e){o.call(this,e);var t=new s(this.type,this.options.key);this._edeState=t}i(u,o),e.exports=u,u.create=function(e){return new u(e)},u.prototype._update=function(e,t,r,n){var i=this._edeState;i.ciphers[0]._update(e,t,r,n),i.ciphers[1]._update(r,n,r,n),i.ciphers[2]._update(r,n,r,n)},u.prototype._pad=a.prototype._pad,u.prototype._unpad=a.prototype._unpad},11278:(e,t)=>{"use strict";t.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},t.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},t.ip=function(e,t,r,n){for(var i=0,o=0,a=6;a>=0;a-=2){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>>s+a&1}for(a=6;a>=0;a-=2){for(s=1;s<=25;s+=8)o<<=1,o|=t>>>s+a&1;for(s=1;s<=25;s+=8)o<<=1,o|=e>>>s+a&1}r[n+0]=i>>>0,r[n+1]=o>>>0},t.rip=function(e,t,r,n){for(var i=0,o=0,a=0;a<4;a++)for(var s=24;s>=0;s-=8)i<<=1,i|=t>>>s+a&1,i<<=1,i|=e>>>s+a&1;for(a=4;a<8;a++)for(s=24;s>=0;s-=8)o<<=1,o|=t>>>s+a&1,o<<=1,o|=e>>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.pc1=function(e,t,r,n){for(var i=0,o=0,a=7;a>=5;a--){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>s+a&1}for(s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(a=1;a<=3;a++){for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1;for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1}for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.r28shl=function(e,t){return e<>>28-t};var r=[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];t.pc2=function(e,t,n,i){for(var o=0,a=0,s=r.length>>>1,u=0;u>>r[u]&1;for(u=s;u>>r[u]&1;n[i+0]=o>>>0,n[i+1]=a>>>0},t.expand=function(e,t,r){var n=0,i=0;n=(1&e)<<5|e>>>27;for(var o=23;o>=15;o-=4)n<<=6,n|=e>>>o&63;for(o=11;o>=3;o-=4)i|=e>>>o&63,i<<=6;i|=(31&e)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=i>>>0};var n=[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];t.substitute=function(e,t){for(var r=0,i=0;i<4;i++){r<<=4,r|=n[64*i+(e>>>18-6*i&63)]}for(i=0;i<4;i++){r<<=4,r|=n[256+64*i+(t>>>18-6*i&63)]}return r>>>0};var i=[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];t.permute=function(e){for(var t=0,r=0;r>>i[r]&1;return t>>>0},t.padSplit=function(e,t,r){for(var n=e.toString(2);n.length{var n=r(48764).Buffer,i=r(43590),o=r(29799),a=r(57426);var s={binary:!0,hex:!0,base64:!0};t.DiffieHellmanGroup=t.createDiffieHellmanGroup=t.getDiffieHellman=function(e){var t=new n(o[e].prime,"hex"),r=new n(o[e].gen,"hex");return new a(t,r)},t.createDiffieHellman=t.DiffieHellman=function e(t,r,o,u){return n.isBuffer(r)||void 0===s[r]?e(t,"binary",r,o):(r=r||"binary",u=u||"binary",o=o||new n([2]),n.isBuffer(o)||(o=new n(o,u)),"number"==typeof t?new a(i(t,o),o,!0):(n.isBuffer(t)||(t=new n(t,r)),new a(t,o,!0)))}},57426:(e,t,r)=>{var n=r(48764).Buffer,i=r(83620),o=new(r(63047)),a=new i(24),s=new i(11),u=new i(10),c=new i(3),l=new i(7),f=r(43590),h=r(61798);function d(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._pub=new i(e),this}function p(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._priv=new i(e),this}e.exports=y;var m={};function y(e,t,r){this.setGenerator(t),this.__prime=new i(e),this._prime=i.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=d,this.setPrivateKey=p):this._primeCode=8}function g(e,t){var r=new n(e.toArray());return t?r.toString(t):r}Object.defineProperty(y.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),n=[r,e.toString(16)].join("_");if(n in m)return m[n];var i,h=0;if(e.isEven()||!f.simpleSieve||!f.fermatTest(e)||!o.test(e))return h+=1,h+="02"===r||"05"===r?8:4,m[n]=h,h;switch(o.test(e.shrn(1))||(h+=2),r){case"02":e.mod(a).cmp(s)&&(h+=8);break;case"05":(i=e.mod(u)).cmp(c)&&i.cmp(l)&&(h+=8);break;default:h+=4}return m[n]=h,h}(this.__prime,this.__gen)),this._primeCode}}),y.prototype.generateKeys=function(){return this._priv||(this._priv=new i(h(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},y.prototype.computeSecret=function(e){var t=(e=(e=new i(e)).toRed(this._prime)).redPow(this._priv).fromRed(),r=new n(t.toArray()),o=this.getPrime();if(r.length{var n=r(61798);e.exports=b,b.simpleSieve=y,b.fermatTest=g;var i=r(83620),o=new i(24),a=new(r(63047)),s=new i(1),u=new i(2),c=new i(5),l=(new i(16),new i(8),new i(10)),f=new i(3),h=(new i(7),new i(11)),d=new i(4),p=(new i(12),null);function m(){if(null!==p)return p;var e=[];e[0]=2;for(var t=1,r=3;r<1048576;r+=2){for(var n=Math.ceil(Math.sqrt(r)),i=0;ie;)r.ishrn(1);if(r.isEven()&&r.iadd(s),r.testn(1)||r.iadd(u),t.cmp(u)){if(!t.cmp(c))for(;r.mod(l).cmp(f);)r.iadd(d)}else for(;r.mod(o).cmp(h);)r.iadd(d);if(y(p=r.shrn(1))&&y(r)&&g(p)&&g(r)&&a.test(p)&&a.test(r))return r}}},83620:function(e,t,r){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(7748).Buffer}catch(e){}function s(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},86266:(e,t,r)=>{"use strict";var n=t;n.version=r(18597).i8,n.utils=r(80953),n.rand=r(29931),n.curve=r(88254),n.curves=r(45427),n.ec=r(57954),n.eddsa=r(65980)},4918:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953),o=i.getNAF,a=i.getJSF,s=i.assert;function u(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function c(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=u,u.prototype.point=function(){throw new Error("Not implemented")},u.prototype.validate=function(){throw new Error("Not implemented")},u.prototype._fixedNafMul=function(e,t){s(e.precomputed);var r=e._getDoubles(),n=o(t,1,this._bitLength),i=(1<=a;l--)u=(u<<1)+n[l];c.push(u)}for(var f=this.jpoint(null,null,null),h=this.jpoint(null,null,null),d=i;d>0;d--){for(a=0;a=0;c--){for(var l=0;c>=0&&0===a[c];c--)l++;if(c>=0&&l++,u=u.dblp(l),c<0)break;var f=a[c];s(0!==f),u="affine"===e.type?f>0?u.mixedAdd(i[f-1>>1]):u.mixedAdd(i[-f-1>>1].neg()):f>0?u.add(i[f-1>>1]):u.add(i[-f-1>>1].neg())}return"affine"===e.type?u.toP():u},u.prototype._wnafMulAdd=function(e,t,r,n,i){var s,u,c,l=this._wnafT1,f=this._wnafT2,h=this._wnafT3,d=0;for(s=0;s=1;s-=2){var m=s-1,y=s;if(1===l[m]&&1===l[y]){var g=[t[m],null,null,t[y]];0===t[m].y.cmp(t[y].y)?(g[1]=t[m].add(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg())):0===t[m].y.cmp(t[y].y.redNeg())?(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].add(t[y].neg())):(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg()));var b=[-3,-1,-5,-7,0,7,5,1,3],v=a(r[m],r[y]);for(d=Math.max(v[0].length,d),h[m]=new Array(d),h[y]=new Array(d),u=0;u=0;s--){for(var E=0;s>=0;){var _=!0;for(u=0;u=0&&E++,S=S.dblp(E),s<0)break;for(u=0;u0?c=f[u][M-1>>1]:M<0&&(c=f[u][-M-1>>1].neg()),S="affine"===c.type?S.mixedAdd(c):S.add(c))}}for(s=0;s=Math.ceil((e.bitLength()+1)/t.step)},c.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i{"use strict";var n=r(80953),i=r(73785),o=r(35717),a=r(4918),s=n.assert;function u(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,a.call(this,"edwards",e),this.a=new i(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new i(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new i(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function c(e,t,r,n,o){a.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===n?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new i(t,16),this.y=new i(r,16),this.z=n?new i(n,16):this.curve.one,this.t=o&&new i(o,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}o(u,a),e.exports=u,u.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},u.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},u.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=n.redMul(o.redInvm()),s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");var u=s.fromRed().isOdd();return(t&&!u||!t&&u)&&(s=s.redNeg()),this.point(e,s)},u.prototype.pointFromY=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=n.redMul(o.redInvm());if(0===a.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");return s.fromRed().isOdd()!==t&&(s=s.redNeg()),this.point(s,e)},u.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===n.cmp(i)},o(c,a.BasePoint),u.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},u.prototype.point=function(e,t,r,n){return new c(this,e,t,r,n)},c.fromJSON=function(e,t){return new c(e,t[0],t[1],t[2])},c.prototype.inspect=function(){return this.isInfinity()?"":""},c.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},c.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),o=n.redAdd(t),a=o.redSub(r),s=n.redSub(t),u=i.redMul(a),c=o.redMul(s),l=i.redMul(s),f=a.redMul(o);return this.curve.point(u,c,f,l)},c.prototype._projDbl=function(){var e,t,r,n,i,o,a=this.x.redAdd(this.y).redSqr(),s=this.x.redSqr(),u=this.y.redSqr();if(this.curve.twisted){var c=(n=this.curve._mulA(s)).redAdd(u);this.zOne?(e=a.redSub(s).redSub(u).redMul(c.redSub(this.curve.two)),t=c.redMul(n.redSub(u)),r=c.redSqr().redSub(c).redSub(c)):(i=this.z.redSqr(),o=c.redSub(i).redISub(i),e=a.redSub(s).redISub(u).redMul(o),t=c.redMul(n.redSub(u)),r=c.redMul(o))}else n=s.redAdd(u),i=this.curve._mulC(this.z).redSqr(),o=n.redSub(i).redSub(i),e=this.curve._mulC(a.redISub(n)).redMul(o),t=this.curve._mulC(n).redMul(s.redISub(u)),r=n.redMul(o);return this.curve.point(e,t,r)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},c.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),o=r.redSub(t),a=i.redSub(n),s=i.redAdd(n),u=r.redAdd(t),c=o.redMul(a),l=s.redMul(u),f=o.redMul(u),h=a.redMul(s);return this.curve.point(c,l,h,f)},c.prototype._projAdd=function(e){var t,r,n=this.z.redMul(e.z),i=n.redSqr(),o=this.x.redMul(e.x),a=this.y.redMul(e.y),s=this.curve.d.redMul(o).redMul(a),u=i.redSub(s),c=i.redAdd(s),l=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(o).redISub(a),f=n.redMul(u).redMul(l);return this.curve.twisted?(t=n.redMul(c).redMul(a.redSub(this.curve._mulA(o))),r=u.redMul(c)):(t=n.redMul(c).redMul(a.redSub(o)),r=this.curve._mulC(u).redMul(c)),this.curve.point(f,t,r)},c.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},c.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},c.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},c.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},c.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()},c.prototype.getY=function(){return this.normalize(),this.y.fromRed()},c.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},c.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(n),0===this.x.cmp(t))return!0}},c.prototype.toP=c.prototype.normalize,c.prototype.mixedAdd=c.prototype.add},88254:(e,t,r)=>{"use strict";var n=t;n.base=r(4918),n.short=r(6673),n.mont=r(22881),n.edwards=r(31138)},22881:(e,t,r)=>{"use strict";var n=r(73785),i=r(35717),o=r(4918),a=r(80953);function s(e){o.call(this,"mont",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.i4=new n(4).toRed(this.red).redInvm(),this.two=new n(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function u(e,t,r){o.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new n(t,16),this.z=new n(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}i(s,o),e.exports=s,s.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===n.redSqrt().redSqr().cmp(n)},i(u,o.BasePoint),s.prototype.decodePoint=function(e,t){return this.point(a.toArray(e,t),1)},s.prototype.point=function(e,t){return new u(this,e,t)},s.prototype.pointFromJSON=function(e){return u.fromJSON(this,e)},u.prototype.precompute=function(){},u.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},u.fromJSON=function(e,t){return new u(e,t[0],t[1]||e.one)},u.prototype.inspect=function(){return this.isInfinity()?"":""},u.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},u.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),n=e.redMul(t),i=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(n,i)},u.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),o=e.x.redSub(e.z).redMul(r),a=i.redMul(n),s=t.z.redMul(o.redAdd(a).redSqr()),u=t.x.redMul(o.redISub(a).redSqr());return this.curve.point(s,u)},u.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=[];0!==t.cmpn(0);t.iushrn(1))i.push(t.andln(1));for(var o=i.length-1;o>=0;o--)0===i[o]?(r=r.diffAdd(n,this),n=n.dbl()):(n=r.diffAdd(n,this),r=r.dbl());return n},u.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},u.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},u.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},6673:(e,t,r)=>{"use strict";var n=r(80953),i=r(73785),o=r(35717),a=r(4918),s=n.assert;function u(e){a.call(this,"short",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.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(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function c(e,t,r,n){a.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new i(t,16),this.y=new i(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function l(e,t,r,n){a.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new i(0)):(this.x=new i(t,16),this.y=new i(r,16),this.z=new i(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}o(u,a),e.exports=u,u.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new i(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new i(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],s(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new i(e.a,16),b:new i(e.b,16)}})):this._getEndoBasis(r)}}},u.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:i.mont(e),r=new i(2).toRed(t).redInvm(),n=r.redNeg(),o=new i(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(o).fromRed(),n.redSub(o).fromRed()]},u.prototype._getEndoBasis=function(e){for(var t,r,n,o,a,s,u,c,l,f=this.n.ushrn(Math.floor(this.n.bitLength()/2)),h=e,d=this.n.clone(),p=new i(1),m=new i(0),y=new i(0),g=new i(1),b=0;0!==h.cmpn(0);){var v=d.div(h);c=d.sub(v.mul(h)),l=y.sub(v.mul(p));var w=g.sub(v.mul(m));if(!n&&c.cmp(f)<0)t=u.neg(),r=p,n=c.neg(),o=l;else if(n&&2==++b)break;u=c,d=h,h=c,y=p,p=l,g=m,m=w}a=c.neg(),s=l;var A=n.sqr().add(o.sqr());return a.sqr().add(s.sqr()).cmp(A)>=0&&(a=t,s=r),n.negative&&(n=n.neg(),o=o.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:n,b:o},{a,b:s}]},u.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=n.fromRed().isOdd();return(t&&!o||!t&&o)&&(n=n.redNeg()),this.point(e,n)},u.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},u.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},c.prototype.isInfinity=function(){return this.inf},c.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},c.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},c.prototype.getX=function(){return this.x.fromRed()},c.prototype.getY=function(){return this.y.fromRed()},c.prototype.mul=function(e){return e=new i(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},c.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},c.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},c.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},c.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(l,a.BasePoint),u.prototype.jpoint=function(e,t,r){return new l(this,e,t,r)},l.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},l.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},l.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},l.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},l.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},l.prototype.inspect=function(){return this.isInfinity()?"":""},l.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},45427:(e,t,r)=>{"use strict";var n,i=t,o=r(33715),a=r(88254),s=r(80953).assert;function u(e){"short"===e.type?this.curve=new a.short(e):"edwards"===e.type?this.curve=new a.edwards(e):this.curve=new a.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,s(this.g.validate(),"Invalid curve"),s(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(i,e,{configurable:!0,enumerable:!0,get:function(){var r=new u(t);return Object.defineProperty(i,e,{configurable:!0,enumerable:!0,value:r}),r}})}i.PresetCurve=u,c("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:o.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("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:o.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("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:o.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("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:o.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"]}),c("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:o.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"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["9"]}),c("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:o.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{n=r(91037)}catch(e){n=void 0}c("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:o.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",n]})},57954:(e,t,r)=>{"use strict";var n=r(73785),i=r(2156),o=r(80953),a=r(45427),s=r(29931),u=o.assert,c=r(31251),l=r(90611);function f(e){if(!(this instanceof f))return new f(e);"string"==typeof e&&(u(Object.prototype.hasOwnProperty.call(a,e),"Unknown curve "+e),e=a[e]),e instanceof a.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=f,f.prototype.keyPair=function(e){return new c(this,e)},f.prototype.keyFromPrivate=function(e,t){return c.fromPrivate(this,e,t)},f.prototype.keyFromPublic=function(e,t){return c.fromPublic(this,e,t)},f.prototype.genKeyPair=function(e){e||(e={});for(var t=new i({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||s(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),o=this.n.sub(new n(2));;){var a=new n(t.generate(r));if(!(a.cmp(o)>0))return a.iaddn(1),this.keyFromPrivate(a)}},f.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},f.prototype.sign=function(e,t,r,o){"object"==typeof r&&(o=r,r=null),o||(o={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new n(e,16));for(var a=this.n.byteLength(),s=t.getPrivate().toArray("be",a),u=e.toArray("be",a),c=new i({hash:this.hash,entropy:s,nonce:u,pers:o.pers,persEnc:o.persEnc||"utf8"}),f=this.n.sub(new n(1)),h=0;;h++){var d=o.k?o.k(h):new n(c.generate(this.n.byteLength()));if(!((d=this._truncateToN(d,!0)).cmpn(1)<=0||d.cmp(f)>=0)){var p=this.g.mul(d);if(!p.isInfinity()){var m=p.getX(),y=m.umod(this.n);if(0!==y.cmpn(0)){var g=d.invm(this.n).mul(y.mul(t.getPrivate()).iadd(e));if(0!==(g=g.umod(this.n)).cmpn(0)){var b=(p.getY().isOdd()?1:0)|(0!==m.cmp(y)?2:0);return o.canonical&&g.cmp(this.nh)>0&&(g=this.n.sub(g),b^=1),new l({r:y,s:g,recoveryParam:b})}}}}}},f.prototype.verify=function(e,t,r,i){e=this._truncateToN(new n(e,16)),r=this.keyFromPublic(r,i);var o=(t=new l(t,"hex")).r,a=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),c=u.mul(e).umod(this.n),f=u.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(c,r.getPublic(),f)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(c,r.getPublic(),f)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},f.prototype.recoverPubKey=function(e,t,r,i){u((3&r)===r,"The recovery param is more than two bits"),t=new l(t,i);var o=this.n,a=new n(e),s=t.r,c=t.s,f=1&r,h=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&h)throw new Error("Unable to find sencond key candinate");s=h?this.curve.pointFromX(s.add(this.curve.n),f):this.curve.pointFromX(s,f);var d=t.r.invm(o),p=o.sub(a).mul(d).umod(o),m=c.mul(d).umod(o);return this.g.mulAdd(p,s,m)},f.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new l(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")}},31251:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953).assert;function o(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=o,o.fromPublic=function(e,t,r){return t instanceof o?t:new o(e,{pub:t,pubEnc:r})},o.fromPrivate=function(e,t,r){return t instanceof o?t:new o(e,{priv:t,privEnc:r})},o.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.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"}},o.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},o.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},o.prototype._importPrivate=function(e,t){this.priv=new n(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},o.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?i(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||i(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},o.prototype.derive=function(e){return e.validate()||i(e.validate(),"public point not validated"),e.mul(this.priv).getX()},o.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},o.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},o.prototype.inspect=function(){return""}},90611:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953),o=i.assert;function a(e,t){if(e instanceof a)return e;this._importDER(e,t)||(o(e.r&&e.s,"Signature without r or s"),this.r=new n(e.r,16),this.s=new n(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function s(){this.place=0}function u(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function c(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}e.exports=a,a.prototype._importDER=function(e,t){e=i.toArray(e,t);var r=new s;if(48!==e[r.place++])return!1;var o=u(e,r);if(!1===o)return!1;if(o+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var a=u(e,r);if(!1===a)return!1;var c=e.slice(r.place,a+r.place);if(r.place+=a,2!==e[r.place++])return!1;var l=u(e,r);if(!1===l)return!1;if(e.length!==l+r.place)return!1;var f=e.slice(r.place,l+r.place);if(0===c[0]){if(!(128&c[1]))return!1;c=c.slice(1)}if(0===f[0]){if(!(128&f[1]))return!1;f=f.slice(1)}return this.r=new n(c),this.s=new n(f),this.recoveryParam=null,!0},a.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=c(t),r=c(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];l(n,t.length),(n=n.concat(t)).push(2),l(n,r.length);var o=n.concat(r),a=[48];return l(a,o.length),a=a.concat(o),i.encode(a,e)}},65980:(e,t,r)=>{"use strict";var n=r(33715),i=r(45427),o=r(80953),a=o.assert,s=o.parseBytes,u=r(79087),c=r(23622);function l(e){if(a("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof l))return new l(e);e=i[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=n.sha512}e.exports=l,l.prototype.sign=function(e,t){e=s(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),o=this.encodePoint(i),a=this.hashInt(o,r.pubBytes(),e).mul(r.priv()),u=n.add(a).umod(this.curve.n);return this.makeSignature({R:i,S:u,Rencoded:o})},l.prototype.verify=function(e,t,r){e=s(e),t=this.makeSignature(t);var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),o=this.g.mul(t.S());return t.R().add(n.pub().mul(i)).eq(o)},l.prototype.hashInt=function(){for(var e=this.hash(),t=0;t{"use strict";var n=r(80953),i=n.assert,o=n.parseBytes,a=n.cachedProperty;function s(e,t){this.eddsa=e,this._secret=o(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=o(t.pub)}s.fromPublic=function(e,t){return t instanceof s?t:new s(e,{pub:t})},s.fromSecret=function(e,t){return t instanceof s?t:new s(e,{secret:t})},s.prototype.secret=function(){return this._secret},a(s,"pubBytes",(function(){return this.eddsa.encodePoint(this.pub())})),a(s,"pub",(function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())})),a(s,"privBytes",(function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n})),a(s,"priv",(function(){return this.eddsa.decodeInt(this.privBytes())})),a(s,"hash",(function(){return this.eddsa.hash().update(this.secret()).digest()})),a(s,"messagePrefix",(function(){return this.hash().slice(this.eddsa.encodingLength)})),s.prototype.sign=function(e){return i(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},s.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},s.prototype.getSecret=function(e){return i(this._secret,"KeyPair is public only"),n.encode(this.secret(),e)},s.prototype.getPublic=function(e){return n.encode(this.pubBytes(),e)},e.exports=s},23622:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953),o=i.assert,a=i.cachedProperty,s=i.parseBytes;function u(e,t){this.eddsa=e,"object"!=typeof t&&(t=s(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),o(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof n&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}a(u,"S",(function(){return this.eddsa.decodeInt(this.Sencoded())})),a(u,"R",(function(){return this.eddsa.decodePoint(this.Rencoded())})),a(u,"Rencoded",(function(){return this.eddsa.encodePoint(this.R())})),a(u,"Sencoded",(function(){return this.eddsa.encodeInt(this.S())})),u.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},u.prototype.toHex=function(){return i.encode(this.toBytes(),"hex").toUpperCase()},e.exports=u},91037:e=>{e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},80953:(e,t,r)=>{"use strict";var n=t,i=r(73785),o=r(79746),a=r(34504);n.assert=o,n.toArray=a.toArray,n.zero2=a.zero2,n.toHex=a.toHex,n.encode=a.encode,n.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!==(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!==(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"==typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new i(e,"hex","le")}},73785:function(e,t,r){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(85568).Buffer}catch(e){}function s(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},10639:(e,t,r)=>{"use strict";const n=r(97912);n.createWebSocketStream=r(73899),n.Server=r(25504),n.Receiver=r(75853),n.Sender=r(80877),n.WebSocket=n,n.WebSocketServer=n.Server,e.exports=n},65966:(e,t,r)=>{"use strict";var n=r(48764).Buffer;const{EMPTY_BUFFER:i}=r(62638);function o(e,t){if(0===e.length)return i;if(1===e.length)return e[0];const r=n.allocUnsafe(t);let o=0;for(let t=0;t{"use strict";var n=r(48764).Buffer;e.exports={BINARY_TYPES:["nodebuffer","arraybuffer","fragments"],EMPTY_BUFFER:n.alloc(0),GUID:"258EAFA5-E914-47DA-95CA-C5AB0DC85B11",kForOnEventAttribute:Symbol("kIsForOnEventAttribute"),kListener:Symbol("kListener"),kStatusCode:Symbol("status-code"),kWebSocket:Symbol("websocket"),NOOP:()=>{}}},27086:(e,t,r)=>{"use strict";const{kForOnEventAttribute:n,kListener:i}=r(62638),o=Symbol("kCode"),a=Symbol("kData"),s=Symbol("kError"),u=Symbol("kMessage"),c=Symbol("kReason"),l=Symbol("kTarget"),f=Symbol("kType"),h=Symbol("kWasClean");class d{constructor(e){this[l]=null,this[f]=e}get target(){return this[l]}get type(){return this[f]}}Object.defineProperty(d.prototype,"target",{enumerable:!0}),Object.defineProperty(d.prototype,"type",{enumerable:!0});class p extends d{constructor(e,t={}){super(e),this[o]=void 0===t.code?0:t.code,this[c]=void 0===t.reason?"":t.reason,this[h]=void 0!==t.wasClean&&t.wasClean}get code(){return this[o]}get reason(){return this[c]}get wasClean(){return this[h]}}Object.defineProperty(p.prototype,"code",{enumerable:!0}),Object.defineProperty(p.prototype,"reason",{enumerable:!0}),Object.defineProperty(p.prototype,"wasClean",{enumerable:!0});class m extends d{constructor(e,t={}){super(e),this[s]=void 0===t.error?null:t.error,this[u]=void 0===t.message?"":t.message}get error(){return this[s]}get message(){return this[u]}}Object.defineProperty(m.prototype,"error",{enumerable:!0}),Object.defineProperty(m.prototype,"message",{enumerable:!0});class y extends d{constructor(e,t={}){super(e),this[a]=void 0===t.data?null:t.data}get data(){return this[a]}}Object.defineProperty(y.prototype,"data",{enumerable:!0});const g={addEventListener(e,t,r={}){let o;if("message"===e)o=function(e,r){const n=new y("message",{data:r?e:e.toString()});n[l]=this,t.call(this,n)};else if("close"===e)o=function(e,r){const n=new p("close",{code:e,reason:r.toString(),wasClean:this._closeFrameReceived&&this._closeFrameSent});n[l]=this,t.call(this,n)};else if("error"===e)o=function(e){const r=new m("error",{error:e,message:e.message});r[l]=this,t.call(this,r)};else{if("open"!==e)return;o=function(){const e=new d("open");e[l]=this,t.call(this,e)}}o[n]=!!r[n],o[i]=t,r.once?this.once(e,o):this.on(e,o)},removeEventListener(e,t){for(const r of this.listeners(e))if(r[i]===t&&!r[n]){this.removeListener(e,r);break}}};e.exports={CloseEvent:p,ErrorEvent:m,Event:d,EventTarget:g,MessageEvent:y}},21800:(e,t,r)=>{"use strict";const{tokenChars:n}=r(42371);function i(e,t,r){void 0===e[t]?e[t]=[r]:e[t].push(r)}e.exports={format:function(e){return Object.keys(e).map((t=>{let r=e[t];return Array.isArray(r)||(r=[r]),r.map((e=>[t].concat(Object.keys(e).map((t=>{let r=e[t];return Array.isArray(r)||(r=[r]),r.map((e=>!0===e?t:`${t}=${e}`)).join("; ")}))).join("; "))).join(", ")})).join(", ")},parse:function(e){const t=Object.create(null);let r,o,a=Object.create(null),s=!1,u=!1,c=!1,l=-1,f=-1,h=-1,d=0;for(;d{"use strict";const t=Symbol("kDone"),r=Symbol("kRun");e.exports=class{constructor(e){this[t]=()=>{this.pending--,this[r]()},this.concurrency=e||1/0,this.jobs=[],this.pending=0}add(e){this.jobs.push(e),this[r]()}[r](){if(this.pending!==this.concurrency&&this.jobs.length){const e=this.jobs.shift();this.pending++,e(this[t])}}}},32702:(e,t,r)=>{"use strict";var n=r(48764).Buffer;const i=r(3996),o=r(65966),a=r(60964),{kStatusCode:s}=r(62638),u=n.from([0,0,255,255]),c=Symbol("permessage-deflate"),l=Symbol("total-length"),f=Symbol("callback"),h=Symbol("buffers"),d=Symbol("error");let p;function m(e){this[h].push(e),this[l]+=e.length}function y(e){this[l]+=e.length,this[c]._maxPayload<1||this[l]<=this[c]._maxPayload?this[h].push(e):(this[d]=new RangeError("Max payload size exceeded"),this[d].code="WS_ERR_UNSUPPORTED_MESSAGE_LENGTH",this[d][s]=1009,this.removeListener("data",y),this.reset())}function g(e){this[c]._inflate=null,e[s]=1007,this[f](e)}e.exports=class{constructor(e,t,r){if(this._maxPayload=0|r,this._options=e||{},this._threshold=void 0!==this._options.threshold?this._options.threshold:1024,this._isServer=!!t,this._deflate=null,this._inflate=null,this.params=null,!p){const e=void 0!==this._options.concurrencyLimit?this._options.concurrencyLimit:10;p=new a(e)}}static get extensionName(){return"permessage-deflate"}offer(){const e={};return this._options.serverNoContextTakeover&&(e.server_no_context_takeover=!0),this._options.clientNoContextTakeover&&(e.client_no_context_takeover=!0),this._options.serverMaxWindowBits&&(e.server_max_window_bits=this._options.serverMaxWindowBits),this._options.clientMaxWindowBits?e.client_max_window_bits=this._options.clientMaxWindowBits:null==this._options.clientMaxWindowBits&&(e.client_max_window_bits=!0),e}accept(e){return e=this.normalizeParams(e),this.params=this._isServer?this.acceptAsServer(e):this.acceptAsClient(e),this.params}cleanup(){if(this._inflate&&(this._inflate.close(),this._inflate=null),this._deflate){const e=this._deflate[f];this._deflate.close(),this._deflate=null,e&&e(new Error("The deflate stream was closed while data was being processed"))}}acceptAsServer(e){const t=this._options,r=e.find((e=>!(!1===t.serverNoContextTakeover&&e.server_no_context_takeover||e.server_max_window_bits&&(!1===t.serverMaxWindowBits||"number"==typeof t.serverMaxWindowBits&&t.serverMaxWindowBits>e.server_max_window_bits)||"number"==typeof t.clientMaxWindowBits&&!e.client_max_window_bits)));if(!r)throw new Error("None of the extension offers can be accepted");return t.serverNoContextTakeover&&(r.server_no_context_takeover=!0),t.clientNoContextTakeover&&(r.client_no_context_takeover=!0),"number"==typeof t.serverMaxWindowBits&&(r.server_max_window_bits=t.serverMaxWindowBits),"number"==typeof t.clientMaxWindowBits?r.client_max_window_bits=t.clientMaxWindowBits:!0!==r.client_max_window_bits&&!1!==t.clientMaxWindowBits||delete r.client_max_window_bits,r}acceptAsClient(e){const t=e[0];if(!1===this._options.clientNoContextTakeover&&t.client_no_context_takeover)throw new Error('Unexpected parameter "client_no_context_takeover"');if(t.client_max_window_bits){if(!1===this._options.clientMaxWindowBits||"number"==typeof this._options.clientMaxWindowBits&&t.client_max_window_bits>this._options.clientMaxWindowBits)throw new Error('Unexpected or invalid parameter "client_max_window_bits"')}else"number"==typeof this._options.clientMaxWindowBits&&(t.client_max_window_bits=this._options.clientMaxWindowBits);return t}normalizeParams(e){return e.forEach((e=>{Object.keys(e).forEach((t=>{let r=e[t];if(r.length>1)throw new Error(`Parameter "${t}" must have only a single value`);if(r=r[0],"client_max_window_bits"===t){if(!0!==r){const e=+r;if(!Number.isInteger(e)||e<8||e>15)throw new TypeError(`Invalid value for parameter "${t}": ${r}`);r=e}else if(!this._isServer)throw new TypeError(`Invalid value for parameter "${t}": ${r}`)}else if("server_max_window_bits"===t){const e=+r;if(!Number.isInteger(e)||e<8||e>15)throw new TypeError(`Invalid value for parameter "${t}": ${r}`);r=e}else{if("client_no_context_takeover"!==t&&"server_no_context_takeover"!==t)throw new Error(`Unknown parameter "${t}"`);if(!0!==r)throw new TypeError(`Invalid value for parameter "${t}": ${r}`)}e[t]=r}))})),e}decompress(e,t,r){p.add((n=>{this._decompress(e,t,((e,t)=>{n(),r(e,t)}))}))}compress(e,t,r){p.add((n=>{this._compress(e,t,((e,t)=>{n(),r(e,t)}))}))}_decompress(e,t,r){const n=this._isServer?"client":"server";if(!this._inflate){const e=`${n}_max_window_bits`,t="number"!=typeof this.params[e]?i.Z_DEFAULT_WINDOWBITS:this.params[e];this._inflate=i.createInflateRaw({...this._options.zlibInflateOptions,windowBits:t}),this._inflate[c]=this,this._inflate[l]=0,this._inflate[h]=[],this._inflate.on("error",g),this._inflate.on("data",y)}this._inflate[f]=r,this._inflate.write(e),t&&this._inflate.write(u),this._inflate.flush((()=>{const e=this._inflate[d];if(e)return this._inflate.close(),this._inflate=null,void r(e);const i=o.concat(this._inflate[h],this._inflate[l]);this._inflate._readableState.endEmitted?(this._inflate.close(),this._inflate=null):(this._inflate[l]=0,this._inflate[h]=[],t&&this.params[`${n}_no_context_takeover`]&&this._inflate.reset()),r(null,i)}))}_compress(e,t,r){const n=this._isServer?"server":"client";if(!this._deflate){const e=`${n}_max_window_bits`,t="number"!=typeof this.params[e]?i.Z_DEFAULT_WINDOWBITS:this.params[e];this._deflate=i.createDeflateRaw({...this._options.zlibDeflateOptions,windowBits:t}),this._deflate[l]=0,this._deflate[h]=[],this._deflate.on("data",m)}this._deflate[f]=r,this._deflate.write(e),this._deflate.flush(i.Z_SYNC_FLUSH,(()=>{if(!this._deflate)return;let e=o.concat(this._deflate[h],this._deflate[l]);t&&(e=e.slice(0,e.length-4)),this._deflate[f]=null,this._deflate[l]=0,this._deflate[h]=[],t&&this.params[`${n}_no_context_takeover`]&&this._deflate.reset(),r(null,e)}))}}},75853:(e,t,r)=>{"use strict";var n=r(48764).Buffer;const{Writable:i}=r(42830),o=r(32702),{BINARY_TYPES:a,EMPTY_BUFFER:s,kStatusCode:u,kWebSocket:c}=r(62638),{concat:l,toArrayBuffer:f,unmask:h}=r(65966),{isValidStatusCode:d,isValidUTF8:p}=r(42371);function m(e,t,r,n,i){const o=new e(r?`Invalid WebSocket frame: ${t}`:t);return Error.captureStackTrace(o,m),o.code=i,o[u]=n,o}e.exports=class extends i{constructor(e={}){super(),this._binaryType=e.binaryType||a[0],this._extensions=e.extensions||{},this._isServer=!!e.isServer,this._maxPayload=0|e.maxPayload,this._skipUTF8Validation=!!e.skipUTF8Validation,this[c]=void 0,this._bufferedBytes=0,this._buffers=[],this._compressed=!1,this._payloadLength=0,this._mask=void 0,this._fragmented=0,this._masked=!1,this._fin=!1,this._opcode=0,this._totalPayloadLength=0,this._messageLength=0,this._fragments=[],this._state=0,this._loop=!1}_write(e,t,r){if(8===this._opcode&&0==this._state)return r();this._bufferedBytes+=e.length,this._buffers.push(e),this.startLoop(r)}consume(e){if(this._bufferedBytes-=e,e===this._buffers[0].length)return this._buffers.shift();if(e=r.length?t.set(this._buffers.shift(),n):(t.set(new Uint8Array(r.buffer,r.byteOffset,e),n),this._buffers[0]=r.slice(e)),e-=r.length}while(e>0);return t}startLoop(e){let t;this._loop=!0;do{switch(this._state){case 0:t=this.getInfo();break;case 1:t=this.getPayloadLength16();break;case 2:t=this.getPayloadLength64();break;case 3:this.getMask();break;case 4:t=this.getData(e);break;default:return void(this._loop=!1)}}while(this._loop);e(t)}getInfo(){if(this._bufferedBytes<2)return void(this._loop=!1);const e=this.consume(2);if(0!=(48&e[0]))return this._loop=!1,m(RangeError,"RSV2 and RSV3 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_2_3");const t=64==(64&e[0]);if(t&&!this._extensions[o.extensionName])return this._loop=!1,m(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(this._fin=128==(128&e[0]),this._opcode=15&e[0],this._payloadLength=127&e[1],0===this._opcode){if(t)return this._loop=!1,m(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(!this._fragmented)return this._loop=!1,m(RangeError,"invalid opcode 0",!0,1002,"WS_ERR_INVALID_OPCODE");this._opcode=this._fragmented}else if(1===this._opcode||2===this._opcode){if(this._fragmented)return this._loop=!1,m(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");this._compressed=t}else{if(!(this._opcode>7&&this._opcode<11))return this._loop=!1,m(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");if(!this._fin)return this._loop=!1,m(RangeError,"FIN must be set",!0,1002,"WS_ERR_EXPECTED_FIN");if(t)return this._loop=!1,m(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(this._payloadLength>125)return this._loop=!1,m(RangeError,`invalid payload length ${this._payloadLength}`,!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH")}if(this._fin||this._fragmented||(this._fragmented=this._opcode),this._masked=128==(128&e[1]),this._isServer){if(!this._masked)return this._loop=!1,m(RangeError,"MASK must be set",!0,1002,"WS_ERR_EXPECTED_MASK")}else if(this._masked)return this._loop=!1,m(RangeError,"MASK must be clear",!0,1002,"WS_ERR_UNEXPECTED_MASK");if(126===this._payloadLength)this._state=1;else{if(127!==this._payloadLength)return this.haveLength();this._state=2}}getPayloadLength16(){if(!(this._bufferedBytes<2))return this._payloadLength=this.consume(2).readUInt16BE(0),this.haveLength();this._loop=!1}getPayloadLength64(){if(this._bufferedBytes<8)return void(this._loop=!1);const e=this.consume(8),t=e.readUInt32BE(0);return t>Math.pow(2,21)-1?(this._loop=!1,m(RangeError,"Unsupported WebSocket frame: payload length > 2^53 - 1",!1,1009,"WS_ERR_UNSUPPORTED_DATA_PAYLOAD_LENGTH")):(this._payloadLength=t*Math.pow(2,32)+e.readUInt32BE(4),this.haveLength())}haveLength(){if(this._payloadLength&&this._opcode<8&&(this._totalPayloadLength+=this._payloadLength,this._totalPayloadLength>this._maxPayload&&this._maxPayload>0))return this._loop=!1,m(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH");this._masked?this._state=3:this._state=4}getMask(){this._bufferedBytes<4?this._loop=!1:(this._mask=this.consume(4),this._state=4)}getData(e){let t=s;if(this._payloadLength){if(this._bufferedBytes7?this.controlMessage(t):this._compressed?(this._state=5,void this.decompress(t,e)):(t.length&&(this._messageLength=this._totalPayloadLength,this._fragments.push(t)),this.dataMessage())}decompress(e,t){this._extensions[o.extensionName].decompress(e,this._fin,((e,r)=>{if(e)return t(e);if(r.length){if(this._messageLength+=r.length,this._messageLength>this._maxPayload&&this._maxPayload>0)return t(m(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH"));this._fragments.push(r)}const n=this.dataMessage();if(n)return t(n);this.startLoop(t)}))}dataMessage(){if(this._fin){const e=this._messageLength,t=this._fragments;if(this._totalPayloadLength=0,this._messageLength=0,this._fragmented=0,this._fragments=[],2===this._opcode){let r;r="nodebuffer"===this._binaryType?l(t,e):"arraybuffer"===this._binaryType?f(l(t,e)):t,this.emit("message",r,!0)}else{const r=l(t,e);if(!this._skipUTF8Validation&&!p(r))return this._loop=!1,m(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");this.emit("message",r,!1)}}this._state=0}controlMessage(e){if(8===this._opcode)if(this._loop=!1,0===e.length)this.emit("conclude",1005,s),this.end();else{if(1===e.length)return m(RangeError,"invalid payload length 1",!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH");{const t=e.readUInt16BE(0);if(!d(t))return m(RangeError,`invalid status code ${t}`,!0,1002,"WS_ERR_INVALID_CLOSE_CODE");const r=e.slice(2);if(!this._skipUTF8Validation&&!p(r))return m(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");this.emit("conclude",t,r),this.end()}}else 9===this._opcode?this.emit("ping",e):this.emit("pong",e);this._state=0}}},80877:(e,t,r)=>{"use strict";var n=r(48764).Buffer;r(59477),r(32859);const{randomFillSync:i}=r(55835),o=r(32702),{EMPTY_BUFFER:a}=r(62638),{isValidStatusCode:s}=r(42371),{mask:u,toBuffer:c}=r(65966),l=Symbol("kByteLength"),f=n.alloc(4);class h{constructor(e,t,r){this._extensions=t||{},r&&(this._generateMask=r,this._maskBuffer=n.alloc(4)),this._socket=e,this._firstFragment=!0,this._compress=!1,this._bufferedBytes=0,this._deflating=!1,this._queue=[]}static frame(e,t){let r,o,a=!1,s=2,c=!1;t.mask&&(r=t.maskBuffer||f,t.generateMask?t.generateMask(r):i(r,0,4),c=0==(r[0]|r[1]|r[2]|r[3]),s=6),"string"==typeof e?o=t.mask&&!c||void 0===t[l]?(e=n.from(e)).length:t[l]:(o=e.length,a=t.mask&&t.readOnly&&!c);let h=o;o>=65536?(s+=8,h=127):o>125&&(s+=2,h=126);const d=n.allocUnsafe(a?o+s:s);return d[0]=t.fin?128|t.opcode:t.opcode,t.rsv1&&(d[0]|=64),d[1]=h,126===h?d.writeUInt16BE(o,2):127===h&&(d[2]=d[3]=0,d.writeUIntBE(o,4,6)),t.mask?(d[1]|=128,d[s-4]=r[0],d[s-3]=r[1],d[s-2]=r[2],d[s-1]=r[3],c?[d,e]:a?(u(e,r,d,s,o),[d]):(u(e,r,e,0,o),[d,e])):[d,e]}close(e,t,r,i){let o;if(void 0===e)o=a;else{if("number"!=typeof e||!s(e))throw new TypeError("First argument must be a valid error code number");if(void 0!==t&&t.length){const r=n.byteLength(t);if(r>123)throw new RangeError("The message must not be greater than 123 bytes");o=n.allocUnsafe(2+r),o.writeUInt16BE(e,0),"string"==typeof t?o.write(t,2):o.set(t,2)}else o=n.allocUnsafe(2),o.writeUInt16BE(e,0)}const u={[l]:o.length,fin:!0,generateMask:this._generateMask,mask:r,maskBuffer:this._maskBuffer,opcode:8,readOnly:!1,rsv1:!1};this._deflating?this.enqueue([this.dispatch,o,!1,u,i]):this.sendFrame(h.frame(o,u),i)}ping(e,t,r){let i,o;if("string"==typeof e?(i=n.byteLength(e),o=!1):(i=(e=c(e)).length,o=c.readOnly),i>125)throw new RangeError("The data size must not be greater than 125 bytes");const a={[l]:i,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:9,readOnly:o,rsv1:!1};this._deflating?this.enqueue([this.dispatch,e,!1,a,r]):this.sendFrame(h.frame(e,a),r)}pong(e,t,r){let i,o;if("string"==typeof e?(i=n.byteLength(e),o=!1):(i=(e=c(e)).length,o=c.readOnly),i>125)throw new RangeError("The data size must not be greater than 125 bytes");const a={[l]:i,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:10,readOnly:o,rsv1:!1};this._deflating?this.enqueue([this.dispatch,e,!1,a,r]):this.sendFrame(h.frame(e,a),r)}send(e,t,r){const i=this._extensions[o.extensionName];let a,s,u=t.binary?2:1,f=t.compress;if("string"==typeof e?(a=n.byteLength(e),s=!1):(a=(e=c(e)).length,s=c.readOnly),this._firstFragment?(this._firstFragment=!1,f&&i&&i.params[i._isServer?"server_no_context_takeover":"client_no_context_takeover"]&&(f=a>=i._threshold),this._compress=f):(f=!1,u=0),t.fin&&(this._firstFragment=!0),i){const n={[l]:a,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:u,readOnly:s,rsv1:f};this._deflating?this.enqueue([this.dispatch,e,this._compress,n,r]):this.dispatch(e,this._compress,n,r)}else this.sendFrame(h.frame(e,{[l]:a,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:u,readOnly:s,rsv1:!1}),r)}dispatch(e,t,r,n){if(!t)return void this.sendFrame(h.frame(e,r),n);const i=this._extensions[o.extensionName];this._bufferedBytes+=r[l],this._deflating=!0,i.compress(e,r.fin,((e,t)=>{if(this._socket.destroyed){const e=new Error("The socket was closed while data was being compressed");"function"==typeof n&&n(e);for(let t=0;t{"use strict";var n=r(34155);const{Duplex:i}=r(42830);function o(e){e.emit("close")}function a(){!this.destroyed&&this._writableState.finished&&this.destroy()}function s(e){this.removeListener("error",s),this.destroy(),0===this.listenerCount("error")&&this.emit("error",e)}e.exports=function(e,t){let r=!0;const u=new i({...t,autoDestroy:!1,emitClose:!1,objectMode:!1,writableObjectMode:!1});return e.on("message",(function(t,r){const n=!r&&u._readableState.objectMode?t.toString():t;u.push(n)||e.pause()})),e.once("error",(function(e){u.destroyed||(r=!1,u.destroy(e))})),e.once("close",(function(){u.destroyed||u.push(null)})),u._destroy=function(t,i){if(e.readyState===e.CLOSED)return i(t),void n.nextTick(o,u);let a=!1;e.once("error",(function(e){a=!0,i(e)})),e.once("close",(function(){a||i(t),n.nextTick(o,u)})),r&&e.terminate()},u._final=function(t){e.readyState!==e.CONNECTING?null!==e._socket&&(e._socket._writableState.finished?(t(),u._readableState.endEmitted&&u.destroy()):(e._socket.once("finish",(function(){t()})),e.close())):e.once("open",(function(){u._final(t)}))},u._read=function(){e.isPaused&&e.resume()},u._write=function(t,r,n){e.readyState!==e.CONNECTING?e.send(t,n):e.once("open",(function(){u._write(t,r,n)}))},u.on("end",a),u.on("error",s),u}},75151:(e,t,r)=>{"use strict";const{tokenChars:n}=r(42371);e.exports={parse:function(e){const t=new Set;let r=-1,i=-1,o=0;for(;o{"use strict";const n=[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,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0];function i(e){return e>=1e3&&e<=1014&&1004!==e&&1005!==e&&1006!==e||e>=3e3&&e<=4999}function o(e){const t=e.length;let r=0;for(;r=t||128!=(192&e[r+1])||128!=(192&e[r+2])||224===e[r]&&128==(224&e[r+1])||237===e[r]&&160==(224&e[r+1]))return!1;r+=3}else{if(240!=(248&e[r]))return!1;if(r+3>=t||128!=(192&e[r+1])||128!=(192&e[r+2])||128!=(192&e[r+3])||240===e[r]&&128==(240&e[r+1])||244===e[r]&&e[r+1]>143||e[r]>244)return!1;r+=4}return!0}try{const t=r(70311);e.exports={isValidStatusCode:i,isValidUTF8:e=>e.length<150?o(e):t(e),tokenChars:n}}catch(t){e.exports={isValidStatusCode:i,isValidUTF8:o,tokenChars:n}}},25504:(e,t,r)=>{"use strict";var n=r(34155),i=r(48764).Buffer;const o=r(17187),a=r(8501),{createHash:s}=(r(79267),r(59477),r(32859),r(55835)),u=r(21800),c=r(32702),l=r(75151),f=r(97912),{GUID:h,kWebSocket:d}=r(62638),p=/^[+/0-9A-Za-z]{22}==$/;function m(e){e._state=2,e.emit("close")}function y(){this.destroy()}function g(e,t,r,n){e.writable&&(r=r||a.STATUS_CODES[t],n={Connection:"close","Content-Type":"text/html","Content-Length":i.byteLength(r),...n},e.write(`HTTP/1.1 ${t} ${a.STATUS_CODES[t]}\r\n`+Object.keys(n).map((e=>`${e}: ${n[e]}`)).join("\r\n")+"\r\n\r\n"+r)),e.removeListener("error",y),e.destroy()}e.exports=class extends o{constructor(e,t){if(super(),null==(e={maxPayload:104857600,skipUTF8Validation:!1,perMessageDeflate:!1,handleProtocols:null,clientTracking:!0,verifyClient:null,noServer:!1,backlog:null,server:null,host:null,path:null,port:null,WebSocket:f,...e}).port&&!e.server&&!e.noServer||null!=e.port&&(e.server||e.noServer)||e.server&&e.noServer)throw new TypeError('One and only one of the "port", "server", or "noServer" options must be specified');if(null!=e.port?(this._server=a.createServer(((e,t)=>{const r=a.STATUS_CODES[426];t.writeHead(426,{"Content-Length":r.length,"Content-Type":"text/plain"}),t.end(r)})),this._server.listen(e.port,e.host,e.backlog,t)):e.server&&(this._server=e.server),this._server){const e=this.emit.bind(this,"connection");this._removeListeners=function(e,t){for(const r of Object.keys(t))e.on(r,t[r]);return function(){for(const r of Object.keys(t))e.removeListener(r,t[r])}}(this._server,{listening:this.emit.bind(this,"listening"),error:this.emit.bind(this,"error"),upgrade:(t,r,n)=>{this.handleUpgrade(t,r,n,e)}})}!0===e.perMessageDeflate&&(e.perMessageDeflate={}),e.clientTracking&&(this.clients=new Set,this._shouldEmitClose=!1),this.options=e,this._state=0}address(){if(this.options.noServer)throw new Error('The server is operating in "noServer" mode');return this._server?this._server.address():null}close(e){if(2===this._state)return e&&this.once("close",(()=>{e(new Error("The server is not running"))})),void n.nextTick(m,this);if(e&&this.once("close",e),1!==this._state)if(this._state=1,this.options.noServer||this.options.server)this._server&&(this._removeListeners(),this._removeListeners=this._server=null),this.clients&&this.clients.size?this._shouldEmitClose=!0:n.nextTick(m,this);else{const e=this._server;this._removeListeners(),this._removeListeners=this._server=null,e.close((()=>{m(this)}))}}shouldHandle(e){if(this.options.path){const t=e.url.indexOf("?");if((-1!==t?e.url.slice(0,t):e.url)!==this.options.path)return!1}return!0}handleUpgrade(e,t,r,n){t.on("error",y);const i=void 0!==e.headers["sec-websocket-key"]&&e.headers["sec-websocket-key"],o=+e.headers["sec-websocket-version"];if("GET"!==e.method||"websocket"!==e.headers.upgrade.toLowerCase()||!i||!p.test(i)||8!==o&&13!==o||!this.shouldHandle(e))return g(t,400);const a=e.headers["sec-websocket-protocol"];let s=new Set;if(void 0!==a)try{s=l.parse(a)}catch(e){return g(t,400)}const f=e.headers["sec-websocket-extensions"],h={};if(this.options.perMessageDeflate&&void 0!==f){const e=new c(this.options.perMessageDeflate,!0,this.options.maxPayload);try{const t=u.parse(f);t[c.extensionName]&&(e.accept(t[c.extensionName]),h[c.extensionName]=e)}catch(e){return g(t,400)}}if(this.options.verifyClient){const a={origin:e.headers[""+(8===o?"sec-websocket-origin":"origin")],secure:!(!e.socket.authorized&&!e.socket.encrypted),req:e};if(2===this.options.verifyClient.length)return void this.options.verifyClient(a,((o,a,u,c)=>{if(!o)return g(t,a||401,u,c);this.completeUpgrade(h,i,s,e,t,r,n)}));if(!this.options.verifyClient(a))return g(t,401)}this.completeUpgrade(h,i,s,e,t,r,n)}completeUpgrade(e,t,r,i,o,a,l){if(!o.readable||!o.writable)return o.destroy();if(o[d])throw new Error("server.handleUpgrade() was called more than once with the same socket, possibly due to a misconfiguration");if(this._state>0)return g(o,503);const f=["HTTP/1.1 101 Switching Protocols","Upgrade: websocket","Connection: Upgrade",`Sec-WebSocket-Accept: ${s("sha1").update(t+h).digest("base64")}`],p=new this.options.WebSocket(null);if(r.size){const e=this.options.handleProtocols?this.options.handleProtocols(r,i):r.values().next().value;e&&(f.push(`Sec-WebSocket-Protocol: ${e}`),p._protocol=e)}if(e[c.extensionName]){const t=e[c.extensionName].params,r=u.format({[c.extensionName]:[t]});f.push(`Sec-WebSocket-Extensions: ${r}`),p._extensions=e}this.emit("headers",f,i),o.write(f.concat("\r\n").join("\r\n")),o.removeListener("error",y),p.setSocket(o,a,{maxPayload:this.options.maxPayload,skipUTF8Validation:this.options.skipUTF8Validation}),this.clients&&(this.clients.add(p),p.on("close",(()=>{this.clients.delete(p),this._shouldEmitClose&&!this.clients.size&&n.nextTick(m,this)}))),l(p,i)}}},97912:(e,t,r)=>{"use strict";var n=r(48764).Buffer,i=r(34155);const o=r(17187),a=r(79267),s=r(8501),u=r(59477),c=r(32859),{randomBytes:l,createHash:f}=r(55835),{Readable:h}=r(42830),{URL:d}=r(8575),p=r(32702),m=r(75853),y=r(80877),{BINARY_TYPES:g,EMPTY_BUFFER:b,GUID:v,kForOnEventAttribute:w,kListener:A,kStatusCode:S,kWebSocket:k,NOOP:E}=r(62638),{EventTarget:{addEventListener:_,removeEventListener:M}}=r(27086),{format:T,parse:x}=r(21800),{toBuffer:P}=r(65966),I=["CONNECTING","OPEN","CLOSING","CLOSED"],O=/^[!#$%&'*+\-.0-9A-Z^_`|a-z~]+$/,R=[8,13];class C extends o{constructor(e,t,r){super(),this._binaryType=g[0],this._closeCode=1006,this._closeFrameReceived=!1,this._closeFrameSent=!1,this._closeMessage=b,this._closeTimer=null,this._extensions={},this._paused=!1,this._protocol="",this._readyState=C.CONNECTING,this._receiver=null,this._sender=null,this._socket=null,null!==e?(this._bufferedAmount=0,this._isServer=!1,this._redirects=0,void 0===t?t=[]:Array.isArray(t)||("object"==typeof t&&null!==t?(r=t,t=[]):t=[t]),B(this,e,t,r)):this._isServer=!0}get binaryType(){return this._binaryType}set binaryType(e){g.includes(e)&&(this._binaryType=e,this._receiver&&(this._receiver._binaryType=e))}get bufferedAmount(){return this._socket?this._socket._writableState.length+this._sender._bufferedBytes:this._bufferedAmount}get extensions(){return Object.keys(this._extensions).join()}get isPaused(){return this._paused}get onclose(){return null}get onerror(){return null}get onopen(){return null}get onmessage(){return null}get protocol(){return this._protocol}get readyState(){return this._readyState}get url(){return this._url}setSocket(e,t,r){const n=new m({binaryType:this.binaryType,extensions:this._extensions,isServer:this._isServer,maxPayload:r.maxPayload,skipUTF8Validation:r.skipUTF8Validation});this._sender=new y(e,this._extensions,r.generateMask),this._receiver=n,this._socket=e,n[k]=this,e[k]=this,n.on("conclude",j),n.on("drain",H),n.on("error",J),n.on("message",G),n.on("ping",q),n.on("pong",K),e.setTimeout(0),e.setNoDelay(),t.length>0&&e.unshift(t),e.on("close",X),e.on("data",Q),e.on("end",W),e.on("error",Z),this._readyState=C.OPEN,this.emit("open")}emitClose(){if(!this._socket)return this._readyState=C.CLOSED,void this.emit("close",this._closeCode,this._closeMessage);this._extensions[p.extensionName]&&this._extensions[p.extensionName].cleanup(),this._receiver.removeAllListeners(),this._readyState=C.CLOSED,this.emit("close",this._closeCode,this._closeMessage)}close(e,t){if(this.readyState!==C.CLOSED){if(this.readyState===C.CONNECTING){const e="WebSocket was closed before the connection was established";return F(this,this._req,e)}this.readyState!==C.CLOSING?(this._readyState=C.CLOSING,this._sender.close(e,t,!this._isServer,(e=>{e||(this._closeFrameSent=!0,(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end())})),this._closeTimer=setTimeout(this._socket.destroy.bind(this._socket),3e4)):this._closeFrameSent&&(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end()}}pause(){this.readyState!==C.CONNECTING&&this.readyState!==C.CLOSED&&(this._paused=!0,this._socket.pause())}ping(e,t,r){if(this.readyState===C.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");"function"==typeof e?(r=e,e=t=void 0):"function"==typeof t&&(r=t,t=void 0),"number"==typeof e&&(e=e.toString()),this.readyState===C.OPEN?(void 0===t&&(t=!this._isServer),this._sender.ping(e||b,t,r)):D(this,e,r)}pong(e,t,r){if(this.readyState===C.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");"function"==typeof e?(r=e,e=t=void 0):"function"==typeof t&&(r=t,t=void 0),"number"==typeof e&&(e=e.toString()),this.readyState===C.OPEN?(void 0===t&&(t=!this._isServer),this._sender.pong(e||b,t,r)):D(this,e,r)}resume(){this.readyState!==C.CONNECTING&&this.readyState!==C.CLOSED&&(this._paused=!1,this._receiver._writableState.needDrain||this._socket.resume())}send(e,t,r){if(this.readyState===C.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if("function"==typeof t&&(r=t,t={}),"number"==typeof e&&(e=e.toString()),this.readyState!==C.OPEN)return void D(this,e,r);const n={binary:"string"!=typeof e,mask:!this._isServer,compress:!0,fin:!0,...t};this._extensions[p.extensionName]||(n.compress=!1),this._sender.send(e||b,n,r)}terminate(){if(this.readyState!==C.CLOSED){if(this.readyState===C.CONNECTING){const e="WebSocket was closed before the connection was established";return F(this,this._req,e)}this._socket&&(this._readyState=C.CLOSING,this._socket.destroy())}}}function B(e,t,r,i){const o={protocolVersion:R[1],maxPayload:104857600,skipUTF8Validation:!1,perMessageDeflate:!0,followRedirects:!1,maxRedirects:10,...i,createConnection:void 0,socketPath:void 0,hostname:void 0,protocol:void 0,timeout:void 0,method:void 0,host:void 0,path:void 0,port:void 0};if(!R.includes(o.protocolVersion))throw new RangeError(`Unsupported protocol version: ${o.protocolVersion} (supported versions: ${R.join(", ")})`);let u;if(t instanceof d)u=t,e._url=t.href;else{try{u=new d(t)}catch(e){throw new SyntaxError(`Invalid URL: ${t}`)}e._url=t}const c="wss:"===u.protocol,h="ws+unix:"===u.protocol;let m;if("ws:"===u.protocol||c||h?h&&!u.pathname?m="The URL's pathname is empty":u.hash&&(m="The URL contains a fragment identifier"):m='The URL\'s protocol must be one of "ws:", "wss:", or "ws+unix:"',m){const t=new SyntaxError(m);if(0===e._redirects)throw t;return void N(e,t)}const y=c?443:80,g=l(16).toString("base64"),b=c?a.get:s.get,w=new Set;let A;if(o.createConnection=c?U:L,o.defaultPort=o.defaultPort||y,o.port=u.port||y,o.host=u.hostname.startsWith("[")?u.hostname.slice(1,-1):u.hostname,o.headers={"Sec-WebSocket-Version":o.protocolVersion,"Sec-WebSocket-Key":g,Connection:"Upgrade",Upgrade:"websocket",...o.headers},o.path=u.pathname+u.search,o.timeout=o.handshakeTimeout,o.perMessageDeflate&&(A=new p(!0!==o.perMessageDeflate?o.perMessageDeflate:{},!1,o.maxPayload),o.headers["Sec-WebSocket-Extensions"]=T({[p.extensionName]:A.offer()})),r.length){for(const e of r){if("string"!=typeof e||!O.test(e)||w.has(e))throw new SyntaxError("An invalid or duplicated subprotocol was specified");w.add(e)}o.headers["Sec-WebSocket-Protocol"]=r.join(",")}if(o.origin&&(o.protocolVersion<13?o.headers["Sec-WebSocket-Origin"]=o.origin:o.headers.Origin=o.origin),(u.username||u.password)&&(o.auth=`${u.username}:${u.password}`),h){const e=o.path.split(":");o.socketPath=e[0],o.path=e[1]}if(o.followRedirects){if(0===e._redirects){e._originalHost=u.host;const t=i&&i.headers;if(i={...i,headers:{}},t)for(const[e,r]of Object.entries(t))i.headers[e.toLowerCase()]=r}else u.host!==e._originalHost&&(delete o.headers.authorization,delete o.headers.cookie,delete o.headers.host,o.auth=void 0);o.auth&&!i.headers.authorization&&(i.headers.authorization="Basic "+n.from(o.auth).toString("base64"))}let S=e._req=b(o);o.timeout&&S.on("timeout",(()=>{F(e,S,"Opening handshake has timed out")})),S.on("error",(t=>{null===S||S.aborted||(S=e._req=null,N(e,t))})),S.on("response",(n=>{const a=n.headers.location,s=n.statusCode;if(a&&o.followRedirects&&s>=300&&s<400){if(++e._redirects>o.maxRedirects)return void F(e,S,"Maximum redirects exceeded");let n;S.abort();try{n=new d(a,t)}catch(t){const r=new SyntaxError(`Invalid URL: ${a}`);return void N(e,r)}B(e,n,r,i)}else e.emit("unexpected-response",S,n)||F(e,S,`Unexpected server response: ${n.statusCode}`)})),S.on("upgrade",((t,r,n)=>{if(e.emit("upgrade",t),e.readyState!==C.CONNECTING)return;S=e._req=null;const i=f("sha1").update(g+v).digest("base64");if(t.headers["sec-websocket-accept"]!==i)return void F(e,r,"Invalid Sec-WebSocket-Accept header");const a=t.headers["sec-websocket-protocol"];let s;if(void 0!==a?w.size?w.has(a)||(s="Server sent an invalid subprotocol"):s="Server sent a subprotocol but none was requested":w.size&&(s="Server sent no subprotocol"),s)return void F(e,r,s);a&&(e._protocol=a);const u=t.headers["sec-websocket-extensions"];if(void 0!==u){if(!A){return void F(e,r,"Server sent a Sec-WebSocket-Extensions header but no extension was requested")}let t;try{t=x(u)}catch(t){return void F(e,r,"Invalid Sec-WebSocket-Extensions header")}const n=Object.keys(t);if(1!==n.length||n[0]!==p.extensionName){return void F(e,r,"Server indicated an extension that was not requested")}try{A.accept(t[p.extensionName])}catch(t){return void F(e,r,"Invalid Sec-WebSocket-Extensions header")}e._extensions[p.extensionName]=A}e.setSocket(r,n,{generateMask:o.generateMask,maxPayload:o.maxPayload,skipUTF8Validation:o.skipUTF8Validation})}))}function N(e,t){e._readyState=C.CLOSING,e.emit("error",t),e.emitClose()}function L(e){return e.path=e.socketPath,u.connect(e)}function U(e){return e.path=void 0,e.servername||""===e.servername||(e.servername=u.isIP(e.host)?"":e.host),c.connect(e)}function F(e,t,r){e._readyState=C.CLOSING;const n=new Error(r);Error.captureStackTrace(n,F),t.setHeader?(t.abort(),t.socket&&!t.socket.destroyed&&t.socket.destroy(),t.once("abort",e.emitClose.bind(e)),e.emit("error",n)):(t.destroy(n),t.once("error",e.emit.bind(e,"error")),t.once("close",e.emitClose.bind(e)))}function D(e,t,r){if(t){const r=P(t).length;e._socket?e._sender._bufferedBytes+=r:e._bufferedAmount+=r}if(r){r(new Error(`WebSocket is not open: readyState ${e.readyState} (${I[e.readyState]})`))}}function j(e,t){const r=this[k];r._closeFrameReceived=!0,r._closeMessage=t,r._closeCode=e,void 0!==r._socket[k]&&(r._socket.removeListener("data",Q),i.nextTick(V,r._socket),1005===e?r.close():r.close(e,t))}function H(){const e=this[k];e.isPaused||e._socket.resume()}function J(e){const t=this[k];void 0!==t._socket[k]&&(t._socket.removeListener("data",Q),i.nextTick(V,t._socket),t.close(e[S])),t.emit("error",e)}function z(){this[k].emitClose()}function G(e,t){this[k].emit("message",e,t)}function q(e){const t=this[k];t.pong(e,!t._isServer,E),t.emit("ping",e)}function K(e){this[k].emit("pong",e)}function V(e){e.resume()}function X(){const e=this[k];let t;this.removeListener("close",X),this.removeListener("data",Q),this.removeListener("end",W),e._readyState=C.CLOSING,this._readableState.endEmitted||e._closeFrameReceived||e._receiver._writableState.errorEmitted||null===(t=e._socket.read())||e._receiver.write(t),e._receiver.end(),this[k]=void 0,clearTimeout(e._closeTimer),e._receiver._writableState.finished||e._receiver._writableState.errorEmitted?e.emitClose():(e._receiver.on("error",z),e._receiver.on("finish",z))}function Q(e){this[k]._receiver.write(e)||this.pause()}function W(){const e=this[k];e._readyState=C.CLOSING,e._receiver.end(),this.end()}function Z(){const e=this[k];this.removeListener("error",Z),this.on("error",E),e&&(e._readyState=C.CLOSING,this.destroy())}Object.defineProperty(C,"CONNECTING",{enumerable:!0,value:I.indexOf("CONNECTING")}),Object.defineProperty(C.prototype,"CONNECTING",{enumerable:!0,value:I.indexOf("CONNECTING")}),Object.defineProperty(C,"OPEN",{enumerable:!0,value:I.indexOf("OPEN")}),Object.defineProperty(C.prototype,"OPEN",{enumerable:!0,value:I.indexOf("OPEN")}),Object.defineProperty(C,"CLOSING",{enumerable:!0,value:I.indexOf("CLOSING")}),Object.defineProperty(C.prototype,"CLOSING",{enumerable:!0,value:I.indexOf("CLOSING")}),Object.defineProperty(C,"CLOSED",{enumerable:!0,value:I.indexOf("CLOSED")}),Object.defineProperty(C.prototype,"CLOSED",{enumerable:!0,value:I.indexOf("CLOSED")}),["binaryType","bufferedAmount","extensions","isPaused","protocol","readyState","url"].forEach((e=>{Object.defineProperty(C.prototype,e,{enumerable:!0})})),["open","error","close","message"].forEach((e=>{Object.defineProperty(C.prototype,`on${e}`,{enumerable:!0,get(){for(const t of this.listeners(e))if(t[w])return t[A];return null},set(t){for(const t of this.listeners(e))if(t[w]){this.removeListener(e,t);break}"function"==typeof t&&this.addEventListener(e,t,{[w]:!0})}})})),C.prototype.addEventListener=_,C.prototype.removeEventListener=M,e.exports=C},17187:e=>{"use strict";var t,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var i=Number.isNaN||function(e){return e!=e};function o(){o.init.call(this)}e.exports=o,e.exports.once=function(e,t){return new Promise((function(r,n){function i(r){e.removeListener(t,o),n(r)}function o(){"function"==typeof e.removeListener&&e.removeListener("error",i),r([].slice.call(arguments))}m(e,t,o,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&m(e,"error",t,r)}(e,i,{once:!0})}))},o.EventEmitter=o,o.prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var a=10;function s(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function u(e){return void 0===e._maxListeners?o.defaultMaxListeners:e._maxListeners}function c(e,t,r,n){var i,o,a,c;if(s(r),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),o=e._events),a=o[t]),void 0===a)a=o[t]=r,++e._eventsCount;else if("function"==typeof a?a=o[t]=n?[r,a]:[a,r]:n?a.unshift(r):a.push(r),(i=u(e))>0&&a.length>i&&!a.warned){a.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=a.length,c=l,console&&console.warn&&console.warn(c)}return e}function l(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function f(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=l.bind(n);return i.listener=r,n.wrapFn=i,i}function h(e,t,r){var n=e._events;if(void 0===n)return[];var i=n[t];return void 0===i?[]:"function"==typeof i?r?[i.listener||i]:[i]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(a=t[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var u=o[e];if(void 0===u)return!1;if("function"==typeof u)n(u,this,t);else{var c=u.length,l=p(u,c);for(r=0;r=0;o--)if(r[o]===t||r[o].listener===t){a=r[o].listener,i=o;break}if(i<0)return this;0===i?r.shift():function(e,t){for(;t+1=0;n--)this.removeListener(e,t[n]);return this},o.prototype.listeners=function(e){return h(this,e,!0)},o.prototype.rawListeners=function(e){return h(this,e,!1)},o.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},o.prototype.listenerCount=d,o.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},13048:(e,t,r)=>{var n=r(89509).Buffer,i=r(62318);e.exports=function(e,t,r,o){if(n.isBuffer(e)||(e=n.from(e,"binary")),t&&(n.isBuffer(t)||(t=n.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var a=r/8,s=n.alloc(a),u=n.alloc(o||0),c=n.alloc(0);a>0||o>0;){var l=new i;l.update(c),l.update(e),t&&l.update(t),c=l.digest();var f=0;if(a>0){var h=s.length-a;f=Math.min(a,c.length),c.copy(s,h,0,f),a-=f}if(f0){var d=u.length-o,p=Math.min(o,c.length-f);c.copy(u,d,f,f+p),o-=p}}return c.fill(0),{key:s,iv:u}}},17648:e=>{"use strict";var t="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,i="[object Function]";e.exports=function(e){var o=this;if("function"!=typeof o||n.call(o)!==i)throw new TypeError(t+o);for(var a,s=r.call(arguments,1),u=function(){if(this instanceof a){var t=o.apply(this,s.concat(r.call(arguments)));return Object(t)===t?t:this}return o.apply(e,s.concat(r.call(arguments)))},c=Math.max(0,o.length-s.length),l=[],f=0;f{"use strict";var n=r(17648);e.exports=Function.prototype.bind||n},40210:(e,t,r)=>{"use strict";var n,i=SyntaxError,o=Function,a=TypeError,s=function(e){try{return o('"use strict"; return ('+e+").constructor;")()}catch(e){}},u=Object.getOwnPropertyDescriptor;if(u)try{u({},"")}catch(e){u=null}var c=function(){throw new a},l=u?function(){try{return c}catch(e){try{return u(arguments,"callee").get}catch(e){return c}}}():c,f=r(41405)(),h=Object.getPrototypeOf||function(e){return e.__proto__},d={},p="undefined"==typeof Uint8Array?n:h(Uint8Array),m={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":f?h([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":d,"%AsyncGenerator%":d,"%AsyncGeneratorFunction%":d,"%AsyncIteratorPrototype%":d,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":d,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":f?h(h([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&f?h((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&f?h((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":f?h(""[Symbol.iterator]()):n,"%Symbol%":f?Symbol:n,"%SyntaxError%":i,"%ThrowTypeError%":l,"%TypedArray%":p,"%TypeError%":a,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},y=function e(t){var r;if("%AsyncFunction%"===t)r=s("async function () {}");else if("%GeneratorFunction%"===t)r=s("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=s("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(r=h(i.prototype))}return m[t]=r,r},g={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},b=r(58612),v=r(17642),w=b.call(Function.call,Array.prototype.concat),A=b.call(Function.apply,Array.prototype.splice),S=b.call(Function.call,String.prototype.replace),k=b.call(Function.call,String.prototype.slice),E=b.call(Function.call,RegExp.prototype.exec),_=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,M=/\\(\\)?/g,T=function(e){var t=k(e,0,1),r=k(e,-1);if("%"===t&&"%"!==r)throw new i("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new i("invalid intrinsic syntax, expected opening `%`");var n=[];return S(e,_,(function(e,t,r,i){n[n.length]=r?S(i,M,"$1"):t||e})),n},x=function(e,t){var r,n=e;if(v(g,n)&&(n="%"+(r=g[n])[0]+"%"),v(m,n)){var o=m[n];if(o===d&&(o=y(n)),void 0===o&&!t)throw new a("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new i("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new a("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new a('"allowMissing" argument must be a boolean');if(null===E(/^%?[^%]*%?$/,e))throw new i("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=T(e),n=r.length>0?r[0]:"",o=x("%"+n+"%",t),s=o.name,c=o.value,l=!1,f=o.alias;f&&(n=f[0],A(r,w([0,1],f)));for(var h=1,d=!0;h=r.length){var b=u(c,p);c=(d=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:c[p]}else d=v(c,p),c=c[p];d&&!l&&(m[s]=c)}}return c}},41405:(e,t,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,i=r(55419);e.exports=function(){return"function"==typeof n&&("function"==typeof Symbol&&("symbol"==typeof n("foo")&&("symbol"==typeof Symbol("bar")&&i())))}},55419:e=>{"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var n=Object.getOwnPropertySymbols(e);if(1!==n.length||n[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(e,t);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},17642:(e,t,r)=>{"use strict";var n=r(58612);e.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},3349:(e,t,r)=>{"use strict";var n=r(89509).Buffer,i=r(88473).Transform;function o(e){i.call(this),this._block=n.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(35717)(o,i),o.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)},o.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},o.prototype.update=function(e,t){if(function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError(t+" must be a string or a buffer")}(e,"Data"),this._finalized)throw new Error("Digest already called");n.isBuffer(e)||(e=n.from(e,t));for(var r=this._block,i=0;this._blockOffset+e.length-i>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},o.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=o},33715:(e,t,r)=>{var n=t;n.utils=r(26436),n.common=r(95772),n.sha=r(89041),n.ripemd=r(12949),n.hmac=r(52344),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},95772:(e,t,r)=>{"use strict";var n=r(26436),i=r(79746);function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}t.BlockHash=o,o.prototype.update=function(e,t){if(e=n.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var i=0;i>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o{"use strict";var n=r(26436),i=r(79746);function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(n.toArray(t,r))}e.exports=o,o.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t{"use strict";var n=r(26436),i=r(95772),o=n.rotl32,a=n.sum32,s=n.sum32_3,u=n.sum32_4,c=i.BlockHash;function l(){if(!(this instanceof l))return new l;c.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function f(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function h(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function d(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}n.inherits(l,c),t.ripemd160=l,l.blockSize=512,l.outSize=160,l.hmacStrength=192,l.padLength=64,l.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],c=this.h[3],l=this.h[4],b=r,v=n,w=i,A=c,S=l,k=0;k<80;k++){var E=a(o(u(r,f(k,n,i,c),e[p[k]+t],h(k)),y[k]),l);r=l,l=c,c=o(i,10),i=n,n=E,E=a(o(u(b,f(79-k,v,w,A),e[m[k]+t],d(k)),g[k]),S),b=S,S=A,A=o(w,10),w=v,v=E}E=s(this.h[1],i,A),this.h[1]=s(this.h[2],c,S),this.h[2]=s(this.h[3],l,b),this.h[3]=s(this.h[4],r,v),this.h[4]=s(this.h[0],n,w),this.h[0]=E},l.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"little"):n.split32(this.h,"little")};var p=[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],m=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],y=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],g=[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]},89041:(e,t,r)=>{"use strict";t.sha1=r(84761),t.sha224=r(10799),t.sha256=r(89344),t.sha384=r(80772),t.sha512=r(45900)},84761:(e,t,r)=>{"use strict";var n=r(26436),i=r(95772),o=r(37038),a=n.rotl32,s=n.sum32,u=n.sum32_5,c=o.ft_1,l=i.BlockHash,f=[1518500249,1859775393,2400959708,3395469782];function h(){if(!(this instanceof h))return new h;l.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}n.inherits(h,l),e.exports=h,h.blockSize=512,h.outSize=160,h.hmacStrength=80,h.padLength=64,h.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(26436),i=r(89344);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,7),"big"):n.split32(this.h.slice(0,7),"big")}},89344:(e,t,r)=>{"use strict";var n=r(26436),i=r(95772),o=r(37038),a=r(79746),s=n.sum32,u=n.sum32_4,c=n.sum32_5,l=o.ch32,f=o.maj32,h=o.s0_256,d=o.s1_256,p=o.g0_256,m=o.g1_256,y=i.BlockHash,g=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function b(){if(!(this instanceof b))return new b;y.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=g,this.W=new Array(64)}n.inherits(b,y),e.exports=b,b.blockSize=512,b.outSize=256,b.hmacStrength=192,b.padLength=64,b.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(26436),i=r(45900);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,12),"big"):n.split32(this.h.slice(0,12),"big")}},45900:(e,t,r)=>{"use strict";var n=r(26436),i=r(95772),o=r(79746),a=n.rotr64_hi,s=n.rotr64_lo,u=n.shr64_hi,c=n.shr64_lo,l=n.sum64,f=n.sum64_hi,h=n.sum64_lo,d=n.sum64_4_hi,p=n.sum64_4_lo,m=n.sum64_5_hi,y=n.sum64_5_lo,g=i.BlockHash,b=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=b,this.W=new Array(160)}function w(e,t,r,n,i){var o=e&r^~e&i;return o<0&&(o+=4294967296),o}function A(e,t,r,n,i,o){var a=t&n^~t&o;return a<0&&(a+=4294967296),a}function S(e,t,r,n,i){var o=e&r^e&i^r&i;return o<0&&(o+=4294967296),o}function k(e,t,r,n,i,o){var a=t&n^t&o^n&o;return a<0&&(a+=4294967296),a}function E(e,t){var r=a(e,t,28)^a(t,e,2)^a(t,e,7);return r<0&&(r+=4294967296),r}function _(e,t){var r=s(e,t,28)^s(t,e,2)^s(t,e,7);return r<0&&(r+=4294967296),r}function M(e,t){var r=a(e,t,14)^a(e,t,18)^a(t,e,9);return r<0&&(r+=4294967296),r}function T(e,t){var r=s(e,t,14)^s(e,t,18)^s(t,e,9);return r<0&&(r+=4294967296),r}function x(e,t){var r=a(e,t,1)^a(e,t,8)^u(e,t,7);return r<0&&(r+=4294967296),r}function P(e,t){var r=s(e,t,1)^s(e,t,8)^c(e,t,7);return r<0&&(r+=4294967296),r}function I(e,t){var r=a(e,t,19)^a(t,e,29)^u(e,t,6);return r<0&&(r+=4294967296),r}function O(e,t){var r=s(e,t,19)^s(t,e,29)^c(e,t,6);return r<0&&(r+=4294967296),r}n.inherits(v,g),e.exports=v,v.blockSize=1024,v.outSize=512,v.hmacStrength=192,v.padLength=128,v.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(26436).rotr32;function i(e,t,r){return e&t^~e&r}function o(e,t,r){return e&t^e&r^t&r}function a(e,t,r){return e^t^r}t.ft_1=function(e,t,r,n){return 0===e?i(t,r,n):1===e||3===e?a(t,r,n):2===e?o(t,r,n):void 0},t.ch32=i,t.maj32=o,t.p32=a,t.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},t.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},t.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},26436:(e,t,r)=>{"use strict";var n=r(79746),i=r(35717);function o(e,t){return 55296==(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1)))}function a(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function s(e){return 1===e.length?"0"+e:e}function u(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=i,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),i=0;i>6|192,r[n++]=63&a|128):o(e,i)?(a=65536+((1023&a)<<10)+(1023&e.charCodeAt(++i)),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=63&a|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=63&a|128)}else for(i=0;i>>0}return a},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,n){return(t+n>>>0>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,o,a,s){var u=0,c=t;return u+=(c=c+n>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,n,i,o,a,s){return t+n+o+s>>>0},t.sum64_5_hi=function(e,t,r,n,i,o,a,s,u,c){var l=0,f=t;return l+=(f=f+n>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,n,i,o,a,s,u,c){return t+n+o+s+c>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},2156:(e,t,r)=>{"use strict";var n=r(33715),i=r(34504),o=r(79746);function a(e){if(!(this instanceof a))return new a(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=i.toArray(e.entropy,e.entropyEnc||"hex"),r=i.toArray(e.nonce,e.nonceEnc||"hex"),n=i.toArray(e.pers,e.persEnc||"hex");o(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}e.exports=a,a.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},a.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=i.toArray(r,n||"hex"),this._update(r));for(var o=[];o.length{var n=r(8501),i=r(8575),o=e.exports;for(var a in n)n.hasOwnProperty(a)&&(o[a]=n[a]);function s(e){if("string"==typeof e&&(e=i.parse(e)),e.protocol||(e.protocol="https:"),"https:"!==e.protocol)throw new Error('Protocol "'+e.protocol+'" not supported. Expected "https:"');return e}o.request=function(e,t){return e=s(e),n.request.call(this,e,t)},o.get=function(e,t){return e=s(e),n.get.call(this,e,t)}},80645:(e,t)=>{t.read=function(e,t,r,n,i){var o,a,s=8*i-n-1,u=(1<>1,l=-7,f=r?i-1:0,h=r?-1:1,d=e[t+f];for(f+=h,o=d&(1<<-l)-1,d>>=-l,l+=s;l>0;o=256*o+e[t+f],f+=h,l-=8);for(a=o&(1<<-l)-1,o>>=-l,l+=n;l>0;a=256*a+e[t+f],f+=h,l-=8);if(0===o)o=1-c;else{if(o===u)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),o-=c}return(d?-1:1)*a*Math.pow(2,o-n)},t.write=function(e,t,r,n,i,o){var a,s,u,c=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:o-1,p=n?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=l):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),(t+=a+f>=1?h/u:h*Math.pow(2,1-f))*u>=2&&(a++,u/=2),a+f>=l?(s=0,a=l):a+f>=1?(s=(t*u-1)*Math.pow(2,i),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),a=0));i>=8;e[r+d]=255&s,d+=p,s/=256,i-=8);for(a=a<0;e[r+d]=255&a,d+=p,a/=256,c-=8);e[r+d-p]|=128*m}},35717:e=>{"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},91094:(e,t,r)=>{var n,i=r(34155);!function(){"use strict";var o="input is invalid type",a="object"==typeof window,s=a?window:{};s.JS_SHA3_NO_WINDOW&&(a=!1);var u=!a&&"object"==typeof self;!s.JS_SHA3_NO_NODE_JS&&"object"==typeof i&&i.versions&&i.versions.node?s=r.g:u&&(s=self);var c=!s.JS_SHA3_NO_COMMON_JS&&e.exports,l=r.amdO,f=!s.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,h="0123456789abcdef".split(""),d=[4,1024,262144,67108864],p=[0,8,16,24],m=[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],y=[224,256,384,512],g=[128,256],b=["hex","buffer","arrayBuffer","array","digest"],v={128:168,256:136};!s.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!f||!s.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"==typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var w=function(e,t,r){return function(n){return new N(e,t,e).update(n)[r]()}},A=function(e,t,r){return function(n,i){return new N(e,t,i).update(n)[r]()}},S=function(e,t,r){return function(t,n,i,o){return T["cshake"+e].update(t,n,i,o)[r]()}},k=function(e,t,r){return function(t,n,i,o){return T["kmac"+e].update(t,n,i,o)[r]()}},E=function(e,t,r,n){for(var i=0;i>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function L(e,t,r){N.call(this,e,t,r)}N.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(o);if(null===e)throw new Error(o);if(f&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||f&&ArrayBuffer.isView(e)))throw new Error(o);t=!0}for(var n,i,a=this.blocks,s=this.byteCount,u=e.length,c=this.blockCount,l=0,h=this.s;l>2]|=e[l]<>2]|=i<>2]|=(192|i>>6)<>2]|=(128|63&i)<=57344?(a[n>>2]|=(224|i>>12)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<>2]|=(240|i>>18)<>2]|=(128|i>>12&63)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<=s){for(this.start=n-s,this.block=a[c],n=0;n>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},N.prototype.encodeString=function(e){var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(o);if(null===e)throw new Error(o);if(f&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||f&&ArrayBuffer.isView(e)))throw new Error(o);t=!0}var n=0,i=e.length;if(t)n=i;else for(var a=0;a=57344?n+=3:(s=65536+((1023&s)<<10|1023&e.charCodeAt(++a)),n+=4)}return n+=this.encode(8*n),this.update(e),n},N.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+h[15&e]+h[e>>12&15]+h[e>>8&15]+h[e>>20&15]+h[e>>16&15]+h[e>>28&15]+h[e>>24&15];a%t==0&&(U(r),o=0)}return i&&(e=r[o],s+=h[e>>4&15]+h[15&e],i>1&&(s+=h[e>>12&15]+h[e>>8&15]),i>2&&(s+=h[e>>20&15]+h[e>>16&15])),s},N.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&U(n)}return o&&(e=s<<2,t=n[a],u[e]=255&t,o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u},L.prototype=new N,L.prototype.finalize=function(){return this.encode(this.outputBits,!0),N.prototype.finalize.call(this)};var U=function(e){var t,r,n,i,o,a,s,u,c,l,f,h,d,p,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],u=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],l=e[6]^e[16]^e[26]^e[36]^e[46],f=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(d=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|c>>>31),r=o^(c<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(l<<1|f>>>31),r=s^(f<<1|l>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(h<<1|d>>>31),r=c^(d<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=l^(i<<1|o>>>31),r=f^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=p^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&p,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~p&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=m[n],e[1]^=m[n+1]};if(c)e.exports=T;else{for(P=0;P{"use strict";const{isArray:n,isObject:i,isString:o}=r(30832),{asArray:a}=r(51055),{prependBase:s}=r(82278),u=r(54093),c=r(26767);function l(e){throw new u("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:e})}function f({context:e,base:t}){if(!e)return;const r=e["@context"];if(o(r))e["@context"]=s(t,r);else if(n(r))for(let e=0;e10)throw new u("Maximum number of @context URLs exceeded.","jsonld.ContextUrlError",{code:"json-ld-1.0"===e.processingMode?"loading remote context failed":"context overflow",max:10});if(a.has(t))throw new u("Cyclical @context URLs detected.","jsonld.ContextUrlError",{code:"json-ld-1.0"===e.processingMode?"recursive context inclusion":"context overflow",url:t});let s,c;a.add(t);try{c=await r(t),s=c.document||null,o(s)&&(s=JSON.parse(s))}catch(e){throw new u("Dereferencing a URL did not result in a valid JSON-LD object. Possible causes are an inaccessible URL perhaps due to a same-origin policy (ensure the server uses CORS if you are using client-side JavaScript), too many redirects, a non-JSON response, or more than one HTTP Link Header was provided for a remote context.","jsonld.InvalidUrl",{code:"loading remote context failed",url:t,cause:e})}if(!i(s))throw new u("Dereferencing a URL did not result in a JSON object. The response was valid JSON, but it was not a JSON object.","jsonld.InvalidUrl",{code:"invalid remote context",url:t});return s="@context"in s?{"@context":s["@context"]}:{"@context":{}},c.contextUrl&&(n(s["@context"])||(s["@context"]=[s["@context"]]),s["@context"].push(c.contextUrl)),{context:s,remoteDoc:c}}}},54093:e=>{"use strict";e.exports=class extends Error{constructor(e="An unspecified JSON-LD error occurred.",t="jsonld.Error",r={}){super(e),this.name=t,this.message=e,this.details=r}}},60731:e=>{"use strict";e.exports=e=>{class t{toString(){return"[object JsonLdProcessor]"}}return Object.defineProperty(t,"prototype",{writable:!1,enumerable:!1}),Object.defineProperty(t.prototype,"constructor",{writable:!0,enumerable:!1,configurable:!0,value:t}),t.compact=function(t,r){return arguments.length<2?Promise.reject(new TypeError("Could not compact, too few arguments.")):e.compact(t,r)},t.expand=function(t){return arguments.length<1?Promise.reject(new TypeError("Could not expand, too few arguments.")):e.expand(t)},t.flatten=function(t){return arguments.length<1?Promise.reject(new TypeError("Could not flatten, too few arguments.")):e.flatten(t)},t}},69048:(e,t,r)=>{"use strict";e.exports=r(47055).NQuads},40533:e=>{"use strict";e.exports=class{constructor(){this._requests={}}wrapLoader(e){const t=this;return t._loader=e,function(){return t.add.apply(t,arguments)}}async add(e){let t=this._requests[e];if(t)return Promise.resolve(t);t=this._requests[e]=this._loader(e);try{return await t}finally{delete this._requests[e]}}}},26767:(e,t,r)=>{"use strict";const n=r(39593);e.exports=class{constructor({document:e}){this.document=e,this.cache=new n({max:10})}getProcessed(e){return this.cache.get(e)}setProcessed(e,t){this.cache.set(e,t)}}},83251:(e,t,r)=>{"use strict";const n=r(54093),{isArray:i,isObject:o,isString:a,isUndefined:s}=r(30832),{isList:u,isValue:c,isGraph:l,isSimpleGraph:f,isSubjectReference:h}=r(18463),{expandIri:d,getContextValue:p,isKeyword:m,process:y,processingMode:g}=r(54131),{removeBase:b,prependBase:v}=r(82278),{REGEX_KEYWORD:w,addValue:A,asArray:S,compareShortestLeast:k}=r(51055),E={};function _(e,t,r){if("@nest"!==d(e,t,{vocab:!0},r))throw new n("JSON-LD compact error; nested property must have an @nest value resolving to @nest.","jsonld.SyntaxError",{code:"invalid @nest value"})}e.exports=E,E.compact=async({activeCtx:e,activeProperty:t=null,element:r,options:d={}})=>{if(i(r)){let n=[];for(let i=0;i1&&(M=Array.from(M).sort());const T=e;for(const t of M){const r=E.compactIri({activeCtx:T,iri:t,relativeTo:{vocab:!0}}),n=p(w,r,"@context");s(n)||(e=await y({activeCtx:e,localCtx:n,options:d,propagate:!1}))}const x=Object.keys(r).sort();for(const s of x){const h=r[s];if("@id"!==s)if("@type"!==s)if("@reverse"!==s)if("@preserve"!==s)if("@index"!==s)if("@graph"!==s&&"@list"!==s&&"@included"!==s&&m(s)){const t=E.compactIri({activeCtx:e,iri:s,relativeTo:{vocab:!0}});A(v,t,h)}else{if(!i(h))throw new n("JSON-LD expansion error; expanded value must be an array.","jsonld.SyntaxError");if(0===h.length){const t=E.compactIri({activeCtx:e,iri:s,value:h,relativeTo:{vocab:!0},reverse:b}),r=e.mappings.has(t)?e.mappings.get(t)["@nest"]:null;let n=v;r&&(_(e,r,d),o(v[r])||(v[r]={}),n=v[r]),A(n,t,h,{propertyIsArray:!0})}for(const t of h){const r=E.compactIri({activeCtx:e,iri:s,value:t,relativeTo:{vocab:!0},reverse:b}),n=e.mappings.has(r)?e.mappings.get(r)["@nest"]:null;let h=v;n&&(_(e,n,d),o(v[n])||(v[n]={}),h=v[n]);const m=p(e,r,"@container")||[],y=l(t),g=u(t);let w;g?w=t["@list"]:y&&(w=t["@graph"]);let k=await E.compact({activeCtx:e,activeProperty:r,element:g||y?w:t,options:d});if(g){if(i(k)||(k=[k]),m.includes("@list")){A(h,r,k,{valueIsArray:!0,allowDuplicate:!0});continue}k={[E.compactIri({activeCtx:e,iri:"@list",relativeTo:{vocab:!0}})]:k},"@index"in t&&(k[E.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=t["@index"])}if(y)if(m.includes("@graph")&&(m.includes("@id")||m.includes("@index")&&f(t))){let n;h.hasOwnProperty(r)?n=h[r]:h[r]=n={};const i=(m.includes("@id")?t["@id"]:t["@index"])||E.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}});A(n,i,k,{propertyIsArray:!d.compactArrays||m.includes("@set")})}else m.includes("@graph")&&f(t)?(i(k)&&k.length>1&&(k={"@included":k}),A(h,r,k,{propertyIsArray:!d.compactArrays||m.includes("@set")})):(i(k)&&1===k.length&&d.compactArrays&&(k=k[0]),k={[E.compactIri({activeCtx:e,iri:"@graph",relativeTo:{vocab:!0}})]:k},"@id"in t&&(k[E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]=t["@id"]),"@index"in t&&(k[E.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=t["@index"]),A(h,r,k,{propertyIsArray:!d.compactArrays||m.includes("@set")}));else if(m.includes("@language")||m.includes("@index")||m.includes("@id")||m.includes("@type")){let n,i;if(h.hasOwnProperty(r)?n=h[r]:h[r]=n={},m.includes("@language"))c(k)&&(k=k["@value"]),i=t["@language"];else if(m.includes("@index")){const n=p(e,r,"@index")||"@index",o=E.compactIri({activeCtx:e,iri:n,relativeTo:{vocab:!0}});if("@index"===n)i=t["@index"],delete k[o];else{let e;if([i,...e]=S(k[n]||[]),a(i))switch(e.length){case 0:delete k[n];break;case 1:k[n]=e[0];break;default:k[n]=e}else i=null}}else if(m.includes("@id")){const t=E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}});i=k[t],delete k[t]}else if(m.includes("@type")){const n=E.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}});let o;switch([i,...o]=S(k[n]||[]),o.length){case 0:delete k[n];break;case 1:k[n]=o[0];break;default:k[n]=o}1===Object.keys(k).length&&"@id"in t&&(k=await E.compact({activeCtx:e,activeProperty:r,element:{"@id":t["@id"]},options:d}))}i||(i=E.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}})),A(n,i,k,{propertyIsArray:m.includes("@set")})}else{const e=!d.compactArrays||m.includes("@set")||m.includes("@list")||i(k)&&0===k.length||"@list"===s||"@graph"===s;A(h,r,k,{propertyIsArray:e})}}}else{if((p(e,t,"@container")||[]).includes("@index"))continue;const r=E.compactIri({activeCtx:e,iri:s,relativeTo:{vocab:!0}});A(v,r,h)}else{const r=await E.compact({activeCtx:e,activeProperty:t,element:h,options:d});i(r)&&0===r.length||A(v,s,r)}else{const t=await E.compact({activeCtx:e,activeProperty:"@reverse",element:h,options:d});for(const r in t)if(e.mappings.has(r)&&e.mappings.get(r).reverse){const n=t[r],i=(p(e,r,"@container")||[]).includes("@set")||!d.compactArrays;A(v,r,n,{propertyIsArray:i}),delete t[r]}if(Object.keys(t).length>0){const r=E.compactIri({activeCtx:e,iri:s,relativeTo:{vocab:!0}});A(v,r,t)}}else{let t=S(h).map((e=>E.compactIri({activeCtx:w,iri:e,relativeTo:{vocab:!0}})));1===t.length&&(t=t[0]);const r=E.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}}),n=(p(e,r,"@container")||[]).includes("@set")&&g(e,1.1)||i(t)&&0===h.length;A(v,r,t,{propertyIsArray:n})}else{let t=S(h).map((t=>E.compactIri({activeCtx:e,iri:t,relativeTo:{vocab:!1},base:d.base})));1===t.length&&(t=t[0]);v[E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]=t}}return v}return r},E.compactIri=({activeCtx:e,iri:t,value:r=null,relativeTo:i={vocab:!1},reverse:a=!1,base:s=null})=>{if(null===t)return t;e.isPropertyTermScoped&&e.previousContext&&(e=e.previousContext);const f=e.getInverse();if(m(t)&&t in f&&"@none"in f[t]&&"@type"in f[t]["@none"]&&"@none"in f[t]["@none"]["@type"])return f[t]["@none"]["@type"]["@none"];if(i.vocab&&t in f){const n=e["@language"]||"@none",i=[];o(r)&&"@index"in r&&!("@graph"in r)&&i.push("@index","@index@set"),o(r)&&"@preserve"in r&&(r=r["@preserve"][0]),l(r)?("@index"in r&&i.push("@graph@index","@graph@index@set","@index","@index@set"),"@id"in r&&i.push("@graph@id","@graph@id@set"),i.push("@graph","@graph@set","@set"),"@index"in r||i.push("@graph@index","@graph@index@set","@index","@index@set"),"@id"in r||i.push("@graph@id","@graph@id@set")):o(r)&&!c(r)&&i.push("@id","@id@set","@type","@set@type");let s="@language",f="@null";if(a)s="@type",f="@reverse",i.push("@set");else if(u(r)){"@index"in r||i.push("@list");const e=r["@list"];if(0===e.length)s="@any",f="@none";else{let t=0===e.length?n:null,r=null;for(let n=0;ne.includes("_")));e&&s.push(e.replace(/^[^_]+_/,"_"))}s.push("@none");const u=e.inverse[t];for(const e of n){if(!(e in u))continue;const t=u[e][i];for(const e of s)if(e in t)return t[e]}return null}(e,t,r,i,s,f);if(null!==h)return h}if(i.vocab&&"@vocab"in e){const r=e["@vocab"];if(0===t.indexOf(r)&&t!==r){const n=t.substr(r.length);if(!e.mappings.has(n))return n}}let h=null;const d=[];let p=e.fastCurieMap;const y=t.length-1;for(let e=0;e=0;--n){const i=d[n],o=i.terms;for(const n of o){const o=n+":"+t.substr(i.iri.length);e.mappings.get(n)._prefix&&(!e.mappings.has(o)||null===r&&e.mappings.get(o)["@id"]===t)&&(null===h||k(o,h)<0)&&(h=o)}}if(null!==h)return h;for(const[r,i]of e.mappings)if(i&&i._prefix&&t.startsWith(r+":"))throw new n(`Absolute IRI "${t}" confused with prefix "${r}".`,"jsonld.SyntaxError",{code:"IRI confused with prefix",context:e});if(!i.vocab){if("@base"in e){if(e["@base"]){const r=b(v(s,e["@base"]),t);return w.test(r)?`./${r}`:r}return t}return b(s,t)}return t},E.compactValue=({activeCtx:e,activeProperty:t,value:r,options:n})=>{if(c(r)){const n=p(e,t,"@type"),i=p(e,t,"@language"),o=p(e,t,"@direction"),s=p(e,t,"@container")||[],u="@index"in r&&!s.includes("@index");if(!u&&"@none"!==n){if(r["@type"]===n)return r["@value"];if("@language"in r&&r["@language"]===i&&"@direction"in r&&r["@direction"]===o)return r["@value"];if("@language"in r&&r["@language"]===i)return r["@value"];if("@direction"in r&&r["@direction"]===o)return r["@value"]}const c=Object.keys(r).length,l=1===c||2===c&&"@index"in r&&!u,f="@language"in e,h=a(r["@value"]),d=e.mappings.has(t)&&null===e.mappings.get(t)["@language"];if(l&&"@none"!==n&&(!f||!h||d))return r["@value"];const m={};return u&&(m[E.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=r["@index"]),"@type"in r?m[E.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}})]=E.compactIri({activeCtx:e,iri:r["@type"],relativeTo:{vocab:!0}}):"@language"in r&&(m[E.compactIri({activeCtx:e,iri:"@language",relativeTo:{vocab:!0}})]=r["@language"]),"@direction"in r&&(m[E.compactIri({activeCtx:e,iri:"@direction",relativeTo:{vocab:!0}})]=r["@direction"]),m[E.compactIri({activeCtx:e,iri:"@value",relativeTo:{vocab:!0}})]=r["@value"],m}const i=d(e,t,{vocab:!0},n),o=p(e,t,"@type"),s=E.compactIri({activeCtx:e,iri:r["@id"],relativeTo:{vocab:"@vocab"===o},base:n.base});return"@id"===o||"@vocab"===o||"@graph"===i?s:{[E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]:s}}},93770:e=>{"use strict";const t="http://www.w3.org/1999/02/22-rdf-syntax-ns#",r="http://www.w3.org/2001/XMLSchema#";e.exports={LINK_HEADER_REL:"http://www.w3.org/ns/json-ld#context",LINK_HEADER_CONTEXT:"http://www.w3.org/ns/json-ld#context",RDF:t,RDF_LIST:t+"List",RDF_FIRST:t+"first",RDF_REST:t+"rest",RDF_NIL:t+"nil",RDF_TYPE:t+"type",RDF_PLAIN_LITERAL:t+"PlainLiteral",RDF_XML_LITERAL:t+"XMLLiteral",RDF_JSON_LITERAL:t+"JSON",RDF_OBJECT:t+"object",RDF_LANGSTRING:t+"langString",XSD:r,XSD_BOOLEAN:r+"boolean",XSD_DOUBLE:r+"double",XSD_INTEGER:r+"integer",XSD_STRING:r+"string"}},54131:(e,t,r)=>{"use strict";const n=r(51055),i=r(54093),{isArray:o,isObject:a,isString:s,isUndefined:u}=r(30832),{isAbsolute:c,isRelative:l,prependBase:f}=r(82278),{handleEvent:h}=r(91696),{REGEX_BCP47:d,REGEX_KEYWORD:p,asArray:m,compareShortestLeast:y}=r(51055),g=new Map,b={};function v(e,t,r,n,i,o){if(null===t||!s(t)||b.isKeyword(t))return t;if(t.match(p))return null;if(n&&n.hasOwnProperty(t)&&!0!==i.get(t)&&b.createTermDefinition({activeCtx:e,localCtx:n,term:t,defined:i,options:o}),(r=r||{}).vocab){const r=e.mappings.get(t);if(null===r)return null;if(a(r)&&"@id"in r)return r["@id"]}const u=t.indexOf(":");if(u>0){const r=t.substr(0,u),a=t.substr(u+1);if("_"===r||0===a.indexOf("//"))return t;n&&n.hasOwnProperty(r)&&b.createTermDefinition({activeCtx:e,localCtx:n,term:r,defined:i,options:o});const s=e.mappings.get(r);if(s&&s._prefix)return s["@id"]+a;if(c(t))return t}if(r.vocab&&"@vocab"in e){t=e["@vocab"]+t}else if(r.base){let r,n;"@base"in e?e["@base"]?(n=f(o.base,e["@base"]),r=f(n,t)):(n=e["@base"],r=t):(n=o.base,r=f(o.base,t)),t=r}return t}function w(e,t){if(!e||"object"!=typeof e||!t||"object"!=typeof t)return e===t;const r=Array.isArray(e);if(r!==Array.isArray(t))return!1;if(r){if(e.length!==t.length)return!1;for(let r=0;r{a(t)&&"@context"in t&&o(t["@context"])&&(t=t["@context"]);if(0===m(t).length)return e;const y=[],g=[({event:e,next:t})=>{y.push(e),t()}];r.eventHandler&&g.push(r.eventHandler);const w=r;r={...r,eventHandler:g};const A=await r.contextResolver.resolve({activeCtx:e,context:t,documentLoader:r.documentLoader,base:r.base});a(A[0].document)&&"boolean"==typeof A[0].document["@propagate"]&&(n=A[0].document["@propagate"]);let S=e;n||S.previousContext||(S=S.clone(),S.previousContext=e);for(const n of A){let{document:o}=n;if(e=S,null===o){if(!u&&0!==Object.keys(e.protected).length)throw new i("Tried to nullify a context with protected terms outside of a term definition.","jsonld.SyntaxError",{code:"invalid context nullification"});S=e=b.getInitialContext(r).clone();continue}const m=n.getProcessed(e);if(m){if(w.eventHandler)for(const e of m.events)h({event:e,options:w});S=e=m.context;continue}if(a(o)&&"@context"in o&&(o=o["@context"]),!a(o))throw new i("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:o});S=S.clone();const g=new Map;if("@version"in o){if(1.1!==o["@version"])throw new i("Unsupported JSON-LD version: "+o["@version"],"jsonld.UnsupportedVersion",{code:"invalid @version value",context:o});if(e.processingMode&&"json-ld-1.0"===e.processingMode)throw new i("@version: "+o["@version"]+" not compatible with "+e.processingMode,"jsonld.ProcessingModeConflict",{code:"processing mode conflict",context:o});S.processingMode="json-ld-1.1",S["@version"]=o["@version"],g.set("@version",!0)}if(S.processingMode=S.processingMode||e.processingMode,"@base"in o){let e=o["@base"];if(null===e||c(e));else{if(!l(e))throw new i('Invalid JSON-LD syntax; the value of "@base" in a @context must be an absolute IRI, a relative IRI, or null.',"jsonld.SyntaxError",{code:"invalid base IRI",context:o});e=f(S["@base"],e)}S["@base"]=e,g.set("@base",!0)}if("@vocab"in o){const e=o["@vocab"];if(null===e)delete S["@vocab"];else{if(!s(e))throw new i('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:o});if(!c(e)&&b.processingMode(S,1))throw new i('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be an absolute IRI.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:o});{const t=v(S,e,{vocab:!0,base:!0},void 0,void 0,r);c(t)||r.eventHandler&&h({event:{type:["JsonLdEvent"],code:"relative @vocab reference",level:"warning",message:"Relative @vocab reference found.",details:{vocab:t}},options:r}),S["@vocab"]=t}}g.set("@vocab",!0)}if("@language"in o){const e=o["@language"];if(null===e)delete S["@language"];else{if(!s(e))throw new i('Invalid JSON-LD syntax; the value of "@language" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid default language",context:o});e.match(d)||r.eventHandler&&h({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e}},options:r}),S["@language"]=e.toLowerCase()}g.set("@language",!0)}if("@direction"in o){const t=o["@direction"];if("json-ld-1.0"===e.processingMode)throw new i("Invalid JSON-LD syntax; @direction not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context member",context:o});if(null===t)delete S["@direction"];else{if("ltr"!==t&&"rtl"!==t)throw new i('Invalid JSON-LD syntax; the value of "@direction" in a @context must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:o});S["@direction"]=t}g.set("@direction",!0)}if("@propagate"in o){const r=o["@propagate"];if("json-ld-1.0"===e.processingMode)throw new i("Invalid JSON-LD syntax; @propagate not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:o});if("boolean"!=typeof r)throw new i("Invalid JSON-LD syntax; @propagate value must be a boolean.","jsonld.SyntaxError",{code:"invalid @propagate value",context:t});g.set("@propagate",!0)}if("@import"in o){const n=o["@import"];if("json-ld-1.0"===e.processingMode)throw new i("Invalid JSON-LD syntax; @import not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:o});if(!s(n))throw new i("Invalid JSON-LD syntax; @import must be a string.","jsonld.SyntaxError",{code:"invalid @import value",context:t});const a=await r.contextResolver.resolve({activeCtx:e,context:n,documentLoader:r.documentLoader,base:r.base});if(1!==a.length)throw new i("Invalid JSON-LD syntax; @import must reference a single context.","jsonld.SyntaxError",{code:"invalid remote context",context:t});const u=a[0].getProcessed(e);if(u)o=u;else{const r=a[0].document;if("@import"in r)throw new i("Invalid JSON-LD syntax: imported context must not include @import.","jsonld.SyntaxError",{code:"invalid context entry",context:t});for(const e in r)o.hasOwnProperty(e)||(o[e]=r[e]);a[0].setProcessed(e,o)}g.set("@import",!0)}g.set("@protected",o["@protected"]||!1);for(const e in o)if(b.createTermDefinition({activeCtx:S,localCtx:o,term:e,defined:g,options:r,overrideProtected:u}),a(o[e])&&"@context"in o[e]){const t=o[e]["@context"];let n=!0;if(s(t)){const e=f(r.base,t);p.has(e)?n=!1:p.add(e)}if(n)try{await b.process({activeCtx:S.clone(),localCtx:o[e]["@context"],overrideProtected:!0,options:r,cycles:p})}catch(t){throw new i("Invalid JSON-LD syntax; invalid scoped context.","jsonld.SyntaxError",{code:"invalid scoped context",context:o[e]["@context"],term:e})}}n.setProcessed(e,{context:S,events:y})}return S},b.createTermDefinition=({activeCtx:e,localCtx:t,term:r,defined:n,options:u,overrideProtected:l=!1})=>{if(n.has(r)){if(n.get(r))return;throw new i("Cyclical context definition detected.","jsonld.CyclicalContext",{code:"cyclic IRI mapping",context:t,term:r})}let f;if(n.set(r,!1),t.hasOwnProperty(r)&&(f=t[r]),"@type"===r&&a(f)&&"@set"===(f["@container"]||"@set")&&b.processingMode(e,1.1)){const e=["@container","@id","@protected"],n=Object.keys(f);if(0===n.length||n.some((t=>!e.includes(t))))throw new i("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:r})}else{if(b.isKeyword(r))throw new i("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:r});if(r.match(p))return void(u.eventHandler&&h({event:{type:["JsonLdEvent"],code:"reserved term",level:"warning",message:'Terms beginning with "@" are reserved for future use and dropped.',details:{term:r}},options:u}));if(""===r)throw new i("Invalid JSON-LD syntax; a term cannot be an empty string.","jsonld.SyntaxError",{code:"invalid term definition",context:t})}const d=e.mappings.get(r);e.mappings.has(r)&&e.mappings.delete(r);let m=!1;if((s(f)||null===f)&&(m=!0,f={"@id":f}),!a(f))throw new i("Invalid JSON-LD syntax; @context term values must be strings or objects.","jsonld.SyntaxError",{code:"invalid term definition",context:t});const y={};e.mappings.set(r,y),y.reverse=!1;const g=["@container","@id","@language","@reverse","@type"];b.processingMode(e,1.1)&&g.push("@context","@direction","@index","@nest","@prefix","@protected");for(const e in f)if(!g.includes(e))throw new i("Invalid JSON-LD syntax; a term definition must not contain "+e,"jsonld.SyntaxError",{code:"invalid term definition",context:t});const A=r.indexOf(":");if(y._termHasColon=A>0,"@reverse"in f){if("@id"in f)throw new i("Invalid JSON-LD syntax; a @reverse term definition must not contain @id.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});if("@nest"in f)throw new i("Invalid JSON-LD syntax; a @reverse term definition must not contain @nest.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});const o=f["@reverse"];if(!s(o))throw new i("Invalid JSON-LD syntax; a @context @reverse value must be a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(o.match(p))return u.eventHandler&&h({event:{type:["JsonLdEvent"],code:"reserved @reverse value",level:"warning",message:'@reverse values beginning with "@" are reserved for future use and dropped.',details:{reverse:o}},options:u}),void(d?e.mappings.set(r,d):e.mappings.delete(r));const a=v(e,o,{vocab:!0,base:!1},t,n,u);if(!c(a))throw new i("Invalid JSON-LD syntax; a @context @reverse value must be an absolute IRI or a blank node identifier.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});y["@id"]=a,y.reverse=!0}else if("@id"in f){let o=f["@id"];if(o&&!s(o))throw new i("Invalid JSON-LD syntax; a @context @id value must be an array of strings or a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(null===o)y["@id"]=null;else{if(!b.isKeyword(o)&&o.match(p))return u.eventHandler&&h({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:'@id values beginning with "@" are reserved for future use and dropped.',details:{id:o}},options:u}),void(d?e.mappings.set(r,d):e.mappings.delete(r));if(o!==r){if(o=v(e,o,{vocab:!0,base:!1},t,n,u),!c(o)&&!b.isKeyword(o))throw new i("Invalid JSON-LD syntax; a @context @id value must be an absolute IRI, a blank node identifier, or a keyword.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(r.match(/(?::[^:])|\//)){if(v(e,r,{vocab:!0,base:!1},t,new Map(n).set(r,!0),u)!==o)throw new i("Invalid JSON-LD syntax; term in form of IRI must expand to definition.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t})}y["@id"]=o,y._prefix=m&&!y._termHasColon&&o.match(/[:\/\?#\[\]@]$/)}}}if(!("@id"in y))if(y._termHasColon){const i=r.substr(0,A);if(t.hasOwnProperty(i)&&b.createTermDefinition({activeCtx:e,localCtx:t,term:i,defined:n,options:u}),e.mappings.has(i)){const t=r.substr(A+1);y["@id"]=e.mappings.get(i)["@id"]+t}else y["@id"]=r}else if("@type"===r)y["@id"]=r;else{if(!("@vocab"in e))throw new i("Invalid JSON-LD syntax; @context terms must define an @id.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t,term:r});y["@id"]=e["@vocab"]+r}if((!0===f["@protected"]||!0===n.get("@protected")&&!1!==f["@protected"])&&(e.protected[r]=!0,y.protected=!0),n.set(r,!0),"@type"in f){let r=f["@type"];if(!s(r))throw new i("Invalid JSON-LD syntax; an @context @type value must be a string.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if("@json"===r||"@none"===r){if(b.processingMode(e,1))throw new i(`Invalid JSON-LD syntax; an @context @type value must not be "${r}" in JSON-LD 1.0 mode.`,"jsonld.SyntaxError",{code:"invalid type mapping",context:t})}else if("@id"!==r&&"@vocab"!==r){if(r=v(e,r,{vocab:!0,base:!1},t,n,u),!c(r))throw new i("Invalid JSON-LD syntax; an @context @type value must be an absolute IRI.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if(0===r.indexOf("_:"))throw new i("Invalid JSON-LD syntax; an @context @type value must be an IRI, not a blank node identifier.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}y["@type"]=r}if("@container"in f){const r=s(f["@container"])?[f["@container"]]:f["@container"]||[],n=["@list","@set","@index","@language"];let a=!0;const u=r.includes("@set");if(b.processingMode(e,1.1)){if(n.push("@graph","@id","@type"),r.includes("@list")){if(1!==r.length)throw new i("Invalid JSON-LD syntax; @context @container with @list must have no other values","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else if(r.includes("@graph")){if(r.some((e=>"@graph"!==e&&"@id"!==e&&"@index"!==e&&"@set"!==e)))throw new i("Invalid JSON-LD syntax; @context @container with @graph must have no other values other than @id, @index, and @set","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else a&=r.length<=(u?2:1);if(r.includes("@type")&&(y["@type"]=y["@type"]||"@id",!["@id","@vocab"].includes(y["@type"])))throw new i("Invalid JSON-LD syntax; container: @type requires @type to be @id or @vocab.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}else a&=!o(f["@container"]),a&=r.length<=1;if(a&=r.every((e=>n.includes(e))),a&=!(u&&r.includes("@list")),!a)throw new i("Invalid JSON-LD syntax; @context @container value must be one of the following: "+n.join(", "),"jsonld.SyntaxError",{code:"invalid container mapping",context:t});if(y.reverse&&!r.every((e=>["@index","@set"].includes(e))))throw new i("Invalid JSON-LD syntax; @context @container value for a @reverse type definition must be @index or @set.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});y["@container"]=r}if("@index"in f){if(!("@container"in f)||!y["@container"].includes("@index"))throw new i(`Invalid JSON-LD syntax; @index without @index in @container: "${f["@index"]}" on term "${r}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});if(!s(f["@index"])||0===f["@index"].indexOf("@"))throw new i(`Invalid JSON-LD syntax; @index must expand to an IRI: "${f["@index"]}" on term "${r}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});y["@index"]=f["@index"]}if("@context"in f&&(y["@context"]=f["@context"]),"@language"in f&&!("@type"in f)){let e=f["@language"];if(null!==e&&!s(e))throw new i("Invalid JSON-LD syntax; @context @language value must be a string or null.","jsonld.SyntaxError",{code:"invalid language mapping",context:t});null!==e&&(e=e.toLowerCase()),y["@language"]=e}if("@prefix"in f){if(r.match(/:|\//))throw new i("Invalid JSON-LD syntax; @context @prefix used on a compact IRI term","jsonld.SyntaxError",{code:"invalid term definition",context:t});if(b.isKeyword(y["@id"]))throw new i("Invalid JSON-LD syntax; keywords may not be used as prefixes","jsonld.SyntaxError",{code:"invalid term definition",context:t});if("boolean"!=typeof f["@prefix"])throw new i("Invalid JSON-LD syntax; @context value for @prefix must be boolean","jsonld.SyntaxError",{code:"invalid @prefix value",context:t});y._prefix=!0===f["@prefix"]}if("@direction"in f){const e=f["@direction"];if(null!==e&&"ltr"!==e&&"rtl"!==e)throw new i('Invalid JSON-LD syntax; @direction value must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:t});y["@direction"]=e}if("@nest"in f){const e=f["@nest"];if(!s(e)||"@nest"!==e&&0===e.indexOf("@"))throw new i("Invalid JSON-LD syntax; @context @nest value must be a string which is not a keyword other than @nest.","jsonld.SyntaxError",{code:"invalid @nest value",context:t});y["@nest"]=e}const S=y["@id"];if("@context"===S||"@preserve"===S)throw new i("Invalid JSON-LD syntax; @context and @preserve cannot be aliased.","jsonld.SyntaxError",{code:"invalid keyword alias",context:t});if(d&&d.protected&&!l&&(e.protected[r]=!0,y.protected=!0,!w(d,y)))throw new i("Invalid JSON-LD syntax; tried to redefine a protected term.","jsonld.SyntaxError",{code:"protected term redefinition",context:t,term:r})},b.expandIri=(e,t,r,n)=>v(e,t,r,void 0,void 0,n),b.getInitialContext=e=>{const t=JSON.stringify({processingMode:e.processingMode}),r=g.get(t);if(r)return r;const i={processingMode:e.processingMode,mappings:new Map,inverse:null,getInverse:function(){const e=this;if(e.inverse)return e.inverse;const t=e.inverse={},r=e.fastCurieMap={},n={},i=(e["@language"]||"@none").toLowerCase(),s=e["@direction"],u=e.mappings,c=[...u.keys()].sort(y);for(const e of c){const o=u.get(e);if(null===o)continue;let c=o["@container"]||"@none";if(c=[].concat(c).sort().join(""),null===o["@id"])continue;const l=m(o["@id"]);for(const u of l){let l=t[u];const f=b.isKeyword(u);if(l)f||o._termHasColon||n[u].push(e);else if(t[u]=l={},!f&&!o._termHasColon){n[u]=[e];const t={iri:u,terms:n[u]};u[0]in r?r[u[0]].push(t):r[u[0]]=[t]}if(l[c]||(l[c]={"@language":{},"@type":{},"@any":{}}),l=l[c],a(e,l["@any"],"@none"),o.reverse)a(e,l["@type"],"@reverse");else if("@none"===o["@type"])a(e,l["@any"],"@none"),a(e,l["@language"],"@none"),a(e,l["@type"],"@none");else if("@type"in o)a(e,l["@type"],o["@type"]);else if("@language"in o&&"@direction"in o){const t=o["@language"],r=o["@direction"];a(e,l["@language"],t&&r?`${t}_${r}`.toLowerCase():t?t.toLowerCase():r?`_${r}`:"@null")}else"@language"in o?a(e,l["@language"],(o["@language"]||"@null").toLowerCase()):"@direction"in o?o["@direction"]?a(e,l["@language"],`_${o["@direction"]}`):a(e,l["@language"],"@none"):s?(a(e,l["@language"],`_${s}`),a(e,l["@language"],"@none"),a(e,l["@type"],"@none")):(a(e,l["@language"],i),a(e,l["@language"],"@none"),a(e,l["@type"],"@none"))}}for(const e in r)o(r,e,1);return t},clone:function(){const e={};e.mappings=n.clone(this.mappings),e.clone=this.clone,e.inverse=null,e.getInverse=this.getInverse,e.protected=n.clone(this.protected),this.previousContext&&(e.previousContext=this.previousContext.clone());e.revertToPreviousContext=this.revertToPreviousContext,"@base"in this&&(e["@base"]=this["@base"]);"@language"in this&&(e["@language"]=this["@language"]);"@vocab"in this&&(e["@vocab"]=this["@vocab"]);return e},revertToPreviousContext:function(){if(!this.previousContext)return this;return this.previousContext.clone()},protected:{}};return 1e4===g.size&&g.clear(),g.set(t,i),i;function o(e,t,r){const n=e[t],i=e[t]={};let a,s;for(const e of n)a=e.iri,s=r>=a.length?"":a[r],s in i?i[s].push(e):i[s]=[e];for(const e in i)""!==e&&o(i,e,r+1)}function a(e,t,r){t.hasOwnProperty(r)||(t[r]=e)}},b.getContextValue=(e,t,r)=>{if(null===t){if("@context"===r)return;return null}if(e.mappings.has(t)){const n=e.mappings.get(t);if(u(r))return n;if(n.hasOwnProperty(r))return n[r]}return"@language"===r&&r in e||"@direction"===r&&r in e?e[r]:"@context"!==r?null:void 0},b.processingMode=(e,t)=>t.toString()>="1.1"?!e.processingMode||e.processingMode>="json-ld-"+t.toString():"json-ld-1.0"===e.processingMode,b.isKeyword=e=>{if(!s(e)||"@"!==e[0])return!1;switch(e){case"@base":case"@container":case"@context":case"@default":case"@direction":case"@embed":case"@explicit":case"@graph":case"@id":case"@included":case"@index":case"@json":case"@language":case"@list":case"@nest":case"@none":case"@omitDefault":case"@prefix":case"@preserve":case"@protected":case"@requireAll":case"@reverse":case"@set":case"@type":case"@value":case"@version":case"@vocab":return!0}return!1}},8831:(e,t,r)=>{"use strict";const{parseLinkHeader:n,buildHeaders:i}=r(51055),{LINK_HEADER_CONTEXT:o}=r(93770),a=r(54093),s=r(40533),{prependBase:u}=r(82278),c=/(^|(\r\n))link:/i;e.exports=({secure:e,headers:t={},xhr:r}={headers:{}})=>{t=i(t);return(new s).wrapLoader((async function i(s){if(0!==s.indexOf("http:")&&0!==s.indexOf("https:"))throw new a('URL could not be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:s});if(e&&0!==s.indexOf("https"))throw new a('URL could not be dereferenced; secure mode is enabled and the URL\'s scheme is not "https".',"jsonld.InvalidUrl",{code:"loading document failed",url:s});let l;try{l=await function(e,t,r){const n=new(e=e||XMLHttpRequest);return new Promise(((e,i)=>{n.onload=()=>e(n),n.onerror=e=>i(e),n.open("GET",t,!0);for(const e in r)n.setRequestHeader(e,r[e]);n.send()}))}(r,s,t)}catch(e){throw new a("URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:s,cause:e})}if(l.status>=400)throw new a("URL could not be dereferenced: "+l.statusText,"jsonld.LoadDocumentError",{code:"loading document failed",url:s,httpStatusCode:l.status});let f={contextUrl:null,documentUrl:s,document:l.response},h=null;const d=l.getResponseHeader("Content-Type");let p;c.test(l.getAllResponseHeaders())&&(p=l.getResponseHeader("Link"));if(p&&"application/ld+json"!==d){const e=n(p),t=e[o];if(Array.isArray(t))throw new a("URL could not be dereferenced, it has more than one associated HTTP Link Header.","jsonld.InvalidUrl",{code:"multiple context link headers",url:s});t&&(f.contextUrl=t.target),h=e.alternate,h&&"application/ld+json"==h.type&&!(d||"").match(/^application\/(\w*\+)?json$/)&&(f=await i(u(s,h.target)))}return f}))}},91696:(e,t,r)=>{"use strict";const n=r(54093),{isArray:i}=r(30832),{asArray:o}=r(51055),a={};function s({event:e,handlers:t}){let r=!0;for(let o=0;r&&o{r=!0}});else{if("object"!=typeof a)throw new n("Invalid event handler.","jsonld.InvalidEventHandler",{event:e});e.code in a?a[e.code]({event:e,next:()=>{r=!0}}):r=!0}}return r}e.exports=a,a.defaultEventHandler=null,a.setupEventHandler=({options:e={}})=>{const t=[].concat(e.safe?a.safeEventHandler:[],e.eventHandler?o(e.eventHandler):[],a.defaultEventHandler?a.defaultEventHandler:[]);return 0===t.length?null:t},a.handleEvent=({event:e,options:t})=>{s({event:e,handlers:t.eventHandler})};const u=new Set(["empty object","free-floating scalar","invalid @language value","invalid property","null @id value","null @value value","object with only @id","object with only @language","object with only @list","object with only @value","relative @id reference","relative @type reference","relative @vocab reference","reserved @id value","reserved @reverse value","reserved term","blank node predicate","relative graph reference","relative object reference","relative predicate reference","relative subject reference"]);a.safeEventHandler=function({event:e,next:t}){if("warning"===e.level&&u.has(e.code))throw new n("Safe mode validation error.","jsonld.ValidationError",{event:e});t()},a.logEventHandler=function({event:e,next:t}){console.log(`EVENT: ${e.message}`,{event:e}),t()},a.logWarningEventHandler=function({event:e,next:t}){"warning"===e.level&&console.warn(`WARNING: ${e.message}`,{event:e}),t()},a.unhandledEventHandler=function({event:e}){throw new n("No handler for event.","jsonld.UnhandledEvent",{event:e})},a.setDefaultEventHandler=function({eventHandler:e}={}){a.defaultEventHandler=e?o(e):null}},62759:(e,t,r)=>{"use strict";const n=r(54093),{isArray:i,isObject:o,isEmptyObject:a,isString:s,isUndefined:u}=r(30832),{isList:c,isValue:l,isGraph:f,isSubject:h}=r(18463),{expandIri:d,getContextValue:p,isKeyword:m,process:y,processingMode:g}=r(54131),{isAbsolute:b}=r(82278),{REGEX_BCP47:v,REGEX_KEYWORD:w,addValue:A,asArray:S,getValues:k,validateTypeValue:E}=r(51055),{handleEvent:_}=r(91696),M={};async function T({activeCtx:e,activeProperty:t,expandedActiveProperty:r,element:f,expandedParent:w,options:k={},insideList:x,typeKey:O,typeScopedContext:R}){const C=Object.keys(f).sort(),B=[];let N;const L=f[O]&&"@json"===d(e,i(f[O])?f[O][0]:f[O],{vocab:!0},{...k,typeExpansion:!0});for(const T of C){let x,O=f[T];if("@context"===T)continue;const C=d(e,T,{vocab:!0},k);if(null===C||!b(C)&&!m(C)){k.eventHandler&&_({event:{type:["JsonLdEvent"],code:"invalid property",level:"warning",message:"Dropping property that did not expand into an absolute IRI or keyword.",details:{property:T,expandedProperty:C}},options:k});continue}if(m(C)){if("@reverse"===r)throw new n("Invalid JSON-LD syntax; a keyword cannot be used as a @reverse property.","jsonld.SyntaxError",{code:"invalid reverse property map",value:O});if(C in w&&"@included"!==C&&"@type"!==C)throw new n("Invalid JSON-LD syntax; colliding keywords detected.","jsonld.SyntaxError",{code:"colliding keywords",keyword:C})}if("@id"===C){if(!s(O)){if(!k.isFrame)throw new n('Invalid JSON-LD syntax; "@id" value must a string.',"jsonld.SyntaxError",{code:"invalid @id value",value:O});if(o(O)){if(!a(O))throw new n('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:O})}else{if(!i(O))throw new n('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:O});if(!O.every((e=>s(e))))throw new n('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:O})}}A(w,"@id",S(O).map((t=>{if(s(t)){const r=d(e,t,{base:!0},k);return k.eventHandler&&(null===r?_(null===t?{event:{type:["JsonLdEvent"],code:"null @id value",level:"warning",message:"Null @id found.",details:{id:t}},options:k}:{event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:t}},options:k}):b(r)||_({event:{type:["JsonLdEvent"],code:"relative @id reference",level:"warning",message:"Relative @id reference found.",details:{id:t,expandedId:r}},options:k})),r}return t})),{propertyIsArray:k.isFrame});continue}if("@type"===C){o(O)&&(O=Object.fromEntries(Object.entries(O).map((([e,t])=>[d(R,e,{vocab:!0}),S(t).map((e=>d(R,e,{base:!0,vocab:!0},{...k,typeExpansion:!0})))])))),E(O,k.isFrame),A(w,"@type",S(O).map((e=>{if(s(e)){const t=d(R,e,{base:!0,vocab:!0},{...k,typeExpansion:!0});return b(t)||k.eventHandler&&_({event:{type:["JsonLdEvent"],code:"relative @type reference",level:"warning",message:"Relative @type reference found.",details:{type:e}},options:k}),t}return e})),{propertyIsArray:k.isFrame});continue}if("@included"===C&&g(e,1.1)){const r=S(await M.expand({activeCtx:e,activeProperty:t,element:O,options:k}));if(!r.every((e=>h(e))))throw new n("Invalid JSON-LD syntax; values of @included must expand to node objects.","jsonld.SyntaxError",{code:"invalid @included value",value:O});A(w,"@included",r,{propertyIsArray:!0});continue}if("@graph"===C&&!o(O)&&!i(O))throw new n('Invalid JSON-LD syntax; "@graph" value must not be an object or an array.',"jsonld.SyntaxError",{code:"invalid @graph value",value:O});if("@value"===C){N=O,L&&g(e,1.1)?w["@value"]=O:A(w,"@value",O,{propertyIsArray:k.isFrame});continue}if("@language"===C){if(null===O)continue;if(!s(O)&&!k.isFrame)throw new n('Invalid JSON-LD syntax; "@language" value must be a string.',"jsonld.SyntaxError",{code:"invalid language-tagged string",value:O});O=S(O).map((e=>s(e)?e.toLowerCase():e));for(const e of O)s(e)&&!e.match(v)&&k.eventHandler&&_({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e}},options:k});A(w,"@language",O,{propertyIsArray:k.isFrame});continue}if("@direction"===C){if(!s(O)&&!k.isFrame)throw new n('Invalid JSON-LD syntax; "@direction" value must be a string.',"jsonld.SyntaxError",{code:"invalid base direction",value:O});O=S(O);for(const e of O)if(s(e)&&"ltr"!==e&&"rtl"!==e)throw new n('Invalid JSON-LD syntax; "@direction" must be "ltr" or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",value:O});A(w,"@direction",O,{propertyIsArray:k.isFrame});continue}if("@index"===C){if(!s(O))throw new n('Invalid JSON-LD syntax; "@index" value must be a string.',"jsonld.SyntaxError",{code:"invalid @index value",value:O});A(w,"@index",O);continue}if("@reverse"===C){if(!o(O))throw new n('Invalid JSON-LD syntax; "@reverse" value must be an object.',"jsonld.SyntaxError",{code:"invalid @reverse value",value:O});if(x=await M.expand({activeCtx:e,activeProperty:"@reverse",element:O,options:k}),"@reverse"in x)for(const e in x["@reverse"])A(w,e,x["@reverse"][e],{propertyIsArray:!0});let t=w["@reverse"]||null;for(const e in x){if("@reverse"===e)continue;null===t&&(t=w["@reverse"]={}),A(t,e,[],{propertyIsArray:!0});const r=x[e];for(let i=0;i"@id"===e||"@index"===e))&&(x=S(x).map((e=>({"@graph":S(e)})))),U.mappings.has(T)&&U.mappings.get(T).reverse){const e=w["@reverse"]=w["@reverse"]||{};x=S(x);for(let t=0;t"@value"===d(e,t,{vocab:!0},k))))throw new n("Invalid JSON-LD syntax; nested value must be a node object.","jsonld.SyntaxError",{code:"invalid @nest value",value:i});await T({activeCtx:e,activeProperty:t,expandedActiveProperty:r,element:i,expandedParent:w,options:k,insideList:x,typeScopedContext:R,typeKey:O})}}}function x({activeCtx:e,activeProperty:t,value:r,options:n}){if(null==r)return null;const i=d(e,t,{vocab:!0},n);if("@id"===i)return d(e,r,{base:!0},n);if("@type"===i)return d(e,r,{vocab:!0,base:!0},{...n,typeExpansion:!0});const o=p(e,t,"@type");if(("@id"===o||"@graph"===i)&&s(r)){const i=d(e,r,{base:!0},n);return null===i&&r.match(w)&&n.eventHandler&&_({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:t}},options:n}),{"@id":i}}if("@vocab"===o&&s(r))return{"@id":d(e,r,{vocab:!0,base:!0},n)};if(m(i))return r;const a={};if(o&&!["@id","@vocab","@none"].includes(o))a["@type"]=o;else if(s(r)){const r=p(e,t,"@language");null!==r&&(a["@language"]=r);const n=p(e,t,"@direction");null!==n&&(a["@direction"]=n)}return["boolean","number","string"].includes(typeof r)||(r=r.toString()),a["@value"]=r,a}function P(e,t,r,o){const a=[],u=Object.keys(t).sort();for(const c of u){const u=d(e,c,{vocab:!0},o);let l=t[c];i(l)||(l=[l]);for(const e of l){if(null===e)continue;if(!s(e))throw new n("Invalid JSON-LD syntax; language map values must be strings.","jsonld.SyntaxError",{code:"invalid language map value",languageMap:t});const i={"@value":e};"@none"!==u&&(c.match(v)||o.eventHandler&&_({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:c}},options:o}),i["@language"]=c.toLowerCase()),r&&(i["@direction"]=r),a.push(i)}}return a}async function I({activeCtx:e,options:t,activeProperty:r,value:o,asGraph:a,indexKey:s,propertyIndex:c}){const h=[],m=Object.keys(o).sort(),g="@type"===s;for(let b of m){if(g){const r=p(e,b,"@context");u(r)||(e=await y({activeCtx:e,localCtx:r,propagate:!1,options:t}))}let m,v=o[b];i(v)||(v=[v]),v=await M.expand({activeCtx:e,activeProperty:r,element:v,options:t,insideList:!1,insideIndex:!0}),m=c?"@none"===b?"@none":x({activeCtx:e,activeProperty:s,value:b,options:t}):d(e,b,{vocab:!0},t),"@id"===s?b=d(e,b,{base:!0},t):g&&(b=m);for(let e of v){if(a&&!f(e)&&(e={"@graph":[e]}),"@type"===s)"@none"===m||(e["@type"]?e["@type"]=[b].concat(e["@type"]):e["@type"]=[b]);else{if(l(e)&&!["@language","@type","@index"].includes(s))throw new n(`Invalid JSON-LD syntax; Attempt to add illegal key to value object: "${s}".`,"jsonld.SyntaxError",{code:"invalid value object",value:e});c?"@none"!==m&&A(e,c,m,{propertyIsArray:!0,prependValue:!0}):"@none"===m||s in e||(e[s]=b)}h.push(e)}}return h}e.exports=M,M.expand=async({activeCtx:e,activeProperty:t=null,element:r,options:c={},insideList:l=!1,insideIndex:f=!1,typeScopedContext:h=null})=>{if(null==r)return null;if("@default"===t&&(c=Object.assign({},c,{isFrame:!1})),!i(r)&&!o(r))return l||null!==t&&"@graph"!==d(e,t,{vocab:!0},c)?x({activeCtx:e,activeProperty:t,value:r,options:c}):(c.eventHandler&&_({event:{type:["JsonLdEvent"],code:"free-floating scalar",level:"warning",message:"Dropping free-floating scalar not in a list.",details:{value:r}},options:c}),null);if(i(r)){let n=[];const o=p(e,t,"@container")||[];l=l||o.includes("@list");for(let o=0;o1?n.slice().sort():n:[n];for(const t of i){const r=p(h,t,"@context");u(r)||(e=await y({activeCtx:e,localCtx:r,options:c,propagate:!1}))}}}let P={};await T({activeCtx:e,activeProperty:t,expandedActiveProperty:m,element:r,expandedParent:P,options:c,insideList:l,typeKey:E,typeScopedContext:h}),w=Object.keys(P);let I=w.length;if("@value"in P){if("@type"in P&&("@language"in P||"@direction"in P))throw new n('Invalid JSON-LD syntax; an element containing "@value" may not contain both "@type" and either "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:P});let t=I-1;if("@type"in P&&(t-=1),"@index"in P&&(t-=1),"@language"in P&&(t-=1),"@direction"in P&&(t-=1),0!==t)throw new n('Invalid JSON-LD syntax; an element containing "@value" may only have an "@index" property and either "@type" or either or both "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:P});const r=null===P["@value"]?[]:S(P["@value"]),i=k(P,"@type");if(g(e,1.1)&&i.includes("@json")&&1===i.length);else if(0===r.length)c.eventHandler&&_({event:{type:["JsonLdEvent"],code:"null @value value",level:"warning",message:"Dropping null @value value.",details:{value:P}},options:c}),P=null;else{if(!r.every((e=>s(e)||a(e)))&&"@language"in P)throw new n("Invalid JSON-LD syntax; only strings may be language-tagged.","jsonld.SyntaxError",{code:"invalid language-tagged value",element:P});if(!i.every((e=>b(e)&&!(s(e)&&0===e.indexOf("_:"))||a(e))))throw new n('Invalid JSON-LD syntax; an element containing "@value" and "@type" must have an absolute IRI for the value of "@type".',"jsonld.SyntaxError",{code:"invalid typed value",element:P})}}else if("@type"in P&&!i(P["@type"]))P["@type"]=[P["@type"]];else if("@set"in P||"@list"in P){if(I>1&&(2!==I||!("@index"in P)))throw new n('Invalid JSON-LD syntax; if an element has the property "@set" or "@list", then it can have at most one other property that is "@index".',"jsonld.SyntaxError",{code:"invalid set or list object",element:P});"@set"in P&&(P=P["@set"],w=Object.keys(P),I=w.length)}else 1===I&&"@language"in P&&(c.eventHandler&&_({event:{type:["JsonLdEvent"],code:"object with only @language",level:"warning",message:"Dropping object with only @language.",details:{value:P}},options:c}),P=null);if(o(P)&&!c.keepFreeFloatingNodes&&!l&&(null===t||"@graph"===m)&&(0===I||"@value"in P||"@list"in P||1===I&&"@id"in P)){if(c.eventHandler){let e,t;0===I?(e="empty object",t="Dropping empty object."):"@value"in P?(e="object with only @value",t="Dropping object with only @value."):"@list"in P?(e="object with only @list",t="Dropping object with only @list."):1===I&&"@id"in P&&(e="object with only @id",t="Dropping object with only @id."),_({event:{type:["JsonLdEvent"],code:e,level:"warning",message:t,details:{value:P}},options:c})}P=null}return P}},41565:(e,t,r)=>{"use strict";const{isSubjectReference:n}=r(18463),{createMergedNodeMap:i}=r(32664),o={};e.exports=o,o.flatten=e=>{const t=i(e),r=[],o=Object.keys(t).sort();for(let e=0;e{"use strict";const{isKeyword:n}=r(54131),i=r(18463),o=r(30832),a=r(51055),s=r(82278),u=r(54093),{createNodeMap:c,mergeNodeMapGraphs:l}=r(32664),f={};function h(e){const t={};for(const r in e)void 0!==e[r]&&(t["@"+r]=[e[r]]);return[t]}function d(e,t,r){for(let n=r.length-1;n>=0;--n){const i=r[n];if(i.graph===t&&i.subject["@id"]===e["@id"])return!0}return!1}function p(e,t,r){const n="@"+r;let i=n in e?e[n][0]:t[r];if("embed"===r)if(!0===i)i="@once";else if(!1===i)i="@never";else if("@always"!==i&&"@never"!==i&&"@link"!==i&&"@first"!==i&&"@last"!==i&&"@once"!==i)throw new u("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:e});return i}function m(e){if(!o.isArray(e)||1!==e.length||!o.isObject(e[0]))throw new u("Invalid JSON-LD syntax; a JSON-LD frame must be a single object.","jsonld.SyntaxError",{frame:e});if("@id"in e[0])for(const t of a.asArray(e[0]["@id"]))if(!o.isObject(t)&&!s.isAbsolute(t)||o.isString(t)&&0===t.indexOf("_:"))throw new u("Invalid JSON-LD syntax; invalid @id in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e});if("@type"in e[0])for(const t of a.asArray(e[0]["@type"]))if(!o.isObject(t)&&!s.isAbsolute(t)||o.isString(t)&&0===t.indexOf("_:"))throw new u("Invalid JSON-LD syntax; invalid @type in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e})}function y(e,t,r,s){let u=!0,c=!1;for(const l in r){let f=!1;const h=a.getValues(t,l),d=0===a.getValues(r,l).length;if("@id"===l){if(o.isEmptyObject(r["@id"][0]||{})?f=!0:r["@id"].length>=0&&(f=r["@id"].includes(h[0])),!s.requireAll)return f}else if("@type"===l){if(u=!1,d){if(h.length>0)return!1;f=!0}else if(1===r["@type"].length&&o.isEmptyObject(r["@type"][0]))f=h.length>0;else for(const e of r["@type"])f=!(!o.isObject(e)||!("@default"in e))||(f||h.some((t=>t===e)));if(!s.requireAll)return f}else{if(n(l))continue;{const t=a.getValues(r,l)[0];let n=!1;if(t&&(m([t]),n="@default"in t),u=!1,0===h.length&&n)continue;if(h.length>0&&d)return!1;if(void 0===t){if(h.length>0)return!1;f=!0}else if(i.isList(t)){const r=t["@list"][0];if(i.isList(h[0])){const t=h[0]["@list"];i.isValue(r)?f=t.some((e=>A(r,e))):(i.isSubject(r)||i.isSubjectReference(r))&&(f=t.some((t=>w(e,r,t,s))))}}else f=i.isValue(t)?h.some((e=>A(t,e))):i.isSubjectReference(t)?h.some((r=>w(e,t,r,s))):!!o.isObject(t)&&h.length>0}}if(!f&&s.requireAll)return!1;c=c||f}return u||c}function g(e,t){const r=e.uniqueEmbeds[e.graph],n=r[t],i=n.parent,s=n.property,u={"@id":t};if(o.isArray(i)){for(let e=0;e{const t=Object.keys(r);for(const n of t)n in r&&o.isObject(r[n].parent)&&r[n].parent["@id"]===e&&(delete r[n],c(n))};c(t)}function b(e,t){if(o.isArray(e))return e.map((e=>b(e,t)));if(o.isObject(e)){if("@preserve"in e)return e["@preserve"][0];if(i.isValue(e))return e;if(i.isList(e))return e["@list"]=b(e["@list"],t),e;if("@id"in e){const r=e["@id"];if(t.link.hasOwnProperty(r)){const n=t.link[r].indexOf(e);if(-1!==n)return t.link[r][n];t.link[r].push(e)}else t.link[r]=[e]}for(const r in e)"@id"===r&&t.bnodesToClear.includes(e[r])?delete e["@id"]:e[r]=b(e[r],t)}return e}function v(e,t,r){o.isObject(e)?a.addValue(e,t,r,{propertyIsArray:!0}):e.push(r)}function w(e,t,r,n){if(!("@id"in r))return!1;const i=e.subjects[r["@id"]];return i&&y(e,i,t,n)}function A(e,t){const r=t["@value"],n=t["@type"],i=t["@language"],a=e["@value"]?o.isArray(e["@value"])?e["@value"]:[e["@value"]]:[],s=e["@type"]?o.isArray(e["@type"])?e["@type"]:[e["@type"]]:[],u=e["@language"]?o.isArray(e["@language"])?e["@language"]:[e["@language"]]:[];return 0===a.length&&0===s.length&&0===u.length||!(!a.includes(r)&&!o.isEmptyObject(a[0]))&&(!!(!n&&0===s.length||s.includes(n)||n&&o.isEmptyObject(s[0]))&&!!(!i&&0===u.length||u.includes(i)||i&&o.isEmptyObject(u[0])))}e.exports=f,f.frameMergedOrDefault=(e,t,r)=>{const n={options:r,embedded:!1,graph:"@default",graphMap:{"@default":{}},subjectStack:[],link:{},bnodeMap:{}},i=new a.IdentifierIssuer("_:b");c(e,n.graphMap,"@default",i),r.merged&&(n.graphMap["@merged"]=l(n.graphMap),n.graph="@merged"),n.subjects=n.graphMap[n.graph];const o=[];return f.frame(n,Object.keys(n.subjects).sort(),t,o),r.pruneBlankNodeIdentifiers&&(r.bnodesToClear=Object.keys(n.bnodeMap).filter((e=>1===n.bnodeMap[e].length))),r.link={},b(o,r)},f.frame=(e,t,r,s,c=null)=>{m(r),r=r[0];const l=e.options,b={embed:p(r,l,"embed"),explicit:p(r,l,"explicit"),requireAll:p(r,l,"requireAll")};e.link.hasOwnProperty(e.graph)||(e.link[e.graph]={});const w=e.link[e.graph],S=function(e,t,r,n){const i={};for(const o of t){const t=e.graphMap[e.graph][o];y(e,t,r,n)&&(i[o]=t)}return i}(e,t,r,b),k=Object.keys(S).sort();for(const m of k){const y=S[m];if(null===c?e.uniqueEmbeds={[e.graph]:{}}:e.uniqueEmbeds[e.graph]=e.uniqueEmbeds[e.graph]||{},"@link"===b.embed&&m in w){v(s,c,w[m]);continue}const k={"@id":m};if(0===m.indexOf("_:")&&a.addValue(e.bnodeMap,m,k,{propertyIsArray:!0}),w[m]=k,("@first"===b.embed||"@last"===b.embed)&&e.is11)throw new u("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:r});if(e.embedded||!e.uniqueEmbeds[e.graph].hasOwnProperty(m))if(!e.embedded||"@never"!==b.embed&&!d(y,e.graph,e.subjectStack))if(!e.embedded||"@first"!=b.embed&&"@once"!=b.embed||!e.uniqueEmbeds[e.graph].hasOwnProperty(m)){if("@last"===b.embed&&m in e.uniqueEmbeds[e.graph]&&g(e,m),e.uniqueEmbeds[e.graph][m]={parent:s,property:c},e.subjectStack.push({subject:y,graph:e.graph}),m in e.graphMap){let t=!1,n=null;"@graph"in r?(n=r["@graph"][0],t=!("@merged"===m||"@default"===m),o.isObject(n)||(n={})):(t="@merged"!==e.graph,n={}),t&&f.frame({...e,graph:m,embedded:!1},Object.keys(e.graphMap[m]).sort(),[n],k,"@graph")}"@included"in r&&f.frame({...e,embedded:!1},t,r["@included"],k,"@included");for(const t of Object.keys(y).sort())if(n(t)){if(k[t]=a.clone(y[t]),"@type"===t)for(const t of y["@type"])0===t.indexOf("_:")&&a.addValue(e.bnodeMap,t,k,{propertyIsArray:!0})}else if(!b.explicit||t in r)for(const n of y[t]){const o=t in r?r[t]:h(b);if(i.isList(n)){const o=r[t]&&r[t][0]&&r[t][0]["@list"]?r[t][0]["@list"]:h(b),s={"@list":[]};v(k,t,s);const u=n["@list"];for(const t of u)i.isSubjectReference(t)?f.frame({...e,embedded:!0},[t["@id"]],o,s,"@list"):v(s,"@list",a.clone(t))}else i.isSubjectReference(n)?f.frame({...e,embedded:!0},[n["@id"]],o,k,t):A(o[0],n)&&v(k,t,a.clone(n))}for(const e of Object.keys(r).sort()){if("@type"===e){if(!o.isObject(r[e][0])||!("@default"in r[e][0]))continue}else if(n(e))continue;const t=r[e][0]||{};if(!p(t,l,"omitDefault")&&!(e in k)){let r="@null";"@default"in t&&(r=a.clone(t["@default"])),o.isArray(r)||(r=[r]),k[e]=[{"@preserve":r}]}}for(const t of Object.keys(r["@reverse"]||{}).sort()){const n=r["@reverse"][t];for(const r of Object.keys(e.subjects)){a.getValues(e.subjects[r],t).some((e=>e["@id"]===m))&&(k["@reverse"]=k["@reverse"]||{},a.addValue(k["@reverse"],t,[],{propertyIsArray:!0}),f.frame({...e,embedded:!0},[r],n,k["@reverse"][t],c))}}v(s,c,k),e.subjectStack.pop()}else v(s,c,k);else v(s,c,k)}},f.cleanupNull=(e,t)=>{if(o.isArray(e)){return e.map((e=>f.cleanupNull(e,t))).filter((e=>e))}if("@null"===e)return null;if(o.isObject(e)){if("@id"in e){const r=e["@id"];if(t.link.hasOwnProperty(r)){const n=t.link[r].indexOf(e);if(-1!==n)return t.link[r][n];t.link[r].push(e)}else t.link[r]=[e]}for(const r in e)e[r]=f.cleanupNull(e[r],t)}return e}},25076:(e,t,r)=>{"use strict";const n=r(54093),i=r(18463),o=r(30832),{REGEX_BCP47:a,addValue:s}=r(51055),{handleEvent:u}=r(91696),{RDF_LIST:c,RDF_FIRST:l,RDF_REST:f,RDF_NIL:h,RDF_TYPE:d,RDF_JSON_LITERAL:p,XSD_BOOLEAN:m,XSD_DOUBLE:y,XSD_INTEGER:g,XSD_STRING:b}=r(93770),v={};function w(e,t,r,i){if(e.termType.endsWith("Node"))return{"@id":e.value};const s={"@value":e.value};if(e.language)e.language.match(a)||i.eventHandler&&u({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e.language}},options:i}),s["@language"]=e.language;else{let c=e.datatype.value;if(c||(c=b),c===p){c="@json";try{s["@value"]=JSON.parse(s["@value"])}catch(e){throw new n("JSON literal could not be parsed.","jsonld.InvalidJsonLiteral",{code:"invalid JSON literal",value:s["@value"],cause:e})}}if(t){if(c===m)"true"===s["@value"]?s["@value"]=!0:"false"===s["@value"]&&(s["@value"]=!1);else if(o.isNumeric(s["@value"]))if(c===g){const e=parseInt(s["@value"],10);e.toFixed(0)===s["@value"]&&(s["@value"]=e)}else c===y&&(s["@value"]=parseFloat(s["@value"]));[m,g,y,b].includes(c)||(s["@type"]=c)}else if("i18n-datatype"===r&&c.startsWith("https://www.w3.org/ns/i18n#")){const[,e,t]=c.split(/[#_]/);e.length>0&&(s["@language"]=e,e.match(a)||i.eventHandler&&u({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e}},options:i})),s["@direction"]=t}else c!==b&&(s["@type"]=c)}return s}e.exports=v,v.fromRDF=async(e,t)=>{const r={},n={"@default":r},a={},{useRdfType:u=!1,useNativeTypes:p=!1,rdfDirection:m=null}=t;for(const i of e){const e="DefaultGraph"===i.graph.termType?"@default":i.graph.value;e in n||(n[e]={}),"@default"===e||e in r||(r[e]={"@id":e});const o=n[e],c=i.subject.value,l=i.predicate.value,f=i.object;c in o||(o[c]={"@id":c});const y=o[c],g=f.termType.endsWith("Node");if(g&&!(f.value in o)&&(o[f.value]={"@id":f.value}),l===d&&!u&&g){s(y,"@type",f.value,{propertyIsArray:!0});continue}const b=w(f,p,m,t);if(s(y,l,b,{propertyIsArray:!0}),g)if(f.value===h){const e=o[f.value];"usages"in e||(e.usages=[]),e.usages.push({node:y,property:l,value:b})}else f.value in a?a[f.value]=!1:a[f.value]={node:y,property:l,value:b}}for(const e in n){const t=n[e];if(!(h in t))continue;const r=t[h];if(r.usages){for(let e of r.usages){let r=e.node,n=e.property,s=e.value;const u=[],h=[];let d=Object.keys(r).length;for(;n===f&&o.isObject(a[r["@id"]])&&o.isArray(r[l])&&1===r[l].length&&o.isArray(r[f])&&1===r[f].length&&(3===d||4===d&&o.isArray(r["@type"])&&1===r["@type"].length&&r["@type"][0]===c)&&(u.push(r[l][0]),h.push(r["@id"]),e=a[r["@id"]],r=e.node,n=e.property,s=e.value,d=Object.keys(r).length,i.isBlankNode(r)););delete s["@id"],s["@list"]=u.reverse();for(const e of h)delete t[e]}delete r.usages}}const y=[],g=Object.keys(r).sort();for(const e of g){const t=r[e];if(e in n){const r=t["@graph"]=[],o=n[e],a=Object.keys(o).sort();for(const e of a){const t=o[e];i.isSubjectReference(t)||r.push(t)}}i.isSubjectReference(t)||y.push(t)}return y}},18463:(e,t,r)=>{"use strict";const n=r(30832),i={};e.exports=i,i.isSubject=e=>{if(n.isObject(e)&&!("@value"in e||"@set"in e||"@list"in e)){return Object.keys(e).length>1||!("@id"in e)}return!1},i.isSubjectReference=e=>n.isObject(e)&&1===Object.keys(e).length&&"@id"in e,i.isValue=e=>n.isObject(e)&&"@value"in e,i.isList=e=>n.isObject(e)&&"@list"in e,i.isGraph=e=>n.isObject(e)&&"@graph"in e&&1===Object.keys(e).filter((e=>"@id"!==e&&"@index"!==e)).length,i.isSimpleGraph=e=>i.isGraph(e)&&!("@id"in e),i.isBlankNode=e=>{if(n.isObject(e)){if("@id"in e){const t=e["@id"];return!n.isString(t)||0===t.indexOf("_:")}return 0===Object.keys(e).length||!("@value"in e||"@set"in e||"@list"in e)}return!1}},36805:(e,t,r)=>{const n=r(47055),i=r(67222),o=r(51055),a=r(68058),s=o.IdentifierIssuer,u=r(54093),c=r(39593),l=r(69048),{expand:f}=r(62759),{flatten:h}=r(41565),{fromRDF:d}=r(25076),{toRDF:p}=r(19382),{frameMergedOrDefault:m,cleanupNull:y}=r(63859),{isArray:g,isObject:b,isString:v}=r(30832),{isSubjectReference:w}=r(18463),{expandIri:A,getInitialContext:S,process:k,processingMode:E}=r(54131),{compact:_,compactIri:M}=r(83251),{createNodeMap:T,createMergedNodeMap:x,mergeNodeMaps:P}=r(32664),{logEventHandler:I,logWarningEventHandler:O,safeEventHandler:R,setDefaultEventHandler:C,setupEventHandler:B,strictEventHandler:N,unhandledEventHandler:L}=r(91696),U=function(e){const t={},U=new c({max:100});function F(t,{documentLoader:r=e.documentLoader,...n}){if(t&&"compactionMap"in t)throw new u('"compactionMap" not supported.',"jsonld.OptionsError");if(t&&"expansionMap"in t)throw new u('"expansionMap" not supported.',"jsonld.OptionsError");return Object.assign({},{documentLoader:r},n,t,{eventHandler:B({options:t})})}return e.compact=async function(t,r,n){if(arguments.length<2)throw new TypeError("Could not compact, too few arguments.");if(null===r)throw new u("The compaction context must not be null.","jsonld.CompactError",{code:"invalid local context"});if(null===t)return null;let i;(n=F(n,{base:v(t)?t:"",compactArrays:!0,compactToRelative:!0,graph:!1,skipExpansion:!1,link:!1,issuer:new s("_:b"),contextResolver:new a({sharedCache:U})})).link&&(n.skipExpansion=!0),n.compactToRelative||delete n.base,i=n.skipExpansion?t:await e.expand(t,n);const c=await e.processContext(S(n),r,n);let l=await _({activeCtx:c,element:i,options:n});n.compactArrays&&!n.graph&&g(l)?1===l.length?l=l[0]:0===l.length&&(l={}):n.graph&&b(l)&&(l=[l]),b(r)&&"@context"in r&&(r=r["@context"]),r=o.clone(r),g(r)||(r=[r]);const f=r;r=[];for(let e=0;e0)&&r.push(f[e]);const h=r.length>0;if(1===r.length&&(r=r[0]),g(l)){const e=M({activeCtx:c,iri:"@graph",relativeTo:{vocab:!0}}),t=l;l={},h&&(l["@context"]=r),l[e]=t}else if(b(l)&&h){const e=l;l={"@context":r};for(const t in e)l[t]=e[t]}return l},e.expand=async function(t,r){if(arguments.length<1)throw new TypeError("Could not expand, too few arguments.");const n={},i=[];if("expandContext"in(r=F(r,{keepFreeFloatingNodes:!1,contextResolver:new a({sharedCache:U})}))){const e=o.clone(r.expandContext);b(e)&&"@context"in e?n.expandContext=e:n.expandContext={"@context":e},i.push(n.expandContext)}let s;if(v(t)){const o=await e.get(t,r);s=o.documentUrl,n.input=o.document,o.contextUrl&&(n.remoteContext={"@context":o.contextUrl},i.push(n.remoteContext))}else n.input=o.clone(t);"base"in r||(r.base=s||"");let u=S(r);for(const e of i)u=await k({activeCtx:u,localCtx:e,options:r});let c=await f({activeCtx:u,element:n.input,options:r});return b(c)&&"@graph"in c&&1===Object.keys(c).length?c=c["@graph"]:null===c&&(c=[]),g(c)||(c=[c]),c},e.flatten=async function(t,r,n){if(arguments.length<1)return new TypeError("Could not flatten, too few arguments.");r="function"==typeof r?null:r||null,n=F(n,{base:v(t)?t:"",contextResolver:new a({sharedCache:U})});const i=await e.expand(t,n),o=h(i);if(null===r)return o;n.graph=!0,n.skipExpansion=!0;const s=await e.compact(o,r,n);return s},e.frame=async function(t,r,n){if(arguments.length<2)throw new TypeError("Could not frame, too few arguments.");if(n=F(n,{base:v(t)?t:"",embed:"@once",explicit:!1,requireAll:!1,omitDefault:!1,bnodesToClear:[],contextResolver:new a({sharedCache:U})}),v(r)){const t=await e.get(r,n);if(r=t.document,t.contextUrl){let e=r["@context"];e?g(e)?e.push(t.contextUrl):e=[e,t.contextUrl]:e=t.contextUrl,r["@context"]=e}}const i=r&&r["@context"]||{},o=await e.processContext(S(n),i,n);n.hasOwnProperty("omitGraph")||(n.omitGraph=E(o,1.1)),n.hasOwnProperty("pruneBlankNodeIdentifiers")||(n.pruneBlankNodeIdentifiers=E(o,1.1));const s=await e.expand(t,n),u={...n};u.isFrame=!0,u.keepFreeFloatingNodes=!0;const c=await e.expand(r,u),l=Object.keys(r).map((e=>A(o,e,{vocab:!0})));u.merged=!l.includes("@graph"),u.is11=E(o,1.1);const f=m(s,c,u);u.graph=!n.omitGraph,u.skipExpansion=!0,u.link={},u.framing=!0;let h=await e.compact(f,i,u);return u.link={},h=y(h,u),h},e.link=async function(t,r,n){const i={};return r&&(i["@context"]=r),i["@embed"]="@link",e.frame(t,i,n)},e.normalize=e.canonize=async function(t,r){if(arguments.length<1)throw new TypeError("Could not canonize, too few arguments.");if("inputFormat"in(r=F(r,{base:v(t)?t:null,algorithm:"URDNA2015",skipExpansion:!1,safe:!0,contextResolver:new a({sharedCache:U})}))){if("application/n-quads"!==r.inputFormat&&"application/nquads"!==r.inputFormat)throw new u("Unknown canonicalization input format.","jsonld.CanonizeError");const e=l.parse(t);return n.canonize(e,r)}const i={...r};delete i.format,i.produceGeneralizedRdf=!1;const o=await e.toRDF(t,i);return n.canonize(o,r)},e.fromRDF=async function(e,r){if(arguments.length<1)throw new TypeError("Could not convert from RDF, too few arguments.");r=F(r,{format:v(e)?"application/n-quads":void 0});const{format:n}=r;let{rdfParser:i}=r;if(n){if(i=i||t[n],!i)throw new u("Unknown input format.","jsonld.UnknownFormat",{format:n})}else i=()=>e;const o=await i(e);return d(o,r)},e.toRDF=async function(t,r){if(arguments.length<1)throw new TypeError("Could not convert to RDF, too few arguments.");let n;n=(r=F(r,{base:v(t)?t:"",skipExpansion:!1,contextResolver:new a({sharedCache:U})})).skipExpansion?t:await e.expand(t,r);const i=p(n,r);if(r.format){if("application/n-quads"===r.format||"application/nquads"===r.format)return l.serialize(i);throw new u("Unknown output format.","jsonld.UnknownFormat",{format:r.format})}return i},e.createNodeMap=async function(t,r){if(arguments.length<1)throw new TypeError("Could not create node map, too few arguments.");r=F(r,{base:v(t)?t:"",contextResolver:new a({sharedCache:U})});const n=await e.expand(t,r);return x(n,r)},e.merge=async function(t,r,n){if(arguments.length<1)throw new TypeError("Could not merge, too few arguments.");if(!g(t))throw new TypeError('Could not merge, "docs" must be an array.');r="function"==typeof r?null:r||null,n=F(n,{contextResolver:new a({sharedCache:U})});const i=await Promise.all(t.map((t=>{const r={...n};return e.expand(t,r)})));let u=!0;"mergeNodes"in n&&(u=n.mergeNodes);const c=n.issuer||new s("_:b"),l={"@default":{}};for(let e=0;ee._documentLoader,set:t=>e._documentLoader=t}),e.documentLoader=async e=>{throw new u("Could not retrieve a JSON-LD document from the URL. URL dereferencing not implemented.","jsonld.LoadDocumentError",{code:"loading document failed",url:e})},e.get=async function(t,r){let n;n="function"==typeof r.documentLoader?r.documentLoader:e.documentLoader;const i=await n(t);try{if(!i.document)throw new u("No remote document found at the given URL.","jsonld.NullRemoteDocument");v(i.document)&&(i.document=JSON.parse(i.document))}catch(e){throw new u("Could not retrieve a JSON-LD document from the URL.","jsonld.LoadDocumentError",{code:"loading document failed",cause:e,remoteDoc:i})}return i},e.processContext=async function(e,t,r){return r=F(r,{base:"",contextResolver:new a({sharedCache:U})}),null===t?S(r):(t=o.clone(t),b(t)&&"@context"in t||(t={"@context":t}),k({activeCtx:e,localCtx:t,options:r}))},e.getContextValue=r(54131).getContextValue,e.documentLoaders={},e.useDocumentLoader=function(t){if(!(t in e.documentLoaders))throw new u('Unknown document loader type: "'+t+'"',"jsonld.UnknownDocumentLoader",{type:t});e.documentLoader=e.documentLoaders[t].apply(e,Array.prototype.slice.call(arguments,1))},e.registerRDFParser=function(e,r){t[e]=r},e.unregisterRDFParser=function(e){delete t[e]},e.registerRDFParser("application/n-quads",l.parse),e.registerRDFParser("application/nquads",l.parse),e.url=r(82278),e.logEventHandler=I,e.logWarningEventHandler=O,e.safeEventHandler=R,e.setDefaultEventHandler=C,e.strictEventHandler=N,e.unhandledEventHandler=L,e.util=o,Object.assign(e,o),e.promises=e,e.RequestQueue=r(40533),e.JsonLdProcessor=r(60731)(e),i.setupGlobals(e),i.setupDocumentLoaders(e),e},F=function(){return U((function(){return F()}))};U(F),e.exports=F},32664:(e,t,r)=>{"use strict";const{isKeyword:n}=r(54131),i=r(18463),o=r(30832),a=r(51055),s=r(54093),u={};e.exports=u,u.createMergedNodeMap=(e,t)=>{const r=(t=t||{}).issuer||new a.IdentifierIssuer("_:b"),n={"@default":{}};return u.createNodeMap(e,n,"@default",r),u.mergeNodeMaps(n)},u.createNodeMap=(e,t,r,c,l,f)=>{if(o.isArray(e)){for(const n of e)u.createNodeMap(n,t,r,c,void 0,f);return}if(!o.isObject(e))return void(f&&f.push(e));if(i.isValue(e)){if("@type"in e){let t=e["@type"];0===t.indexOf("_:")&&(e["@type"]=t=c.getId(t))}return void(f&&f.push(e))}if(f&&i.isList(e)){const n=[];return u.createNodeMap(e["@list"],t,r,c,l,n),void f.push({"@list":n})}if("@type"in e){const t=e["@type"];for(const e of t)0===e.indexOf("_:")&&c.getId(e)}o.isUndefined(l)&&(l=i.isBlankNode(e)?c.getId(e["@id"]):e["@id"]),f&&f.push({"@id":l});const h=t[r],d=h[l]=h[l]||{};d["@id"]=l;const p=Object.keys(e).sort();for(let o of p){if("@id"===o)continue;if("@reverse"===o){const n={"@id":l},o=e["@reverse"];for(const e in o){const s=o[e];for(const o of s){let s=o["@id"];i.isBlankNode(o)&&(s=c.getId(s)),u.createNodeMap(o,t,r,c,s),a.addValue(h[s],e,n,{propertyIsArray:!0,allowDuplicate:!1})}}continue}if("@graph"===o){l in t||(t[l]={}),u.createNodeMap(e[o],t,l,c);continue}if("@included"===o){u.createNodeMap(e[o],t,r,c);continue}if("@type"!==o&&n(o)){if("@index"===o&&o in d&&(e[o]!==d[o]||e[o]["@id"]!==d[o]["@id"]))throw new s("Invalid JSON-LD syntax; conflicting @index property detected.","jsonld.SyntaxError",{code:"conflicting indexes",subject:d});d[o]=e[o];continue}const f=e[o];if(0===o.indexOf("_:")&&(o=c.getId(o)),0!==f.length)for(let e of f)if("@type"===o&&(e=0===e.indexOf("_:")?c.getId(e):e),i.isSubject(e)||i.isSubjectReference(e)){if("@id"in e&&!e["@id"])continue;const n=i.isBlankNode(e)?c.getId(e["@id"]):e["@id"];a.addValue(d,o,{"@id":n},{propertyIsArray:!0,allowDuplicate:!1}),u.createNodeMap(e,t,r,c,n)}else if(i.isValue(e))a.addValue(d,o,e,{propertyIsArray:!0,allowDuplicate:!1});else if(i.isList(e)){const n=[];u.createNodeMap(e["@list"],t,r,c,l,n),e={"@list":n},a.addValue(d,o,e,{propertyIsArray:!0,allowDuplicate:!1})}else u.createNodeMap(e,t,r,c,l),a.addValue(d,o,e,{propertyIsArray:!0,allowDuplicate:!1});else a.addValue(d,o,[],{propertyIsArray:!0})}},u.mergeNodeMapGraphs=e=>{const t={};for(const r of Object.keys(e).sort())for(const i of Object.keys(e[r]).sort()){const o=e[r][i];i in t||(t[i]={"@id":i});const s=t[i];for(const e of Object.keys(o).sort())if(n(e)&&"@type"!==e)s[e]=a.clone(o[e]);else for(const t of o[e])a.addValue(s,e,a.clone(t),{propertyIsArray:!0,allowDuplicate:!1})}return t},u.mergeNodeMaps=e=>{const t=e["@default"],r=Object.keys(e).sort();for(const n of r){if("@default"===n)continue;const r=e[n];let o=t[n];o?"@graph"in o||(o["@graph"]=[]):t[n]=o={"@id":n,"@graph":[]};const a=o["@graph"];for(const e of Object.keys(r).sort()){const t=r[e];i.isSubjectReference(t)||a.push(t)}}return t}},67222:(e,t,r)=>{"use strict";const n=r(8831),i={};e.exports=i,i.setupDocumentLoaders=function(e){"undefined"!=typeof XMLHttpRequest&&(e.documentLoaders.xhr=n,e.useDocumentLoader("xhr"))},i.setupGlobals=function(e){void 0===globalThis.JsonLdProcessor&&Object.defineProperty(globalThis,"JsonLdProcessor",{writable:!0,enumerable:!1,configurable:!0,value:e.JsonLdProcessor})}},19382:(e,t,r)=>{"use strict";const{createNodeMap:n}=r(32664),{isKeyword:i}=r(54131),o=r(18463),a=r(95456),s=r(30832),u=r(51055),{handleEvent:c}=r(91696),{RDF_FIRST:l,RDF_REST:f,RDF_NIL:h,RDF_TYPE:d,RDF_JSON_LITERAL:p,RDF_LANGSTRING:m,XSD_BOOLEAN:y,XSD_DOUBLE:g,XSD_INTEGER:b,XSD_STRING:v}=r(93770),{isAbsolute:w}=r(82278),A={};function S(e,t,r,n,o){const a=Object.keys(t).sort();for(const s of a){const a=t[s],u=Object.keys(a).sort();for(let t of u){const u=a[t];if("@type"===t)t=d;else if(i(t))continue;for(const i of u){const a={termType:s.startsWith("_:")?"BlankNode":"NamedNode",value:s};if(!w(s)){o.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative subject reference",level:"warning",message:"Relative subject reference found.",details:{subject:s}},options:o});continue}const u={termType:t.startsWith("_:")?"BlankNode":"NamedNode",value:t};if(!w(t)){o.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative predicate reference",level:"warning",message:"Relative predicate reference found.",details:{predicate:t}},options:o});continue}if("BlankNode"===u.termType&&!o.produceGeneralizedRdf){o.eventHandler&&c({event:{type:["JsonLdEvent"],code:"blank node predicate",level:"warning",message:"Dropping blank node predicate.",details:{property:n.getOldIds().find((e=>n.getId(e)===t))}},options:o});continue}const l=k(i,n,e,r,o.rdfDirection,o);l&&e.push({subject:a,predicate:u,object:l,graph:r})}}}}function k(e,t,r,n,i,u){const d={};if(o.isValue(e)){d.termType="Literal",d.value=void 0,d.datatype={termType:"NamedNode"};let t=e["@value"];const r=e["@type"]||null;if("@json"===r)d.value=a(t),d.datatype.value=p;else if(s.isBoolean(t))d.value=t.toString(),d.datatype.value=r||y;else if(s.isDouble(t)||r===g)s.isDouble(t)||(t=parseFloat(t)),d.value=t.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),d.datatype.value=r||g;else if(s.isNumber(t))d.value=t.toFixed(0),d.datatype.value=r||b;else if("i18n-datatype"===i&&"@direction"in e){const r="https://www.w3.org/ns/i18n#"+(e["@language"]||"")+`_${e["@direction"]}`;d.datatype.value=r,d.value=t}else"@language"in e?(d.value=t,d.datatype.value=r||m,d.language=e["@language"]):(d.value=t,d.datatype.value=r||v)}else if(o.isList(e)){const o=function(e,t,r,n,i,o){const a={termType:"NamedNode",value:l},s={termType:"NamedNode",value:f},u={termType:"NamedNode",value:h},c=e.pop(),d=c?{termType:"BlankNode",value:t.getId()}:u;let p=d;for(const u of e){const e=k(u,t,r,n,i,o),c={termType:"BlankNode",value:t.getId()};r.push({subject:p,predicate:a,object:e,graph:n}),r.push({subject:p,predicate:s,object:c,graph:n}),p=c}if(c){const e=k(c,t,r,n,i,o);r.push({subject:p,predicate:a,object:e,graph:n}),r.push({subject:p,predicate:s,object:u,graph:n})}return d}(e["@list"],t,r,n,i,u);d.termType=o.termType,d.value=o.value}else{const t=s.isObject(e)?e["@id"]:e;d.termType=t.startsWith("_:")?"BlankNode":"NamedNode",d.value=t}return"NamedNode"!==d.termType||w(d.value)?d:(u.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative object reference",level:"warning",message:"Relative object reference found.",details:{object:d.value}},options:u}),null)}e.exports=A,A.toRDF=(e,t)=>{const r=new u.IdentifierIssuer("_:b"),i={"@default":{}};n(e,i,"@default",r);const o=[],a=Object.keys(i).sort();for(const e of a){let n;if("@default"===e)n={termType:"DefaultGraph",value:""};else{if(!w(e)){t.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative graph reference",level:"warning",message:"Relative graph reference found.",details:{graph:e}},options:t});continue}n=e.startsWith("_:")?{termType:"BlankNode"}:{termType:"NamedNode"},n.value=e}S(o,i[e],n,r,t)}return o}},30832:e=>{"use strict";const t={};e.exports=t,t.isArray=Array.isArray,t.isBoolean=e=>"boolean"==typeof e||"[object Boolean]"===Object.prototype.toString.call(e),t.isDouble=e=>t.isNumber(e)&&(-1!==String(e).indexOf(".")||Math.abs(e)>=1e21),t.isEmptyObject=e=>t.isObject(e)&&0===Object.keys(e).length,t.isNumber=e=>"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e),t.isNumeric=e=>!isNaN(parseFloat(e))&&isFinite(e),t.isObject=e=>"[object Object]"===Object.prototype.toString.call(e),t.isString=e=>"string"==typeof e||"[object String]"===Object.prototype.toString.call(e),t.isUndefined=e=>void 0===e},82278:(e,t,r)=>{"use strict";const n=r(30832),i={};e.exports=i,i.parsers={simple:{keys:["href","scheme","authority","path","query","fragment"],regex:/^(?:([^:\/?#]+):)?(?:\/\/([^\/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?/},full:{keys:["href","protocol","scheme","authority","auth","user","password","hostname","port","path","directory","file","query","fragment"],regex:/^(([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?(?:(((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/}},i.parse=(e,t)=>{const r={},n=i.parsers[t||"full"],o=n.regex.exec(e);let a=n.keys.length;for(;a--;)r[n.keys[a]]=void 0===o[a]?null:o[a];return("https"===r.scheme&&"443"===r.port||"http"===r.scheme&&"80"===r.port)&&(r.href=r.href.replace(":"+r.port,""),r.authority=r.authority.replace(":"+r.port,""),r.port=null),r.normalizedPath=i.removeDotSegments(r.path),r},i.prependBase=(e,t)=>{if(null===e)return t;if(i.isAbsolute(t))return t;e&&!n.isString(e)||(e=i.parse(e||""));const r=i.parse(t),o={protocol:e.protocol||""};if(null!==r.authority)o.authority=r.authority,o.path=r.path,o.query=r.query;else if(o.authority=e.authority,""===r.path)o.path=e.path,null!==r.query?o.query=r.query:o.query=e.query;else{if(0===r.path.indexOf("/"))o.path=r.path;else{let t=e.path;t=t.substr(0,t.lastIndexOf("/")+1),(t.length>0||e.authority)&&"/"!==t.substr(-1)&&(t+="/"),t+=r.path,o.path=t}o.query=r.query}""!==r.path&&(o.path=i.removeDotSegments(o.path));let a=o.protocol;return null!==o.authority&&(a+="//"+o.authority),a+=o.path,null!==o.query&&(a+="?"+o.query),null!==r.fragment&&(a+="#"+r.fragment),""===a&&(a="./"),a},i.removeBase=(e,t)=>{if(null===e)return t;e&&!n.isString(e)||(e=i.parse(e||""));let r="";if(""!==e.href?r+=(e.protocol||"")+"//"+(e.authority||""):t.indexOf("//")&&(r+="//"),0!==t.indexOf(r))return t;const o=i.parse(t.substr(r.length)),a=e.normalizedPath.split("/"),s=o.normalizedPath.split("/"),u=o.fragment||o.query?0:1;for(;a.length>0&&s.length>u&&a[0]===s[0];)a.shift(),s.shift();let c="";if(a.length>0){a.pop();for(let e=0;e{if(0===e.length)return"";const t=e.split("/"),r=[];for(;t.length>0;){const e=t.shift(),n=0===t.length;"."!==e?".."!==e?r.push(e):(r.pop(),n&&r.push("")):n&&r.push("")}return"/"===e[0]&&r.length>0&&""!==r[0]&&r.unshift(""),1===r.length&&""===r[0]?"/":r.join("/")};const o=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^\s]*$/;i.isAbsolute=e=>n.isString(e)&&o.test(e),i.isRelative=e=>n.isString(e)},51055:(e,t,r)=>{"use strict";const n=r(18463),i=r(30832),o=r(47055).IdentifierIssuer,a=r(54093),s=/(?:<[^>]*?>|"[^"]*?"|[^,])+/g,u=/\s*<([^>]*?)>\s*(?:;\s*(.*))?/,c=/(.*?)=(?:(?:"([^"]*?)")|([^"]*?))\s*(?:(?:;\s*)|$)/g,l={accept:"application/ld+json, application/json"},f={};function h(e,t){if(i.isArray(t))for(let r=0;r{if(Object.keys(e).some((e=>"accept"===e.toLowerCase())))throw new RangeError('Accept header may not be specified; only "'+l.accept+'" is supported.');return Object.assign({Accept:l.accept},e)},f.parseLinkHeader=e=>{const t={},r=e.match(s);for(let e=0;e{if(!(i.isString(e)||i.isArray(e)&&e.every((e=>i.isString(e))))){if(t&&i.isObject(e))switch(Object.keys(e).length){case 0:return;case 1:if("@default"in e&&f.asArray(e["@default"]).every((e=>i.isString(e))))return}throw new a('Invalid JSON-LD syntax; "@type" value must a string, an array of strings, an empty object, or a default object.',"jsonld.SyntaxError",{code:"invalid type value",value:e})}},f.hasProperty=(e,t)=>{if(e.hasOwnProperty(t)){const r=e[t];return!i.isArray(r)||r.length>0}return!1},f.hasValue=(e,t,r)=>{if(f.hasProperty(e,t)){let o=e[t];const a=n.isList(o);if(i.isArray(o)||a){a&&(o=o["@list"]);for(let e=0;e{if("propertyIsArray"in(n=n||{})||(n.propertyIsArray=!1),"valueIsArray"in n||(n.valueIsArray=!1),"allowDuplicate"in n||(n.allowDuplicate=!0),"prependValue"in n||(n.prependValue=!1),n.valueIsArray)e[t]=r;else if(i.isArray(r)){0===r.length&&n.propertyIsArray&&!e.hasOwnProperty(t)&&(e[t]=[]),n.prependValue&&(r=r.concat(e[t]),e[t]=[]);for(let i=0;i[].concat(e[t]||[]),f.removeProperty=(e,t)=>{delete e[t]},f.removeValue=(e,t,r,n)=>{"propertyIsArray"in(n=n||{})||(n.propertyIsArray=!1);const i=f.getValues(e,t).filter((e=>!f.compareValues(e,r)));0===i.length?f.removeProperty(e,t):1!==i.length||n.propertyIsArray?e[t]=i:e[t]=i[0]},f.relabelBlankNodes=(e,t)=>h((t=t||{}).issuer||new o("_:b"),e),f.compareValues=(e,t)=>e===t||(!(!n.isValue(e)||!n.isValue(t)||e["@value"]!==t["@value"]||e["@type"]!==t["@type"]||e["@language"]!==t["@language"]||e["@index"]!==t["@index"])||!!(i.isObject(e)&&"@id"in e&&i.isObject(t)&&"@id"in t)&&e["@id"]===t["@id"]),f.compareShortestLeast=(e,t)=>e.length{"use strict";const n=r(34411),i=Symbol("max"),o=Symbol("length"),a=Symbol("lengthCalculator"),s=Symbol("allowStale"),u=Symbol("maxAge"),c=Symbol("dispose"),l=Symbol("noDisposeOnSet"),f=Symbol("lruList"),h=Symbol("cache"),d=Symbol("updateAgeOnGet"),p=()=>1;const m=(e,t,r)=>{const n=e[h].get(t);if(n){const t=n.value;if(y(e,t)){if(b(e,n),!e[s])return}else r&&(e[d]&&(n.value.now=Date.now()),e[f].unshiftNode(n));return t.value}},y=(e,t)=>{if(!t||!t.maxAge&&!e[u])return!1;const r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[u]&&r>e[u]},g=e=>{if(e[o]>e[i])for(let t=e[f].tail;e[o]>e[i]&&null!==t;){const r=t.prev;b(e,t),t=r}},b=(e,t)=>{if(t){const r=t.value;e[c]&&e[c](r.key,r.value),e[o]-=r.length,e[h].delete(r.key),e[f].removeNode(t)}};class v{constructor(e,t,r,n,i){this.key=e,this.value=t,this.length=r,this.now=n,this.maxAge=i||0}}const w=(e,t,r,n)=>{let i=r.value;y(e,i)&&(b(e,r),e[s]||(i=void 0)),i&&t.call(n,i.value,i.key,e)};e.exports=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");this[i]=e.max||1/0;const t=e.length||p;if(this[a]="function"!=typeof t?p:t,this[s]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[u]=e.maxAge||0,this[c]=e.dispose,this[l]=e.noDisposeOnSet||!1,this[d]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[i]=e||1/0,g(this)}get max(){return this[i]}set allowStale(e){this[s]=!!e}get allowStale(){return this[s]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[u]=e,g(this)}get maxAge(){return this[u]}set lengthCalculator(e){"function"!=typeof e&&(e=p),e!==this[a]&&(this[a]=e,this[o]=0,this[f].forEach((e=>{e.length=this[a](e.value,e.key),this[o]+=e.length}))),g(this)}get lengthCalculator(){return this[a]}get length(){return this[o]}get itemCount(){return this[f].length}rforEach(e,t){t=t||this;for(let r=this[f].tail;null!==r;){const n=r.prev;w(this,e,r,t),r=n}}forEach(e,t){t=t||this;for(let r=this[f].head;null!==r;){const n=r.next;w(this,e,r,t),r=n}}keys(){return this[f].toArray().map((e=>e.key))}values(){return this[f].toArray().map((e=>e.value))}reset(){this[c]&&this[f]&&this[f].length&&this[f].forEach((e=>this[c](e.key,e.value))),this[h]=new Map,this[f]=new n,this[o]=0}dump(){return this[f].map((e=>!y(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)})).toArray().filter((e=>e))}dumpLru(){return this[f]}set(e,t,r){if((r=r||this[u])&&"number"!=typeof r)throw new TypeError("maxAge must be a number");const n=r?Date.now():0,s=this[a](t,e);if(this[h].has(e)){if(s>this[i])return b(this,this[h].get(e)),!1;const a=this[h].get(e).value;return this[c]&&(this[l]||this[c](e,a.value)),a.now=n,a.maxAge=r,a.value=t,this[o]+=s-a.length,a.length=s,this.get(e),g(this),!0}const d=new v(e,t,s,n,r);return d.length>this[i]?(this[c]&&this[c](e,t),!1):(this[o]+=d.length,this[f].unshift(d),this[h].set(e,this[f].head),g(this),!0)}has(e){if(!this[h].has(e))return!1;const t=this[h].get(e).value;return!y(this,t)}get(e){return m(this,e,!0)}peek(e){return m(this,e,!1)}pop(){const e=this[f].tail;return e?(b(this,e),e.value):null}del(e){b(this,this[h].get(e))}load(e){this.reset();const t=Date.now();for(let r=e.length-1;r>=0;r--){const n=e[r],i=n.e||0;if(0===i)this.set(n.k,n.v);else{const e=i-t;e>0&&this.set(n.k,n.v,e)}}}prune(){this[h].forEach(((e,t)=>m(this,t,!1)))}}},62318:(e,t,r)=>{"use strict";var n=r(35717),i=r(3349),o=r(89509).Buffer,a=new Array(16);function s(){i.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function u(e,t){return e<>>32-t}function c(e,t,r,n,i,o,a){return u(e+(t&r|~t&n)+i+o|0,a)+t|0}function l(e,t,r,n,i,o,a){return u(e+(t&n|r&~n)+i+o|0,a)+t|0}function f(e,t,r,n,i,o,a){return u(e+(t^r^n)+i+o|0,a)+t|0}function h(e,t,r,n,i,o,a){return u(e+(r^(t|~n))+i+o|0,a)+t|0}n(s,i),s.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,o=this._d;r=c(r,n,i,o,e[0],3614090360,7),o=c(o,r,n,i,e[1],3905402710,12),i=c(i,o,r,n,e[2],606105819,17),n=c(n,i,o,r,e[3],3250441966,22),r=c(r,n,i,o,e[4],4118548399,7),o=c(o,r,n,i,e[5],1200080426,12),i=c(i,o,r,n,e[6],2821735955,17),n=c(n,i,o,r,e[7],4249261313,22),r=c(r,n,i,o,e[8],1770035416,7),o=c(o,r,n,i,e[9],2336552879,12),i=c(i,o,r,n,e[10],4294925233,17),n=c(n,i,o,r,e[11],2304563134,22),r=c(r,n,i,o,e[12],1804603682,7),o=c(o,r,n,i,e[13],4254626195,12),i=c(i,o,r,n,e[14],2792965006,17),r=l(r,n=c(n,i,o,r,e[15],1236535329,22),i,o,e[1],4129170786,5),o=l(o,r,n,i,e[6],3225465664,9),i=l(i,o,r,n,e[11],643717713,14),n=l(n,i,o,r,e[0],3921069994,20),r=l(r,n,i,o,e[5],3593408605,5),o=l(o,r,n,i,e[10],38016083,9),i=l(i,o,r,n,e[15],3634488961,14),n=l(n,i,o,r,e[4],3889429448,20),r=l(r,n,i,o,e[9],568446438,5),o=l(o,r,n,i,e[14],3275163606,9),i=l(i,o,r,n,e[3],4107603335,14),n=l(n,i,o,r,e[8],1163531501,20),r=l(r,n,i,o,e[13],2850285829,5),o=l(o,r,n,i,e[2],4243563512,9),i=l(i,o,r,n,e[7],1735328473,14),r=f(r,n=l(n,i,o,r,e[12],2368359562,20),i,o,e[5],4294588738,4),o=f(o,r,n,i,e[8],2272392833,11),i=f(i,o,r,n,e[11],1839030562,16),n=f(n,i,o,r,e[14],4259657740,23),r=f(r,n,i,o,e[1],2763975236,4),o=f(o,r,n,i,e[4],1272893353,11),i=f(i,o,r,n,e[7],4139469664,16),n=f(n,i,o,r,e[10],3200236656,23),r=f(r,n,i,o,e[13],681279174,4),o=f(o,r,n,i,e[0],3936430074,11),i=f(i,o,r,n,e[3],3572445317,16),n=f(n,i,o,r,e[6],76029189,23),r=f(r,n,i,o,e[9],3654602809,4),o=f(o,r,n,i,e[12],3873151461,11),i=f(i,o,r,n,e[15],530742520,16),r=h(r,n=f(n,i,o,r,e[2],3299628645,23),i,o,e[0],4096336452,6),o=h(o,r,n,i,e[7],1126891415,10),i=h(i,o,r,n,e[14],2878612391,15),n=h(n,i,o,r,e[5],4237533241,21),r=h(r,n,i,o,e[12],1700485571,6),o=h(o,r,n,i,e[3],2399980690,10),i=h(i,o,r,n,e[10],4293915773,15),n=h(n,i,o,r,e[1],2240044497,21),r=h(r,n,i,o,e[8],1873313359,6),o=h(o,r,n,i,e[15],4264355552,10),i=h(i,o,r,n,e[6],2734768916,15),n=h(n,i,o,r,e[13],1309151649,21),r=h(r,n,i,o,e[4],4149444226,6),o=h(o,r,n,i,e[11],3174756917,10),i=h(i,o,r,n,e[2],718787259,15),n=h(n,i,o,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+o|0},s.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 e=o.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=s},75117:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Base=void 0;const i=r(48764),o=n(r(81354));class a{print(){a.print(this)}bufferIndexOf(e,t,r=!1){if(r)return this.binarySearch(e,t,i.Buffer.compare);return this.linearSearch(e,t,((e,t)=>e.equals(t)))}static binarySearch(e,t,r){let n=0,i=e.length-1;for(;n<=i;){const o=Math.floor((n+i)/2),a=r(e[o],t);if(0===a){for(let n=o-1;n>=0;n--)if(0!==r(e[n],t))return n+1;return 0}a<0?n=o+1:i=o-1}return-1}binarySearch(e,t,r){return a.binarySearch(e,t,r)}static linearSearch(e,t,r){for(let n=0;n{const r=e(t);return i.Buffer.isBuffer(r)?r:this.isHexString(r)?i.Buffer.from(r.replace("0x",""),"hex"):"string"==typeof r?i.Buffer.from(r):"bigint"==typeof r?i.Buffer.from(t.toString(16),"hex"):ArrayBuffer.isView(r)?i.Buffer.from(r.buffer,r.byteOffset,r.byteLength):i.Buffer.from(e(o.default.enc.Hex.parse(t.toString("hex"))).toString(o.default.enc.Hex),"hex")}}isHexString(e){return a.isHexString(e)}log2(e){return 1===e?0:1+this.log2(e/2|0)}zip(e,t){return e.map(((e,r)=>[e,t[r]]))}static hexZeroPad(e,t){return"0x"+e.replace("0x","").padStart(t,"0")}}t.Base=a,t.default=a},8659:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.IncrementalMerkleTree=void 0;const i=n(r(75117)),o=n(r(99269));class a extends i.default{constructor(e,t){if(super(),this.hashFn=e,t.depth&&(this.depth=t.depth),t.arity&&(this.arity=t.arity),this.depth<1)throw new Error("depth must be greater than 0");if(this.arity<1)throw new Error("arity must be greater than 0");const r=[];let n=t.zeroValue;if(this.zeroValue=n,this.zeroes=[],this.depth)for(let e=0;e=this.getMaxLeaves())throw new Error("tree is full");let t=e,r=this.nodes[0].length;for(let e=0;e=this.nodes[0].length)throw new Error("out of bounds");let r=t;for(let t=0;tBigInt(e)))}getLayers(){const e=[];for(const t of this.nodes)e.push(this.copyList(t));if(e[0].length=e[r].length&&(e[r][t]=this.zeroes[r]);t=Math.floor(t/this.arity)}}return e.push([this.root]),e}getHexLayers(){return this.getLayers().reduce(((e,t)=>(Array.isArray(t)?e.push(t.map((e=>this.bufferToHex(this.bufferify(e))))):e.push(t),e)),[])}getLayersAsObject(){const e=this.getLayers().map((e=>e.map((e=>this.bufferToHex(this.bufferify(e),!1))))),t=[];for(let r=0;r=this.nodes[0].length)throw new Error("The leaf does not exist in this tree");const t=[],r=[],n=e;for(let n=0;n0&&!(0!=(e&1<=t));o--);if(n!==r.length)throw new Error("invalid bit calculation");return r}numOfPeaks(e){let t=e,r=0;for(;t>0;)t%2==1&&r++,t>>=1;return r}peakBagging(e,t){const r=this.getSize(e);if(this.numOfPeaks(e)!==t.length)throw new Error("received invalid number of peaks");return 0!==e||t.length?this.peakBaggingFn?this.bufferify(this.peakBaggingFn(r,t)):this.hashFn(i.Buffer.concat([this.bufferify(r),...t.map(this.bufferify)])):i.Buffer.alloc(0)}getSize(e){return(e<<1)-this.numOfPeaks(e)}getRoot(){return this.root}getHexRoot(){return this.bufferToHex(this.getRoot())}getNode(e){return this.hashes[e]}mountainHeight(e){let t=1;for(;1<r;)t-=(1<this.size)throw new Error("out of range");if(!this.isLeaf(e))throw new Error("not a leaf");const t=this.root,r=this.width,n=this.getPeakIndexes(this.width),i=[];let o=0;for(let t=0;t=e&&0===o&&(o=n[t]);let a=0,s=0,u=this.heightAt(o);const c=[];for(;o!==e;)u--,[a,s]=this.getChildren(o),o=e<=a?a:s,c[u-1]=this.hashes[e<=a?s:a];return{root:t,width:r,peakBagging:i,siblings:c}}verify(e,t,r,n,i,o){n=this.bufferify(n);if(this.getSize(t)=r){a=i[e],s=u[e];break}if(!a)throw new Error("target not found");let c=o.length+1;const l=new Array(c);let f,h=0,d=0;for(;c>0&&(l[--c]=s,s!==r);)[h,d]=this.getChildren(s),s=r>h?d:h;for(;cthis.size)throw new Error("out of range");if(!this.hashes[e]){const[t,r]=this.getChildren(e),n=this._getOrCreateNode(t),i=this._getOrCreateNode(r);this.hashes[e]=this.hashBranch(e,n,i)}return this.hashes[e]}}t.MerkleMountainRange=s,"undefined"!=typeof window&&(window.MerkleMountainRange=s),t.default=s},75028:(e,t,r)=>{"use strict";var n=r(48764).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.MerkleSumTree=t.ProofStep=t.Leaf=t.Bucket=void 0;const i=r(75117);class o{constructor(e,t){this.size=BigInt(e),this.hashed=t,this.parent=null,this.left=null,this.right=null}}t.Bucket=o;t.Leaf=class{constructor(e,t,r){this.hashFn=e,this.rng=t.map((e=>BigInt(e))),this.data=r}getBucket(){let e;return e=this.data?this.hashFn(this.data):n.alloc(32),new o(BigInt(this.rng[1])-BigInt(this.rng[0]),e)}};class a{constructor(e,t){this.bucket=e,this.right=t}}t.ProofStep=a;class s extends i.Base{constructor(e,t){super(),this.leaves=e,this.hashFn=t,s.checkConsecutive(e),this.buckets=[];for(const t of e)this.buckets.push(t.getBucket());let r=[];for(const e of this.buckets)r.push(e);for(;1!==r.length;){const e=[];for(;r.length;)if(r.length>=2){const t=r.shift(),i=r.shift(),a=t.size+i.size,s=this.hashFn(n.concat([this.sizeToBuffer(t.size),this.bufferify(t.hashed),this.sizeToBuffer(i.size),this.bufferify(i.hashed)])),u=new o(a,s);i.parent=u,t.parent=i.parent,t.right=i,i.left=t,e.push(u)}else e.push(r.shift());r=e}this.root=r[0]}sizeToBuffer(e){const t=n.alloc(8);return new DataView(t.buffer).setBigInt64(0,BigInt(e),!1),t}static checkConsecutive(e){let t=BigInt(0);for(const r of e){if(r.rng[0]!==t)throw new Error("leaf ranges are invalid");t=BigInt(r.rng[1])}}getProof(e){let t=this.buckets[Number(e)];const r=[];for(;t&&t.parent;){const e=!!t.right,n=t.right?t.right:t.left;t=t.parent,r.push(new a(n,e))}return r}sum(e){let t=BigInt(0);for(const r of e)t+=BigInt(r);return t}verifyProof(e,t,r){const i=[this.sum(r.filter((e=>!e.right)).map((e=>e.bucket.size))),BigInt(e.size)-this.sum(r.filter((e=>e.right)).map((e=>e.bucket.size)))];if(i[0]!==t.rng[0]||i[1]!==t.rng[1])return!1;let a,s=t.getBucket();for(const e of r)a=e.right?this.hashFn(n.concat([this.sizeToBuffer(s.size),this.bufferify(s.hashed),this.sizeToBuffer(e.bucket.size),this.bufferify(e.bucket.hashed)])):this.hashFn(n.concat([this.sizeToBuffer(e.bucket.size),this.bufferify(e.bucket.hashed),this.sizeToBuffer(s.size),this.bufferify(s.hashed)])),s=new o(BigInt(s.size)+BigInt(e.bucket.size),a);return s.size===e.size&&s.hashed.toString("hex")===e.hashed.toString("hex")}}t.MerkleSumTree=s,"undefined"!=typeof window&&(window.MerkleSumTree=s),t.default=s},78493:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.MerkleTree=void 0;const i=r(48764),o=n(r(56351)),a=n(r(52153)),s=n(r(99269)),u=n(r(75117));class c extends u.default{constructor(e,t=a.default,r={}){if(super(),this.duplicateOdd=!1,this.concatenator=i.Buffer.concat,this.hashLeaves=!1,this.isBitcoinTree=!1,this.leaves=[],this.layers=[],this.sortLeaves=!1,this.sortPairs=!1,this.sort=!1,this.fillDefaultHash=null,this.complete=!1,r.complete){if(r.isBitcoinTree)throw new Error('option "complete" is incompatible with "isBitcoinTree"');if(r.duplicateOdd)throw new Error('option "complete" is incompatible with "duplicateOdd"')}if(this.isBitcoinTree=!!r.isBitcoinTree,this.hashLeaves=!!r.hashLeaves,this.sortLeaves=!!r.sortLeaves,this.sortPairs=!!r.sortPairs,this.complete=!!r.complete,r.fillDefaultHash)if("function"==typeof r.fillDefaultHash)this.fillDefaultHash=r.fillDefaultHash;else{if(!i.Buffer.isBuffer(r.fillDefaultHash)&&"string"!=typeof r.fillDefaultHash)throw new Error('method "fillDefaultHash" must be a function, Buffer, or string');this.fillDefaultHash=(e,t)=>r.fillDefaultHash}this.sort=!!r.sort,this.sort&&(this.sortLeaves=!0,this.sortPairs=!0),this.duplicateOdd=!!r.duplicateOdd,r.concatenator&&(this.concatenator=r.concatenator),this.hashFn=this.bufferifyFn(t),this.processLeaves(e)}getOptions(){var e,t;return{complete:this.complete,isBitcoinTree:this.isBitcoinTree,hashLeaves:this.hashLeaves,sortLeaves:this.sortLeaves,sortPairs:this.sortPairs,sort:this.sort,fillDefaultHash:null!==(t=null===(e=this.fillDefaultHash)||void 0===e?void 0:e.toString())&&void 0!==t?t:null,duplicateOdd:this.duplicateOdd}}processLeaves(e){if(this.hashLeaves&&(e=e.map(this.hashFn)),this.leaves=e.map(this.bufferify),this.sortLeaves&&(this.leaves=this.leaves.sort(i.Buffer.compare)),this.fillDefaultHash)for(let e=this.leaves.length;e1;){const t=this.layers.length;this.layers.push([]);const r=this.complete&&1===t&&!Number.isInteger(Math.log2(e.length))?2*e.length-Math.pow(2,Math.ceil(Math.log2(e.length))):e.length;for(let n=0;n=r){this.layers[t].push(...e.slice(r));break}if(n+1===e.length&&e.length%2==1){const r=e[e.length-1];let i=r;if(this.isBitcoinTree){i=this.hashFn(this.concatenator([o.default(r),o.default(r)])),i=o.default(this.hashFn(i)),this.layers[t].push(i);continue}if(!this.duplicateOdd){this.layers[t].push(e[n]);continue}}const a=e[n],s=n+1===e.length?a:e[n+1];let u=null;u=this.isBitcoinTree?[o.default(a),o.default(s)]:[a,s],this.sortPairs&&u.sort(i.Buffer.compare);let c=this.hashFn(this.concatenator(u));this.isBitcoinTree&&(c=o.default(this.hashFn(c))),this.layers[t].push(c)}e=this.layers[t]}}addLeaf(e,t=!1){t&&(e=this.hashFn(e)),this.processLeaves(this.leaves.concat(e))}addLeaves(e,t=!1){t&&(e=e.map(this.hashFn)),this.processLeaves(this.leaves.concat(e))}getLeaves(e){return Array.isArray(e)?(this.hashLeaves&&(e=e.map(this.hashFn),this.sortLeaves&&(e=e.sort(i.Buffer.compare))),this.leaves.filter((t=>-1!==this.bufferIndexOf(e,t,this.sortLeaves)))):this.leaves}getLeaf(e){return e<0||e>this.leaves.length-1?i.Buffer.from([]):this.leaves[e]}getLeafIndex(e){e=this.bufferify(e);const t=this.getLeaves();for(let r=0;rthis.bufferToHex(e)))}static marshalLeaves(e){return JSON.stringify(e.map((e=>c.bufferToHex(e))),null,2)}static unmarshalLeaves(e){let t=null;if("string"==typeof e)t=JSON.parse(e);else{if(!(e instanceof Object))throw new Error("Expected type of string or object");t=e}if(!t)return[];if(!Array.isArray(t))throw new Error("Expected JSON string to be array");return t.map(c.bufferify)}getLayers(){return this.layers}getHexLayers(){return this.layers.reduce(((e,t)=>(Array.isArray(t)?e.push(t.map((e=>this.bufferToHex(e)))):e.push(t),e)),[])}getLayersFlat(){const e=this.layers.reduce(((e,t)=>(Array.isArray(t)?e.unshift(...t):e.unshift(t),e)),[]);return e.unshift(i.Buffer.from([0])),e}getHexLayersFlat(){return this.getLayersFlat().map((e=>this.bufferToHex(e)))}getLayerCount(){return this.getLayers().length}getRoot(){return 0===this.layers.length?i.Buffer.from([]):this.layers[this.layers.length-1][0]||i.Buffer.from([])}getHexRoot(){return this.bufferToHex(this.getRoot())}getProof(e,t){if(void 0===e)throw new Error("leaf is required");e=this.bufferify(e);const r=[];if(!Number.isInteger(t)){t=-1;for(let r=0;rthis.bufferToHex(e.data)))}getProofs(){const e=[];return this.getProofsDFS(this.layers.length-1,0,[],e),e}getProofsDFS(e,t,r,n){const i=t%2;if(-1===e)return void(i||n.push([...r].reverse()));if(t>=this.layers[e].length)return;const o=this.layers[e],a=i?t-1:t+1;let s=!1;athis.bufferToHex(e.data)))}getPositionalHexProof(e,t){return this.getProof(e,t).map((e=>["left"===e.position?0:1,this.bufferToHex(e.data)]))}static marshalProof(e){const t=e.map((e=>"string"==typeof e?e:i.Buffer.isBuffer(e)?c.bufferToHex(e):{position:e.position,data:c.bufferToHex(e.data)}));return JSON.stringify(t,null,2)}static unmarshalProof(e){let t=null;if("string"==typeof e)t=JSON.parse(e);else{if(!(e instanceof Object))throw new Error("Expected type of string or object");t=e}if(!t)return[];if(!Array.isArray(t))throw new Error("Expected JSON string to be array");return t.map((e=>{if("string"==typeof e)return c.bufferify(e);if(e instanceof Object)return{position:e.position,data:c.bufferify(e.data)};throw new Error("Expected item to be of type string or object")}))}static marshalTree(e){const t=e.getHexRoot(),r=e.leaves.map((e=>c.bufferToHex(e))),n=e.getHexLayers(),i=e.getOptions();return JSON.stringify({options:i,root:t,layers:n,leaves:r},null,2)}static unmarshalTree(e,t=a.default,r={}){let n=null;if("string"==typeof e)n=JSON.parse(e);else{if(!(e instanceof Object))throw new Error("Expected type of string or object");n=e}if(!n)throw new Error("could not parse json");return r=Object.assign({},n.options||{},r),new c(n.leaves,t,r)}getProofIndices(e,t){const r=Math.pow(2,t);let n=new Set;for(const t of e){let e=r+t;for(;e>1;)n.add(1^e),e=e/2|0}const i=e.map((e=>r+e)),o=Array.from(n).sort(((e,t)=>e-t)).reverse();n=i.concat(o);const a=new Set,s=[];for(let e of n)if(!a.has(e))for(s.push(e);e>1&&(a.add(e),a.has(1^e));)e=e/2|0;return s.filter((t=>!e.includes(t-r)))}getProofIndicesForUnevenTree(e,t){const r=Math.ceil(Math.log2(t)),n=[];for(let e=0;ee%2==0?e+1:e-1)).filter((e=>!o.includes(e)));const r=n.find((({index:t})=>t===e));r&&o.includes(r.leavesCount-1)&&(t=t.slice(0,-1)),i.push(t),o=[...new Set(o.map((e=>e%2==0?e/2:e%2==0?(e+1)/2:(e-1)/2)))]}return i}getMultiProof(e,t){this.complete||console.warn("Warning: For correct multiProofs it's strongly recommended to set complete: true"),t||(t=e,e=this.getLayersFlat());if(this.isUnevenTree()&&t.every(Number.isInteger))return this.getMultiProofForUnevenTree(t);if(!t.every(Number.isInteger)){let e=t;this.sortPairs&&(e=e.sort(i.Buffer.compare));let r=e.map((e=>this.bufferIndexOf(this.leaves,e,this.sortLeaves))).sort(((e,t)=>e===t?0:e>t?1:-1));if(!r.every((e=>-1!==e)))throw new Error("Element does not exist in Merkle tree");const n=[],o=[];let a=[];for(let e=0;er.indexOf(e)===t)),a=[]}return o.filter((e=>!n.includes(e)))}return this.getProofIndices(t,Math.log2(e.length/2|0)).map((t=>e[t]))}getMultiProofForUnevenTree(e,t){t||(t=e,e=this.getLayers());let r=[],n=t;for(const t of e){const e=[];for(const r of n){if(r%2==0){const i=r+1;if(!n.includes(i)&&t[i]){e.push(t[i]);continue}}const i=r-1;n.includes(i)||!t[i]||e.push(t[i])}r=r.concat(e);const i=new Set;for(const e of n)e%2!=0?e%2!=0?i.add((e-1)/2):i.add((e+1)/2):i.add(e/2);n=Array.from(i)}return r}getHexMultiProof(e,t){return this.getMultiProof(e,t).map((e=>this.bufferToHex(e)))}getProofFlags(e,t){if(!Array.isArray(e)||e.length<=0)throw new Error("Invalid Inputs!");let r;if(r=e.every(Number.isInteger)?[...e].sort(((e,t)=>e===t?0:e>t?1:-1)):e.map((e=>this.bufferIndexOf(this.leaves,e,this.sortLeaves))).sort(((e,t)=>e===t?0:e>t?1:-1)),!r.every((e=>-1!==e)))throw new Error("Element does not exist in Merkle tree");const n=t.map((e=>this.bufferify(e))),i=[],o=[];for(let e=0;e{if(!i.includes(t[r])){const e=this.getPairNode(t,r),a=n.includes(t[r])||n.includes(e);e&&o.push(!a),i.push(t[r]),i.push(e)}return e.push(r/2|0),e}),[])}return o}verify(e,t,r){let n=this.bufferify(t);if(r=this.bufferify(r),!Array.isArray(e)||!t||!r)return!1;for(let t=0;tthis.bufferify(e))),o=o.map((e=>this.bufferify(e)));const s={};for(const[e,n]of this.zip(t,r))s[Math.pow(2,a)+e]=n;for(const[e,r]of this.zip(this.getProofIndices(t,a),o))s[e]=r;let u=Object.keys(s).map((e=>+e)).sort(((e,t)=>e-t));u=u.slice(0,u.length-1);let c=0;for(;c=2&&{}.hasOwnProperty.call(s,1^e)){let t=[s[e-e%2],s[e-e%2+1]];this.sortPairs&&(t=t.sort(i.Buffer.compare));const r=t[1]?this.hashFn(this.concatenator(t)):t[0];s[e/2|0]=r,u.push(e/2|0)}c+=1}return!t.length||{}.hasOwnProperty.call(s,1)&&s[1].equals(e)}verifyMultiProofWithFlags(e,t,r,n){e=this.bufferify(e),t=t.map(this.bufferify),r=r.map(this.bufferify);const o=t.length,a=n.length,s=[];let u=0,c=0,l=0;for(let e=0;ethis.bufferify(e))),i=i.map((e=>this.bufferify(e)));const o=this.calculateRootForUnevenTree(t,r,n,i);return e.equals(o)}getDepth(){return this.getLayers().length-1}getLayersAsObject(){const e=this.getLayers().map((e=>e.map((e=>this.bufferToHex(e,!1))))),t=[];for(let r=0;re-t)),o=i.map((([e])=>e)),a=this.getProofIndicesForUnevenTree(o,r);let s=0;const u=[];for(let e=0;ee-t)).map((([,e])=>e)),r=c[e].map((([e])=>e)),n=[...new Set(r.map((e=>e%2==0?e/2:e%2==0?(e+1)/2:(e-1)/2)))],i=[];for(let e=0;e{var n=r(96240),i=r(29931);function o(e){this.rand=e||new i.Rand}e.exports=o,o.create=function(e){return new o(e)},o.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var i=new n(this.rand.generate(r))}while(i.cmp(e)>=0);return i},o.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},o.prototype.test=function(e,t,r){var i=e.bitLength(),o=n.mont(e),a=new n(1).toRed(o);t||(t=Math.max(1,i/48|0));for(var s=e.subn(1),u=0;!s.testn(u);u++);for(var c=e.shrn(u),l=s.toRed(o);t>0;t--){var f=this._randrange(new n(2),s);r&&r(f);var h=f.toRed(o).redPow(c);if(0!==h.cmp(a)&&0!==h.cmp(l)){for(var d=1;d0;t--){var l=this._randrange(new n(2),a),f=e.gcd(l);if(0!==f.cmpn(1))return f;var h=l.toRed(i).redPow(u);if(0!==h.cmp(o)&&0!==h.cmp(c)){for(var d=1;d=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},79746:e=>{function t(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=t,t.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},34504:(e,t)=>{"use strict";var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}},19516:(e,t,r)=>{var n=r(34155),i=r(28325),o=r(84574),a=r(24753),s=require,u=n.config&&n.config.variables||{},c=!!n.env.PREBUILDS_ONLY,l=n.versions.modules,f=!(!n.versions||!n.versions.electron)||!!n.env.ELECTRON_RUN_AS_NODE||"undefined"!=typeof window&&window.process&&"renderer"===window.process.type?"electron":n.versions&&n.versions.nw?"node-webkit":"node",h=n.env.npm_config_arch||a.arch(),d=n.env.npm_config_platform||a.platform(),p=n.env.LIBC||(function(e){return"linux"===e&&i.existsSync("/etc/alpine-release")}(d)?"musl":"glibc"),m=n.env.ARM_VERSION||("arm64"===h?"8":u.arm_version)||"",y=(n.versions.uv||"").split(".")[0];function g(e){return s(g.path(e))}function b(e){try{return i.readdirSync(e)}catch(e){return[]}}function v(e,t){var r=b(e).filter(t);return r[0]&&o.join(e,r[0])}function w(e){return/\.node$/.test(e)}function A(e){var t=e.split("-");if(2===t.length){var r=t[0],n=t[1].split("+");if(r&&n.length&&n.every(Boolean))return{name:e,platform:r,architectures:n}}}function S(e,t){return function(r){return null!=r&&(r.platform===e&&r.architectures.includes(t))}}function k(e,t){return e.architectures.length-t.architectures.length}function E(e){var t=e.split("."),r={file:e,specificity:0};if("node"===t.pop()){for(var n=0;nr.specificity?-1:1:0}}e.exports=g,g.path=function(e){e=o.resolve(e||".");try{var t=s(o.join(e,"package.json")).name.toUpperCase().replace(/-/g,"_");n.env[t+"_PREBUILD"]&&(e=n.env[t+"_PREBUILD"])}catch(e){}if(!c){var r=v(o.join(e,"build/Release"),w);if(r)return r;var i=v(o.join(e,"build/Debug"),w);if(i)return i}var a=T(e);if(a)return a;var u=T(o.dirname(n.execPath));if(u)return u;var g=["platform="+d,"arch="+h,"runtime="+f,"abi="+l,"uv="+y,m?"armv="+m:"","libc="+p,"node="+n.versions.node,n.versions.electron?"electron="+n.versions.electron:"","webpack=true"].filter(Boolean).join(" ");throw new Error("No native build was found for "+g+"\n loaded from: "+e+"\n");function T(e){var t=b(o.join(e,"prebuilds")).map(A).filter(S(d,h)).sort(k)[0];if(t){var r=o.join(e,"prebuilds",t.name),n=b(r).map(E).filter(_(f,l)).sort(M(f))[0];return n?o.join(r,n.file):void 0}}},g.parseTags=E,g.matchTags=_,g.compareTags=M,g.parseTuple=A,g.matchTuple=S,g.compareTuples=k},70631:(e,t,r)=>{var n="function"==typeof Map&&Map.prototype,i=Object.getOwnPropertyDescriptor&&n?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,o=n&&i&&"function"==typeof i.get?i.get:null,a=n&&Map.prototype.forEach,s="function"==typeof Set&&Set.prototype,u=Object.getOwnPropertyDescriptor&&s?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,c=s&&u&&"function"==typeof u.get?u.get:null,l=s&&Set.prototype.forEach,f="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,h="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,d="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,p=Boolean.prototype.valueOf,m=Object.prototype.toString,y=Function.prototype.toString,g=String.prototype.match,b=String.prototype.slice,v=String.prototype.replace,w=String.prototype.toUpperCase,A=String.prototype.toLowerCase,S=RegExp.prototype.test,k=Array.prototype.concat,E=Array.prototype.join,_=Array.prototype.slice,M=Math.floor,T="function"==typeof BigInt?BigInt.prototype.valueOf:null,x=Object.getOwnPropertySymbols,P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,I="function"==typeof Symbol&&"object"==typeof Symbol.iterator,O="function"==typeof Symbol&&Symbol.toStringTag&&(typeof Symbol.toStringTag===I||"symbol")?Symbol.toStringTag:null,R=Object.prototype.propertyIsEnumerable,C=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function B(e,t){if(e===1/0||e===-1/0||e!=e||e&&e>-1e3&&e<1e3||S.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof e){var n=e<0?-M(-e):M(e);if(n!==e){var i=String(n),o=b.call(t,i.length+1);return v.call(i,r,"$&_")+"."+v.call(v.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return v.call(t,r,"$&_")}var N=r(24654),L=N.custom,U=J(L)?L:null;function F(e,t,r){var n="double"===(r.quoteStyle||t)?'"':"'";return n+e+n}function D(e){return v.call(String(e),/"/g,""")}function j(e){return!("[object Array]"!==q(e)||O&&"object"==typeof e&&O in e)}function H(e){return!("[object RegExp]"!==q(e)||O&&"object"==typeof e&&O in e)}function J(e){if(I)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!P)return!1;try{return P.call(e),!0}catch(e){}return!1}e.exports=function e(t,r,n,i){var s=r||{};if(G(s,"quoteStyle")&&"single"!==s.quoteStyle&&"double"!==s.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(G(s,"maxStringLength")&&("number"==typeof s.maxStringLength?s.maxStringLength<0&&s.maxStringLength!==1/0:null!==s.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var u=!G(s,"customInspect")||s.customInspect;if("boolean"!=typeof u&&"symbol"!==u)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(G(s,"indent")&&null!==s.indent&&"\t"!==s.indent&&!(parseInt(s.indent,10)===s.indent&&s.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(G(s,"numericSeparator")&&"boolean"!=typeof s.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var m=s.numericSeparator;if(void 0===t)return"undefined";if(null===t)return"null";if("boolean"==typeof t)return t?"true":"false";if("string"==typeof t)return V(t,s);if("number"==typeof t){if(0===t)return 1/0/t>0?"0":"-0";var w=String(t);return m?B(t,w):w}if("bigint"==typeof t){var S=String(t)+"n";return m?B(t,S):S}var M=void 0===s.depth?5:s.depth;if(void 0===n&&(n=0),n>=M&&M>0&&"object"==typeof t)return j(t)?"[Array]":"[Object]";var x=function(e,t){var r;if("\t"===e.indent)r="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;r=E.call(Array(e.indent+1)," ")}return{base:r,prev:E.call(Array(t+1),r)}}(s,n);if(void 0===i)i=[];else if(K(i,t)>=0)return"[Circular]";function L(t,r,o){if(r&&(i=_.call(i)).push(r),o){var a={depth:s.depth};return G(s,"quoteStyle")&&(a.quoteStyle=s.quoteStyle),e(t,a,n+1,i)}return e(t,s,n+1,i)}if("function"==typeof t&&!H(t)){var z=function(e){if(e.name)return e.name;var t=g.call(y.call(e),/^function\s*([\w$]+)/);if(t)return t[1];return null}(t),X=$(t,L);return"[Function"+(z?": "+z:" (anonymous)")+"]"+(X.length>0?" { "+E.call(X,", ")+" }":"")}if(J(t)){var ee=I?v.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):P.call(t);return"object"!=typeof t||I?ee:Q(ee)}if(function(e){if(!e||"object"!=typeof e)return!1;if("undefined"!=typeof HTMLElement&&e instanceof HTMLElement)return!0;return"string"==typeof e.nodeName&&"function"==typeof e.getAttribute}(t)){for(var te="<"+A.call(String(t.nodeName)),re=t.attributes||[],ne=0;ne"}if(j(t)){if(0===t.length)return"[]";var ie=$(t,L);return x&&!function(e){for(var t=0;t=0)return!1;return!0}(ie)?"["+Y(ie,x)+"]":"[ "+E.call(ie,", ")+" ]"}if(function(e){return!("[object Error]"!==q(e)||O&&"object"==typeof e&&O in e)}(t)){var oe=$(t,L);return"cause"in Error.prototype||!("cause"in t)||R.call(t,"cause")?0===oe.length?"["+String(t)+"]":"{ ["+String(t)+"] "+E.call(oe,", ")+" }":"{ ["+String(t)+"] "+E.call(k.call("[cause]: "+L(t.cause),oe),", ")+" }"}if("object"==typeof t&&u){if(U&&"function"==typeof t[U]&&N)return N(t,{depth:M-n});if("symbol"!==u&&"function"==typeof t.inspect)return t.inspect()}if(function(e){if(!o||!e||"object"!=typeof e)return!1;try{o.call(e);try{c.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(t)){var ae=[];return a.call(t,(function(e,r){ae.push(L(r,t,!0)+" => "+L(e,t))})),Z("Map",o.call(t),ae,x)}if(function(e){if(!c||!e||"object"!=typeof e)return!1;try{c.call(e);try{o.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(t)){var se=[];return l.call(t,(function(e){se.push(L(e,t))})),Z("Set",c.call(t),se,x)}if(function(e){if(!f||!e||"object"!=typeof e)return!1;try{f.call(e,f);try{h.call(e,h)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(t))return W("WeakMap");if(function(e){if(!h||!e||"object"!=typeof e)return!1;try{h.call(e,h);try{f.call(e,f)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(t))return W("WeakSet");if(function(e){if(!d||!e||"object"!=typeof e)return!1;try{return d.call(e),!0}catch(e){}return!1}(t))return W("WeakRef");if(function(e){return!("[object Number]"!==q(e)||O&&"object"==typeof e&&O in e)}(t))return Q(L(Number(t)));if(function(e){if(!e||"object"!=typeof e||!T)return!1;try{return T.call(e),!0}catch(e){}return!1}(t))return Q(L(T.call(t)));if(function(e){return!("[object Boolean]"!==q(e)||O&&"object"==typeof e&&O in e)}(t))return Q(p.call(t));if(function(e){return!("[object String]"!==q(e)||O&&"object"==typeof e&&O in e)}(t))return Q(L(String(t)));if(!function(e){return!("[object Date]"!==q(e)||O&&"object"==typeof e&&O in e)}(t)&&!H(t)){var ue=$(t,L),ce=C?C(t)===Object.prototype:t instanceof Object||t.constructor===Object,le=t instanceof Object?"":"null prototype",fe=!ce&&O&&Object(t)===t&&O in t?b.call(q(t),8,-1):le?"Object":"",he=(ce||"function"!=typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(fe||le?"["+E.call(k.call([],fe||[],le||[]),": ")+"] ":"");return 0===ue.length?he+"{}":x?he+"{"+Y(ue,x)+"}":he+"{ "+E.call(ue,", ")+" }"}return String(t)};var z=Object.prototype.hasOwnProperty||function(e){return e in this};function G(e,t){return z.call(e,t)}function q(e){return m.call(e)}function K(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;rt.maxStringLength){var r=e.length-t.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return V(b.call(e,0,t.maxStringLength),t)+n}return F(v.call(v.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,X),"single",t)}function X(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+w.call(t.toString(16))}function Q(e){return"Object("+e+")"}function W(e){return e+" { ? }"}function Z(e,t,r,n){return e+" ("+t+") {"+(n?Y(r,n):E.call(r,", "))+"}"}function Y(e,t){if(0===e.length)return"";var r="\n"+t.prev+t.base;return r+E.call(e,","+r)+"\n"+t.prev}function $(e,t){var r=j(e),n=[];if(r){n.length=e.length;for(var i=0;i{e.exports=r(24753)},52818:(e,t,r)=>{"use strict";var n=r(39809);t.certificate=r(41934);var i=n.define("RSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())}));t.RSAPrivateKey=i;var o=n.define("RSAPublicKey",(function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())}));t.RSAPublicKey=o;var a=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())}));t.PublicKey=a;var s=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())})),u=n.define("PrivateKeyInfo",(function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(s),this.key("subjectPrivateKey").octstr())}));t.PrivateKey=u;var c=n.define("EncryptedPrivateKeyInfo",(function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())}));t.EncryptedPrivateKey=c;var l=n.define("DSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())}));t.DSAPrivateKey=l,t.DSAparam=n.define("DSAparam",(function(){this.int()}));var f=n.define("ECPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(h),this.key("publicKey").optional().explicit(1).bitstr())}));t.ECPrivateKey=f;var h=n.define("ECParameters",(function(){this.choice({namedCurve:this.objid()})}));t.signature=n.define("signature",(function(){this.seq().obj(this.key("r").int(),this.key("s").int())}))},41934:(e,t,r)=>{"use strict";var n=r(39809),i=n.define("Time",(function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})})),o=n.define("AttributeTypeValue",(function(){this.seq().obj(this.key("type").objid(),this.key("value").any())})),a=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())})),s=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(a),this.key("subjectPublicKey").bitstr())})),u=n.define("RelativeDistinguishedName",(function(){this.setof(o)})),c=n.define("RDNSequence",(function(){this.seqof(u)})),l=n.define("Name",(function(){this.choice({rdnSequence:this.use(c)})})),f=n.define("Validity",(function(){this.seq().obj(this.key("notBefore").use(i),this.key("notAfter").use(i))})),h=n.define("Extension",(function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())})),d=n.define("TBSCertificate",(function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(a),this.key("issuer").use(l),this.key("validity").use(f),this.key("subject").use(l),this.key("subjectPublicKeyInfo").use(s),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(h).optional())})),p=n.define("X509Certificate",(function(){this.seq().obj(this.key("tbsCertificate").use(d),this.key("signatureAlgorithm").use(a),this.key("signatureValue").bitstr())}));e.exports=p},77631:(e,t,r)=>{var n=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,i=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,o=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,a=r(13048),s=r(44696),u=r(89509).Buffer;e.exports=function(e,t){var r,c=e.toString(),l=c.match(n);if(l){var f="aes"+l[1],h=u.from(l[2],"hex"),d=u.from(l[3].replace(/[\r\n]/g,""),"base64"),p=a(t,h.slice(0,8),parseInt(l[1],10)).key,m=[],y=s.createDecipheriv(f,p,h);m.push(y.update(d)),m.push(y.final()),r=u.concat(m)}else{var g=c.match(o);r=u.from(g[2].replace(/[\r\n]/g,""),"base64")}return{tag:c.match(i)[1],data:r}}},70980:(e,t,r)=>{var n=r(52818),i=r(22562),o=r(77631),a=r(44696),s=r(25632),u=r(89509).Buffer;function c(e){var t;"object"!=typeof e||u.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=u.from(e));var r,c,l=o(e,t),f=l.tag,h=l.data;switch(f){case"CERTIFICATE":c=n.certificate.decode(h,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(c||(c=n.PublicKey.decode(h,"der")),r=c.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPublicKey.decode(c.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return c.subjectPrivateKey=c.subjectPublicKey,{type:"ec",data:c};case"1.2.840.10040.4.1":return c.algorithm.params.pub_key=n.DSAparam.decode(c.subjectPublicKey.data,"der"),{type:"dsa",data:c.algorithm.params};default:throw new Error("unknown key id "+r)}case"ENCRYPTED PRIVATE KEY":h=function(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,n=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),o=i[e.algorithm.decrypt.cipher.algo.join(".")],c=e.algorithm.decrypt.cipher.iv,l=e.subjectPrivateKey,f=parseInt(o.split("-")[1],10)/8,h=s.pbkdf2Sync(t,r,n,f,"sha1"),d=a.createDecipheriv(o,h,c),p=[];return p.push(d.update(l)),p.push(d.final()),u.concat(p)}(h=n.EncryptedPrivateKey.decode(h,"der"),t);case"PRIVATE KEY":switch(r=(c=n.PrivateKey.decode(h,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPrivateKey.decode(c.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:c.algorithm.curve,privateKey:n.ECPrivateKey.decode(c.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return c.algorithm.params.priv_key=n.DSAparam.decode(c.subjectPrivateKey,"der"),{type:"dsa",params:c.algorithm.params};default:throw new Error("unknown key id "+r)}case"RSA PUBLIC KEY":return n.RSAPublicKey.decode(h,"der");case"RSA PRIVATE KEY":return n.RSAPrivateKey.decode(h,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:n.DSAPrivateKey.decode(h,"der")};case"EC PRIVATE KEY":return{curve:(h=n.ECPrivateKey.decode(h,"der")).parameters.value,privateKey:h.privateKey};default:throw new Error("unknown key type "+f)}}e.exports=c,c.signature=n.signature},25632:(e,t,r)=>{t.pbkdf2=r(88638),t.pbkdf2Sync=r(91257)},88638:(e,t,r)=>{var n,i,o=r(89509).Buffer,a=r(77357),s=r(12368),u=r(91257),c=r(57777),l=r.g.crypto&&r.g.crypto.subtle,f={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},h=[];function d(){return i||(i=r.g.process&&r.g.process.nextTick?r.g.process.nextTick:r.g.queueMicrotask?r.g.queueMicrotask:r.g.setImmediate?r.g.setImmediate:r.g.setTimeout)}function p(e,t,r,n,i){return l.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then((function(e){return l.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},e,n<<3)})).then((function(e){return o.from(e)}))}e.exports=function(e,t,i,m,y,g){"function"==typeof y&&(g=y,y=void 0);var b=f[(y=y||"sha1").toLowerCase()];if(b&&"function"==typeof r.g.Promise){if(a(i,m),e=c(e,s,"Password"),t=c(t,s,"Salt"),"function"!=typeof g)throw new Error("No callback provided to pbkdf2");!function(e,t){e.then((function(e){d()((function(){t(null,e)}))}),(function(e){d()((function(){t(e)}))}))}(function(e){if(r.g.process&&!r.g.process.browser)return Promise.resolve(!1);if(!l||!l.importKey||!l.deriveBits)return Promise.resolve(!1);if(void 0!==h[e])return h[e];var t=p(n=n||o.alloc(8),n,10,128,e).then((function(){return!0})).catch((function(){return!1}));return h[e]=t,t}(b).then((function(r){return r?p(e,t,i,m,b):u(e,t,i,m,y)})),g)}else d()((function(){var r;try{r=u(e,t,i,m,y)}catch(e){return g(e)}g(null,r)}))}},12368:(e,t,r)=>{var n,i=r(34155);if(r.g.process&&r.g.process.browser)n="utf-8";else if(r.g.process&&r.g.process.version){n=parseInt(i.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary"}else n="utf-8";e.exports=n},77357:e=>{var t=Math.pow(2,30)-1;e.exports=function(e,r){if("number"!=typeof e)throw new TypeError("Iterations not a number");if(e<0)throw new TypeError("Bad iterations");if("number"!=typeof r)throw new TypeError("Key length not a number");if(r<0||r>t||r!=r)throw new TypeError("Bad key length")}},91257:(e,t,r)=>{var n=r(78028),i=r(79785),o=r(89072),a=r(89509).Buffer,s=r(77357),u=r(12368),c=r(57777),l=a.alloc(128),f={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function h(e,t,r){var s=function(e){function t(t){return o(e).update(t).digest()}function r(e){return(new i).update(e).digest()}return"rmd160"===e||"ripemd160"===e?r:"md5"===e?n:t}(e),u="sha512"===e||"sha384"===e?128:64;t.length>u?t=s(t):t.length{var n=r(89509).Buffer;e.exports=function(e,t,r){if(n.isBuffer(e))return e;if("string"==typeof e)return n.from(e,t);if(ArrayBuffer.isView(e))return n.from(e.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")}},34155:e=>{var t,r,n=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===i||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:i}catch(e){t=i}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(e){r=o}}();var s,u=[],c=!1,l=-1;function f(){c&&s&&(c=!1,s.length?u=s.concat(u):l=-1,u.length&&h())}function h(){if(!c){var e=a(f);c=!0;for(var t=u.length;t;){for(s=u,u=[];++l1)for(var r=1;r{t.publicEncrypt=r(16559),t.privateDecrypt=r(26138),t.privateEncrypt=function(e,r){return t.publicEncrypt(e,r,!0)},t.publicDecrypt=function(e,r){return t.privateDecrypt(e,r,!0)}},99199:(e,t,r)=>{var n=r(23482),i=r(89509).Buffer;function o(e){var t=i.allocUnsafe(4);return t.writeUInt32BE(e,0),t}e.exports=function(e,t){for(var r,a=i.alloc(0),s=0;a.length=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},26138:(e,t,r)=>{var n=r(70980),i=r(99199),o=r(57859),a=r(92144),s=r(23663),u=r(23482),c=r(84818),l=r(89509).Buffer;e.exports=function(e,t,r){var f;f=e.padding?e.padding:r?1:4;var h,d=n(e),p=d.modulus.byteLength();if(t.length>p||new a(t).cmp(d.modulus)>=0)throw new Error("decryption error");h=r?c(new a(t),d):s(t,d);var m=l.alloc(p-h.length);if(h=l.concat([m,h],p),4===f)return function(e,t){var r=e.modulus.byteLength(),n=u("sha1").update(l.alloc(0)).digest(),a=n.length;if(0!==t[0])throw new Error("decryption error");var s=t.slice(1,a+1),c=t.slice(a+1),f=o(s,i(c,a)),h=o(c,i(f,r-a-1));if(function(e,t){e=l.from(e),t=l.from(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));var i=-1;for(;++i=t.length){o++;break}var a=t.slice(2,i-1);("0002"!==n.toString("hex")&&!r||"0001"!==n.toString("hex")&&r)&&o++;a.length<8&&o++;if(o)throw new Error("decryption error");return t.slice(i)}(0,h,r);if(3===f)return h;throw new Error("unknown padding")}},16559:(e,t,r)=>{var n=r(70980),i=r(61798),o=r(23482),a=r(99199),s=r(57859),u=r(92144),c=r(84818),l=r(23663),f=r(89509).Buffer;e.exports=function(e,t,r){var h;h=e.padding?e.padding:r?1:4;var d,p=n(e);if(4===h)d=function(e,t){var r=e.modulus.byteLength(),n=t.length,c=o("sha1").update(f.alloc(0)).digest(),l=c.length,h=2*l;if(n>r-h-2)throw new Error("message too long");var d=f.alloc(r-n-h-2),p=r-l-1,m=i(l),y=s(f.concat([c,d,f.alloc(1,1),t],p),a(m,p)),g=s(m,a(y,l));return new u(f.concat([f.alloc(1),g,y],r))}(p,t);else if(1===h)d=function(e,t,r){var n,o=t.length,a=e.modulus.byteLength();if(o>a-11)throw new Error("message too long");n=r?f.alloc(a-o-3,255):function(e){var t,r=f.allocUnsafe(e),n=0,o=i(2*e),a=0;for(;n=0)throw new Error("data too long for modulus")}return r?l(d,p):c(d,p)}},84818:(e,t,r)=>{var n=r(92144),i=r(89509).Buffer;e.exports=function(e,t){return i.from(e.toRed(n.mont(t.modulus)).redPow(new n(t.publicExponent)).fromRed().toArray())}},57859:e=>{e.exports=function(e,t){for(var r=e.length,n=-1;++n{"use strict";var t=String.prototype.replace,r=/%20/g,n="RFC1738",i="RFC3986";e.exports={default:i,formatters:{RFC1738:function(e){return t.call(e,r,"+")},RFC3986:function(e){return String(e)}},RFC1738:n,RFC3986:i}},80129:(e,t,r)=>{"use strict";var n=r(58261),i=r(55235),o=r(55798);e.exports={formats:o,parse:i,stringify:n}},55235:(e,t,r)=>{"use strict";var n=r(12769),i=Object.prototype.hasOwnProperty,o=Array.isArray,a={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:n.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},s=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},u=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},c=function(e,t,r,n){if(e){var o=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,a=/(\[[^[\]]*])/g,s=r.depth>0&&/(\[[^[\]]*])/.exec(o),c=s?o.slice(0,s.index):o,l=[];if(c){if(!r.plainObjects&&i.call(Object.prototype,c)&&!r.allowPrototypes)return;l.push(c)}for(var f=0;r.depth>0&&null!==(s=a.exec(o))&&f=0;--o){var a,s=e[o];if("[]"===s&&r.parseArrays)a=[].concat(i);else{a=r.plainObjects?Object.create(null):{};var c="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,l=parseInt(c,10);r.parseArrays||""!==c?!isNaN(l)&&s!==c&&String(l)===c&&l>=0&&r.parseArrays&&l<=r.arrayLimit?(a=[])[l]=i:"__proto__"!==c&&(a[c]=i):a={0:i}}i=a}return i}(l,t,r,n)}};e.exports=function(e,t){var r=function(e){if(!e)return a;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?a.charset:e.charset;return{allowDots:void 0===e.allowDots?a.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:a.allowPrototypes,allowSparse:"boolean"==typeof e.allowSparse?e.allowSparse:a.allowSparse,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:a.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:a.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:a.comma,decoder:"function"==typeof e.decoder?e.decoder:a.decoder,delimiter:"string"==typeof e.delimiter||n.isRegExp(e.delimiter)?e.delimiter:a.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:a.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:a.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:a.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:a.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var l="string"==typeof e?function(e,t){var r,c={},l=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,f=t.parameterLimit===1/0?void 0:t.parameterLimit,h=l.split(t.delimiter,f),d=-1,p=t.charset;if(t.charsetSentinel)for(r=0;r-1&&(y=o(y)?[y]:y),i.call(c,m)?c[m]=n.combine(c[m],y):c[m]=y}return c}(e,r):e,f=r.plainObjects?Object.create(null):{},h=Object.keys(l),d=0;d{"use strict";var n=r(37478),i=r(12769),o=r(55798),a=Object.prototype.hasOwnProperty,s={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},u=Array.isArray,c=String.prototype.split,l=Array.prototype.push,f=function(e,t){l.apply(e,u(t)?t:[t])},h=Date.prototype.toISOString,d=o.default,p={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:i.encode,encodeValuesOnly:!1,format:d,formatter:o.formatters[d],indices:!1,serializeDate:function(e){return h.call(e)},skipNulls:!1,strictNullHandling:!1},m={},y=function e(t,r,o,a,s,l,h,d,y,g,b,v,w,A,S,k){for(var E,_=t,M=k,T=0,x=!1;void 0!==(M=M.get(m))&&!x;){var P=M.get(t);if(T+=1,void 0!==P){if(P===T)throw new RangeError("Cyclic object value");x=!0}void 0===M.get(m)&&(T=0)}if("function"==typeof d?_=d(r,_):_ instanceof Date?_=b(_):"comma"===o&&u(_)&&(_=i.maybeMap(_,(function(e){return e instanceof Date?b(e):e}))),null===_){if(s)return h&&!A?h(r,p.encoder,S,"key",v):r;_=""}if("string"==typeof(E=_)||"number"==typeof E||"boolean"==typeof E||"symbol"==typeof E||"bigint"==typeof E||i.isBuffer(_)){if(h){var I=A?r:h(r,p.encoder,S,"key",v);if("comma"===o&&A){for(var O=c.call(String(_),","),R="",C=0;C0?_.join(",")||null:void 0}];else if(u(d))B=d;else{var L=Object.keys(_);B=y?L.sort(y):L}for(var U=a&&u(_)&&1===_.length?r+"[]":r,F=0;F0?A+w:""}},12769:(e,t,r)=>{"use strict";var n=r(55798),i=Object.prototype.hasOwnProperty,o=Array.isArray,a=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),s=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},n=0;n1;){var t=e.pop(),r=t.obj[t.prop];if(o(r)){for(var n=[],i=0;i=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||o===n.RFC1738&&(40===l||41===l)?u+=s.charAt(c):l<128?u+=a[l]:l<2048?u+=a[192|l>>6]+a[128|63&l]:l<55296||l>=57344?u+=a[224|l>>12]+a[128|l>>6&63]+a[128|63&l]:(c+=1,l=65536+((1023&l)<<10|1023&s.charCodeAt(c)),u+=a[240|l>>18]+a[128|l>>12&63]+a[128|l>>6&63]+a[128|63&l])}return u},isBuffer:function(e){return!(!e||"object"!=typeof e)&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(o(e)){for(var r=[],n=0;n{"use strict";var n=r(34155),i=65536,o=4294967295;var a=r(89509).Buffer,s=r.g.crypto||r.g.msCrypto;s&&s.getRandomValues?e.exports=function(e,t){if(e>o)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(e);if(e>0)if(e>i)for(var u=0;u{"use strict";var n=r(34155);function i(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var o=r(89509),a=r(61798),s=o.Buffer,u=o.kMaxLength,c=r.g.crypto||r.g.msCrypto,l=Math.pow(2,32)-1;function f(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(e>l||e<0)throw new TypeError("offset must be a uint32");if(e>u||e>t)throw new RangeError("offset out of range")}function h(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(e>l||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>u)throw new RangeError("buffer too small")}function d(e,t,r,i){if(n.browser){var o=e.buffer,s=new Uint8Array(o,t,r);return c.getRandomValues(s),i?void n.nextTick((function(){i(null,e)})):e}if(!i)return a(r).copy(e,t),e;a(r,(function(r,n){if(r)return i(r);n.copy(e,t),i(null,e)}))}c&&c.getRandomValues||!n.browser?(t.randomFill=function(e,t,n,i){if(!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof t)i=t,t=0,n=e.length;else if("function"==typeof n)i=n,n=e.length-t;else if("function"!=typeof i)throw new TypeError('"cb" argument must be a function');return f(t,e.length),h(n,t,e.length),d(e,t,n,i)},t.randomFillSync=function(e,t,n){void 0===t&&(t=0);if(!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');f(t,e.length),void 0===n&&(n=e.length-t);return h(n,t,e.length),d(e,t,n)}):(t.randomFill=i,t.randomFillSync=i)},47055:(e,t,r)=>{e.exports=r(29344)},12401:e=>{"use strict";e.exports=class e{constructor(e,t=new Map,r=0){this.prefix=e,this._existing=t,this.counter=r}clone(){const{prefix:t,_existing:r,counter:n}=this;return new e(t,new Map(r),n)}getId(e){const t=e&&this._existing.get(e);if(t)return t;const r=this.prefix+this.counter;return this.counter++,e&&this._existing.set(e,r),r}hasId(e){return this._existing.has(e)}getOldIds(){return[...this._existing.keys()]}}},75947:(e,t,r)=>{"use strict";r(24889);const n=self.crypto||self.msCrypto;e.exports=class{constructor(e){if(!n||!n.subtle)throw new Error("crypto.subtle not found.");if("sha256"===e)this.algorithm={name:"SHA-256"};else{if("sha1"!==e)throw new Error(`Unsupported algorithm "${e}".`);this.algorithm={name:"SHA-1"}}this._content=""}update(e){this._content+=e}async digest(){const e=(new TextEncoder).encode(this._content),t=new Uint8Array(await n.subtle.digest(this.algorithm,e));let r="";for(let e=0;e{"use strict";const t="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",r="http://www.w3.org/2001/XMLSchema#string",n="NamedNode",i="BlankNode",o="Literal",a="DefaultGraph",s={};function u(e,t){return e.subject.termType===t.subject.termType&&e.object.termType===t.object.termType&&(e.subject.value===t.subject.value&&e.predicate.value===t.predicate.value&&e.object.value===t.object.value&&(e.object.termType!==o||e.object.datatype.termType===t.object.datatype.termType&&e.object.language===t.object.language&&e.object.datatype.value===t.object.datatype.value))}s.eoln=/(?:\r\n)|(?:\n)|(?:\r)/g,s.empty=new RegExp("^[ \\t]*$"),s.quad=new RegExp('^[ \\t]*(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9])(?:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀.])*(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀]))?))[ \\t]+(?:<([^:]+:[^>]*)>)[ \\t]+(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9])(?:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀.])*(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀]))?)|(?:"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"(?:(?:\\^\\^(?:<([^:]+:[^>]*)>))|(?:@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)))?))[ \\t]*(?:\\.|(?:(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9])(?:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀.])*(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀]))?))[ \\t]*\\.))[ \\t]*$'),e.exports=class e{static parse(e){const c=[],f={},h=e.split(s.eoln);let d=0;for(const e of h){if(d++,s.empty.test(e))continue;const h=e.match(s.quad);if(null===h)throw new Error("N-Quads parse error on line "+d+".");const p={subject:null,predicate:null,object:null,graph:null};if(void 0!==h[1]?p.subject={termType:n,value:h[1]}:p.subject={termType:i,value:h[2]},p.predicate={termType:n,value:h[3]},void 0!==h[4]?p.object={termType:n,value:h[4]}:void 0!==h[5]?p.object={termType:i,value:h[5]}:(p.object={termType:o,value:void 0,datatype:{termType:n}},void 0!==h[7]?p.object.datatype.value=h[7]:void 0!==h[8]?(p.object.datatype.value=t,p.object.language=h[8]):p.object.datatype.value=r,p.object.value=h[6].replace(l,(function(e,t,r,n){if(t)switch(t){case"t":return"\t";case"b":return"\b";case"n":return"\n";case"r":return"\r";case"f":return"\f";case'"':return'"';case"'":return"'";case"\\":return"\\"}if(r)return String.fromCharCode(parseInt(r,16));if(n)throw new Error("Unsupported U escape")}))),void 0!==h[9]?p.graph={termType:n,value:h[9]}:void 0!==h[10]?p.graph={termType:i,value:h[10]}:p.graph={termType:a,value:""},p.graph.value in f){let e=!0;const t=f[p.graph.value];for(const r of t)if(u(r,p)){e=!1;break}e&&(t.push(p),c.push(p))}else f[p.graph.value]=[p],c.push(p)}return c}static serialize(t){Array.isArray(t)||(t=e.legacyDatasetToQuads(t));const r=[];for(const n of t)r.push(e.serializeQuad(n));return r.sort().join("")}static serializeQuadComponents(e,o,a,s){let u="";return e.termType===n?u+=`<${e.value}>`:u+=`${e.value}`,u+=` <${o.value}> `,a.termType===n?u+=`<${a.value}>`:a.termType===i?u+=a.value:(u+=`"${function(e){return e.replace(c,(function(e){switch(e){case'"':return'\\"';case"\\":return"\\\\";case"\n":return"\\n";case"\r":return"\\r"}}))}(a.value)}"`,a.datatype.value===t?a.language&&(u+=`@${a.language}`):a.datatype.value!==r&&(u+=`^^<${a.datatype.value}>`)),s.termType===n?u+=` <${s.value}>`:s.termType===i&&(u+=` ${s.value}`),u+=" .\n",u}static serializeQuad(t){return e.serializeQuadComponents(t.subject,t.predicate,t.object,t.graph)}static legacyDatasetToQuads(e){const s=[],u={"blank node":i,IRI:n,literal:o};for(const c in e){e[c].forEach((e=>{const l={};for(const i in e){const a=e[i],s={termType:u[a.type],value:a.value};s.termType===o&&(s.datatype={termType:n},"datatype"in a&&(s.datatype.value=a.datatype),"language"in a?("datatype"in a||(s.datatype.value=t),s.language=a.language):"datatype"in a||(s.datatype.value=r)),l[i]=s}l.graph="@default"===c?{termType:a,value:""}:{termType:c.startsWith("_:")?i:n,value:c},s.push(l)}))}return s}};const c=/["\\\n\r]/g;const l=/(?:\\([tbnrf"'\\]))|(?:\\u([0-9A-Fa-f]{4}))|(?:\\U([0-9A-Fa-f]{8}))/g},68326:e=>{"use strict";e.exports=class{constructor(e){this.current=e.sort(),this.done=!1,this.dir=new Map;for(let t=0;tn)&&(s&&r>0&&a>e[r-1]||!s&&re[r+1])&&(n=a,i=r)}if(null===n)this.done=!0;else{const r=t.get(n)?i-1:i+1;e[i]=e[r],e[r]=n;for(const r of e)r>n&&t.set(r,!t.get(r))}return r}}},23445:(e,t,r)=>{"use strict";const n=r(12401),i=r(75947),o=r(68326),a=r(69980);function s(e,t){return e.hasht.hash?1:0}e.exports=class{constructor({maxDeepIterations:e=1/0}={}){this.name="URDNA2015",this.blankNodeInfo=new Map,this.canonicalIssuer=new n("_:c14n"),this.hashAlgorithm="sha256",this.maxDeepIterations=e,this.quads=null,this.deepIterations=null}async main(e){this.deepIterations=new Map,this.quads=e;for(const t of e)this._addBlankNodeQuadInfo({quad:t,component:t.subject}),this._addBlankNodeQuadInfo({quad:t,component:t.object}),this._addBlankNodeQuadInfo({quad:t,component:t.graph});const t=new Map,r=[...this.blankNodeInfo.keys()];let i=0;for(const e of r)++i%100==0&&await this._yield(),await this._hashAndTrackBlankNode({id:e,hashToBlankNodes:t});const o=[...t.keys()].sort(),u=[];for(const e of o){const r=t.get(e);if(r.length>1){u.push(r);continue}const n=r[0];this.canonicalIssuer.getId(n)}for(const e of u){const t=[];for(const r of e){if(this.canonicalIssuer.hasId(r))continue;const e=new n("_:b");e.getId(r);const i=await this.hashNDegreeQuads(r,e);t.push(i)}t.sort(s);for(const e of t){const t=e.issuer.getOldIds();for(const e of t)this.canonicalIssuer.getId(e)}}const c=[];for(const e of this.quads){const t=a.serializeQuadComponents(this._componentWithCanonicalId(e.subject),e.predicate,this._componentWithCanonicalId(e.object),this._componentWithCanonicalId(e.graph));c.push(t)}return c.sort(),c.join("")}async hashFirstDegreeQuads(e){const t=[],r=this.blankNodeInfo.get(e),n=r.quads;for(const r of n){const n={subject:null,predicate:r.predicate,object:null,graph:null};n.subject=this.modifyFirstDegreeComponent(e,r.subject,"subject"),n.object=this.modifyFirstDegreeComponent(e,r.object,"object"),n.graph=this.modifyFirstDegreeComponent(e,r.graph,"graph"),t.push(a.serializeQuad(n))}t.sort();const o=new i(this.hashAlgorithm);for(const e of t)o.update(e);return r.hash=await o.digest(),r.hash}async hashRelatedBlankNode(e,t,r,n){let o;o=this.canonicalIssuer.hasId(e)?this.canonicalIssuer.getId(e):r.hasId(e)?r.getId(e):this.blankNodeInfo.get(e).hash;const a=new i(this.hashAlgorithm);return a.update(n),"g"!==n&&a.update(this.getRelatedPredicate(t)),a.update(o),a.digest()}async hashNDegreeQuads(e,t){const r=this.deepIterations.get(e)||0;if(r>this.maxDeepIterations)throw new Error(`Maximum deep iterations (${this.maxDeepIterations}) exceeded.`);this.deepIterations.set(e,r+1);const n=new i(this.hashAlgorithm),a=await this.createHashToRelated(e,t),s=[...a.keys()].sort();for(const e of s){n.update(e);let r,i="";const s=new o(a.get(e));let u=0;for(;s.hasNext();){const e=s.next();++u%3==0&&await this._yield();let n=t.clone(),o="";const a=[];let c=!1;for(const t of e)if(this.canonicalIssuer.hasId(t)?o+=this.canonicalIssuer.getId(t):(n.hasId(t)||a.push(t),o+=n.getId(t)),0!==i.length&&o>i){c=!0;break}if(!c){for(const e of a){const t=await this.hashNDegreeQuads(e,n);if(o+=n.getId(e),o+=`<${t.hash}>`,n=t.issuer,0!==i.length&&o>i){c=!0;break}}c||(0===i.length||o`}async createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;let i=0;for(const o of n)++i%100==0&&await this._yield(),await Promise.all([this._addRelatedBlankNodeHash({quad:o,component:o.subject,position:"s",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.object,position:"o",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.graph,position:"g",id:e,issuer:t,hashToRelated:r})]);return r}async _hashAndTrackBlankNode({id:e,hashToBlankNodes:t}){const r=await this.hashFirstDegreeQuads(e),n=t.get(r);n?n.push(e):t.set(r,[e])}_addBlankNodeQuadInfo({quad:e,component:t}){if("BlankNode"!==t.termType)return;const r=t.value,n=this.blankNodeInfo.get(r);n?n.quads.add(e):this.blankNodeInfo.set(r,{quads:new Set([e]),hash:null})}async _addRelatedBlankNodeHash({quad:e,component:t,position:r,id:n,issuer:i,hashToRelated:o}){if("BlankNode"!==t.termType||t.value===n)return;const a=t.value,s=await this.hashRelatedBlankNode(a,e,i,r),u=o.get(s);u?u.push(a):o.set(s,[a])}_componentWithCanonicalId(e){return"BlankNode"!==e.termType||e.value.startsWith(this.canonicalIssuer.prefix)?e:{termType:"BlankNode",value:this.canonicalIssuer.getId(e.value)}}async _yield(){return new Promise((e=>setImmediate(e)))}}},5643:(e,t,r)=>{"use strict";const n=r(12401),i=r(75947),o=r(68326),a=r(69980);function s(e,t){return e.hasht.hash?1:0}e.exports=class{constructor({maxDeepIterations:e=1/0}={}){this.name="URDNA2015",this.blankNodeInfo=new Map,this.canonicalIssuer=new n("_:c14n"),this.hashAlgorithm="sha256",this.maxDeepIterations=e,this.quads=null,this.deepIterations=null}main(e){this.deepIterations=new Map,this.quads=e;for(const t of e)this._addBlankNodeQuadInfo({quad:t,component:t.subject}),this._addBlankNodeQuadInfo({quad:t,component:t.object}),this._addBlankNodeQuadInfo({quad:t,component:t.graph});const t=new Map,r=[...this.blankNodeInfo.keys()];for(const e of r)this._hashAndTrackBlankNode({id:e,hashToBlankNodes:t});const i=[...t.keys()].sort(),o=[];for(const e of i){const r=t.get(e);if(r.length>1){o.push(r);continue}const n=r[0];this.canonicalIssuer.getId(n)}for(const e of o){const t=[];for(const r of e){if(this.canonicalIssuer.hasId(r))continue;const e=new n("_:b");e.getId(r);const i=this.hashNDegreeQuads(r,e);t.push(i)}t.sort(s);for(const e of t){const t=e.issuer.getOldIds();for(const e of t)this.canonicalIssuer.getId(e)}}const u=[];for(const e of this.quads){const t=a.serializeQuadComponents(this._componentWithCanonicalId({component:e.subject}),e.predicate,this._componentWithCanonicalId({component:e.object}),this._componentWithCanonicalId({component:e.graph}));u.push(t)}return u.sort(),u.join("")}hashFirstDegreeQuads(e){const t=[],r=this.blankNodeInfo.get(e),n=r.quads;for(const r of n){const n={subject:null,predicate:r.predicate,object:null,graph:null};n.subject=this.modifyFirstDegreeComponent(e,r.subject,"subject"),n.object=this.modifyFirstDegreeComponent(e,r.object,"object"),n.graph=this.modifyFirstDegreeComponent(e,r.graph,"graph"),t.push(a.serializeQuad(n))}t.sort();const o=new i(this.hashAlgorithm);for(const e of t)o.update(e);return r.hash=o.digest(),r.hash}hashRelatedBlankNode(e,t,r,n){let o;o=this.canonicalIssuer.hasId(e)?this.canonicalIssuer.getId(e):r.hasId(e)?r.getId(e):this.blankNodeInfo.get(e).hash;const a=new i(this.hashAlgorithm);return a.update(n),"g"!==n&&a.update(this.getRelatedPredicate(t)),a.update(o),a.digest()}hashNDegreeQuads(e,t){const r=this.deepIterations.get(e)||0;if(r>this.maxDeepIterations)throw new Error(`Maximum deep iterations (${this.maxDeepIterations}) exceeded.`);this.deepIterations.set(e,r+1);const n=new i(this.hashAlgorithm),a=this.createHashToRelated(e,t),s=[...a.keys()].sort();for(const e of s){n.update(e);let r,i="";const s=new o(a.get(e));for(;s.hasNext();){const e=s.next();let n=t.clone(),o="";const a=[];let u=!1;for(const t of e)if(this.canonicalIssuer.hasId(t)?o+=this.canonicalIssuer.getId(t):(n.hasId(t)||a.push(t),o+=n.getId(t)),0!==i.length&&o>i){u=!0;break}if(!u){for(const e of a){const t=this.hashNDegreeQuads(e,n);if(o+=n.getId(e),o+=`<${t.hash}>`,n=t.issuer,0!==i.length&&o>i){u=!0;break}}u||(0===i.length||o`}createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;for(const i of n)this._addRelatedBlankNodeHash({quad:i,component:i.subject,position:"s",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:i,component:i.object,position:"o",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:i,component:i.graph,position:"g",id:e,issuer:t,hashToRelated:r});return r}_hashAndTrackBlankNode({id:e,hashToBlankNodes:t}){const r=this.hashFirstDegreeQuads(e),n=t.get(r);n?n.push(e):t.set(r,[e])}_addBlankNodeQuadInfo({quad:e,component:t}){if("BlankNode"!==t.termType)return;const r=t.value,n=this.blankNodeInfo.get(r);n?n.quads.add(e):this.blankNodeInfo.set(r,{quads:new Set([e]),hash:null})}_addRelatedBlankNodeHash({quad:e,component:t,position:r,id:n,issuer:i,hashToRelated:o}){if("BlankNode"!==t.termType||t.value===n)return;const a=t.value,s=this.hashRelatedBlankNode(a,e,i,r),u=o.get(s);u?u.push(a):o.set(s,[a])}_componentWithCanonicalId({component:e}){return"BlankNode"!==e.termType||e.value.startsWith(this.canonicalIssuer.prefix)?e:{termType:"BlankNode",value:this.canonicalIssuer.getId(e.value)}}}},89201:(e,t,r)=>{"use strict";const n=r(23445);e.exports=class extends n{constructor(){super(),this.name="URGNA2012",this.hashAlgorithm="sha1"}modifyFirstDegreeComponent(e,t,r){return"BlankNode"!==t.termType?t:"graph"===r?{termType:"BlankNode",value:"_:g"}:{termType:"BlankNode",value:t.value===e?"_:a":"_:z"}}getRelatedPredicate(e){return e.predicate.value}async createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;let i=0;for(const o of n){let n,a;if("BlankNode"===o.subject.termType&&o.subject.value!==e)a=o.subject.value,n="p";else{if("BlankNode"!==o.object.termType||o.object.value===e)continue;a=o.object.value,n="r"}++i%100==0&&await this._yield();const s=await this.hashRelatedBlankNode(a,o,t,n),u=r.get(s);u?u.push(a):r.set(s,[a])}return r}}},17702:(e,t,r)=>{"use strict";const n=r(5643);e.exports=class extends n{constructor(){super(),this.name="URGNA2012",this.hashAlgorithm="sha1"}modifyFirstDegreeComponent(e,t,r){return"BlankNode"!==t.termType?t:"graph"===r?{termType:"BlankNode",value:"_:g"}:{termType:"BlankNode",value:t.value===e?"_:a":"_:z"}}getRelatedPredicate(e){return e.predicate.value}createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;for(const i of n){let n,o;if("BlankNode"===i.subject.termType&&i.subject.value!==e)o=i.subject.value,n="p";else{if("BlankNode"!==i.object.termType||i.object.value===e)continue;o=i.object.value,n="r"}const a=this.hashRelatedBlankNode(o,i,t,n),s=r.get(a);s?s.push(o):r.set(a,[o])}return r}}},29344:(e,t,r)=>{"use strict";const n=r(23445),i=r(89201),o=r(5643),a=r(17702);let s;try{s=r(97670)}catch(e){}const u={};e.exports=u,u.NQuads=r(69980),u.IdentifierIssuer=r(12401),u._rdfCanonizeNative=function(e){return e&&(s=e),s},u.canonize=async function(e,t){if(Array.isArray(e)||(e=u.NQuads.legacyDatasetToQuads(e)),t.useNative){if(!s)throw new Error("rdf-canonize-native not available");return new Promise(((r,n)=>s.canonize(e,t,((e,t)=>e?n(e):r(t)))))}if("URDNA2015"===t.algorithm)return new n(t).main(e);if("URGNA2012"===t.algorithm)return new i(t).main(e);if(!("algorithm"in t))throw new Error("No RDF Dataset Canonicalization algorithm specified.");throw new Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)},u._canonizeSync=function(e,t){if(Array.isArray(e)||(e=u.NQuads.legacyDatasetToQuads(e)),t.useNative){if(s)return s.canonizeSync(e,t);throw new Error("rdf-canonize-native not available")}if("URDNA2015"===t.algorithm)return new o(t).main(e);if("URGNA2012"===t.algorithm)return new a(t).main(e);if(!("algorithm"in t))throw new Error("No RDF Dataset Canonicalization algorithm specified.");throw new Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)}},94281:e=>{"use strict";var t={};function r(e,r,n){n||(n=Error);var i=function(e){var t,n;function i(t,n,i){return e.call(this,function(e,t,n){return"string"==typeof r?r:r(e,t,n)}(t,n,i))||this}return n=e,(t=i).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n,i}(n);i.prototype.name=n.name,i.prototype.code=e,t[e]=i}function n(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map((function(e){return String(e)})),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}r("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),r("ERR_INVALID_ARG_TYPE",(function(e,t,r){var i,o,a,s;if("string"==typeof t&&(o="not ",t.substr(!a||a<0?0:+a,o.length)===o)?(i="must not be",t=t.replace(/^not /,"")):i="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))s="The ".concat(e," ").concat(i," ").concat(n(t,"type"));else{var u=function(e,t,r){return"number"!=typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}(e,".")?"property":"argument";s='The "'.concat(e,'" ').concat(u," ").concat(i," ").concat(n(t,"type"))}return s+=". Received type ".concat(typeof r)}),TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.q=t},56753:(e,t,r)=>{"use strict";var n=r(34155),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=l;var o=r(79481),a=r(64229);r(35717)(l,o);for(var s=i(a.prototype),u=0;u{"use strict";e.exports=i;var n=r(74605);function i(e){if(!(this instanceof i))return new i(e);n.call(this,e)}r(35717)(i,n),i.prototype._transform=function(e,t,r){r(null,e)}},79481:(e,t,r)=>{"use strict";var n,i=r(34155);e.exports=_,_.ReadableState=E;r(17187).EventEmitter;var o=function(e,t){return e.listeners(t).length},a=r(22503),s=r(48764).Buffer,u=r.g.Uint8Array||function(){};var c,l=r(94616);c=l&&l.debuglog?l.debuglog("stream"):function(){};var f,h,d,p=r(57327),m=r(61195),y=r(82457).getHighWaterMark,g=r(94281).q,b=g.ERR_INVALID_ARG_TYPE,v=g.ERR_STREAM_PUSH_AFTER_EOF,w=g.ERR_METHOD_NOT_IMPLEMENTED,A=g.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(35717)(_,a);var S=m.errorOrDestroy,k=["error","close","destroy","pause","resume"];function E(e,t,i){n=n||r(56753),e=e||{},"boolean"!=typeof i&&(i=t instanceof n),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",i),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(f||(f=r(32553).s),this.decoder=new f(e.encoding),this.encoding=e.encoding)}function _(e){if(n=n||r(56753),!(this instanceof _))return new _(e);var t=this instanceof n;this._readableState=new E(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),a.call(this)}function M(e,t,r,n,i){c("readableAddChunk",t);var o,a=e._readableState;if(null===t)a.reading=!1,function(e,t){if(c("onEofChunk"),t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?I(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,O(e)))}(e,a);else if(i||(o=function(e,t){var r;n=t,s.isBuffer(n)||n instanceof u||"string"==typeof t||void 0===t||e.objectMode||(r=new b("chunk",["string","Buffer","Uint8Array"],t));var n;return r}(a,t)),o)S(e,o);else if(a.objectMode||t&&t.length>0)if("string"==typeof t||a.objectMode||Object.getPrototypeOf(t)===s.prototype||(t=function(e){return s.from(e)}(t)),n)a.endEmitted?S(e,new A):T(e,a,t,!0);else if(a.ended)S(e,new v);else{if(a.destroyed)return!1;a.reading=!1,a.decoder&&!r?(t=a.decoder.write(t),a.objectMode||0!==t.length?T(e,a,t,!1):R(e,a)):T(e,a,t,!1)}else n||(a.reading=!1,R(e,a));return!a.ended&&(a.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=x?e=x:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function I(e){var t=e._readableState;c("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(c("emitReadable",t.flowing),t.emittedReadable=!0,i.nextTick(O,e))}function O(e){var t=e._readableState;c("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,U(e)}function R(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(C,e,t))}function C(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function N(e){c("readable nexttick read 0"),e.read(0)}function L(e,t){c("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(c("flow",t.flowing);t.flowing&&null!==e.read(););}function F(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function D(e){var t=e._readableState;c("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,i.nextTick(j,t,e))}function j(e,t){if(c("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function H(e,t){for(var r=0,n=e.length;r=t.highWaterMark:t.length>0)||t.ended))return c("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?D(this):I(this),null;if(0===(e=P(e,t))&&t.ended)return 0===t.length&&D(this),null;var n,i=t.needReadable;return c("need readable",i),(0===t.length||t.length-e0?F(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&D(this)),null!==n&&this.emit("data",n),n},_.prototype._read=function(e){S(this,new w("_read()"))},_.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e)}n.pipesCount+=1,c("pipe count=%d opts=%j",n.pipesCount,t);var a=(!t||!1!==t.end)&&e!==i.stdout&&e!==i.stderr?u:y;function s(t,i){c("onunpipe"),t===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,c("cleanup"),e.removeListener("close",p),e.removeListener("finish",m),e.removeListener("drain",l),e.removeListener("error",d),e.removeListener("unpipe",s),r.removeListener("end",u),r.removeListener("end",y),r.removeListener("data",h),f=!0,!n.awaitDrain||e._writableState&&!e._writableState.needDrain||l())}function u(){c("onend"),e.end()}n.endEmitted?i.nextTick(a):r.once("end",a),e.on("unpipe",s);var l=function(e){return function(){var t=e._readableState;c("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&o(e,"data")&&(t.flowing=!0,U(e))}}(r);e.on("drain",l);var f=!1;function h(t){c("ondata");var i=e.write(t);c("dest.write",i),!1===i&&((1===n.pipesCount&&n.pipes===e||n.pipesCount>1&&-1!==H(n.pipes,e))&&!f&&(c("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function d(t){c("onerror",t),y(),e.removeListener("error",d),0===o(e,"error")&&S(e,t)}function p(){e.removeListener("finish",m),y()}function m(){c("onfinish"),e.removeListener("close",p),y()}function y(){c("unpipe"),r.unpipe(e)}return r.on("data",h),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",d),e.once("close",p),e.once("finish",m),e.emit("pipe",r),n.flowing||(c("pipe resume"),r.resume()),e},_.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0,!1!==n.flowing&&this.resume()):"readable"===e&&(n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,c("on readable",n.length,n.reading),n.length?I(this):n.reading||i.nextTick(N,this))),r},_.prototype.addListener=_.prototype.on,_.prototype.removeListener=function(e,t){var r=a.prototype.removeListener.call(this,e,t);return"readable"===e&&i.nextTick(B,this),r},_.prototype.removeAllListeners=function(e){var t=a.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||i.nextTick(B,this),t},_.prototype.resume=function(){var e=this._readableState;return e.flowing||(c("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}(this,e)),e.paused=!1,this},_.prototype.pause=function(){return c("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(c("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},_.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",(function(){if(c("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(i){(c("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))})),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o{"use strict";e.exports=l;var n=r(94281).q,i=n.ERR_METHOD_NOT_IMPLEMENTED,o=n.ERR_MULTIPLE_CALLBACK,a=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=n.ERR_TRANSFORM_WITH_LENGTH_0,u=r(56753);function c(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length{"use strict";var n,i=r(34155);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}e.exports=_,_.WritableState=E;var a={deprecate:r(94927)},s=r(22503),u=r(48764).Buffer,c=r.g.Uint8Array||function(){};var l,f=r(61195),h=r(82457).getHighWaterMark,d=r(94281).q,p=d.ERR_INVALID_ARG_TYPE,m=d.ERR_METHOD_NOT_IMPLEMENTED,y=d.ERR_MULTIPLE_CALLBACK,g=d.ERR_STREAM_CANNOT_PIPE,b=d.ERR_STREAM_DESTROYED,v=d.ERR_STREAM_NULL_VALUES,w=d.ERR_STREAM_WRITE_AFTER_END,A=d.ERR_UNKNOWN_ENCODING,S=f.errorOrDestroy;function k(){}function E(e,t,a){n=n||r(56753),e=e||{},"boolean"!=typeof a&&(a=t instanceof n),this.objectMode=!!e.objectMode,a&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=h(this,e,"writableHighWaterMark",a),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var s=!1===e.decodeStrings;this.decodeStrings=!s,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if("function"!=typeof o)throw new y;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,n,o){--t.pendingcb,r?(i.nextTick(o,n),i.nextTick(O,e,t),e._writableState.errorEmitted=!0,S(e,n)):(o(n),e._writableState.errorEmitted=!0,S(e,n),O(e,t))}(e,r,n,t,o);else{var a=P(r)||e.destroyed;a||r.corked||r.bufferProcessing||!r.bufferedRequest||x(e,r),n?i.nextTick(T,e,r,a,o):T(e,r,a,o)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function _(e){var t=this instanceof(n=n||r(56753));if(!t&&!l.call(_,this))return new _(e);this._writableState=new E(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),s.call(this)}function M(e,t,r,n,i,o,a){t.writelen=n,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new b("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function T(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),O(e,t)}function x(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),a=t.corkedRequestsFree;a.entry=r;for(var s=0,u=!0;r;)i[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;i.allBuffers=u,M(e,t,!0,t.length,i,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,l=r.encoding,f=r.callback;if(M(e,t,!1,t.objectMode?1:c.length,c,l,f),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function P(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function I(e,t){e._final((function(r){t.pendingcb--,r&&S(e,r),t.prefinished=!0,e.emit("prefinish"),O(e,t)}))}function O(e,t){var r=P(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,i.nextTick(I,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}r(35717)(_,s),E.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(E.prototype,"buffer",{get:a.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(l=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!l.call(this,e)||this===_&&(e&&e._writableState instanceof E)}})):l=function(e){return e instanceof this},_.prototype.pipe=function(){S(this,new g)},_.prototype.write=function(e,t,r){var n,o=this._writableState,a=!1,s=!o.objectMode&&(n=e,u.isBuffer(n)||n instanceof c);return s&&!u.isBuffer(e)&&(e=function(e){return u.from(e)}(e)),"function"==typeof t&&(r=t,t=null),s?t="buffer":t||(t=o.defaultEncoding),"function"!=typeof r&&(r=k),o.ending?function(e,t){var r=new w;S(e,r),i.nextTick(t,r)}(this,r):(s||function(e,t,r,n){var o;return null===r?o=new v:"string"==typeof r||t.objectMode||(o=new p("chunk",["string","Buffer"],r)),!o||(S(e,o),i.nextTick(n,o),!1)}(this,o,e,r))&&(o.pendingcb++,a=function(e,t,r,n,i,o){if(!r){var a=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=u.from(t,r));return t}(t,n,i);n!==a&&(r=!0,i="buffer",n=a)}var s=t.objectMode?1:n.length;t.length+=s;var c=t.length-1))throw new A(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(_.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,r){r(new m("_write()"))},_.prototype._writev=null,_.prototype.end=function(e,t,r){var n=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||function(e,t,r){t.ending=!0,O(e,t),r&&(t.finished?i.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,n,r),this},Object.defineProperty(_.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(_.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=f.destroy,_.prototype._undestroy=f.undestroy,_.prototype._destroy=function(e,t){t(e)}},45850:(e,t,r)=>{"use strict";var n,i=r(34155);function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var a=r(8610),s=Symbol("lastResolve"),u=Symbol("lastReject"),c=Symbol("error"),l=Symbol("ended"),f=Symbol("lastPromise"),h=Symbol("handlePromise"),d=Symbol("stream");function p(e,t){return{value:e,done:t}}function m(e){var t=e[s];if(null!==t){var r=e[d].read();null!==r&&(e[f]=null,e[s]=null,e[u]=null,t(p(r,!1)))}}function y(e){i.nextTick(m,e)}var g=Object.getPrototypeOf((function(){})),b=Object.setPrototypeOf((o(n={get stream(){return this[d]},next:function(){var e=this,t=this[c];if(null!==t)return Promise.reject(t);if(this[l])return Promise.resolve(p(void 0,!0));if(this[d].destroyed)return new Promise((function(t,r){i.nextTick((function(){e[c]?r(e[c]):t(p(void 0,!0))}))}));var r,n=this[f];if(n)r=new Promise(function(e,t){return function(r,n){e.then((function(){t[l]?r(p(void 0,!0)):t[h](r,n)}),n)}}(n,this));else{var o=this[d].read();if(null!==o)return Promise.resolve(p(o,!1));r=new Promise(this[h])}return this[f]=r,r}},Symbol.asyncIterator,(function(){return this})),o(n,"return",(function(){var e=this;return new Promise((function(t,r){e[d].destroy(null,(function(e){e?r(e):t(p(void 0,!0))}))}))})),n),g);e.exports=function(e){var t,r=Object.create(b,(o(t={},d,{value:e,writable:!0}),o(t,s,{value:null,writable:!0}),o(t,u,{value:null,writable:!0}),o(t,c,{value:null,writable:!0}),o(t,l,{value:e._readableState.endEmitted,writable:!0}),o(t,h,{value:function(e,t){var n=r[d].read();n?(r[f]=null,r[s]=null,r[u]=null,e(p(n,!1))):(r[s]=e,r[u]=t)},writable:!0}),t));return r[f]=null,a(e,(function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[u];return null!==t&&(r[f]=null,r[s]=null,r[u]=null,t(e)),void(r[c]=e)}var n=r[s];null!==n&&(r[f]=null,r[s]=null,r[u]=null,n(p(void 0,!0))),r[l]=!0})),e.on("readable",y.bind(null,r)),r}},57327:(e,t,r)=>{"use strict";function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function o(e,t){for(var r=0;r0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return a.alloc(0);for(var t,r,n,i=a.allocUnsafe(e>>>0),o=this.head,s=0;o;)t=o.data,r=i,n=s,a.prototype.copy.call(t,r,n),s+=o.data.length,o=o.next;return i}},{key:"consume",value:function(e,t){var r;return ei.length?i.length:e;if(o===i.length?n+=i:n+=i.slice(0,e),0==(e-=o)){o===i.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(e){var t=a.allocUnsafe(e),r=this.head,n=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var i=r.data,o=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,o),0==(e-=o)){o===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(o));break}++n}return this.length-=n,t}},{key:u,value:function(e,t){return s(this,function(e){for(var t=1;t{"use strict";var n=r(34155);function i(e,t){a(e,t),o(e)}function o(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function a(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,s=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return s||u?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,n.nextTick(a,this,e)):n.nextTick(a,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!t&&e?r._writableState?r._writableState.errorEmitted?n.nextTick(o,r):(r._writableState.errorEmitted=!0,n.nextTick(i,r,e)):n.nextTick(i,r,e):t?(n.nextTick(o,r),t(e)):n.nextTick(o,r)})),this)},undestroy:function(){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)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}},8610:(e,t,r)=>{"use strict";var n=r(94281).q.ERR_STREAM_PREMATURE_CLOSE;function i(){}e.exports=function e(t,r,o){if("function"==typeof r)return e(t,null,r);r||(r={}),o=function(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i{e.exports=function(){throw new Error("Readable.from is not available in the browser")}},59946:(e,t,r)=>{"use strict";var n;var i=r(94281).q,o=i.ERR_MISSING_ARGS,a=i.ERR_STREAM_DESTROYED;function s(e){if(e)throw e}function u(e,t,i,o){o=function(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}(o);var s=!1;e.on("close",(function(){s=!0})),void 0===n&&(n=r(8610)),n(e,{readable:t,writable:i},(function(e){if(e)return o(e);s=!0,o()}));var u=!1;return function(t){if(!s&&!u)return u=!0,function(e){return e.setHeader&&"function"==typeof e.abort}(e)?e.abort():"function"==typeof e.destroy?e.destroy():void o(t||new a("pipe"))}}function c(e){e()}function l(e,t){return e.pipe(t)}function f(e){return e.length?"function"!=typeof e[e.length-1]?s:e.pop():s}e.exports=function(){for(var e=arguments.length,t=new Array(e),r=0;r0,(function(e){n||(n=e),e&&a.forEach(c),o||(a.forEach(c),i(n))}))}));return t.reduce(l)}},82457:(e,t,r)=>{"use strict";var n=r(94281).q.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,i){var o=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,i,r);if(null!=o){if(!isFinite(o)||Math.floor(o)!==o||o<0)throw new n(i?r:"highWaterMark",o);return Math.floor(o)}return e.objectMode?16:16384}}},22503:(e,t,r)=>{e.exports=r(17187).EventEmitter},88473:(e,t,r)=>{(t=e.exports=r(79481)).Stream=t,t.Readable=t,t.Writable=r(64229),t.Duplex=r(56753),t.Transform=r(74605),t.PassThrough=r(82725),t.finished=r(8610),t.pipeline=r(59946)},79785:(e,t,r)=>{"use strict";var n=r(48764).Buffer,i=r(35717),o=r(3349),a=new Array(16),s=[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],u=[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],c=[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],l=[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],f=[0,1518500249,1859775393,2400959708,2840853838],h=[1352829926,1548603684,1836072691,2053994217,0];function d(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(e,t){return e<>>32-t}function m(e,t,r,n,i,o,a,s){return p(e+(t^r^n)+o+a|0,s)+i|0}function y(e,t,r,n,i,o,a,s){return p(e+(t&r|~t&n)+o+a|0,s)+i|0}function g(e,t,r,n,i,o,a,s){return p(e+((t|~r)^n)+o+a|0,s)+i|0}function b(e,t,r,n,i,o,a,s){return p(e+(t&n|r&~n)+o+a|0,s)+i|0}function v(e,t,r,n,i,o,a,s){return p(e+(t^(r|~n))+o+a|0,s)+i|0}i(d,o),d.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,A=0|this._b,S=0|this._c,k=0|this._d,E=0|this._e,_=0;_<80;_+=1){var M,T;_<16?(M=m(r,n,i,o,d,e[s[_]],f[0],c[_]),T=v(w,A,S,k,E,e[u[_]],h[0],l[_])):_<32?(M=y(r,n,i,o,d,e[s[_]],f[1],c[_]),T=b(w,A,S,k,E,e[u[_]],h[1],l[_])):_<48?(M=g(r,n,i,o,d,e[s[_]],f[2],c[_]),T=g(w,A,S,k,E,e[u[_]],h[2],l[_])):_<64?(M=b(r,n,i,o,d,e[s[_]],f[3],c[_]),T=y(w,A,S,k,E,e[u[_]],h[3],l[_])):(M=v(r,n,i,o,d,e[s[_]],f[4],c[_]),T=m(w,A,S,k,E,e[u[_]],h[4],l[_])),r=d,d=o,o=p(i,10),i=n,n=M,w=E,E=k,k=p(S,10),S=A,A=T}var x=this._b+i+k|0;this._b=this._c+o+E|0,this._c=this._d+d+w|0,this._d=this._e+r+A|0,this._e=this._a+n+S|0,this._a=x},d.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 e=n.alloc?n.alloc(20):new n(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=d},89509:(e,t,r)=>{var n=r(48764),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=a),a.prototype=Object.create(i.prototype),o(i,a),a.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},2399:(e,t,r)=>{"use strict";var n,i=r(34155),o=r(48764),a=o.Buffer,s={};for(n in o)o.hasOwnProperty(n)&&"SlowBuffer"!==n&&"Buffer"!==n&&(s[n]=o[n]);var u=s.Buffer={};for(n in a)a.hasOwnProperty(n)&&"allocUnsafe"!==n&&"allocUnsafeSlow"!==n&&(u[n]=a[n]);if(s.Buffer.prototype=a.prototype,u.from&&u.from!==Uint8Array.from||(u.from=function(e,t,r){if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type '+typeof e);if(e&&void 0===e.length)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);return a(e,t,r)}),u.alloc||(u.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError('The "size" argument must be of type number. Received type '+typeof e);if(e<0||e>=2*(1<<30))throw new RangeError('The value "'+e+'" is invalid for option "size"');var n=a(e);return t&&0!==t.length?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n}),!s.kStringMaxLength)try{s.kStringMaxLength=i.binding("buffer").kStringMaxLength}catch(e){}s.constants||(s.constants={MAX_LENGTH:s.kMaxLength},s.kStringMaxLength&&(s.constants.MAX_STRING_LENGTH=s.kStringMaxLength)),e.exports=s},17635:function(e){"use strict";!function(t){const r=2147483647;function n(e){const t=new Uint32Array([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]);let r=1779033703,n=3144134277,i=1013904242,o=2773480762,a=1359893119,s=2600822924,u=528734635,c=1541459225;const l=new Uint32Array(64);function f(e){let f=0,h=e.length;for(;h>=64;){let d,p,m,y,g,b=r,v=n,w=i,A=o,S=a,k=s,E=u,_=c;for(p=0;p<16;p++)m=f+4*p,l[p]=(255&e[m])<<24|(255&e[m+1])<<16|(255&e[m+2])<<8|255&e[m+3];for(p=16;p<64;p++)d=l[p-2],y=(d>>>17|d<<15)^(d>>>19|d<<13)^d>>>10,d=l[p-15],g=(d>>>7|d<<25)^(d>>>18|d<<14)^d>>>3,l[p]=(y+l[p-7]|0)+(g+l[p-16]|0)|0;for(p=0;p<64;p++)y=(((S>>>6|S<<26)^(S>>>11|S<<21)^(S>>>25|S<<7))+(S&k^~S&E)|0)+(_+(t[p]+l[p]|0)|0)|0,g=((b>>>2|b<<30)^(b>>>13|b<<19)^(b>>>22|b<<10))+(b&v^b&w^v&w)|0,_=E,E=k,k=S,S=A+y|0,A=w,w=v,v=b,b=y+g|0;r=r+b|0,n=n+v|0,i=i+w|0,o=o+A|0,a=a+S|0,s=s+k|0,u=u+E|0,c=c+_|0,f+=64,h-=64}}f(e);let h,d=e.length%64,p=e.length/536870912|0,m=e.length<<3,y=d<56?56:120,g=e.slice(e.length-d,e.length);for(g.push(128),h=d+1;h>>24&255),g.push(p>>>16&255),g.push(p>>>8&255),g.push(p>>>0&255),g.push(m>>>24&255),g.push(m>>>16&255),g.push(m>>>8&255),g.push(m>>>0&255),f(g),[r>>>24&255,r>>>16&255,r>>>8&255,r>>>0&255,n>>>24&255,n>>>16&255,n>>>8&255,n>>>0&255,i>>>24&255,i>>>16&255,i>>>8&255,i>>>0&255,o>>>24&255,o>>>16&255,o>>>8&255,o>>>0&255,a>>>24&255,a>>>16&255,a>>>8&255,a>>>0&255,s>>>24&255,s>>>16&255,s>>>8&255,s>>>0&255,u>>>24&255,u>>>16&255,u>>>8&255,u>>>0&255,c>>>24&255,c>>>16&255,c>>>8&255,c>>>0&255]}function i(e,t,r){e=e.length<=64?e:n(e);const i=64+t.length+4,o=new Array(i),a=new Array(64);let s,u=[];for(s=0;s<64;s++)o[s]=54;for(s=0;s=i-4;e--){if(o[e]++,o[e]<=255)return;o[e]=0}}for(;r>=32;)c(),u=u.concat(n(a.concat(n(o)))),r-=32;return r>0&&(c(),u=u.concat(n(a.concat(n(o))).slice(0,r))),u}function o(e,t,r,n,i){let o;for(c(e,16*(2*r-1),i,0,16),o=0;o<2*r;o++)u(e,16*o,i,16),s(i,n),c(i,0,e,t+16*o,16);for(o=0;o>>32-t}function s(e,t){c(e,0,t,0,16);for(let e=8;e>0;e-=2)t[4]^=a(t[0]+t[12],7),t[8]^=a(t[4]+t[0],9),t[12]^=a(t[8]+t[4],13),t[0]^=a(t[12]+t[8],18),t[9]^=a(t[5]+t[1],7),t[13]^=a(t[9]+t[5],9),t[1]^=a(t[13]+t[9],13),t[5]^=a(t[1]+t[13],18),t[14]^=a(t[10]+t[6],7),t[2]^=a(t[14]+t[10],9),t[6]^=a(t[2]+t[14],13),t[10]^=a(t[6]+t[2],18),t[3]^=a(t[15]+t[11],7),t[7]^=a(t[3]+t[15],9),t[11]^=a(t[7]+t[3],13),t[15]^=a(t[11]+t[7],18),t[1]^=a(t[0]+t[3],7),t[2]^=a(t[1]+t[0],9),t[3]^=a(t[2]+t[1],13),t[0]^=a(t[3]+t[2],18),t[6]^=a(t[5]+t[4],7),t[7]^=a(t[6]+t[5],9),t[4]^=a(t[7]+t[6],13),t[5]^=a(t[4]+t[7],18),t[11]^=a(t[10]+t[9],7),t[8]^=a(t[11]+t[10],9),t[9]^=a(t[8]+t[11],13),t[10]^=a(t[9]+t[8],18),t[12]^=a(t[15]+t[14],7),t[13]^=a(t[12]+t[15],9),t[14]^=a(t[13]+t[12],13),t[15]^=a(t[14]+t[13],18);for(let r=0;r<16;++r)e[r]+=t[r]}function u(e,t,r,n){for(let i=0;i=256)return!1}return!0}function f(e,t){if("number"!=typeof e||e%1)throw new Error("invalid "+t);return e}function h(e,t,n,a,s,h,d){if(n=f(n,"N"),a=f(a,"r"),s=f(s,"p"),h=f(h,"dkLen"),0===n||0!=(n&n-1))throw new Error("N must be power of 2");if(n>r/128/a)throw new Error("N too large");if(a>r/128/s)throw new Error("r too large");if(!l(e))throw new Error("password must be an array or buffer");if(e=Array.prototype.slice.call(e),!l(t))throw new Error("salt must be an array or buffer");t=Array.prototype.slice.call(t);let p=i(e,t,128*s*a);const m=new Uint32Array(32*s*a);for(let e=0;eP&&(t=P);for(let e=0;eP&&(t=P);for(let e=0;e>0&255),p.push(m[e]>>8&255),p.push(m[e]>>16&255),p.push(m[e]>>24&255);const r=i(e,p,h);return d&&d(null,1,r),r}d&&I(O)};if(!d)for(;;){const e=O();if(null!=e)return e}O()}const d={scrypt:function(e,t,r,n,i,o,a){return new Promise((function(s,u){let c=0;a&&a(0),h(e,t,r,n,i,o,(function(e,t,r){if(e)u(e);else if(r)a&&1!==c&&a(1),s(new Uint8Array(r));else if(a&&t!==c)return c=t,a(t)}))}))},syncScrypt:function(e,t,r,n,i,o){return new Uint8Array(h(e,t,r,n,i,o))}};e.exports=d}()},24889:function(e,t,r){var n=r(34155);!function(e,t){"use strict";if(!e.setImmediate){var r,i,o,a,s,u=1,c={},l=!1,f=e.document,h=Object.getPrototypeOf&&Object.getPrototypeOf(e);h=h&&h.setTimeout?h:e,"[object process]"==={}.toString.call(e.process)?r=function(e){n.nextTick((function(){p(e)}))}:!function(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}()?e.MessageChannel?((o=new MessageChannel).port1.onmessage=function(e){p(e.data)},r=function(e){o.port2.postMessage(e)}):f&&"onreadystatechange"in f.createElement("script")?(i=f.documentElement,r=function(e){var t=f.createElement("script");t.onreadystatechange=function(){p(e),t.onreadystatechange=null,i.removeChild(t),t=null},i.appendChild(t)}):r=function(e){setTimeout(p,0,e)}:(a="setImmediate$"+Math.random()+"$",s=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(a)&&p(+t.data.slice(a.length))},e.addEventListener?e.addEventListener("message",s,!1):e.attachEvent("onmessage",s),r=function(t){e.postMessage(a+t,"*")}),h.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),n=0;n{var n=r(89509).Buffer;function i(e,t){this._block=n.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}i.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=n.from(e,t));for(var r=this._block,i=this._blockSize,o=e.length,a=this._len,s=0;s=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},89072:(e,t,r)=>{var n=e.exports=function(e){e=e.toLowerCase();var t=n[e];if(!t)throw new Error(e+" is not supported (we accept pull requests)");return new t};n.sha=r(74448),n.sha1=r(18336),n.sha224=r(48432),n.sha256=r(67499),n.sha384=r(51686),n.sha512=r(87816)},74448:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<30|e>>>2}function l(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,f=0;f<16;++f)r[f]=e.readInt32BE(4*f);for(;f<80;++f)r[f]=r[f-3]^r[f-8]^r[f-14]^r[f-16];for(var h=0;h<80;++h){var d=~~(h/20),p=0|((t=n)<<5|t>>>27)+l(d,i,o,s)+u+r[h]+a[d];u=s,s=o,o=c(i),i=n,n=p}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},18336:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<5|e>>>27}function l(e){return e<<30|e>>>2}function f(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,h=0;h<16;++h)r[h]=e.readInt32BE(4*h);for(;h<80;++h)r[h]=(t=r[h-3]^r[h-8]^r[h-14]^r[h-16])<<1|t>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=c(n)+f(p,i,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=l(i),i=n,n=m}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},48432:(e,t,r)=>{var n=r(35717),i=r(67499),o=r(24189),a=r(89509).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}n(u,i),u.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=u},67499:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[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],s=new Array(64);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function h(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function d(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}n(u,i),u.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,y=0|this._h,g=0;g<16;++g)r[g]=e.readInt32BE(4*g);for(;g<64;++g)r[g]=0|(((t=r[g-2])>>>17|t<<15)^(t>>>19|t<<13)^t>>>10)+r[g-7]+d(r[g-15])+r[g-16];for(var b=0;b<64;++b){var v=y+h(u)+c(u,p,m)+a[b]+r[b]|0,w=f(n)+l(n,i,o)|0;y=m,m=p,p=u,u=s+v|0,s=o,o=i,i=n,n=v+w|0}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=y+this._h|0},u.prototype._hash=function(){var e=o.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=u},51686:(e,t,r)=>{var n=r(35717),i=r(87816),o=r(24189),a=r(89509).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}n(u,i),u.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(48);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e},e.exports=u},87816:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],s=new Array(160);function u(){this.init(),this._w=s,i.call(this,128,112)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function h(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function d(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function p(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function y(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function g(e,t){return e>>>0>>0?1:0}n(u,i),u.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},u.prototype._update=function(e){for(var t=this._w,r=0|this._ah,n=0|this._bh,i=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,b=0|this._gh,v=0|this._hh,w=0|this._al,A=0|this._bl,S=0|this._cl,k=0|this._dl,E=0|this._el,_=0|this._fl,M=0|this._gl,T=0|this._hl,x=0;x<32;x+=2)t[x]=e.readInt32BE(4*x),t[x+1]=e.readInt32BE(4*x+4);for(;x<160;x+=2){var P=t[x-30],I=t[x-30+1],O=d(P,I),R=p(I,P),C=m(P=t[x-4],I=t[x-4+1]),B=y(I,P),N=t[x-14],L=t[x-14+1],U=t[x-32],F=t[x-32+1],D=R+L|0,j=O+N+g(D,R)|0;j=(j=j+C+g(D=D+B|0,B)|0)+U+g(D=D+F|0,F)|0,t[x]=j,t[x+1]=D}for(var H=0;H<160;H+=2){j=t[H],D=t[H+1];var J=l(r,n,i),z=l(w,A,S),G=f(r,w),q=f(w,r),K=h(s,E),V=h(E,s),X=a[H],Q=a[H+1],W=c(s,u,b),Z=c(E,_,M),Y=T+V|0,$=v+K+g(Y,T)|0;$=($=($=$+W+g(Y=Y+Z|0,Z)|0)+X+g(Y=Y+Q|0,Q)|0)+j+g(Y=Y+D|0,D)|0;var ee=q+z|0,te=G+J+g(ee,q)|0;v=b,T=M,b=u,M=_,u=s,_=E,s=o+$+g(E=k+Y|0,k)|0,o=i,k=S,i=n,S=A,n=r,A=w,r=$+te+g(w=Y+ee|0,Y)|0}this._al=this._al+w|0,this._bl=this._bl+A|0,this._cl=this._cl+S|0,this._dl=this._dl+k|0,this._el=this._el+E|0,this._fl=this._fl+_|0,this._gl=this._gl+M|0,this._hl=this._hl+T|0,this._ah=this._ah+r+g(this._al,w)|0,this._bh=this._bh+n+g(this._bl,A)|0,this._ch=this._ch+i+g(this._cl,S)|0,this._dh=this._dh+o+g(this._dl,k)|0,this._eh=this._eh+s+g(this._el,E)|0,this._fh=this._fh+u+g(this._fl,_)|0,this._gh=this._gh+b+g(this._gl,M)|0,this._hh=this._hh+v+g(this._hl,T)|0},u.prototype._hash=function(){var e=o.allocUnsafe(64);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=u},37478:(e,t,r)=>{"use strict";var n=r(40210),i=r(21924),o=r(70631),a=n("%TypeError%"),s=n("%WeakMap%",!0),u=n("%Map%",!0),c=i("WeakMap.prototype.get",!0),l=i("WeakMap.prototype.set",!0),f=i("WeakMap.prototype.has",!0),h=i("Map.prototype.get",!0),d=i("Map.prototype.set",!0),p=i("Map.prototype.has",!0),m=function(e,t){for(var r,n=e;null!==(r=n.next);n=r)if(r.key===t)return n.next=r.next,r.next=e.next,e.next=r,r};e.exports=function(){var e,t,r,n={assert:function(e){if(!n.has(e))throw new a("Side channel does not contain "+o(e))},get:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(e)return c(e,n)}else if(u){if(t)return h(t,n)}else if(r)return function(e,t){var r=m(e,t);return r&&r.value}(r,n)},has:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(e)return f(e,n)}else if(u){if(t)return p(t,n)}else if(r)return function(e,t){return!!m(e,t)}(r,n);return!1},set:function(n,i){s&&n&&("object"==typeof n||"function"==typeof n)?(e||(e=new s),l(e,n,i)):u?(t||(t=new u),d(t,n,i)):(r||(r={key:{},next:null}),function(e,t,r){var n=m(e,t);n?n.value=r:e.next={key:t,next:e.next,value:r}}(r,n,i))}};return n}},42830:(e,t,r)=>{e.exports=i;var n=r(17187).EventEmitter;function i(){n.call(this)}r(35717)(i,n),i.Readable=r(79481),i.Writable=r(64229),i.Duplex=r(56753),i.Transform=r(74605),i.PassThrough=r(82725),i.finished=r(8610),i.pipeline=r(59946),i.Stream=i,i.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",i),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",s),r.on("close",u));var a=!1;function s(){a||(a=!0,e.end())}function u(){a||(a=!0,"function"==typeof e.destroy&&e.destroy())}function c(e){if(l(),0===n.listenerCount(this,"error"))throw e}function l(){r.removeListener("data",i),e.removeListener("drain",o),r.removeListener("end",s),r.removeListener("close",u),r.removeListener("error",c),e.removeListener("error",c),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return r.on("error",c),e.on("error",c),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e}},8501:(e,t,r)=>{var n=r(11989),i=r(55676),o=r(47529),a=r(50584),s=r(8575),u=t;u.request=function(e,t){e="string"==typeof e?s.parse(e):o(e);var i=-1===r.g.location.protocol.search(/^https?:$/)?"http:":"",a=e.protocol||i,u=e.hostname||e.host,c=e.port,l=e.path||"/";u&&-1!==u.indexOf(":")&&(u="["+u+"]"),e.url=(u?a+"//"+u:"")+(c?":"+c:"")+l,e.method=(e.method||"GET").toUpperCase(),e.headers=e.headers||{};var f=new n(e);return t&&f.on("response",t),f},u.get=function(e,t){var r=u.request(e,t);return r.end(),r},u.ClientRequest=n,u.IncomingMessage=i.IncomingMessage,u.Agent=function(){},u.Agent.defaultMaxSockets=4,u.globalAgent=new u.Agent,u.STATUS_CODES=a,u.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]},8725:(e,t,r)=>{var n;function i(){if(void 0!==n)return n;if(r.g.XMLHttpRequest){n=new r.g.XMLHttpRequest;try{n.open("GET",r.g.XDomainRequest?"/":"https://example.com")}catch(e){n=null}}else n=null;return n}function o(e){var t=i();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}function a(e){return"function"==typeof e}t.fetch=a(r.g.fetch)&&a(r.g.ReadableStream),t.writableStream=a(r.g.WritableStream),t.abortController=a(r.g.AbortController),t.arraybuffer=t.fetch||o("arraybuffer"),t.msstream=!t.fetch&&o("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&o("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!i()&&a(i().overrideMimeType),n=null},11989:(e,t,r)=>{var n=r(48764).Buffer,i=r(34155),o=r(8725),a=r(35717),s=r(55676),u=r(88473),c=s.IncomingMessage,l=s.readyStates;var f=e.exports=function(e){var t,r=this;u.Writable.call(r),r._opts=e,r._body=[],r._headers={},e.auth&&r.setHeader("Authorization","Basic "+n.from(e.auth).toString("base64")),Object.keys(e.headers).forEach((function(t){r.setHeader(t,e.headers[t])}));var i=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!o.abortController)i=!1,t=!0;else if("prefer-streaming"===e.mode)t=!1;else if("allow-wrong-content-type"===e.mode)t=!o.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");t=!0}r._mode=function(e,t){return o.fetch&&t?"fetch":o.mozchunkedarraybuffer?"moz-chunked-arraybuffer":o.msstream?"ms-stream":o.arraybuffer&&e?"arraybuffer":"text"}(t,i),r._fetchTimer=null,r._socketTimeout=null,r._socketTimer=null,r.on("finish",(function(){r._onFinish()}))};a(f,u.Writable),f.prototype.setHeader=function(e,t){var r=e.toLowerCase();-1===h.indexOf(r)&&(this._headers[r]={name:e,value:t})},f.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},f.prototype.removeHeader=function(e){delete this._headers[e.toLowerCase()]},f.prototype._onFinish=function(){var e=this;if(!e._destroyed){var t=e._opts;"timeout"in t&&0!==t.timeout&&e.setTimeout(t.timeout);var n=e._headers,a=null;"GET"!==t.method&&"HEAD"!==t.method&&(a=new Blob(e._body,{type:(n["content-type"]||{}).value||""}));var s=[];if(Object.keys(n).forEach((function(e){var t=n[e].name,r=n[e].value;Array.isArray(r)?r.forEach((function(e){s.push([t,e])})):s.push([t,r])})),"fetch"===e._mode){var u=null;if(o.abortController){var c=new AbortController;u=c.signal,e._fetchAbortController=c,"requestTimeout"in t&&0!==t.requestTimeout&&(e._fetchTimer=r.g.setTimeout((function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()}),t.requestTimeout))}r.g.fetch(e._opts.url,{method:e._opts.method,headers:s,body:a||void 0,mode:"cors",credentials:t.withCredentials?"include":"same-origin",signal:u}).then((function(t){e._fetchResponse=t,e._resetTimers(!1),e._connect()}),(function(t){e._resetTimers(!0),e._destroyed||e.emit("error",t)}))}else{var f=e._xhr=new r.g.XMLHttpRequest;try{f.open(e._opts.method,e._opts.url,!0)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}"responseType"in f&&(f.responseType=e._mode),"withCredentials"in f&&(f.withCredentials=!!t.withCredentials),"text"===e._mode&&"overrideMimeType"in f&&f.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in t&&(f.timeout=t.requestTimeout,f.ontimeout=function(){e.emit("requestTimeout")}),s.forEach((function(e){f.setRequestHeader(e[0],e[1])})),e._response=null,f.onreadystatechange=function(){switch(f.readyState){case l.LOADING:case l.DONE:e._onXHRProgress()}},"moz-chunked-arraybuffer"===e._mode&&(f.onprogress=function(){e._onXHRProgress()}),f.onerror=function(){e._destroyed||(e._resetTimers(!0),e.emit("error",new Error("XHR error")))};try{f.send(a)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}}}},f.prototype._onXHRProgress=function(){var e=this;e._resetTimers(!1),function(e){try{var t=e.status;return null!==t&&0!==t}catch(e){return!1}}(e._xhr)&&!e._destroyed&&(e._response||e._connect(),e._response._onXHRProgress(e._resetTimers.bind(e)))},f.prototype._connect=function(){var e=this;e._destroyed||(e._response=new c(e._xhr,e._fetchResponse,e._mode,e._resetTimers.bind(e)),e._response.on("error",(function(t){e.emit("error",t)})),e.emit("response",e._response))},f.prototype._write=function(e,t,r){this._body.push(e),r()},f.prototype._resetTimers=function(e){var t=this;r.g.clearTimeout(t._socketTimer),t._socketTimer=null,e?(r.g.clearTimeout(t._fetchTimer),t._fetchTimer=null):t._socketTimeout&&(t._socketTimer=r.g.setTimeout((function(){t.emit("timeout")}),t._socketTimeout))},f.prototype.abort=f.prototype.destroy=function(e){var t=this;t._destroyed=!0,t._resetTimers(!0),t._response&&(t._response._destroyed=!0),t._xhr?t._xhr.abort():t._fetchAbortController&&t._fetchAbortController.abort(),e&&t.emit("error",e)},f.prototype.end=function(e,t,r){"function"==typeof e&&(r=e,e=void 0),u.Writable.prototype.end.call(this,e,t,r)},f.prototype.setTimeout=function(e,t){var r=this;t&&r.once("timeout",t),r._socketTimeout=e,r._resetTimers(!1)},f.prototype.flushHeaders=function(){},f.prototype.setNoDelay=function(){},f.prototype.setSocketKeepAlive=function(){};var h=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]},55676:(e,t,r)=>{var n=r(34155),i=r(48764).Buffer,o=r(8725),a=r(35717),s=r(88473),u=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},c=t.IncomingMessage=function(e,t,r,a){var u=this;if(s.Readable.call(u),u._mode=r,u.headers={},u.rawHeaders=[],u.trailers={},u.rawTrailers=[],u.on("end",(function(){n.nextTick((function(){u.emit("close")}))})),"fetch"===r){if(u._fetchResponse=t,u.url=t.url,u.statusCode=t.status,u.statusMessage=t.statusText,t.headers.forEach((function(e,t){u.headers[t.toLowerCase()]=e,u.rawHeaders.push(t,e)})),o.writableStream){var c=new WritableStream({write:function(e){return a(!1),new Promise((function(t,r){u._destroyed?r():u.push(i.from(e))?t():u._resumeFetch=t}))},close:function(){a(!0),u._destroyed||u.push(null)},abort:function(e){a(!0),u._destroyed||u.emit("error",e)}});try{return void t.body.pipeTo(c).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}catch(e){}}var l=t.body.getReader();!function e(){l.read().then((function(t){u._destroyed||(a(t.done),t.done?u.push(null):(u.push(i.from(t.value)),e()))})).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}()}else{if(u._xhr=e,u._pos=0,u.url=e.responseURL,u.statusCode=e.status,u.statusMessage=e.statusText,e.getAllResponseHeaders().split(/\r?\n/).forEach((function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var r=t[1].toLowerCase();"set-cookie"===r?(void 0===u.headers[r]&&(u.headers[r]=[]),u.headers[r].push(t[2])):void 0!==u.headers[r]?u.headers[r]+=", "+t[2]:u.headers[r]=t[2],u.rawHeaders.push(t[1],t[2])}})),u._charset="x-user-defined",!o.overrideMimeType){var f=u.rawHeaders["mime-type"];if(f){var h=f.match(/;\s*charset=([^;])(;|$)/);h&&(u._charset=h[1].toLowerCase())}u._charset||(u._charset="utf-8")}}};a(c,s.Readable),c.prototype._read=function(){var e=this._resumeFetch;e&&(this._resumeFetch=null,e())},c.prototype._onXHRProgress=function(e){var t=this,n=t._xhr,o=null;switch(t._mode){case"text":if((o=n.responseText).length>t._pos){var a=o.substr(t._pos);if("x-user-defined"===t._charset){for(var s=i.alloc(a.length),c=0;ct._pos&&(t.push(i.from(new Uint8Array(l.result.slice(t._pos)))),t._pos=l.result.byteLength)},l.onload=function(){e(!0),t.push(null)},l.readAsArrayBuffer(o)}t._xhr.readyState===u.DONE&&"ms-stream"!==t._mode&&(e(!0),t.push(null))}},32553:(e,t,r)=>{"use strict";var n=r(89509).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.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 o(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){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 e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=u,this.end=c,t=4;break;case"utf8":this.fillLast=s,t=4;break;case"base64":this.text=l,this.end=f,t=3;break;default:return this.write=h,void(this.end=d)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function a(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function u(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function c(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function l(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function h(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}t.s=o,o.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0)return i>0&&(e.lastNeed=i-1),i;if(--n=0)return i>0&&(e.lastNeed=i-2),i;if(--n=0)return i>0&&(2===i?i=0:e.lastNeed=i-3),i;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},o.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},99269:function(e){e.exports=function(){function e(e,t){var r=t?"└":"├";return r+=e?"─ ":"──┐"}function t(e,t){var r=[];for(var n in e)e.hasOwnProperty(n)&&(t&&"function"==typeof e[n]||r.push(n));return r}function r(n,i,o,a,s,u,c){var l,f,h="",d=0,p=a.slice(0);if(p.push([i,o])&&a.length>0&&(a.forEach((function(e,t){t>0&&(h+=(e[1]?" ":"│")+" "),f||e[0]!==i||(f=!0)})),h+=e(n,o)+n,s&&("object"!=typeof i||i instanceof Date)&&(h+=": "+i),f&&(h+=" (circular ref.)"),c(h)),!f&&"object"==typeof i){var m=t(i,u);m.forEach((function(e){l=++d===m.length,r(e,i[e],l,p,s,u,c)}))}}var n={asLines:function(e,t,n,i){r(".",e,!1,[],t,"function"!=typeof n&&n,i||n)},asTree:function(e,t,n){var i="";return r(".",e,!1,[],t,n,(function(e){i+=e+"\n"})),i}};return n}()},52511:function(e,t,r){var n;e=r.nmd(e),function(i){t&&t.nodeType,e&&e.nodeType;var o="object"==typeof r.g&&r.g;o.global!==o&&o.window!==o&&o.self;var a,s=2147483647,u=36,c=/^xn--/,l=/[^\x20-\x7E]/,f=/[\x2E\u3002\uFF0E\uFF61]/g,h={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},d=Math.floor,p=String.fromCharCode;function m(e){throw new RangeError(h[e])}function y(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function g(e,t){var r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+y((e=e.replace(f,".")).split("."),t).join(".")}function b(e){for(var t,r,n=[],i=0,o=e.length;i=55296&&t<=56319&&i65535&&(t+=p((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+=p(e)})).join("")}function w(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function A(e,t,r){var n=0;for(e=r?d(e/700):e>>1,e+=d(e/t);e>455;n+=u)e=d(e/35);return d(n+36*e/(e+38))}function S(e){var t,r,n,i,o,a,c,l,f,h,p,y=[],g=e.length,b=0,w=128,S=72;for((r=e.lastIndexOf("-"))<0&&(r=0),n=0;n=128&&m("not-basic"),y.push(e.charCodeAt(n));for(i=r>0?r+1:0;i=g&&m("invalid-input"),((l=(p=e.charCodeAt(i++))-48<10?p-22:p-65<26?p-65:p-97<26?p-97:u)>=u||l>d((s-b)/a))&&m("overflow"),b+=l*a,!(l<(f=c<=S?1:c>=S+26?26:c-S));c+=u)a>d(s/(h=u-f))&&m("overflow"),a*=h;S=A(b-o,t=y.length+1,0==o),d(b/t)>s-w&&m("overflow"),w+=d(b/t),b%=t,y.splice(b++,0,w)}return v(y)}function k(e){var t,r,n,i,o,a,c,l,f,h,y,g,v,S,k,E=[];for(g=(e=b(e)).length,t=128,r=0,o=72,a=0;a=t&&yd((s-r)/(v=n+1))&&m("overflow"),r+=(c-t)*v,t=c,a=0;as&&m("overflow"),y==t){for(l=r,f=u;!(l<(h=f<=o?1:f>=o+26?26:f-o));f+=u)k=l-h,S=u-h,E.push(p(w(h+k%S,0))),l=d(k/S);E.push(p(w(l,0))),o=A(r,v,n==i),r=0,++n}++r,++t}return E.join("")}a={version:"1.4.1",ucs2:{decode:b,encode:v},decode:S,encode:k,toASCII:function(e){return g(e,(function(e){return l.test(e)?"xn--"+k(e):e}))},toUnicode:function(e){return g(e,(function(e){return c.test(e)?S(e.slice(4).toLowerCase()):e}))}},void 0===(n=function(){return a}.call(t,r,t,e))||(e.exports=n)}()},8575:(e,t,r)=>{"use strict";var n=r(52511);function i(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var o=/^([a-z0-9.+-]+:)/i,a=/:[0-9]*$/,s=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,u=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),c=["'"].concat(u),l=["%","/","?",";","#"].concat(c),f=["/","?","#"],h=/^[+a-z0-9A-Z_-]{0,63}$/,d=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,p={javascript:!0,"javascript:":!0},m={javascript:!0,"javascript:":!0},y={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},g=r(80129);function b(e,t,r){if(e&&"object"==typeof e&&e instanceof i)return e;var n=new i;return n.parse(e,t,r),n}i.prototype.parse=function(e,t,r){if("string"!=typeof e)throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var i=e.indexOf("?"),a=-1!==i&&i127?R+="x":R+=O[C];if(!R.match(h)){var N=P.slice(0,M),L=P.slice(M+1),U=O.match(d);U&&(N.push(U[1]),L.unshift(U[2])),L.length&&(b="/"+L.join(".")+b),this.hostname=N.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),x||(this.hostname=n.toASCII(this.hostname));var F=this.port?":"+this.port:"",D=this.hostname||"";this.host=D+F,this.href+=this.host,x&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==b[0]&&(b="/"+b))}if(!p[A])for(M=0,I=c.length;M0)&&r.host.split("@"))&&(r.auth=x.shift(),r.hostname=x.shift(),r.host=r.hostname);return r.search=e.search,r.query=e.query,null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!S.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var E=S.slice(-1)[0],_=(r.host||e.host||S.length>1)&&("."===E||".."===E)||""===E,M=0,T=S.length;T>=0;T--)"."===(E=S[T])?S.splice(T,1):".."===E?(S.splice(T,1),M++):M&&(S.splice(T,1),M--);if(!w&&!A)for(;M--;M)S.unshift("..");!w||""===S[0]||S[0]&&"/"===S[0].charAt(0)||S.unshift(""),_&&"/"!==S.join("/").substr(-1)&&S.push("");var x,P=""===S[0]||S[0]&&"/"===S[0].charAt(0);k&&(r.hostname=P?"":S.length?S.shift():"",r.host=r.hostname,(x=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=x.shift(),r.hostname=x.shift(),r.host=r.hostname));return(w=w||r.host&&S.length)&&!P&&S.unshift(""),S.length>0?r.pathname=S.join("/"):(r.pathname=null,r.path=null),null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},i.prototype.parseHost=function(){var e=this.host,t=a.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},t.parse=b,t.resolve=function(e,t){return b(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?b(e,!1,!0).resolveObject(t):t},t.format=function(e){return"string"==typeof e&&(e=b(e)),e instanceof i?e.format():i.prototype.format.call(e)},t.Url=i},60137:e=>{"use strict";e.exports=function(e){const t=e.length;let r=0;for(;r=t||128!=(192&e[r+1])||128!=(192&e[r+2])||224===e[r]&&128==(224&e[r+1])||237===e[r]&&160==(224&e[r+1]))return!1;r+=3}else{if(240!=(248&e[r]))return!1;if(r+3>=t||128!=(192&e[r+1])||128!=(192&e[r+2])||128!=(192&e[r+3])||240===e[r]&&128==(240&e[r+1])||244===e[r]&&e[r+1]>143||e[r]>244)return!1;r+=4}return!0}},70311:(e,t,r)=>{"use strict";try{e.exports=r(19516)("/")}catch(t){e.exports=r(60137)}},94927:(e,t,r)=>{function n(e){try{if(!r.g.localStorage)return!1}catch(e){return!1}var t=r.g.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=function(e,t){if(n("noDeprecation"))return e;var r=!1;return function(){if(!r){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}},37918:e=>{var t;self,t=()=>(()=>{var e={1645:(e,t,r)=>{"use strict";var n=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.chains=t._getInitializedChains=void 0;var i=n(r(7295)),o=n(r(1227)),a=n(r(439)),s=n(r(7098)),u=n(r(7687));function c(e){var t,r,n={1:"mainnet",3:"ropsten",4:"rinkeby",42:"kovan",5:"goerli"},c={mainnet:i.default,ropsten:o.default,rinkeby:a.default,kovan:s.default,goerli:u.default};if(e)try{for(var l=function(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),f=l.next();!f.done;f=l.next()){var h=f.value,d=h.name;n[h.chainId.toString()]=d,c[d]=h}}catch(e){t={error:e}}finally{try{f&&!f.done&&(r=l.return)&&r.call(l)}finally{if(t)throw t.error}}return c.names=n,c}t._getInitializedChains=c,t.chains=c()},425:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EIPs=void 0,t.EIPs={1559:r(7523),2315:r(3339),2537:r(6769),2565:r(7897),2718:r(2170),2929:r(8436),2930:r(6213),3198:r(5491),3529:r(7852),3541:r(1871),3554:r(7225),3675:r(8571)}},7002:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hardforks=void 0,t.hardforks=[["chainstart",r(114)],["homestead",r(2800)],["dao",r(7197)],["tangerineWhistle",r(2302)],["spuriousDragon",r(716)],["byzantium",r(6985)],["constantinople",r(5993)],["petersburg",r(4064)],["istanbul",r(3166)],["muirGlacier",r(2946)],["berlin",r(15)],["london",r(1250)],["shanghai",r(5553)],["merge",r(8648)]]},3863:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=r(8847)(r(3355)),a=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),s=function(){return s=Object.assign||function(e){for(var t,r=1,n=arguments.length;r=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0}),t.ConsensusAlgorithm=t.ConsensusType=t.Hardfork=t.Chain=t.CustomChain=void 0;var c,l,f,h,d,p=r(8291),m=r(4628),y=r(3062),g=r(1645),b=r(7002),v=r(425);!function(e){e.PolygonMainnet="polygon-mainnet",e.PolygonMumbai="polygon-mumbai",e.ArbitrumRinkebyTestnet="arbitrum-rinkeby-testnet",e.xDaiChain="x-dai-chain"}(c=t.CustomChain||(t.CustomChain={})),(d=t.Chain||(t.Chain={}))[d.Mainnet=1]="Mainnet",d[d.Ropsten=3]="Ropsten",d[d.Rinkeby=4]="Rinkeby",d[d.Kovan=42]="Kovan",d[d.Goerli=5]="Goerli",function(e){e.Chainstart="chainstart",e.Homestead="homestead",e.Dao="dao",e.TangerineWhistle="tangerineWhistle",e.SpuriousDragon="spuriousDragon",e.Byzantium="byzantium",e.Constantinople="constantinople",e.Petersburg="petersburg",e.Istanbul="istanbul",e.MuirGlacier="muirGlacier",e.Berlin="berlin",e.London="london",e.Shanghai="shanghai",e.Merge="merge"}(l=t.Hardfork||(t.Hardfork={})),(h=t.ConsensusType||(t.ConsensusType={})).ProofOfStake="pos",h.ProofOfWork="pow",h.ProofOfAuthority="poa",(f=t.ConsensusAlgorithm||(t.ConsensusAlgorithm={})).Ethash="ethash",f.Clique="clique",f.Casper="casper";var w=function(e){function t(t){var r,n,i,o,a=e.call(this)||this;a._supportedHardforks=[],a._eips=[],a._customChains=null!==(i=t.customChains)&&void 0!==i?i:[],a._chainParams=a.setChain(t.chain),a.DEFAULT_HARDFORK=null!==(o=a._chainParams.defaultHardfork)&&void 0!==o?o:l.Istanbul;try{for(var s=u(a._chainParams.hardforks),c=s.next();!c.done;c=s.next()){var f=c.value;f.forkHash||(f.forkHash=a._calcForkHash(f.name))}}catch(e){r={error:e}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(r)throw r.error}}return a._hardfork=a.DEFAULT_HARDFORK,t.supportedHardforks&&(a._supportedHardforks=t.supportedHardforks),t.hardfork&&a.setHardfork(t.hardfork),t.eips&&a.setEIPs(t.eips),a}return a(t,e),t.custom=function(e,r){var n;void 0===r&&(r={});var i=null!==(n=r.baseChain)&&void 0!==n?n:"mainnet",o=s({},t._getChainParams(i));if(o.name="custom-chain","string"!=typeof e)return new t(s({chain:s(s({},o),e)},r));if(e===c.PolygonMainnet)return t.custom({name:c.PolygonMainnet,chainId:137,networkId:137});if(e===c.PolygonMumbai)return t.custom({name:c.PolygonMumbai,chainId:80001,networkId:80001});if(e===c.ArbitrumRinkebyTestnet)return t.custom({name:c.ArbitrumRinkebyTestnet,chainId:421611,networkId:421611});if(e===c.xDaiChain)return t.custom({name:c.xDaiChain,chainId:100,networkId:100});throw new Error("Custom chain "+e+" not supported")},t.forCustomChain=function(e,r,n,i){var o=t._getChainParams(e);return new t({chain:s(s({},o),r),hardfork:n,supportedHardforks:i})},t.isSupportedChainId=function(e){var t=(0,g._getInitializedChains)();return Boolean(t.names[e.toString()])},t._getChainParams=function(e,t){var r=(0,g._getInitializedChains)(t);if("number"==typeof e||y.BN.isBN(e)){if(e=e.toString(),r.names[e])return r[r.names[e]];throw new Error("Chain with ID "+e+" not supported")}if(r[e])return r[e];throw new Error("Chain with name "+e+" not supported")},t.prototype.setChain=function(e){var r,n;if("number"==typeof e||"string"==typeof e||y.BN.isBN(e)){var i;i=this._customChains&&this._customChains.length>0&&Array.isArray(this._customChains[0])?this._customChains.map((function(e){return e[0]})):this._customChains,this._chainParams=t._getChainParams(e,i)}else{if("object"!==(0,o.default)(e))throw new Error("Wrong input format");if(this._customChains.length>0)throw new Error("Chain must be a string, number, or BN when initialized with customChains passed in");try{for(var a=u(["networkId","genesis","hardforks","bootstrapNodes"]),s=a.next();!s.done;s=a.next()){var c=s.value;if(void 0===e[c])throw new Error("Missing required chain parameter: "+c)}}catch(e){r={error:e}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}this._chainParams=e}return this._chainParams},t.prototype.setHardfork=function(e){var t,r;if(!this._isSupportedHardfork(e))throw new Error("Hardfork "+e+" not set as supported in supportedHardforks");var n=!1;try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next())o.value[0]===e&&(this._hardfork!==e&&(this._hardfork=e,this.emit("hardforkChanged",e)),n=!0)}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}if(!n)throw new Error("Hardfork with name "+e+" not supported")},t.prototype.getHardforkByBlockNumber=function(e,t){var r,n;e=(0,y.toType)(e,y.TypeOutput.BN),t=t?(0,y.toType)(t,y.TypeOutput.BN):void 0;var i,o,a,s=l.Chainstart;try{for(var c=u(this.hardforks()),f=c.next();!f.done;f=c.next()){var h=f.value;if(null!==h.block)e.gte(new y.BN(h.block))&&(s=h.name),t&&h.td&&(t.gten(h.td)?i=h.name:o=a),a=h.name;else if(t&&h.td&&t.gten(h.td))return h.name}}catch(e){r={error:e}}finally{try{f&&!f.done&&(n=c.return)&&n.call(c)}finally{if(r)throw r.error}}if(t){var d="block number: "+e+" (-> "+s+"), ";if(i&&!this.hardforkGteHardfork(s,i)){var p="HF determined by block number is lower than the minimum total difficulty HF";throw d+="total difficulty: "+t+" (-> "+i+")",new Error(p+": "+d)}if(o&&!this.hardforkGteHardfork(o,s))throw p="Maximum HF determined by total difficulty is lower than the block number HF",d+="total difficulty: "+t+" (-> "+o+")",new Error(p+": "+d)}return s},t.prototype.setHardforkByBlockNumber=function(e,t){var r=this.getHardforkByBlockNumber(e,t);return this.setHardfork(r),r},t.prototype._chooseHardfork=function(e,t){if(void 0===t&&(t=!0),e){if(t&&!this._isSupportedHardfork(e))throw new Error("Hardfork "+e+" not set as supported in supportedHardforks")}else e=this._hardfork;return e},t.prototype._getHardfork=function(e){var t,r,n=this.hardforks();try{for(var i=u(n),o=i.next();!o.done;o=i.next()){var a=o.value;if(a.name===e)return a}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}throw new Error("Hardfork "+e+" not defined for chain "+this.chainName())},t.prototype._isSupportedHardfork=function(e){var t,r;if(!(this._supportedHardforks.length>0))return!0;try{for(var n=u(this._supportedHardforks),i=n.next();!i.done;i=n.next())if(e===i.value)return!0}catch(e){t={error:e}}finally{try{i&&!i.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}return!1},t.prototype.setEIPs=function(e){var t,r,n=this;void 0===e&&(e=[]);var i=function(t){if(!(t in v.EIPs))throw new Error(t+" not supported");var r=o.gteHardfork(v.EIPs[t].minimumHardfork);if(!r)throw new Error(t+" cannot be activated on hardfork "+o.hardfork()+", minimumHardfork: "+r);v.EIPs[t].requiredEIPs&&v.EIPs[t].requiredEIPs.forEach((function(r){if(!e.includes(r)&&!n.isActivatedEIP(r))throw new Error(t+" requires EIP "+r+", but is not included in the EIP list")}))},o=this;try{for(var a=u(e),s=a.next();!s.done;s=a.next())i(s.value)}catch(e){t={error:e}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}this._eips=e},t.prototype.param=function(e,t){var r,n,i=null;try{for(var o=u(this._eips),a=o.next();!a.done;a=o.next()){var s=a.value;if(null!==(i=this.paramByEIP(e,t,s)))return i}}catch(e){r={error:e}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return this.paramByHardfork(e,t,this._hardfork)},t.prototype.paramByHardfork=function(e,t,r){var n,i,o,a;r=this._chooseHardfork(r);var s=null;try{for(var c=u(b.hardforks),l=c.next();!l.done;l=c.next()){var f=l.value;if("eips"in f[1]){var h=f[1].eips;try{for(var d=(o=void 0,u(h)),p=d.next();!p.done;p=d.next()){var m=p.value,y=this.paramByEIP(e,t,m);s=null!==y?y:s}}catch(e){o={error:e}}finally{try{p&&!p.done&&(a=d.return)&&a.call(d)}finally{if(o)throw o.error}}}else{if(!f[1][e])throw new Error("Topic "+e+" not defined");void 0!==f[1][e][t]&&(s=f[1][e][t].v)}if(f[0]===r)break}}catch(e){n={error:e}}finally{try{l&&!l.done&&(i=c.return)&&i.call(c)}finally{if(n)throw n.error}}return s},t.prototype.paramByEIP=function(e,t,r){if(!(r in v.EIPs))throw new Error(r+" not supported");var n=v.EIPs[r];if(!(e in n))throw new Error("Topic "+e+" not defined");return void 0===n[e][t]?null:n[e][t].v},t.prototype.paramByBlock=function(e,t,r){var n=this.activeHardforks(r),i=n[n.length-1].name;return this.paramByHardfork(e,t,i)},t.prototype.isActivatedEIP=function(e){var t,r;if(this.eips().includes(e))return!0;try{for(var n=u(b.hardforks),i=n.next();!i.done;i=n.next()){var o=i.value[1];if(this.gteHardfork(o.name)&&"eips"in o&&o.eips.includes(e))return!0}}catch(e){t={error:e}}finally{try{i&&!i.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}return!1},t.prototype.hardforkIsActiveOnBlock=function(e,t,r){var n;void 0===r&&(r={}),t=(0,y.toType)(t,y.TypeOutput.BN);var i=null!==(n=r.onlySupported)&&void 0!==n&&n;e=this._chooseHardfork(e,i);var o=this.hardforkBlockBN(e);return!(!o||!t.gte(o))},t.prototype.activeOnBlock=function(e,t){return this.hardforkIsActiveOnBlock(null,e,t)},t.prototype.hardforkGteHardfork=function(e,t,r){var n,i;void 0===r&&(r={});var o,a=void 0!==r.onlyActive&&r.onlyActive;e=this._chooseHardfork(e,r.onlySupported),o=a?this.activeHardforks(null,r):this.hardforks();var s=-1,c=-1,l=0;try{for(var f=u(o),h=f.next();!h.done;h=f.next()){var d=h.value;d.name===e&&(s=l),d.name===t&&(c=l),l+=1}}catch(e){n={error:e}}finally{try{h&&!h.done&&(i=f.return)&&i.call(f)}finally{if(n)throw n.error}}return s>=c&&-1!==c},t.prototype.gteHardfork=function(e,t){return this.hardforkGteHardfork(null,e,t)},t.prototype.hardforkIsActiveOnChain=function(e,t){var r,n,i;void 0===t&&(t={});var o=null!==(i=t.onlySupported)&&void 0!==i&&i;e=this._chooseHardfork(e,o);try{for(var a=u(this.hardforks()),s=a.next();!s.done;s=a.next()){var c=s.value;if(c.name===e&&null!==c.block)return!0}}catch(e){r={error:e}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}return!1},t.prototype.activeHardforks=function(e,t){var r,n;void 0===t&&(t={});var i=[],o=this.hardforks();try{for(var a=u(o),s=a.next();!s.done;s=a.next()){var c=s.value;if(null!==c.block){if(null!=e&&e0)return r[r.length-1].name;throw new Error("No (supported) active hardfork found")},t.prototype.hardforkBlock=function(e){var t=this.hardforkBlockBN(e);return t?(0,y.toType)(t,y.TypeOutput.Number):null},t.prototype.hardforkBlockBN=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e).block;return null==t?null:new y.BN(t)},t.prototype.hardforkTD=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e).td;return null==t?null:new y.BN(t)},t.prototype.isHardforkBlock=function(e,t){e=(0,y.toType)(e,y.TypeOutput.BN),t=this._chooseHardfork(t,!1);var r=this.hardforkBlockBN(t);return!!r&&r.eq(e)},t.prototype.nextHardforkBlock=function(e){var t=this.nextHardforkBlockBN(e);return null===t?null:(0,y.toType)(t,y.TypeOutput.Number)},t.prototype.nextHardforkBlockBN=function(e){e=this._chooseHardfork(e,!1);var t=this.hardforkBlockBN(e);return null===t?null:this.hardforks().reduce((function(e,r){var n=new y.BN(r.block);return n.gt(t)&&null===e?n:e}),null)},t.prototype.isNextHardforkBlock=function(e,t){e=(0,y.toType)(e,y.TypeOutput.BN),t=this._chooseHardfork(t,!1);var r=this.nextHardforkBlockBN(t);return null!==r&&r.eq(e)},t.prototype._calcForkHash=function(e){var t,r,n=i.from(this.genesis().hash.substr(2),"hex"),o=i.alloc(0),a=0;try{for(var s=u(this.hardforks()),c=s.next();!c.done;c=s.next()){var l=c.value,f=l.block;if(0!==f&&null!==f&&f!==a){var h=i.from(f.toString(16).padStart(16,"0"),"hex");o=i.concat([o,h])}if(l.name===e)break;null!==f&&(a=f)}}catch(e){t={error:e}}finally{try{c&&!c.done&&(r=s.return)&&r.call(s)}finally{if(t)throw t.error}}var d=i.concat([n,o]);return"0x"+(0,y.intToBuffer)((0,m.buf)(d)>>>0).toString("hex")},t.prototype.forkHash=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e);if(null===t.block)throw new Error("No fork hash calculation possible for non-applied or future hardfork");return void 0!==t.forkHash?t.forkHash:this._calcForkHash(e)},t.prototype.hardforkForForkHash=function(e){var t=this.hardforks().filter((function(t){return t.forkHash===e}));return t.length>=1?t[t.length-1]:null},t.prototype.genesis=function(){return this._chainParams.genesis},t.prototype.genesisState=function(){var e,t;switch(this.chainName()){case"mainnet":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/mainnet.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"ropsten":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/ropsten.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"rinkeby":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/rinkeby.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"kovan":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/kovan.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"goerli":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/goerli.json'");throw e.code="MODULE_NOT_FOUND",e}()))}if(this._customChains&&this._customChains.length>0&&Array.isArray(this._customChains[0]))try{for(var n=u(this._customChains),i=n.next();!i.done;i=n.next()){var o=i.value;if(o[0].name===this.chainName())return o[1]}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return{}},t.prototype.hardforks=function(){return this._chainParams.hardforks},t.prototype.bootstrapNodes=function(){return this._chainParams.bootstrapNodes},t.prototype.dnsNetworks=function(){return this._chainParams.dnsNetworks},t.prototype.hardfork=function(){return this._hardfork},t.prototype.chainId=function(){return(0,y.toType)(this.chainIdBN(),y.TypeOutput.Number)},t.prototype.chainIdBN=function(){return new y.BN(this._chainParams.chainId)},t.prototype.chainName=function(){return this._chainParams.name},t.prototype.networkId=function(){return(0,y.toType)(this.networkIdBN(),y.TypeOutput.Number)},t.prototype.networkIdBN=function(){return new y.BN(this._chainParams.networkId)},t.prototype.eips=function(){return this._eips},t.prototype.consensusType=function(){var e,t,r,n=this.hardfork();try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next()){var a=o.value;if("consensus"in a[1]&&(r=a[1].consensus.type),a[0]===n)break}}catch(t){e={error:t}}finally{try{o&&!o.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}return r||this._chainParams.consensus.type},t.prototype.consensusAlgorithm=function(){var e,t,r,n=this.hardfork();try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next()){var a=o.value;if("consensus"in a[1]&&(r=a[1].consensus.algorithm),a[0]===n)break}}catch(t){e={error:t}}finally{try{o&&!o.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}return r||this._chainParams.consensus.algorithm},t.prototype.consensusConfig=function(){var e,t,r,n=this.hardfork();try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next()){var a=o.value;if("consensus"in a[1]&&(r=a[1].consensus[a[1].consensus.algorithm]),a[0]===n)break}}catch(t){e={error:t}}finally{try{o&&!o.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}if(r)return r;var s=this.consensusAlgorithm();return this._chainParams.consensus[s]},t.prototype.copy=function(){return Object.assign(Object.create(Object.getPrototypeOf(this)),this)},t}(p.EventEmitter);t.default=w},4383:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t},o=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a};Object.defineProperty(t,"__esModule",{value:!0}),t.BaseTransaction=void 0;var a=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t}(r(3863)),s=r(3062),u=r(7325),c=function(){function e(e){this.cache={hash:void 0},this.activeCapabilities=[],this.DEFAULT_CHAIN=a.Chain.Mainnet,this.DEFAULT_HARDFORK=a.Hardfork.Istanbul;var t=e.nonce,r=e.gasLimit,n=e.to,i=e.value,o=e.data,u=e.v,c=e.r,l=e.s,f=e.type;this._type=new s.BN((0,s.toBuffer)(f)).toNumber();var h=(0,s.toBuffer)(""===n?"0x":n),d=(0,s.toBuffer)(""===u?"0x":u),p=(0,s.toBuffer)(""===c?"0x":c),m=(0,s.toBuffer)(""===l?"0x":l);this.nonce=new s.BN((0,s.toBuffer)(""===t?"0x":t)),this.gasLimit=new s.BN((0,s.toBuffer)(""===r?"0x":r)),this.to=h.length>0?new s.Address(h):void 0,this.value=new s.BN((0,s.toBuffer)(""===i?"0x":i)),this.data=(0,s.toBuffer)(""===o?"0x":o),this.v=d.length>0?new s.BN(d):void 0,this.r=p.length>0?new s.BN(p):void 0,this.s=m.length>0?new s.BN(m):void 0,this._validateCannotExceedMaxInteger({nonce:this.nonce,gasLimit:this.gasLimit,value:this.value,r:this.r,s:this.s})}return Object.defineProperty(e.prototype,"transactionType",{get:function(){return this.type},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"type",{get:function(){return this._type},enumerable:!1,configurable:!0}),e.prototype.supports=function(e){return this.activeCapabilities.includes(e)},e.prototype.validate=function(e){void 0===e&&(e=!1);var t=[];return this.getBaseFee().gt(this.gasLimit)&&t.push("gasLimit is too low. given "+this.gasLimit+", need at least "+this.getBaseFee()),this.isSigned()&&!this.verifySignature()&&t.push("Invalid Signature"),e?t:0===t.length},e.prototype.getBaseFee=function(){var e=this.getDataFee().addn(this.common.param("gasPrices","tx"));return this.common.gteHardfork("homestead")&&this.toCreationAddress()&&e.iaddn(this.common.param("gasPrices","txCreation")),e},e.prototype.getDataFee=function(){for(var e=this.common.param("gasPrices","txDataZero"),t=this.common.param("gasPrices","txDataNonZero"),r=0,n=0;n-1&&this.activeCapabilities.splice(l,1)}return c},e.prototype._getCommon=function(e,t){var r;if(t){var n=new s.BN((0,s.toBuffer)(t));if(e){if(!e.chainIdBN().eq(n))throw new Error("The chain ID does not match the chain ID of Common");return e.copy()}return a.default.isSupportedChainId(n)?new a.default({chain:n,hardfork:this.DEFAULT_HARDFORK}):a.default.forCustomChain(this.DEFAULT_CHAIN,{name:"custom-chain",networkId:n,chainId:n},this.DEFAULT_HARDFORK)}return null!==(r=null==e?void 0:e.copy())&&void 0!==r?r:new a.default({chain:this.DEFAULT_CHAIN,hardfork:this.DEFAULT_HARDFORK})},e.prototype._validateCannotExceedMaxInteger=function(e,t){var r,n;void 0===t&&(t=53);try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),a=i.next();!a.done;a=i.next()){var u=o(a.value,2),c=u[0],l=u[1];if(53===t){if(null==l?void 0:l.gt(s.MAX_INTEGER))throw new Error(c+" cannot exceed MAX_INTEGER, given "+l)}else{if(256!==t)throw new Error("unimplemented bits value");if(null==l?void 0:l.gte(s.TWO_POW256))throw new Error(c+" must be less than 2^256, given "+l)}}}catch(e){r={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}},e}();t.BaseTransaction=c},660:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(e,12),i=n[0],o=n[1],a=n[2],u=n[3],c=n[4],l=n[5],f=n[6],h=n[7],d=n[8],p=n[9],m=n[10],y=n[11];return new t({chainId:new s.BN(i),nonce:o,maxPriorityFeePerGas:a,maxFeePerGas:u,gasLimit:c,to:l,value:f,data:h,accessList:null!=d?d:[],v:void 0!==p?new s.BN(p):void 0,r:m,s:y},r)},t.prototype.getDataFee=function(){var t=e.prototype.getDataFee.call(this);return t.iaddn(l.AccessLists.getDataFeeEIP2930(this.accessList,this.common)),t},t.prototype.getUpfrontCost=function(e){void 0===e&&(e=new s.BN(0));var t=s.BN.min(this.maxPriorityFeePerGas,this.maxFeePerGas.sub(e)).add(e);return this.gasLimit.mul(t).add(this.value)},t.prototype.raw=function(){return[(0,s.bnToUnpaddedBuffer)(this.chainId),(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.maxPriorityFeePerGas),(0,s.bnToUnpaddedBuffer)(this.maxFeePerGas),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data,this.accessList,void 0!==this.v?(0,s.bnToUnpaddedBuffer)(this.v):i.from([]),void 0!==this.r?(0,s.bnToUnpaddedBuffer)(this.r):i.from([]),void 0!==this.s?(0,s.bnToUnpaddedBuffer)(this.s):i.from([])]},t.prototype.serialize=function(){var e=this.raw();return i.concat([f,s.rlp.encode(e)])},t.prototype.getMessageToSign=function(e){void 0===e&&(e=!0);var t=this.raw().slice(0,9),r=i.concat([f,s.rlp.encode(t)]);return e?(0,s.keccak256)(r):r},t.prototype.hash=function(){if(!this.isSigned())throw new Error("Cannot call hash method if transaction is not signed");return Object.isFrozen(this)?(this.cache.hash||(this.cache.hash=(0,s.keccak256)(this.serialize())),this.cache.hash):(0,s.keccak256)(this.serialize())},t.prototype.getMessageToVerifySignature=function(){return this.getMessageToSign()},t.prototype.getSenderPublicKey=function(){var e;if(!this.isSigned())throw new Error("Cannot call this method if transaction is not signed");var t=this.getMessageToVerifySignature();if(this.common.gteHardfork("homestead")&&(null===(e=this.s)||void 0===e?void 0:e.gt(c.N_DIV_2)))throw new Error("Invalid Signature: s-values greater than secp256k1n/2 are considered invalid");var r=this,n=r.v,i=r.r,o=r.s;try{return(0,s.ecrecover)(t,n.addn(27),(0,s.bnToUnpaddedBuffer)(i),(0,s.bnToUnpaddedBuffer)(o))}catch(e){throw new Error("Invalid Signature")}},t.prototype._processSignature=function(e,r,n){var i={common:this.common};return t.fromTxData({chainId:this.chainId,nonce:this.nonce,maxPriorityFeePerGas:this.maxPriorityFeePerGas,maxFeePerGas:this.maxFeePerGas,gasLimit:this.gasLimit,to:this.to,value:this.value,data:this.data,accessList:this.accessList,v:new s.BN(e-27),r:new s.BN(r),s:new s.BN(n)},i)},t.prototype.toJSON=function(){var e=l.AccessLists.getAccessListJSON(this.accessList);return{chainId:(0,s.bnToHex)(this.chainId),nonce:(0,s.bnToHex)(this.nonce),maxPriorityFeePerGas:(0,s.bnToHex)(this.maxPriorityFeePerGas),maxFeePerGas:(0,s.bnToHex)(this.maxFeePerGas),gasLimit:(0,s.bnToHex)(this.gasLimit),to:void 0!==this.to?this.to.toString():void 0,value:(0,s.bnToHex)(this.value),data:"0x"+this.data.toString("hex"),accessList:e,v:void 0!==this.v?(0,s.bnToHex)(this.v):void 0,r:void 0!==this.r?(0,s.bnToHex)(this.r):void 0,s:void 0!==this.s?(0,s.bnToHex)(this.s):void 0}},t}(u.BaseTransaction);t.default=h},7613:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(e,11),i=n[0],o=n[1],a=n[2],u=n[3],c=n[4],l=n[5],f=n[6],h=n[7],d=n[8],p=n[9],m=n[10];return new t({chainId:new s.BN(i),nonce:o,gasPrice:a,gasLimit:u,to:c,value:l,data:f,accessList:null!=h?h:[],v:void 0!==d?new s.BN(d):void 0,r:p,s:m},r)},t.prototype.getDataFee=function(){var t=e.prototype.getDataFee.call(this);return t.iaddn(l.AccessLists.getDataFeeEIP2930(this.accessList,this.common)),t},t.prototype.getUpfrontCost=function(){return this.gasLimit.mul(this.gasPrice).add(this.value)},t.prototype.raw=function(){return[(0,s.bnToUnpaddedBuffer)(this.chainId),(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.gasPrice),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data,this.accessList,void 0!==this.v?(0,s.bnToUnpaddedBuffer)(this.v):i.from([]),void 0!==this.r?(0,s.bnToUnpaddedBuffer)(this.r):i.from([]),void 0!==this.s?(0,s.bnToUnpaddedBuffer)(this.s):i.from([])]},t.prototype.serialize=function(){var e=this.raw();return i.concat([f,s.rlp.encode(e)])},t.prototype.getMessageToSign=function(e){void 0===e&&(e=!0);var t=this.raw().slice(0,8),r=i.concat([f,s.rlp.encode(t)]);return e?(0,s.keccak256)(r):r},t.prototype.hash=function(){if(!this.isSigned())throw new Error("Cannot call hash method if transaction is not signed");return Object.isFrozen(this)?(this.cache.hash||(this.cache.hash=(0,s.keccak256)(this.serialize())),this.cache.hash):(0,s.keccak256)(this.serialize())},t.prototype.getMessageToVerifySignature=function(){return this.getMessageToSign()},t.prototype.getSenderPublicKey=function(){var e;if(!this.isSigned())throw new Error("Cannot call this method if transaction is not signed");var t=this.getMessageToVerifySignature();if(this.common.gteHardfork("homestead")&&(null===(e=this.s)||void 0===e?void 0:e.gt(c.N_DIV_2)))throw new Error("Invalid Signature: s-values greater than secp256k1n/2 are considered invalid");var r=this,n=r.yParity,i=r.r,o=r.s;try{return(0,s.ecrecover)(t,n.addn(27),(0,s.bnToUnpaddedBuffer)(i),(0,s.bnToUnpaddedBuffer)(o))}catch(e){throw new Error("Invalid Signature")}},t.prototype._processSignature=function(e,r,n){var i={common:this.common};return t.fromTxData({chainId:this.chainId,nonce:this.nonce,gasPrice:this.gasPrice,gasLimit:this.gasLimit,to:this.to,value:this.value,data:this.data,accessList:this.accessList,v:new s.BN(e-27),r:new s.BN(r),s:new s.BN(n)},i)},t.prototype.toJSON=function(){var e=l.AccessLists.getAccessListJSON(this.accessList);return{chainId:(0,s.bnToHex)(this.chainId),nonce:(0,s.bnToHex)(this.nonce),gasPrice:(0,s.bnToHex)(this.gasPrice),gasLimit:(0,s.bnToHex)(this.gasLimit),to:void 0!==this.to?this.to.toString():void 0,value:(0,s.bnToHex)(this.value),data:"0x"+this.data.toString("hex"),accessList:e,v:void 0!==this.v?(0,s.bnToHex)(this.v):void 0,r:void 0!==this.r?(0,s.bnToHex)(this.r):void 0,s:void 0!==this.s?(0,s.bnToHex)(this.s):void 0}},t}(u.BaseTransaction);t.default=h},2339:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.FeeMarketEIP1559Transaction=t.TransactionFactory=t.AccessListEIP2930Transaction=t.Transaction=void 0;var o=r(3088);Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return i(o).default}});var a=r(7613);Object.defineProperty(t,"AccessListEIP2930Transaction",{enumerable:!0,get:function(){return i(a).default}});var s=r(9562);Object.defineProperty(t,"TransactionFactory",{enumerable:!0,get:function(){return i(s).default}});var u=r(660);Object.defineProperty(t,"FeeMarketEIP1559Transaction",{enumerable:!0,get:function(){return i(u).default}}),function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)}(r(7325),t)},3088:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(e,9);return new t({nonce:n[0],gasPrice:n[1],gasLimit:n[2],to:n[3],value:n[4],data:n[5],v:n[6],r:n[7],s:n[8]},r)},t.prototype.raw=function(){return[(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.gasPrice),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data,void 0!==this.v?(0,s.bnToUnpaddedBuffer)(this.v):i.from([]),void 0!==this.r?(0,s.bnToUnpaddedBuffer)(this.r):i.from([]),void 0!==this.s?(0,s.bnToUnpaddedBuffer)(this.s):i.from([])]},t.prototype.serialize=function(){return s.rlp.encode(this.raw())},t.prototype._getMessageToSign=function(){var e=[(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.gasPrice),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data];return this.supports(u.Capability.EIP155ReplayProtection)&&(e.push((0,s.toBuffer)(this.common.chainIdBN())),e.push((0,s.unpadBuffer)((0,s.toBuffer)(0))),e.push((0,s.unpadBuffer)((0,s.toBuffer)(0)))),e},t.prototype.getMessageToSign=function(e){void 0===e&&(e=!0);var t=this._getMessageToSign();return e?(0,s.rlphash)(t):t},t.prototype.getUpfrontCost=function(){return this.gasLimit.mul(this.gasPrice).add(this.value)},t.prototype.hash=function(){return Object.isFrozen(this)?(this.cache.hash||(this.cache.hash=(0,s.rlphash)(this.raw())),this.cache.hash):(0,s.rlphash)(this.raw())},t.prototype.getMessageToVerifySignature=function(){if(!this.isSigned())throw Error("This transaction is not signed");var e=this._getMessageToSign();return(0,s.rlphash)(e)},t.prototype.getSenderPublicKey=function(){var e,t=this.getMessageToVerifySignature();if(this.common.gteHardfork("homestead")&&(null===(e=this.s)||void 0===e?void 0:e.gt(u.N_DIV_2)))throw new Error("Invalid Signature: s-values greater than secp256k1n/2 are considered invalid");var r=this,n=r.v,i=r.r,o=r.s;try{return(0,s.ecrecover)(t,n,(0,s.bnToUnpaddedBuffer)(i),(0,s.bnToUnpaddedBuffer)(o),this.supports(u.Capability.EIP155ReplayProtection)?this.common.chainIdBN():void 0)}catch(e){throw new Error("Invalid Signature")}},t.prototype._processSignature=function(e,r,n){var i=new s.BN(e);this.supports(u.Capability.EIP155ReplayProtection)&&i.iadd(this.common.chainIdBN().muln(2).addn(8));var o={common:this.common};return t.fromTxData({nonce:this.nonce,gasPrice:this.gasPrice,gasLimit:this.gasLimit,to:this.to,value:this.value,data:this.data,v:i,r:new s.BN(r),s:new s.BN(n)},o)},t.prototype.toJSON=function(){return{nonce:(0,s.bnToHex)(this.nonce),gasPrice:(0,s.bnToHex)(this.gasPrice),gasLimit:(0,s.bnToHex)(this.gasLimit),to:void 0!==this.to?this.to.toString():void 0,value:(0,s.bnToHex)(this.value),data:"0x"+this.data.toString("hex"),v:void 0!==this.v?(0,s.bnToHex)(this.v):void 0,r:void 0!==this.r?(0,s.bnToHex)(this.r):void 0,s:void 0!==this.s?(0,s.bnToHex)(this.s):void 0}},t.prototype._validateTxV=function(e,t){var r;if(void 0!==e&&!e.eqn(0)&&(!t||t.gteHardfork("spuriousDragon"))&&!e.eqn(27)&&!e.eqn(28))if(t){var n=t.chainIdBN().muln(2);if(!e.eq(n.addn(35))&&!e.eq(n.addn(36)))throw new Error("Incompatible EIP155-based V "+e.toString()+" and chain id "+t.chainIdBN().toString()+". See the Common parameter of the Transaction constructor to set the chain id.")}else{var i;i=e.subn(35).isEven()?35:36,r=e.subn(i).divn(2)}return this._getCommon(t,r)},t.prototype._unsignedTxImplementsEIP155=function(){return this.common.gteHardfork("spuriousDragon")},t.prototype._signedTxImplementsEIP155=function(){if(!this.isSigned())throw Error("This transaction is not signed");var e=this.common.gteHardfork("spuriousDragon"),t=this.v,r=this.common.chainIdBN().muln(2);return(t.eq(r.addn(35))||t.eq(r.addn(36)))&&e},t}(r(4383).BaseTransaction);t.default=c},9562:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0});var i=r(3062),o=r(2339),a=function(){function e(){}return e.fromTxData=function(e,t){if(void 0===t&&(t={}),"type"in e&&void 0!==e.type){var r=new i.BN((0,i.toBuffer)(e.type)).toNumber();if(0===r)return o.Transaction.fromTxData(e,t);if(1===r)return o.AccessListEIP2930Transaction.fromTxData(e,t);if(2===r)return o.FeeMarketEIP1559Transaction.fromTxData(e,t);throw new Error("Tx instantiation with type "+r+" not supported")}return o.Transaction.fromTxData(e,t)},e.fromSerializedData=function(e,t){if(void 0===t&&(t={}),e[0]<=127){var r=void 0;switch(e[0]){case 1:r=2930;break;case 2:r=1559;break;default:throw new Error("TypedTransaction with ID "+e[0]+" unknown")}return 1559===r?o.FeeMarketEIP1559Transaction.fromSerializedTx(e,t):o.AccessListEIP2930Transaction.fromSerializedTx(e,t)}return o.Transaction.fromSerializedTx(e,t)},e.fromBlockBodyData=function(e,t){if(void 0===t&&(t={}),n.isBuffer(e))return this.fromSerializedData(e,t);if(Array.isArray(e))return o.Transaction.fromValuesArray(e,t);throw new Error("Cannot decode transaction: unknown type input")},e.getTransactionClass=function(e,t){if(void 0===e&&(e=0),0==e||e>=128&&e<=255)return o.Transaction;switch(e){case 1:return o.AccessListEIP2930Transaction;case 2:return o.FeeMarketEIP1559Transaction;default:throw new Error("TypedTransaction with ID "+e+" unknown")}},e}();t.default=a},7325:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.N_DIV_2=t.isAccessList=t.isAccessListBuffer=t.Capability=void 0;var n,i=r(3062);function o(e){if(0===e.length)return!0;var t=e[0];return!!Array.isArray(t)}(n=t.Capability||(t.Capability={}))[n.EIP155ReplayProtection=155]="EIP155ReplayProtection",n[n.EIP1559FeeMarket=1559]="EIP1559FeeMarket",n[n.EIP2718TypedTransaction=2718]="EIP2718TypedTransaction",n[n.EIP2930AccessLists=2930]="EIP2930AccessLists",t.isAccessListBuffer=o,t.isAccessList=function(e){return!o(e)},t.N_DIV_2=new i.BN("7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0",16)},3789:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AccessLists=void 0;var n=r(3062),i=r(7325),o=function(){function e(){}return e.getAccessListData=function(e){var t,r;if(e&&(0,i.isAccessList)(e)){t=e;for(var o=[],a=0;a{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="abi/5.7.0"},4937:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.defaultAbiCoder=t.AbiCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=r(908),s=r(3694),u=r(4327),c=r(8067),l=r(7316),f=r(9146),h=r(4341),d=r(24),p=r(3861),m=r(28),y=r(4522),g=r(8287),b=r(8040),v=r(2010),w=r(800),A=new u.Logger(c.version),S=new RegExp(/^bytes([0-9]*)$/),k=new RegExp(/^(u?int)([0-9]*)$/),E=function(){function e(t){(0,i.default)(this,e),(0,s.defineReadOnly)(this,"coerceFunc",t||null)}return(0,o.default)(e,[{key:"_getCoder",value:function(e){var t=this;switch(e.baseType){case"address":return new f.AddressCoder(e.name);case"bool":return new d.BooleanCoder(e.name);case"string":return new b.StringCoder(e.name);case"bytes":return new p.BytesCoder(e.name);case"array":return new h.ArrayCoder(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new v.TupleCoder((e.components||[]).map((function(e){return t._getCoder(e)})),e.name);case"":return new y.NullCoder(e.name)}var r=e.type.match(k);if(r){var n=parseInt(r[2]||"256");return(0===n||n>256||n%8!=0)&&A.throwArgumentError("invalid "+r[1]+" bit length","param",e),new g.NumberCoder(n/8,"int"===r[1],e.name)}if(r=e.type.match(S)){var i=parseInt(r[1]);return(0===i||i>32)&&A.throwArgumentError("invalid bytes length","param",e),new m.FixedBytesCoder(i,e.name)}return A.throwArgumentError("invalid type","type",e.type)}},{key:"_getWordSize",value:function(){return 32}},{key:"_getReader",value:function(e,t){return new l.Reader(e,this._getWordSize(),this.coerceFunc,t)}},{key:"_getWriter",value:function(){return new l.Writer(this._getWordSize())}},{key:"getDefaultValue",value:function(e){var t=this,r=e.map((function(e){return t._getCoder(w.ParamType.from(e))}));return new v.TupleCoder(r,"_").defaultValue()}},{key:"encode",value:function(e,t){var r=this;e.length!==t.length&&A.throwError("types/values length mismatch",u.Logger.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});var n=e.map((function(e){return r._getCoder(w.ParamType.from(e))})),i=new v.TupleCoder(n,"_"),o=this._getWriter();return i.encode(o,t),o.data}},{key:"decode",value:function(e,t,r){var n=this,i=e.map((function(e){return n._getCoder(w.ParamType.from(e))}));return new v.TupleCoder(i,"_").decode(this._getReader((0,a.arrayify)(t),r))}}]),e}();t.AbiCoder=E;var _=new E;t.defaultAbiCoder=_},7316:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.Writer=t.Reader=t.Coder=void 0,t.checkResultErrors=function(e){var t=[];return function e(r,n){if(Array.isArray(n))for(var i in n){var o=r.slice();o.push(i);try{e(o,n[i])}catch(e){t.push({path:o,error:e})}}}([],e),t};var i=n(r(9721)),o=n(r(8985)),a=r(908),s=r(4952),u=r(3694),c=r(4327),l=r(8067),f=new c.Logger(l.version),h=function(){function e(t,r,n,o){(0,i.default)(this,e),this.name=t,this.type=r,this.localName=n,this.dynamic=o}return(0,o.default)(e,[{key:"_throwError",value:function(e,t){f.throwArgumentError(e,this.localName,t)}}]),e}();t.Coder=h;var d=function(){function e(t){(0,i.default)(this,e),(0,u.defineReadOnly)(this,"wordSize",t||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(t)}return(0,o.default)(e,[{key:"data",get:function(){return(0,a.hexConcat)(this._data)}},{key:"length",get:function(){return this._dataLength}},{key:"_writeData",value:function(e){return this._data.push(e),this._dataLength+=e.length,e.length}},{key:"appendWriter",value:function(e){return this._writeData((0,a.concat)(e._data))}},{key:"writeBytes",value:function(e){var t=(0,a.arrayify)(e),r=t.length%this.wordSize;return r&&(t=(0,a.concat)([t,this._padding.slice(r)])),this._writeData(t)}},{key:"_getValue",value:function(e){var t=(0,a.arrayify)(s.BigNumber.from(e));return t.length>this.wordSize&&f.throwError("value out-of-bounds",c.Logger.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=(0,a.concat)([this._padding.slice(t.length%this.wordSize),t])),t}},{key:"writeValue",value:function(e){return this._writeData(this._getValue(e))}},{key:"writeUpdatableValue",value:function(){var e=this,t=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,function(r){e._data[t]=e._getValue(r)}}}]),e}();t.Writer=d;var p=function(){function e(t,r,n,o){(0,i.default)(this,e),(0,u.defineReadOnly)(this,"_data",(0,a.arrayify)(t)),(0,u.defineReadOnly)(this,"wordSize",r||32),(0,u.defineReadOnly)(this,"_coerceFunc",n),(0,u.defineReadOnly)(this,"allowLoose",o),this._offset=0}return(0,o.default)(e,[{key:"data",get:function(){return(0,a.hexlify)(this._data)}},{key:"consumed",get:function(){return this._offset}},{key:"coerce",value:function(t,r){return this._coerceFunc?this._coerceFunc(t,r):e.coerce(t,r)}},{key:"_peekBytes",value:function(e,t,r){var n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:f.throwError("data out-of-bounds",c.Logger.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}},{key:"subReader",value:function(t){return new e(this._data.slice(this._offset+t),this.wordSize,this._coerceFunc,this.allowLoose)}},{key:"readBytes",value:function(e,t){var r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}},{key:"readValue",value:function(){return s.BigNumber.from(this.readBytes(this.wordSize))}}],[{key:"coerce",value:function(e,t){var r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}}]),e}();t.Reader=p},9146:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.AddressCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(7921),l=r(908),f=function(e){(0,a.default)(f,e);var t,r,n=(t=f,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function f(e){return(0,i.default)(this,f),n.call(this,"address","address",e,!1)}return(0,o.default)(f,[{key:"defaultValue",value:function(){return"0x0000000000000000000000000000000000000000"}},{key:"encode",value:function(e,t){try{t=(0,c.getAddress)(t)}catch(e){this._throwError(e.message,t)}return e.writeValue(t)}},{key:"decode",value:function(e){return(0,c.getAddress)((0,l.hexZeroPad)(e.readValue().toHexString(),20))}}]),f}(r(7316).Coder);t.AddressCoder=f},8090:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.AnonymousCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e){var t;return(0,i.default)(this,c),(t=n.call(this,e.name,e.type,void 0,e.dynamic)).coder=e,t}return(0,o.default)(c,[{key:"defaultValue",value:function(){return this.coder.defaultValue()}},{key:"encode",value:function(e,t){return this.coder.encode(e,t)}},{key:"decode",value:function(e){return this.coder.decode(e)}}]),c}(r(7316).Coder);t.AnonymousCoder=c},4341:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.ArrayCoder=void 0,t.pack=m,t.unpack=y;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=n(r(3355)),l=r(4327),f=r(8067),h=r(7316),d=r(8090),p=new l.Logger(f.version);function m(e,t,r){var n=null;if(Array.isArray(r))n=r;else if(r&&"object"===(0,c.default)(r)){var i={};n=t.map((function(e){var t=e.localName;return t||p.throwError("cannot encode object for signature with missing names",l.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),i[t]&&p.throwError("cannot encode object for signature with duplicate names",l.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),i[t]=!0,r[t]}))}else p.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&p.throwArgumentError("types/value length mismatch","tuple",r);var o=new h.Writer(e.wordSize),a=new h.Writer(e.wordSize),s=[];return t.forEach((function(e,t){var r=n[t];if(e.dynamic){var i=a.length;e.encode(a,r);var u=o.writeUpdatableValue();s.push((function(e){u(e+i)}))}else e.encode(o,r)})),s.forEach((function(e){e(o.length)})),e.appendWriter(o)+e.appendWriter(a)}function y(e,t){var r=[],n=e.subReader(0);t.forEach((function(t){var i=null;if(t.dynamic){var o=e.readValue(),a=n.subReader(o.toNumber());try{i=t.decode(a)}catch(e){if(e.code===l.Logger.errors.BUFFER_OVERRUN)throw e;(i=e).baseType=t.name,i.name=t.localName,i.type=t.type}}else try{i=t.decode(e)}catch(e){if(e.code===l.Logger.errors.BUFFER_OVERRUN)throw e;(i=e).baseType=t.name,i.name=t.localName,i.type=t.type}null!=i&&r.push(i)}));var i=t.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach((function(e,t){var n=e.localName;if(n&&1===i[n]&&("length"===n&&(n="_length"),null==r[n])){var o=r[t];o instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:function(){throw o}}):r[n]=o}}));for(var o=function(e){var t=r[e];t instanceof Error&&Object.defineProperty(r,e,{enumerable:!0,get:function(){throw t}})},a=0;a=0?t:"")+"]",s=-1===t||e.dynamic;return(o=n.call(this,"array",a,r,s)).coder=e,o.length=t,o}return(0,o.default)(c,[{key:"defaultValue",value:function(){for(var e=this.coder.defaultValue(),t=[],r=0;re._data.length&&p.throwError("insufficient data length",l.Logger.errors.BUFFER_OVERRUN,{length:e._data.length,count:t});for(var r=[],n=0;n{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.BooleanCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e){return(0,i.default)(this,c),n.call(this,"bool","bool",e,!1)}return(0,o.default)(c,[{key:"defaultValue",value:function(){return!1}},{key:"encode",value:function(e,t){return e.writeValue(t?1:0)}},{key:"decode",value:function(e){return e.coerce(this.type,!e.readValue().isZero())}}]),c}(r(7316).Coder);t.BooleanCoder=c},3861:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.DynamicBytesCoder=t.BytesCoder=void 0;var i=n(r(119)),o=n(r(9721)),a=n(r(8985)),s=n(r(5163)),u=n(r(4650)),c=n(r(1949)),l=r(908);function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,u.default)(this,r)}}var h=function(e){(0,s.default)(r,e);var t=f(r);function r(e,n){return(0,o.default)(this,r),t.call(this,e,e,n,!0)}return(0,a.default)(r,[{key:"defaultValue",value:function(){return"0x"}},{key:"encode",value:function(e,t){return t=(0,l.arrayify)(t),e.writeValue(t.length)+e.writeBytes(t)}},{key:"decode",value:function(e){return e.readBytes(e.readValue().toNumber(),!0)}}]),r}(r(7316).Coder);t.DynamicBytesCoder=h;var d=function(e){(0,s.default)(r,e);var t=f(r);function r(e){return(0,o.default)(this,r),t.call(this,"bytes",e)}return(0,a.default)(r,[{key:"decode",value:function(e){return e.coerce(this.name,(0,l.hexlify)((0,i.default)((0,c.default)(r.prototype),"decode",this).call(this,e)))}}]),r}(h);t.BytesCoder=d},28:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.FixedBytesCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(908),l=function(e){(0,a.default)(l,e);var t,r,n=(t=l,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function l(e,t){var r;(0,i.default)(this,l);var o="bytes"+String(e);return(r=n.call(this,o,o,t,!1)).size=e,r}return(0,o.default)(l,[{key:"defaultValue",value:function(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+2*this.size)}},{key:"encode",value:function(e,t){var r=(0,c.arrayify)(t);return r.length!==this.size&&this._throwError("incorrect data length",t),e.writeBytes(r)}},{key:"decode",value:function(e){return e.coerce(this.name,(0,c.hexlify)(e.readBytes(this.size)))}}]),l}(r(7316).Coder);t.FixedBytesCoder=l},4522:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.NullCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e){return(0,i.default)(this,c),n.call(this,"null","",e,!1)}return(0,o.default)(c,[{key:"defaultValue",value:function(){return null}},{key:"encode",value:function(e,t){return null!=t&&this._throwError("not null",t),e.writeBytes([])}},{key:"decode",value:function(e){return e.readBytes(0),e.coerce(this.name,null)}}]),c}(r(7316).Coder);t.NullCoder=c},8287:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.NumberCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(4952),l=r(5465),f=function(e){(0,a.default)(f,e);var t,r,n=(t=f,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function f(e,t,r){var o;(0,i.default)(this,f);var a=(t?"int":"uint")+8*e;return(o=n.call(this,a,a,r,!1)).size=e,o.signed=t,o}return(0,o.default)(f,[{key:"defaultValue",value:function(){return 0}},{key:"encode",value:function(e,t){var r=c.BigNumber.from(t),n=l.MaxUint256.mask(8*e.wordSize);if(this.signed){var i=n.mask(8*this.size-1);(r.gt(i)||r.lt(i.add(l.One).mul(l.NegativeOne)))&&this._throwError("value out-of-bounds",t)}else(r.lt(l.Zero)||r.gt(n.mask(8*this.size)))&&this._throwError("value out-of-bounds",t);return r=r.toTwos(8*this.size).mask(8*this.size),this.signed&&(r=r.fromTwos(8*this.size).toTwos(8*e.wordSize)),e.writeValue(r)}},{key:"decode",value:function(e){var t=e.readValue().mask(8*this.size);return this.signed&&(t=t.fromTwos(8*this.size)),e.coerce(this.name,t)}}]),f}(r(7316).Coder);t.NumberCoder=f},8040:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.StringCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(119)),s=n(r(5163)),u=n(r(4650)),c=n(r(1949)),l=r(8627),f=function(e){(0,s.default)(f,e);var t,r,n=(t=f,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,c.default)(t);if(r){var i=(0,c.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,u.default)(this,e)});function f(e){return(0,i.default)(this,f),n.call(this,"string",e)}return(0,o.default)(f,[{key:"defaultValue",value:function(){return""}},{key:"encode",value:function(e,t){return(0,a.default)((0,c.default)(f.prototype),"encode",this).call(this,e,(0,l.toUtf8Bytes)(t))}},{key:"decode",value:function(e){return(0,l.toUtf8String)((0,a.default)((0,c.default)(f.prototype),"decode",this).call(this,e))}}]),f}(r(3861).DynamicBytesCoder);t.StringCoder=f},2010:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.TupleCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(7316),l=r(4341),f=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e,t){var r;(0,i.default)(this,c);var o=!1,a=[];e.forEach((function(e){e.dynamic&&(o=!0),a.push(e.type)}));var s="tuple("+a.join(",")+")";return(r=n.call(this,"tuple",s,t,o)).coders=e,r}return(0,o.default)(c,[{key:"defaultValue",value:function(){var e=[];this.coders.forEach((function(t){e.push(t.defaultValue())}));var t=this.coders.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach((function(r,n){var i=r.localName;i&&1===t[i]&&("length"===i&&(i="_length"),null==e[i]&&(e[i]=e[n]))})),Object.freeze(e)}},{key:"encode",value:function(e,t){return(0,l.pack)(e,this.coders,t)}},{key:"decode",value:function(e){return e.coerce(this.name,(0,l.unpack)(e,this.coders))}}]),c}(c.Coder);t.TupleCoder=f},800:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.ParamType=t.FunctionFragment=t.Fragment=t.FormatTypes=t.EventFragment=t.ErrorFragment=t.ConstructorFragment=void 0;var i=n(r(5163)),o=n(r(4650)),a=n(r(1949)),s=n(r(9721)),u=n(r(8985)),c=r(4952),l=r(3694),f=r(4327),h=r(8067);function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,a.default)(e);if(t){var i=(0,a.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,o.default)(this,r)}}var p=new f.Logger(h.version),m={},y={calldata:!0,memory:!0,storage:!0},g={calldata:!0,memory:!0};function b(e,t){if("bytes"===e||"string"===e){if(y[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&g[t])return!0;return(y[t]||"payable"===t)&&p.throwArgumentError("invalid modifier","name",t),!1}function v(e,t){for(var r in t)(0,l.defineReadOnly)(e,r,t[r])}var w=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"});t.FormatTypes=w;var A=new RegExp(/^(.*)\[([0-9]*)\]$/),S=function(){function e(t,r){(0,s.default)(this,e),t!==m&&p.throwError("use fromString",f.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),v(this,r);var n=this.type.match(A);v(this,n?{arrayLength:parseInt(n[2]||"-1"),arrayChildren:e.fromObject({type:n[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}return(0,u.default)(e,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json){var t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((function(t){return JSON.parse(t.format(e))}))),JSON.stringify(t)}var r="";return"array"===this.baseType?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==w.sighash&&(r+=this.type),r+="("+this.components.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+")"):r+=this.type,e!==w.sighash&&(!0===this.indexed&&(r+=" indexed"),e===w.full&&this.name&&(r+=" "+this.name)),r}}],[{key:"from",value:function(t,r){return"string"==typeof t?e.fromString(t,r):e.fromObject(t)}},{key:"fromObject",value:function(t){return e.isParamType(t)?t:new e(m,{name:t.name||null,type:C(t.type),indexed:null==t.indexed?null:!!t.indexed,components:t.components?t.components.map(e.fromObject):null})}},{key:"fromString",value:function(t,r){return n=function(e,t){var r=e;function n(t){p.throwArgumentError("unexpected character at position ".concat(t),"param",e)}function i(e){var r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");for(var o={type:"",name:"",state:{allowType:!0}},a=o,s=0;s2&&p.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||p.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=c.BigNumber.from(r[1]),r[0]):e}function T(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((function(e){switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function x(e){var t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&p.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&p.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||p.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&p.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&p.throwArgumentError("unable to determine stateMutability","value",e),t}t.EventFragment=_;var P=function(e){(0,i.default)(r,e);var t=d(r);function r(){return(0,s.default)(this,r),t.apply(this,arguments)}return(0,u.default)(r,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});e===w.sighash&&p.throwError("cannot format a constructor for sighash",f.Logger.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});var t="constructor("+this.inputs.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}}],[{key:"from",value:function(e){return"string"==typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isConstructorFragment(e))return e;"constructor"!==e.type&&p.throwArgumentError("invalid constructor object","value",e);var t=x(e);t.constant&&p.throwArgumentError("constructor cannot be constant","value",e);var n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(S.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.BigNumber.from(e.gas):null};return new r(m,n)}},{key:"fromString",value:function(e){var t={type:"constructor"},n=(e=M(e,t)).match(L);return n&&"constructor"===n[1].trim()||p.throwArgumentError("invalid constructor string","value",e),t.inputs=k(n[2].trim(),!1),T(n[3].trim(),t),r.fromObject(t)}},{key:"isConstructorFragment",value:function(e){return e&&e._isFragment&&"constructor"===e.type}}]),r}(E);t.ConstructorFragment=P;var I=function(e){(0,i.default)(r,e);var t=d(r);function r(){return(0,s.default)(this,r),t.apply(this,arguments)}return(0,u.default)(r,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))})),outputs:this.outputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==w.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+") ",e!==w.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((function(t){return t.format(e)})).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}}],[{key:"from",value:function(e){return"string"==typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isFunctionFragment(e))return e;"function"!==e.type&&p.throwArgumentError("invalid function object","value",e);var t=x(e),n={type:e.type,name:N(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(S.fromObject):[],outputs:e.outputs?e.outputs.map(S.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.BigNumber.from(e.gas):null};return new r(m,n)}},{key:"fromString",value:function(e){var t={type:"function"},n=(e=M(e,t)).split(" returns ");n.length>2&&p.throwArgumentError("invalid function string","value",e);var i=n[0].match(L);if(i||p.throwArgumentError("invalid function signature","value",e),t.name=i[1].trim(),t.name&&N(t.name),t.inputs=k(i[2],!1),T(i[3].trim(),t),n.length>1){var o=n[1].match(L);""==o[1].trim()&&""==o[3].trim()||p.throwArgumentError("unexpected tokens","value",e),t.outputs=k(o[2],!1)}else t.outputs=[];return r.fromObject(t)}},{key:"isFunctionFragment",value:function(e){return e&&e._isFragment&&"function"===e.type}}]),r}(P);function O(e){var t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||p.throwArgumentError("cannot specify user defined ".concat(t," error"),"fragment",e),e}t.FunctionFragment=I;var R=function(e){(0,i.default)(r,e);var t=d(r);function r(){return(0,s.default)(this,r),t.apply(this,arguments)}return(0,u.default)(r,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==w.sighash&&(t+="error "),(t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+") ").trim()}}],[{key:"from",value:function(e){return"string"==typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isErrorFragment(e))return e;"error"!==e.type&&p.throwArgumentError("invalid error object","value",e);var t={type:e.type,name:N(e.name),inputs:e.inputs?e.inputs.map(S.fromObject):[]};return O(new r(m,t))}},{key:"fromString",value:function(e){var t={type:"error"},n=e.match(L);return n||p.throwArgumentError("invalid error signature","value",e),t.name=n[1].trim(),t.name&&N(t.name),t.inputs=k(n[2],!1),O(r.fromObject(t))}},{key:"isErrorFragment",value:function(e){return e&&e._isFragment&&"error"===e.type}}]),r}(E);function C(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}t.ErrorFragment=R;var B=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function N(e){return e&&e.match(B)||p.throwArgumentError('invalid identifier "'.concat(e,'"'),"value",e),e}var L=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$")},2914:(e,t,r)=>{"use strict";Object.defineProperty(t,"RQ",{enumerable:!0,get:function(){return i.AbiCoder}}),Object.defineProperty(t,"_R",{enumerable:!0,get:function(){return n.ParamType}});var n=r(800),i=r(4937);r(9044)},9044:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionDescription=t.LogDescription=t.Interface=t.Indexed=t.ErrorDescription=void 0,Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return y.checkResultErrors}});var i=n(r(8985)),o=n(r(9721)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(7921),l=r(4952),f=r(908),h=r(7515),d=r(4642),p=r(3694),m=r(4937),y=r(7316),g=r(800),b=r(4327),v=r(8067);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,s.default)(this,r)}}var A=new b.Logger(v.version),S=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r)}(p.Description);t.LogDescription=S;var k=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r)}(p.Description);t.TransactionDescription=k;var E=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r)}(p.Description);t.ErrorDescription=E;var _=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r,null,[{key:"isIndexed",value:function(e){return!(!e||!e._isIndexed)}}]),r}(p.Description);t.Indexed=_;var M={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function T(e,t){var r=new Error("deferred error during ABI decoding triggered accessing ".concat(e));return r.error=t,r}var x=function(){function e(t){var r=this;(0,o.default)(this,e);var n=[];n="string"==typeof t?JSON.parse(t):t,(0,p.defineReadOnly)(this,"fragments",n.map((function(e){return g.Fragment.from(e)})).filter((function(e){return null!=e}))),(0,p.defineReadOnly)(this,"_abiCoder",(0,p.getStatic)(this instanceof e?this.constructor:void 0,"getAbiCoder")()),(0,p.defineReadOnly)(this,"functions",{}),(0,p.defineReadOnly)(this,"errors",{}),(0,p.defineReadOnly)(this,"events",{}),(0,p.defineReadOnly)(this,"structs",{}),this.fragments.forEach((function(e){var t=null;switch(e.type){case"constructor":return r.deploy?void A.warn("duplicate definition - constructor"):void(0,p.defineReadOnly)(r,"deploy",e);case"function":t=r.functions;break;case"event":t=r.events;break;case"error":t=r.errors;break;default:return}var n=e.format();t[n]?A.warn("duplicate definition - "+n):t[n]=e})),this.deploy||(0,p.defineReadOnly)(this,"deploy",g.ConstructorFragment.from({payable:!1,type:"constructor"})),(0,p.defineReadOnly)(this,"_isInterface",!0)}return(0,i.default)(e,[{key:"format",value:function(e){e||(e=g.FormatTypes.full),e===g.FormatTypes.sighash&&A.throwArgumentError("interface does not support formatting sighash","format",e);var t=this.fragments.map((function(t){return t.format(e)}));return e===g.FormatTypes.json?JSON.stringify(t.map((function(e){return JSON.parse(e)}))):t}},{key:"getFunction",value:function(e){if((0,f.isHexString)(e)){for(var t in this.functions)if(e===this.getSighash(t))return this.functions[t];A.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){var r=e.trim(),n=Object.keys(this.functions).filter((function(e){return e.split("(")[0]===r}));return 0===n.length?A.throwArgumentError("no matching function","name",r):n.length>1&&A.throwArgumentError("multiple matching functions","name",r),this.functions[n[0]]}var i=this.functions[g.FunctionFragment.fromString(e).format()];return i||A.throwArgumentError("no matching function","signature",e),i}},{key:"getEvent",value:function(e){if((0,f.isHexString)(e)){var t=e.toLowerCase();for(var r in this.events)if(t===this.getEventTopic(r))return this.events[r];A.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){var n=e.trim(),i=Object.keys(this.events).filter((function(e){return e.split("(")[0]===n}));return 0===i.length?A.throwArgumentError("no matching event","name",n):i.length>1&&A.throwArgumentError("multiple matching events","name",n),this.events[i[0]]}var o=this.events[g.EventFragment.fromString(e).format()];return o||A.throwArgumentError("no matching event","signature",e),o}},{key:"getError",value:function(e){if((0,f.isHexString)(e)){var t=(0,p.getStatic)(this.constructor,"getSighash");for(var r in this.errors)if(e===t(this.errors[r]))return this.errors[r];A.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){var n=e.trim(),i=Object.keys(this.errors).filter((function(e){return e.split("(")[0]===n}));return 0===i.length?A.throwArgumentError("no matching error","name",n):i.length>1&&A.throwArgumentError("multiple matching errors","name",n),this.errors[i[0]]}var o=this.errors[g.FunctionFragment.fromString(e).format()];return o||A.throwArgumentError("no matching error","signature",e),o}},{key:"getSighash",value:function(e){if("string"==typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(e){throw t}}return(0,p.getStatic)(this.constructor,"getSighash")(e)}},{key:"getEventTopic",value:function(e){return"string"==typeof e&&(e=this.getEvent(e)),(0,p.getStatic)(this.constructor,"getEventTopic")(e)}},{key:"_decodeParams",value:function(e,t){return this._abiCoder.decode(e,t)}},{key:"_encodeParams",value:function(e,t){return this._abiCoder.encode(e,t)}},{key:"encodeDeploy",value:function(e){return this._encodeParams(this.deploy.inputs,e||[])}},{key:"decodeErrorResult",value:function(e,t){"string"==typeof e&&(e=this.getError(e));var r=(0,f.arrayify)(t);return(0,f.hexlify)(r.slice(0,4))!==this.getSighash(e)&&A.throwArgumentError("data signature does not match error ".concat(e.name,"."),"data",(0,f.hexlify)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeErrorResult",value:function(e,t){return"string"==typeof e&&(e=this.getError(e)),(0,f.hexlify)((0,f.concat)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionData",value:function(e,t){"string"==typeof e&&(e=this.getFunction(e));var r=(0,f.arrayify)(t);return(0,f.hexlify)(r.slice(0,4))!==this.getSighash(e)&&A.throwArgumentError("data signature does not match function ".concat(e.name,"."),"data",(0,f.hexlify)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeFunctionData",value:function(e,t){return"string"==typeof e&&(e=this.getFunction(e)),(0,f.hexlify)((0,f.concat)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionResult",value:function(e,t){"string"==typeof e&&(e=this.getFunction(e));var r=(0,f.arrayify)(t),n=null,i="",o=null,a=null,s=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(l){}break;case 4:var u=(0,f.hexlify)(r.slice(0,4)),c=M[u];if(c)o=this._abiCoder.decode(c.inputs,r.slice(4)),a=c.name,s=c.signature,c.reason&&(n=o[0]),"Error"===a?i="; VM Exception while processing transaction: reverted with reason string ".concat(JSON.stringify(o[0])):"Panic"===a&&(i="; VM Exception while processing transaction: reverted with panic code ".concat(o[0]));else try{var l=this.getError(u);o=this._abiCoder.decode(l.inputs,r.slice(4)),a=l.name,s=l.format()}catch(l){}}return A.throwError("call revert exception"+i,b.Logger.errors.CALL_EXCEPTION,{method:e.format(),data:(0,f.hexlify)(t),errorArgs:o,errorName:a,errorSignature:s,reason:n})}},{key:"encodeFunctionResult",value:function(e,t){return"string"==typeof e&&(e=this.getFunction(e)),(0,f.hexlify)(this._abiCoder.encode(e.outputs,t||[]))}},{key:"encodeFilterTopics",value:function(e,t){var r=this;"string"==typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&A.throwError("too many arguments for "+e.format(),b.Logger.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});var n=[];e.anonymous||n.push(this.getEventTopic(e));var i=function(e,t){return"string"===e.type?(0,h.id)(t):"bytes"===e.type?(0,d.keccak256)((0,f.hexlify)(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=l.BigNumber.from(t).toHexString()),"address"===e.type&&r._abiCoder.encode(["address"],[t]),(0,f.hexZeroPad)((0,f.hexlify)(t),32))};for(t.forEach((function(t,r){var o=e.inputs[r];o.indexed?null==t?n.push(null):"array"===o.baseType||"tuple"===o.baseType?A.throwArgumentError("filtering with tuples or arrays not supported","contract."+o.name,t):Array.isArray(t)?n.push(t.map((function(e){return i(o,e)}))):n.push(i(o,t)):null!=t&&A.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+o.name,t)}));n.length&&null===n[n.length-1];)n.pop();return n}},{key:"encodeEventLog",value:function(e,t){var r=this;"string"==typeof e&&(e=this.getEvent(e));var n=[],i=[],o=[];return e.anonymous||n.push(this.getEventTopic(e)),t.length!==e.inputs.length&&A.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach((function(e,a){var s=t[a];if(e.indexed)if("string"===e.type)n.push((0,h.id)(s));else if("bytes"===e.type)n.push((0,d.keccak256)(s));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");n.push(r._abiCoder.encode([e.type],[s]))}else i.push(e),o.push(s)})),{data:this._abiCoder.encode(i,o),topics:n}}},{key:"decodeEventLog",value:function(e,t,r){if("string"==typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){var n=this.getEventTopic(e);(0,f.isHexString)(r[0],32)&&r[0].toLowerCase()===n||A.throwError("fragment/topic mismatch",b.Logger.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:n,value:r[0]}),r=r.slice(1)}var i=[],o=[],a=[];e.inputs.forEach((function(e,t){e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(i.push(g.ParamType.fromObject({type:"bytes32",name:e.name})),a.push(!0)):(i.push(e),a.push(!1)):(o.push(e),a.push(!1))}));var s=null!=r?this._abiCoder.decode(i,(0,f.concat)(r)):null,u=this._abiCoder.decode(o,t,!0),c=[],l=0,h=0;e.inputs.forEach((function(e,t){if(e.indexed)if(null==s)c[t]=new _({_isIndexed:!0,hash:null});else if(a[t])c[t]=new _({_isIndexed:!0,hash:s[h++]});else try{c[t]=s[h++]}catch(e){c[t]=e}else try{c[t]=u[l++]}catch(e){c[t]=e}if(e.name&&null==c[e.name]){var r=c[t];r instanceof Error?Object.defineProperty(c,e.name,{enumerable:!0,get:function(){throw T("property ".concat(JSON.stringify(e.name)),r)}}):c[e.name]=r}}));for(var d=function(e){var t=c[e];t instanceof Error&&Object.defineProperty(c,e,{enumerable:!0,get:function(){throw T("index ".concat(e),t)}})},p=0;p{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="address/5.7.0"},7921:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAddress=g,t.getContractAddress=function(e){var t=null;try{t=g(e.from)}catch(t){c.throwArgumentError("missing from address","transaction",e)}var r=(0,n.stripZeros)((0,n.arrayify)(i.BigNumber.from(e.nonce).toHexString()));return g((0,n.hexDataSlice)((0,o.keccak256)((0,a.encode)([t,r])),12))},t.getCreate2Address=function(e,t,r){return 32!==(0,n.hexDataLength)(t)&&c.throwArgumentError("salt must be 32 bytes","salt",t),32!==(0,n.hexDataLength)(r)&&c.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),g((0,n.hexDataSlice)((0,o.keccak256)((0,n.concat)(["0xff",g(e),t,r])),12))},t.getIcapAddress=function(e){for(var t=(0,i._base16To36)(g(e).substring(2)).toUpperCase();t.length<30;)t="0"+t;return"XE"+y("XE00"+t)+t},t.isAddress=function(e){try{return g(e),!0}catch(e){}return!1};var n=r(908),i=r(4952),o=r(4642),a=r(5265),s=r(4327),u=r(8222),c=new s.Logger(u.version);function l(e){(0,n.isHexString)(e,20)||c.throwArgumentError("invalid address","address",e);for(var t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40),i=0;i<40;i++)r[i]=t[i].charCodeAt(0);for(var a=(0,n.arrayify)((0,o.keccak256)(r)),s=0;s<40;s+=2)a[s>>1]>>4>=8&&(t[s]=t[s].toUpperCase()),(15&a[s>>1])>=8&&(t[s+1]=t[s+1].toUpperCase());return"0x"+t.join("")}for(var f={},h=0;h<10;h++)f[String(h)]=String(h);for(var d=0;d<26;d++)f[String.fromCharCode(65+d)]=String(10+d);var p,m=Math.floor((p=9007199254740991,Math.log10?Math.log10(p):Math.log(p)/Math.LN10));function y(e){for(var t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((function(e){return f[e]})).join("");t.length>=m;){var r=t.substring(0,m);t=parseInt(r,10)%97+t.substring(r.length)}for(var n=String(98-parseInt(t,10)%97);n.length<2;)n="0"+n;return n}function g(e){var t=null;if("string"!=typeof e&&c.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=l(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&c.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==y(e)&&c.throwArgumentError("bad icap checksum","address",e),t=(0,i._base36To16)(e.substring(4));t.length<40;)t="0"+t;t=l("0x"+t)}else c.throwArgumentError("invalid address","address",e);return t}},5798:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decode=function(e){e=atob(e);for(var t=[],r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"decode",{enumerable:!0,get:function(){return n.decode}}),Object.defineProperty(t,"encode",{enumerable:!0,get:function(){return n.encode}});var n=r(5798)},3042:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="bignumber/5.7.0"},1872:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.BigNumber=void 0,t._base16To36=function(e){return new l(e,16).toString(36)},t._base36To16=function(e){return new l(e,36).toString(16)},t.isBigNumberish=function(e){return null!=e&&(m.isBigNumber(e)||"number"==typeof e&&e%1==0||"string"==typeof e&&!!e.match(/^-?[0-9]+$/)||(0,s.isHexString)(e)||"bigint"==typeof e||(0,s.isBytes)(e))};var i=n(r(9721)),o=n(r(8985)),a=n(r(1734)),s=r(908),u=r(4327),c=r(3042),l=a.default.BN,f=new u.Logger(c.version),h={},d=9007199254740991,p=!1,m=function(){function e(t,r){(0,i.default)(this,e),t!==h&&f.throwError("cannot call constructor directly; use BigNumber.from",u.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=r,this._isBigNumber=!0,Object.freeze(this)}return(0,o.default)(e,[{key:"fromTwos",value:function(e){return g(b(this).fromTwos(e))}},{key:"toTwos",value:function(e){return g(b(this).toTwos(e))}},{key:"abs",value:function(){return"-"===this._hex[0]?e.from(this._hex.substring(1)):this}},{key:"add",value:function(e){return g(b(this).add(b(e)))}},{key:"sub",value:function(e){return g(b(this).sub(b(e)))}},{key:"div",value:function(t){return e.from(t).isZero()&&v("division-by-zero","div"),g(b(this).div(b(t)))}},{key:"mul",value:function(e){return g(b(this).mul(b(e)))}},{key:"mod",value:function(e){var t=b(e);return t.isNeg()&&v("division-by-zero","mod"),g(b(this).umod(t))}},{key:"pow",value:function(e){var t=b(e);return t.isNeg()&&v("negative-power","pow"),g(b(this).pow(t))}},{key:"and",value:function(e){var t=b(e);return(this.isNegative()||t.isNeg())&&v("unbound-bitwise-result","and"),g(b(this).and(t))}},{key:"or",value:function(e){var t=b(e);return(this.isNegative()||t.isNeg())&&v("unbound-bitwise-result","or"),g(b(this).or(t))}},{key:"xor",value:function(e){var t=b(e);return(this.isNegative()||t.isNeg())&&v("unbound-bitwise-result","xor"),g(b(this).xor(t))}},{key:"mask",value:function(e){return(this.isNegative()||e<0)&&v("negative-width","mask"),g(b(this).maskn(e))}},{key:"shl",value:function(e){return(this.isNegative()||e<0)&&v("negative-width","shl"),g(b(this).shln(e))}},{key:"shr",value:function(e){return(this.isNegative()||e<0)&&v("negative-width","shr"),g(b(this).shrn(e))}},{key:"eq",value:function(e){return b(this).eq(b(e))}},{key:"lt",value:function(e){return b(this).lt(b(e))}},{key:"lte",value:function(e){return b(this).lte(b(e))}},{key:"gt",value:function(e){return b(this).gt(b(e))}},{key:"gte",value:function(e){return b(this).gte(b(e))}},{key:"isNegative",value:function(){return"-"===this._hex[0]}},{key:"isZero",value:function(){return b(this).isZero()}},{key:"toNumber",value:function(){try{return b(this).toNumber()}catch(e){v("overflow","toNumber",this.toString())}return null}},{key:"toBigInt",value:function(){try{return BigInt(this.toString())}catch(e){}return f.throwError("this platform does not support BigInt",u.Logger.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}},{key:"toString",value:function(){return arguments.length>0&&(10===arguments[0]?p||(p=!0,f.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?f.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",u.Logger.errors.UNEXPECTED_ARGUMENT,{}):f.throwError("BigNumber.toString does not accept parameters",u.Logger.errors.UNEXPECTED_ARGUMENT,{})),b(this).toString(10)}},{key:"toHexString",value:function(){return this._hex}},{key:"toJSON",value:function(e){return{type:"BigNumber",hex:this.toHexString()}}}],[{key:"from",value:function(t){if(t instanceof e)return t;if("string"==typeof t)return t.match(/^-?0x[0-9a-f]+$/i)?new e(h,y(t)):t.match(/^-?[0-9]+$/)?new e(h,y(new l(t))):f.throwArgumentError("invalid BigNumber string","value",t);if("number"==typeof t)return t%1&&v("underflow","BigNumber.from",t),(t>=d||t<=-d)&&v("overflow","BigNumber.from",t),e.from(String(t));var r=t;if("bigint"==typeof r)return e.from(r.toString());if((0,s.isBytes)(r))return e.from((0,s.hexlify)(r));if(r)if(r.toHexString){var n=r.toHexString();if("string"==typeof n)return e.from(n)}else{var i=r._hex;if(null==i&&"BigNumber"===r.type&&(i=r.hex),"string"==typeof i&&((0,s.isHexString)(i)||"-"===i[0]&&(0,s.isHexString)(i.substring(1))))return e.from(i)}return f.throwArgumentError("invalid BigNumber value","value",t)}},{key:"isBigNumber",value:function(e){return!(!e||!e._isBigNumber)}}]),e}();function y(e){if("string"!=typeof e)return y(e.toString(16));if("-"===e[0])return"-"===(e=e.substring(1))[0]&&f.throwArgumentError("invalid hex","value",e),"0x00"===(e=y(e))?e:"-"+e;if("0x"!==e.substring(0,2)&&(e="0x"+e),"0x"===e)return"0x00";for(e.length%2&&(e="0x0"+e.substring(2));e.length>4&&"0x00"===e.substring(0,4);)e="0x"+e.substring(4);return e}function g(e){return m.from(y(e))}function b(e){var t=m.from(e).toHexString();return"-"===t[0]?new l("-"+t.substring(3),16):new l(t.substring(2),16)}function v(e,t,r){var n={fault:e,operation:t};return null!=r&&(n.value=r),f.throwError(e,u.Logger.errors.NUMERIC_FAULT,n)}t.BigNumber=m},8390:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.FixedNumber=t.FixedFormat=void 0,t.formatFixed=b,t.parseFixed=v;var i=n(r(3355)),o=n(r(9721)),a=n(r(8985)),s=r(908),u=r(4327),c=r(3042),l=r(1872),f=new u.Logger(c.version),h={},d=l.BigNumber.from(0),p=l.BigNumber.from(-1);function m(e,t,r,n){var i={fault:t,operation:r};return void 0!==n&&(i.value=n),f.throwError(e,u.Logger.errors.NUMERIC_FAULT,i)}for(var y="0";y.length<256;)y+=y;function g(e){if("number"!=typeof e)try{e=l.BigNumber.from(e).toNumber()}catch(e){}return"number"==typeof e&&e>=0&&e<=256&&!(e%1)?"1"+y.substring(0,e):f.throwArgumentError("invalid decimal size","decimals",e)}function b(e,t){null==t&&(t=0);var r=g(t),n=(e=l.BigNumber.from(e)).lt(d);n&&(e=e.mul(p));for(var i=e.mod(r).toString();i.length2&&f.throwArgumentError("too many decimal points","value",e);var o=i[0],a=i[1];for(o||(o="0"),a||(a="0");"0"===a[a.length-1];)a=a.substring(0,a.length-1);for(a.length>r.length-1&&m("fractional component exceeds decimals","underflow","parseFixed"),""===a&&(a="0");a.length80&&f.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",o),new e(h,r,n,o)}}]),e}();t.FixedFormat=w;var A=function(){function e(t,r,n,i){(0,o.default)(this,e),t!==h&&f.throwError("cannot use FixedNumber constructor; use FixedNumber.from",u.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=i,this._hex=r,this._value=n,this._isFixedNumber=!0,Object.freeze(this)}return(0,a.default)(e,[{key:"_checkFormat",value:function(e){this.format.name!==e.format.name&&f.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}},{key:"addUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.add(n),this.format.decimals,this.format)}},{key:"subUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.sub(n),this.format.decimals,this.format)}},{key:"mulUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(n).div(this.format._multiplier),this.format.decimals,this.format)}},{key:"divUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(this.format._multiplier).div(n),this.format.decimals,this.format)}},{key:"floor",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return this.isNegative()&&n&&(r=r.subUnsafe(S.toFormat(r.format))),r}},{key:"ceiling",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return!this.isNegative()&&n&&(r=r.addUnsafe(S.toFormat(r.format))),r}},{key:"round",value:function(t){null==t&&(t=0);var r=this.toString().split(".");if(1===r.length&&r.push("0"),(t<0||t>80||t%1)&&f.throwArgumentError("invalid decimal count","decimals",t),r[1].length<=t)return this;var n=e.from("1"+y.substring(0,t),this.format),i=k.toFormat(this.format);return this.mulUnsafe(n).addUnsafe(i).floor().divUnsafe(n)}},{key:"isZero",value:function(){return"0.0"===this._value||"0"===this._value}},{key:"isNegative",value:function(){return"-"===this._value[0]}},{key:"toString",value:function(){return this._value}},{key:"toHexString",value:function(e){if(null==e)return this._hex;e%8&&f.throwArgumentError("invalid byte width","width",e);var t=l.BigNumber.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString();return(0,s.hexZeroPad)(t,e/8)}},{key:"toUnsafeFloat",value:function(){return parseFloat(this.toString())}},{key:"toFormat",value:function(t){return e.fromString(this._value,t)}}],[{key:"fromValue",value:function(t,r,n){return null!=n||null==r||(0,l.isBigNumberish)(r)||(n=r,r=null),null==r&&(r=0),null==n&&(n="fixed"),e.fromString(b(t,r),w.from(n))}},{key:"fromString",value:function(t,r){null==r&&(r="fixed");var n=w.from(r),i=v(t,n.decimals);!n.signed&&i.lt(d)&&m("unsigned value cannot be negative","overflow","value",t);var o=null;n.signed?o=i.toTwos(n.width).toHexString():(o=i.toHexString(),o=(0,s.hexZeroPad)(o,n.width/8));var a=b(i,n.decimals);return new e(h,o,a,n)}},{key:"fromBytes",value:function(t,r){null==r&&(r="fixed");var n=w.from(r);if((0,s.arrayify)(t).length>n.width/8)throw new Error("overflow");var i=l.BigNumber.from(t);n.signed&&(i=i.fromTwos(n.width));var o=i.toTwos((n.signed?0:1)+n.width).toHexString(),a=b(i,n.decimals);return new e(h,o,a,n)}},{key:"from",value:function(t,r){if("string"==typeof t)return e.fromString(t,r);if((0,s.isBytes)(t))return e.fromBytes(t,r);try{return e.fromValue(t,0,r)}catch(e){if(e.code!==u.Logger.errors.INVALID_ARGUMENT)throw e}return f.throwArgumentError("invalid FixedNumber value","value",t)}},{key:"isFixedNumber",value:function(e){return!(!e||!e._isFixedNumber)}}]),e}();t.FixedNumber=A;var S=A.from(1),k=A.from("0.5")},4952:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"BigNumber",{enumerable:!0,get:function(){return n.BigNumber}}),Object.defineProperty(t,"FixedFormat",{enumerable:!0,get:function(){return i.FixedFormat}}),Object.defineProperty(t,"FixedNumber",{enumerable:!0,get:function(){return i.FixedNumber}}),Object.defineProperty(t,"_base16To36",{enumerable:!0,get:function(){return n._base16To36}}),Object.defineProperty(t,"_base36To16",{enumerable:!0,get:function(){return n._base36To16}}),Object.defineProperty(t,"formatFixed",{enumerable:!0,get:function(){return i.formatFixed}}),Object.defineProperty(t,"parseFixed",{enumerable:!0,get:function(){return i.parseFixed}});var n=r(1872),i=r(8390)},8729:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="bytes/5.7.0"},908:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.arrayify=f,t.concat=h,t.hexConcat=function(e){var t="0x";return e.forEach((function(e){t+=y(e).substring(2)})),t},t.hexDataLength=function(e){if("string"!=typeof e)e=y(e);else if(!p(e)||e.length%2)return null;return(e.length-2)/2},t.hexDataSlice=function(e,t,r){return"string"!=typeof e?e=y(e):(!p(e)||e.length%2)&&o.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)},t.hexStripZeros=g,t.hexValue=function(e){var t=g(y(e,{hexPad:"left"}));return"0x"===t?"0x0":t},t.hexZeroPad=b,t.hexlify=y,t.isBytes=l,t.isBytesLike=u,t.isHexString=p,t.joinSignature=function(e){return y(h([(e=v(e)).r,e.s,e.recoveryParam?"0x1c":"0x1b"]))},t.splitSignature=v,t.stripZeros=function(e){var t=f(e);if(0===t.length)return t;for(var r=0;r=256)return!1}return!0}function f(e,t){if(t||(t={}),"number"==typeof e){o.checkSafeUint53(e,"invalid arrayify value");for(var r=[];e;)r.unshift(255&e),e=parseInt(String(e/256));return 0===r.length&&r.push(0),s(new Uint8Array(r))}if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e)&&(e=e.toHexString()),p(e)){var n=e.substring(2);n.length%2&&("left"===t.hexPad?n="0"+n:"right"===t.hexPad?n+="0":o.throwArgumentError("hex data is odd-length","value",e));for(var i=[],u=0;ut&&o.throwArgumentError("value out of range","value",arguments[0]);var r=new Uint8Array(t);return r.set(e,t-e.length),s(r)}function p(e,t){return!("string"!=typeof e||!e.match(/^0x[0-9A-Fa-f]*$/)||t&&e.length!==2+2*t)}var m="0123456789abcdef";function y(e,t){if(t||(t={}),"number"==typeof e){o.checkSafeUint53(e,"invalid hexlify value");for(var r="";e;)r=m[15&e]+r,e=Math.floor(e/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if("bigint"==typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e))return e.toHexString();if(p(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":o.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(l(e)){for(var n="0x",i=0;i>4]+m[15&s]}return n}return o.throwArgumentError("invalid hexlify value","value",e)}function g(e){"string"!=typeof e&&(e=y(e)),p(e)||o.throwArgumentError("invalid hex string","value",e),e=e.substring(2);for(var t=0;t2*t+2&&o.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function v(e){var t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(u(e)){var r=f(e);64===r.length?(t.v=27+(r[32]>>7),r[32]&=127,t.r=y(r.slice(0,32)),t.s=y(r.slice(32,64))):65===r.length?(t.r=y(r.slice(0,32)),t.s=y(r.slice(32,64)),t.v=r[64]):o.throwArgumentError("invalid signature string","signature",e),t.v<27&&(0===t.v||1===t.v?t.v+=27:o.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=y(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){var n=d(f(t._vs),32);t._vs=y(n);var i=n[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=i:t.recoveryParam!==i&&o.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),n[0]&=127;var a=y(n);null==t.s?t.s=a:t.s!==a&&o.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?o.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{var s=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==s&&o.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&p(t.r)?t.r=b(t.r,32):o.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&p(t.s)?t.s=b(t.s,32):o.throwArgumentError("signature missing or invalid s","signature",e);var c=f(t.s);c[0]>=128&&o.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(c[0]|=128);var l=y(c);t._vs&&(p(t._vs)||o.throwArgumentError("signature invalid _vs","signature",e),t._vs=b(t._vs,32)),null==t._vs?t._vs=l:t._vs!==l&&o.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t.yParityAndS=t._vs,t.compact=t.r+t.yParityAndS.substring(2),t}},8721:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AddressZero=void 0,t.AddressZero="0x0000000000000000000000000000000000000000"},2997:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Zero=t.WeiPerEther=t.Two=t.One=t.NegativeOne=t.MinInt256=t.MaxUint256=t.MaxInt256=void 0;var n=r(4952),i=n.BigNumber.from(-1);t.NegativeOne=i;var o=n.BigNumber.from(0);t.Zero=o;var a=n.BigNumber.from(1);t.One=a;var s=n.BigNumber.from(2);t.Two=s;var u=n.BigNumber.from("1000000000000000000");t.WeiPerEther=u;var c=n.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");t.MaxUint256=c;var l=n.BigNumber.from("-0x8000000000000000000000000000000000000000000000000000000000000000");t.MinInt256=l;var f=n.BigNumber.from("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");t.MaxInt256=f},396:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.HashZero=void 0,t.HashZero="0x0000000000000000000000000000000000000000000000000000000000000000"},5465:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AddressZero",{enumerable:!0,get:function(){return n.AddressZero}}),Object.defineProperty(t,"EtherSymbol",{enumerable:!0,get:function(){return a.EtherSymbol}}),Object.defineProperty(t,"HashZero",{enumerable:!0,get:function(){return o.HashZero}}),Object.defineProperty(t,"MaxInt256",{enumerable:!0,get:function(){return i.MaxInt256}}),Object.defineProperty(t,"MaxUint256",{enumerable:!0,get:function(){return i.MaxUint256}}),Object.defineProperty(t,"MinInt256",{enumerable:!0,get:function(){return i.MinInt256}}),Object.defineProperty(t,"NegativeOne",{enumerable:!0,get:function(){return i.NegativeOne}}),Object.defineProperty(t,"One",{enumerable:!0,get:function(){return i.One}}),Object.defineProperty(t,"Two",{enumerable:!0,get:function(){return i.Two}}),Object.defineProperty(t,"WeiPerEther",{enumerable:!0,get:function(){return i.WeiPerEther}}),Object.defineProperty(t,"Zero",{enumerable:!0,get:function(){return i.Zero}});var n=r(8721),i=r(2997),o=r(396),a=r(8347)},8347:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EtherSymbol=void 0,t.EtherSymbol="Ξ"},3989:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="hash/5.7.0"},3731:(e,t)=>{"use strict";function r(e,t){null==t&&(t=1);var r=[],n=r.forEach;return function e(t,i){n.call(t,(function(t){i>0&&Array.isArray(t)?e(t,i-1):r.push(t)}))}(e,t),r}function n(e){var t=0;function r(){return e[t++]<<8|e[t++]}for(var n=r(),i=1,o=[0,1],a=1;a>--c&1}for(var h=Math.pow(2,31),d=h>>>1,p=d>>1,m=h-1,y=0,g=0;g<31;g++)y=y<<1|f();for(var b=[],v=0,w=h;;){for(var A=Math.floor(((y-v+1)*i-1)/w),S=0,k=n;k-S>1;){var E=S+k>>>1;A>>1|f(),_=_<<1^d,M=(M^d)<<1|d|1;v=_,w=1+M-_}var T=n-4;return b.map((function(t){switch(t-T){case 3:return T+65792+(e[u++]<<16|e[u++]<<8|e[u++]);case 2:return T+256+(e[u++]<<8|e[u++]);case 1:return T+e[u++];default:return t-1}}))}function i(e){var t=0;return function(){return e[t++]}}function o(e){return 1&e?~e>>1:e>>1}function a(e,t){for(var r=Array(e),n=0,i=-1;n>=1),check:2==o}}()},t.read_mapped_map=function(e){for(var t=[];;){var n=e();if(0==n)break;t.push(f(n,e))}for(;;){var i=e()-1;if(i<0)break;t.push(h(i,e))}return function(e){for(var t={},r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getData=function(){return(0,i.read_compressed_payload)((0,n.decode)("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA=="))};var n=r(997),i=r(3731)},7032:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.ens_normalize=function(e){return y(function(e,t){for(var r=p(e).reverse(),n=[];r.length;){var o=g(r);if(o)n.push.apply(n,(0,i.default)(t(o)));else{var a=r.pop();if(l.has(a))n.push(a);else if(!f.has(a)){var s=h[a];if(!s)throw new Error("Disallowed codepoint: 0x".concat(a.toString(16).toUpperCase()));n.push.apply(n,(0,i.default)(s))}}}return y(String.fromCodePoint.apply(String,n).normalize("NFC"))}(e,m))},t.ens_normalize_post_check=y;var i=n(r(3106)),o=r(8627),a=r(3961),s=r(3731);function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}(e.split("."));try{for(r.s();!(t=r.n()).done;){var n=t.value,i=p(n);try{for(var o=i.lastIndexOf(95)-1;o>=0;o--)if(95!==i[o])throw new Error("underscore only allowed at start");if(i.length>=4&&i.every((function(e){return e<128}))&&45===i[2]&&45===i[3])throw new Error("invalid label extension")}catch(e){throw new Error('Invalid label "'.concat(n,'": ').concat(e.message))}}}catch(e){r.e(e)}finally{r.f()}return e}function g(e,t){var r,n,o,a=d,s=[],u=e.length;t&&(t.length=0);for(var c=function(){var c=e[--u];if(!(a=null===(r=a.branches.find((function(e){return e.set.has(c)})))||void 0===r?void 0:r.node))return"break";if(a.save)o=c;else if(a.check&&c===o)return"break";s.push(c),a.fe0f&&(s.push(65039),u>0&&65039==e[u-1]&&u--),a.valid&&(n=s.slice(),2==a.valid&&n.splice(1,1),t&&t.push.apply(t,(0,i.default)(e.slice(u).reverse())),e.length=u)};u&&"break"!==c(););return n}},7901:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.id=function(e){return(0,n.keccak256)((0,i.toUtf8Bytes)(e))};var n=r(4642),i=r(8627)},7515:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"_TypedDataEncoder",{enumerable:!0,get:function(){return a.TypedDataEncoder}}),Object.defineProperty(t,"dnsEncode",{enumerable:!0,get:function(){return i.dnsEncode}}),Object.defineProperty(t,"ensNormalize",{enumerable:!0,get:function(){return i.ensNormalize}}),Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return o.hashMessage}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return n.id}}),Object.defineProperty(t,"isValidName",{enumerable:!0,get:function(){return i.isValidName}}),Object.defineProperty(t,"messagePrefix",{enumerable:!0,get:function(){return o.messagePrefix}}),Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return i.namehash}});var n=r(7901),i=r(4898),o=r(4443),a=r(2171)},4443:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hashMessage=function(e){return"string"==typeof e&&(e=(0,o.toUtf8Bytes)(e)),(0,i.keccak256)((0,n.concat)([(0,o.toUtf8Bytes)(a),(0,o.toUtf8Bytes)(String(e.length)),e]))},t.messagePrefix=void 0;var n=r(908),i=r(4642),o=r(8627),a="Ethereum Signed Message:\n";t.messagePrefix=a},4898:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dnsEncode=function(e){return(0,n.hexlify)((0,n.concat)(h(e).map((function(e){if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");var t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"},t.ensNormalize=function(e){return h(e).map((function(e){return(0,i.toUtf8String)(e)})).join(".")},t.isValidName=function(e){try{return 0!==h(e).length}catch(e){}return!1},t.namehash=function(e){"string"!=typeof e&&c.throwArgumentError("invalid ENS name; not a string","name",e);for(var t=l,r=h(e);r.length;)t=(0,o.keccak256)((0,n.concat)([t,(0,o.keccak256)(r.pop())]));return(0,n.hexlify)(t)};var n=r(908),i=r(8627),o=r(4642),a=r(4327),s=r(3989),u=r(7032),c=new a.Logger(s.version),l=new Uint8Array(32);function f(e){if(0===e.length)throw new Error("invalid ENS name; empty component");return e}function h(e){var t=(0,i.toUtf8Bytes)((0,u.ens_normalize)(e)),r=[];if(0===e.length)return r;for(var n=0,o=0;o=t.length)throw new Error("invalid ENS name; empty component");return r.push(f(t.slice(n))),r}l.fill(0)},2171:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.TypedDataEncoder=void 0;var i=n(r(2247)),o=n(r(9721)),a=n(r(8985)),s=r(7921),u=r(4952),c=r(908),l=r(4642),f=r(3694),h=r(4327),d=r(3989),p=r(7901),m=new h.Logger(d.version),y=new Uint8Array(32);y.fill(0);var g=u.BigNumber.from(-1),b=u.BigNumber.from(0),v=u.BigNumber.from(1),w=u.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),A=(0,c.hexZeroPad)(v.toHexString(),32),S=(0,c.hexZeroPad)(b.toHexString(),32),k={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},E=["name","version","chainId","verifyingContract","salt"];function _(e){return function(t){return"string"!=typeof t&&m.throwArgumentError("invalid domain value for ".concat(JSON.stringify(e)),"domain.".concat(e),t),t}}var M={name:_("name"),version:_("version"),chainId:function(e){try{return u.BigNumber.from(e).toString()}catch(e){}return m.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",e)},verifyingContract:function(e){try{return(0,s.getAddress)(e).toLowerCase()}catch(e){}return m.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){try{var t=(0,c.arrayify)(e);if(32!==t.length)throw new Error("bad length");return(0,c.hexlify)(t)}catch(e){}return m.throwArgumentError('invalid domain value "salt"',"domain.salt",e)}};function T(e){var t=e.match(/^(u?)int(\d*)$/);if(t){var r=""===t[1],n=parseInt(t[2]||"256");(n%8!=0||n>256||t[2]&&t[2]!==String(n))&&m.throwArgumentError("invalid numeric width","type",e);var i=w.mask(r?n-1:n),o=r?i.add(v).mul(g):b;return function(t){var r=u.BigNumber.from(t);return(r.lt(o)||r.gt(i))&&m.throwArgumentError("value out-of-bounds for ".concat(e),"value",t),(0,c.hexZeroPad)(r.toTwos(256).toHexString(),32)}}var a=e.match(/^bytes(\d+)$/);if(a){var f=parseInt(a[1]);return(0===f||f>32||a[1]!==String(f))&&m.throwArgumentError("invalid bytes width","type",e),function(t){return(0,c.arrayify)(t).length!==f&&m.throwArgumentError("invalid length for ".concat(e),"value",t),function(e){var t=(0,c.arrayify)(e),r=t.length%32;return r?(0,c.hexConcat)([t,y.slice(r)]):(0,c.hexlify)(t)}(t)}}switch(e){case"address":return function(e){return(0,c.hexZeroPad)((0,s.getAddress)(e),32)};case"bool":return function(e){return e?A:S};case"bytes":return function(e){return(0,l.keccak256)(e)};case"string":return function(e){return(0,p.id)(e)}}return null}function x(e,t){return"".concat(e,"(").concat(t.map((function(e){var t=e.name;return e.type+" "+t})).join(","),")")}var P=function(){function e(t){(0,o.default)(this,e),(0,f.defineReadOnly)(this,"types",Object.freeze((0,f.deepCopy)(t))),(0,f.defineReadOnly)(this,"_encoderCache",{}),(0,f.defineReadOnly)(this,"_types",{});var r={},n={},i={};Object.keys(t).forEach((function(e){r[e]={},n[e]=[],i[e]={}}));var a=function(e){var i={};t[e].forEach((function(o){i[o.name]&&m.throwArgumentError("duplicate variable name ".concat(JSON.stringify(o.name)," in ").concat(JSON.stringify(e)),"types",t),i[o.name]=!0;var a=o.type.match(/^([^\x5b]*)(\x5b|$)/)[1];a===e&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(a)),"types",t),T(a)||(n[a]||m.throwArgumentError("unknown type ".concat(JSON.stringify(a)),"types",t),n[a].push(e),r[e][a]=!0)}))};for(var s in t)a(s);var u=Object.keys(n).filter((function(e){return 0===n[e].length}));for(var c in 0===u.length?m.throwArgumentError("missing primary type","types",t):u.length>1&&m.throwArgumentError("ambiguous primary types or unused types: ".concat(u.map((function(e){return JSON.stringify(e)})).join(", ")),"types",t),(0,f.defineReadOnly)(this,"primaryType",u[0]),function e(o,a){a[o]&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(o)),"types",t),a[o]=!0,Object.keys(r[o]).forEach((function(t){n[t]&&(e(t,a),Object.keys(a).forEach((function(e){i[e][t]=!0})))})),delete a[o]}(this.primaryType,{}),i){var l=Object.keys(i[c]);l.sort(),this._types[c]=x(c,t[c])+l.map((function(e){return x(e,t[e])})).join("")}}return(0,a.default)(e,[{key:"getEncoder",value:function(e){var t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}},{key:"_getEncoder",value:function(e){var t=this,r=T(e);if(r)return r;var n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){var i=n[1],o=this.getEncoder(i),a=parseInt(n[3]);return function(e){a>=0&&e.length!==a&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",e);var r=e.map(o);return t._types[i]&&(r=r.map(l.keccak256)),(0,l.keccak256)((0,c.hexConcat)(r))}}var s=this.types[e];if(s){var u=(0,p.id)(this._types[e]);return function(e){var r=s.map((function(r){var n=r.name,i=r.type,o=t.getEncoder(i)(e[n]);return t._types[i]?(0,l.keccak256)(o):o}));return r.unshift(u),(0,c.hexConcat)(r)}}return m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"encodeType",value:function(e){var t=this._types[e];return t||m.throwArgumentError("unknown type: ".concat(JSON.stringify(e)),"name",e),t}},{key:"encodeData",value:function(e,t){return this.getEncoder(e)(t)}},{key:"hashStruct",value:function(e,t){return(0,l.keccak256)(this.encodeData(e,t))}},{key:"encode",value:function(e){return this.encodeData(this.primaryType,e)}},{key:"hash",value:function(e){return this.hashStruct(this.primaryType,e)}},{key:"_visit",value:function(e,t,r){var n=this;if(T(e))return r(e,t);var i=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(i){var o=i[1],a=parseInt(i[3]);return a>=0&&t.length!==a&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((function(e){return n._visit(o,e,r)}))}var s=this.types[e];return s?s.reduce((function(e,i){var o=i.name,a=i.type;return e[o]=n._visit(a,t[o],r),e}),{}):m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"visit",value:function(e,t){return this._visit(this.primaryType,e,t)}}],[{key:"from",value:function(t){return new e(t)}},{key:"getPrimaryType",value:function(t){return e.from(t).primaryType}},{key:"hashStruct",value:function(t,r,n){return e.from(r).hashStruct(t,n)}},{key:"hashDomain",value:function(t){var r=[];for(var n in t){var i=k[n];i||m.throwArgumentError("invalid typed-data domain key: ".concat(JSON.stringify(n)),"domain",t),r.push({name:n,type:i})}return r.sort((function(e,t){return E.indexOf(e.name)-E.indexOf(t.name)})),e.hashStruct("EIP712Domain",{EIP712Domain:r},t)}},{key:"encode",value:function(t,r,n){return(0,c.hexConcat)(["0x1901",e.hashDomain(t),e.from(r).hash(n)])}},{key:"hash",value:function(t,r,n){return(0,l.keccak256)(e.encode(t,r,n))}},{key:"resolveNames",value:function(t,r,n,o){return a=this,s=void 0,u=i.default.mark((function a(){var s,u,l;return i.default.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:t=(0,f.shallowCopy)(t),s={},t.verifyingContract&&!(0,c.isHexString)(t.verifyingContract,20)&&(s[t.verifyingContract]="0x"),(u=e.from(r)).visit(n,(function(e,t){return"address"!==e||(0,c.isHexString)(t,20)||(s[t]="0x"),t})),a.t0=i.default.keys(s);case 6:if((a.t1=a.t0()).done){a.next=13;break}return l=a.t1.value,a.next=10,o(l);case 10:s[l]=a.sent,a.next=6;break;case 13:return t.verifyingContract&&s[t.verifyingContract]&&(t.verifyingContract=s[t.verifyingContract]),n=u.visit(n,(function(e,t){return"address"===e&&s[t]?s[t]:t})),a.abrupt("return",{domain:t,value:n});case 16:case"end":return a.stop()}}),a)})),new(s||(s=Promise))((function(e,t){function r(e){try{i(u.next(e))}catch(e){t(e)}}function n(e){try{i(u.throw(e))}catch(e){t(e)}}function i(t){var i;t.done?e(t.value):(i=t.value,i instanceof s?i:new s((function(e){e(i)}))).then(r,n)}i((u=u.apply(a,[])).next())}));var a,s,u}},{key:"getPayload",value:function(t,r,n){e.hashDomain(t);var i={},o=[];E.forEach((function(e){var r=t[e];null!=r&&(i[e]=M[e](r),o.push({name:e,type:k[e]}))}));var a=e.from(r),s=(0,f.shallowCopy)(r);return s.EIP712Domain?m.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",r):s.EIP712Domain=o,a.encode(n),{types:s,domain:i,primaryType:a.primaryType,message:a.visit(n,(function(e,t){if(e.match(/^bytes(\d*)/))return(0,c.hexlify)((0,c.arrayify)(t));if(e.match(/^u?int/))return u.BigNumber.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!=typeof t&&m.throwArgumentError("invalid string","value",t),t}return m.throwArgumentError("unsupported type","type",e)}))}}}]),e}();t.TypedDataEncoder=P},4642:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.keccak256=function(e){return"0x"+i.default.keccak_256((0,o.arrayify)(e))};var i=n(r(5975)),o=r(908)},5975:(e,t,r)=>{"use strict";e=r.nmd(e);var n,i=r(9142),o=r(8847)(r(3355));!function(){var a="input is invalid type",s="object"===("undefined"==typeof window?"undefined":(0,o.default)(window)),u=s?window:{};u.JS_SHA3_NO_WINDOW&&(s=!1);var c=!s&&"object"===("undefined"==typeof self?"undefined":(0,o.default)(self));!u.JS_SHA3_NO_NODE_JS&&"object"===(void 0===i?"undefined":(0,o.default)(i))&&i.versions&&i.versions.node?u=r.g:c&&(u=self);var l=!u.JS_SHA3_NO_COMMON_JS&&"object"===(0,o.default)(e)&&e.exports,f=r.amdO,h=!u.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,d="0123456789abcdef".split(""),p=[4,1024,262144,67108864],m=[0,8,16,24],y=[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],g=[224,256,384,512],b=[128,256],v=["hex","buffer","arrayBuffer","array","digest"],w={128:168,256:136};!u.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!h||!u.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===(0,o.default)(e)&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var A=function(e,t,r){return function(n){return new L(e,t,e).update(n)[r]()}},S=function(e,t,r){return function(n,i){return new L(e,t,i).update(n)[r]()}},k=function(e,t,r){return function(t,n,i,o){return x["cshake"+e].update(t,n,i,o)[r]()}},E=function(e,t,r){return function(t,n,i,o){return x["kmac"+e].update(t,n,i,o)[r]()}},_=function(e,t,r,n){for(var i=0;i>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function U(e,t,r){L.call(this,e,t,r)}L.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}for(var n,i,s=this.blocks,u=this.byteCount,c=e.length,l=this.blockCount,f=0,d=this.s;f>2]|=e[f]<>2]|=i<>2]|=(192|i>>6)<>2]|=(128|63&i)<=57344?(s[n>>2]|=(224|i>>12)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<>2]|=(240|i>>18)<>2]|=(128|i>>12&63)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<=u){for(this.start=n-u,this.block=s[l],n=0;n>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},L.prototype.encodeString=function(e){var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}var n=0,i=e.length;if(t)n=i;else for(var s=0;s=57344?n+=3:(u=65536+((1023&u)<<10|1023&e.charCodeAt(++s)),n+=4)}return n+=this.encode(8*n),this.update(e),n},L.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+d[15&e]+d[e>>12&15]+d[e>>8&15]+d[e>>20&15]+d[e>>16&15]+d[e>>28&15]+d[e>>24&15];a%t==0&&(F(r),o=0)}return i&&(e=r[o],s+=d[e>>4&15]+d[15&e],i>1&&(s+=d[e>>12&15]+d[e>>8&15]),i>2&&(s+=d[e>>20&15]+d[e>>16&15])),s},L.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&F(n)}return o&&(e=s<<2,t=n[a],u[e]=255&t,o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u},U.prototype=new L,U.prototype.finalize=function(){return this.encode(this.outputBits,!0),L.prototype.finalize.call(this)};var F=function(e){var t,r,n,i,o,a,s,u,c,l,f,h,d,p,m,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],u=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],l=e[6]^e[16]^e[26]^e[36]^e[46],f=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(d=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|c>>>31),r=o^(c<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(l<<1|f>>>31),r=s^(f<<1|l>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(h<<1|d>>>31),r=c^(d<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=l^(i<<1|o>>>31),r=f^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],m=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=p^~g&v,e[1]=m^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&p,e[7]=S^~E&m,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~p&g,e[9]=E^~m&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=y[n],e[1]^=y[n+1]};if(l)e.exports=x;else{for(I=0;I{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="logger/5.7.0"},4327:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.Logger=t.LogLevel=t.ErrorCode=void 0;var i,o,a=n(r(9721)),s=n(r(8985)),u=r(7252),c=!1,l=!1,f={debug:1,default:2,info:2,warning:3,error:4,off:5},h=f.default,d=null,p=function(){try{var e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((function(t){try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(e){return e.message}return null}();t.LogLevel=i,function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(i||(t.LogLevel=i={})),t.ErrorCode=o,function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED",e.ACTION_REJECTED="ACTION_REJECTED"}(o||(t.ErrorCode=o={}));var m="0123456789abcdef",y=function(){function e(t){(0,a.default)(this,e),Object.defineProperty(this,"version",{enumerable:!0,value:t,writable:!1})}return(0,s.default)(e,[{key:"_log",value:function(e,t){var r=e.toLowerCase();null==f[r]&&this.throwArgumentError("invalid log level name","logLevel",e),h>f[r]||console.log.apply(console,t)}},{key:"debug",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n>4],r+=m[15&t[o]];i.push(e+"=Uint8Array(0x"+r+")")}else i.push(e+"="+JSON.stringify(t))}catch(t){i.push(e+"="+JSON.stringify(n[e].toString()))}})),i.push("code=".concat(r)),i.push("version=".concat(this.version));var a=t,s="";switch(r){case o.NUMERIC_FAULT:s="NUMERIC_FAULT";var u=t;switch(u){case"overflow":case"underflow":case"division-by-zero":s+="-"+u;break;case"negative-power":case"negative-width":s+="-unsupported";break;case"unbound-bitwise-result":s+="-unbound-result"}break;case o.CALL_EXCEPTION:case o.INSUFFICIENT_FUNDS:case o.MISSING_NEW:case o.NONCE_EXPIRED:case o.REPLACEMENT_UNDERPRICED:case o.TRANSACTION_REPLACED:case o.UNPREDICTABLE_GAS_LIMIT:s=r}s&&(t+=" [ See: https://links.ethers.org/v5-errors-"+s+" ]"),i.length&&(t+=" ("+i.join(", ")+")");var c=new Error(t);return c.reason=a,c.code=r,Object.keys(n).forEach((function(e){c[e]=n[e]})),c}},{key:"throwError",value:function(e,t,r){throw this.makeError(e,t,r)}},{key:"throwArgumentError",value:function(t,r,n){return this.throwError(t,e.errors.INVALID_ARGUMENT,{argument:r,value:n})}},{key:"assert",value:function(e,t,r,n){e||this.throwError(t,r,n)}},{key:"assertArgument",value:function(e,t,r,n){e||this.throwArgumentError(t,r,n)}},{key:"checkNormalize",value:function(t){null==t&&(t="platform missing String.prototype.normalize"),p&&this.throwError("platform missing String.prototype.normalize",e.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:p})}},{key:"checkSafeUint53",value:function(t,r){"number"==typeof t&&(null==r&&(r="value not safe"),(t<0||t>=9007199254740991)&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}},{key:"checkArgumentCount",value:function(t,r,n){n=n?": "+n:"",tr&&this.throwError("too many arguments"+n,e.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:r})}},{key:"checkNew",value:function(t,r){t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}},{key:"checkAbstract",value:function(t,r){t===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",e.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}}],[{key:"globalLogger",value:function(){return d||(d=new e(u.version)),d}},{key:"setCensorship",value:function(t,r){if(!t&&r&&this.globalLogger().throwError("cannot permanently disable censorship",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),c){if(!t)return;this.globalLogger().throwError("error censorship permanent",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}l=!!t,c=!!r}},{key:"setLogLevel",value:function(t){var r=f[t.toLowerCase()];null!=r?h=r:e.globalLogger().warn("invalid log level - "+t)}},{key:"from",value:function(t){return new e(t)}}]),e}();t.Logger=y,y.errors=o,y.levels=i},4071:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="properties/5.7.0"},3694:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.Description=void 0,t.checkProperties=function(e,t){e&&"object"===(0,s.default)(e)||f.throwArgumentError("invalid object","object",e),Object.keys(e).forEach((function(r){t[r]||f.throwArgumentError("invalid object key - "+r,"transaction:"+r,e)}))},t.deepCopy=y,t.defineReadOnly=h,t.getStatic=function(e,t){for(var r=0;r<32;r++){if(e[t])return e[t];if(!e.prototype||"object"!==(0,s.default)(e.prototype))break;e=Object.getPrototypeOf(e.prototype).constructor}return null},t.resolveProperties=function(e){return l(this,void 0,void 0,i.default.mark((function t(){var r,n;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=Object.keys(e).map((function(t){var r=e[t];return Promise.resolve(r).then((function(e){return{key:t,value:e}}))})),t.next=3,Promise.all(r);case 3:return n=t.sent,t.abrupt("return",n.reduce((function(e,t){return e[t.key]=t.value,e}),{}));case 5:case"end":return t.stop()}}),t)})))},t.shallowCopy=function(e){var t={};for(var r in e)t[r]=e[r];return t};var i=n(r(2247)),o=n(r(8985)),a=n(r(9721)),s=n(r(3355)),u=r(4327),c=r(4071),l=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))},f=new u.Logger(c.version);function h(e,t,r){Object.defineProperty(e,t,{enumerable:!0,value:r,writable:!1})}var d={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function p(e){if(null==e||d[(0,s.default)(e)])return!0;if(Array.isArray(e)||"object"===(0,s.default)(e)){if(!Object.isFrozen(e))return!1;for(var t=Object.keys(e),r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="rlp/5.7.0"},5265:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decode=function(e){var t=(0,n.arrayify)(e),r=f(t,0);return r.consumed!==t.length&&a.throwArgumentError("invalid rlp data","data",e),r.result},t.encode=function(e){return(0,n.hexlify)(c(e))};var n=r(908),i=r(4327),o=r(1466),a=new i.Logger(o.version);function s(e){for(var t=[];e;)t.unshift(255&e),e>>=8;return t}function u(e,t,r){for(var n=0,i=0;it+1+n&&a.throwError("child data too short",i.Logger.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:o}}function f(e,t){if(0===e.length&&a.throwError("data too short",i.Logger.errors.BUFFER_OVERRUN,{}),e[t]>=248){var r=e[t]-247;t+1+r>e.length&&a.throwError("data short segment too short",i.Logger.errors.BUFFER_OVERRUN,{});var o=u(e,t+1,r);return t+1+r+o>e.length&&a.throwError("data long segment too short",i.Logger.errors.BUFFER_OVERRUN,{}),l(e,t,t+1+r,r+o)}if(e[t]>=192){var s=e[t]-192;return t+1+s>e.length&&a.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{}),l(e,t,t+1,s)}if(e[t]>=184){var c=e[t]-183;t+1+c>e.length&&a.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{});var f=u(e,t+1,c);return t+1+c+f>e.length&&a.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+c+f,result:(0,n.hexlify)(e.slice(t+1+c,t+1+c+f))}}if(e[t]>=128){var h=e[t]-128;return t+1+h>e.length&&a.throwError("data too short",i.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+h,result:(0,n.hexlify)(e.slice(t+1,t+1+h))}}return{consumed:1,result:(0,n.hexlify)(e[t])}}},8100:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="signing-key/5.7.0"},6918:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.EC=void 0;var i=n(r(3355)),o=n(r(1734)),a=n(r(7198));function s(e,t,r){return r={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&r.path)}},e(r,r.exports),r.exports}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==r.g?r.g:"undefined"!=typeof self&&self;var u=c;function c(e,t){if(!e)throw new Error(t||"Assertion failed")}c.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var l=s((function(e,t){var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}})),f=s((function(e,t){var r=t;r.assert=u,r.toArray=l.toArray,r.zero2=l.zero2,r.toHex=l.toHex,r.encode=l.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!=(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!=(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"==typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new o.default(e,"hex","le")}})),h=f.getNAF,d=f.getJSF,p=f.assert;function m(e,t){this.type=e,this.p=new o.default(t.p,16),this.red=t.prime?o.default.red(t.prime):o.default.mont(this.p),this.zero=new o.default(0).toRed(this.red),this.one=new o.default(1).toRed(this.red),this.two=new o.default(2).toRed(this.red),this.n=t.n&&new o.default(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var y=m;function g(e,t){this.curve=e,this.type=t,this.precomputed=null}m.prototype.point=function(){throw new Error("Not implemented")},m.prototype.validate=function(){throw new Error("Not implemented")},m.prototype._fixedNafMul=function(e,t){p(e.precomputed);var r=e._getDoubles(),n=h(t,1,this._bitLength),i=(1<=o;u--)a=(a<<1)+n[u];s.push(a)}for(var c=this.jpoint(null,null,null),l=this.jpoint(null,null,null),f=i;f>0;f--){for(o=0;o=0;s--){for(var u=0;s>=0&&0===o[s];s--)u++;if(s>=0&&u++,a=a.dblp(u),s<0)break;var c=o[s];p(0!==c),a="affine"===e.type?c>0?a.mixedAdd(i[c-1>>1]):a.mixedAdd(i[-c-1>>1].neg()):c>0?a.add(i[c-1>>1]):a.add(i[-c-1>>1].neg())}return"affine"===e.type?a.toP():a},m.prototype._wnafMulAdd=function(e,t,r,n,i){var o,a,s,u=this._wnafT1,c=this._wnafT2,l=this._wnafT3,f=0;for(o=0;o=1;o-=2){var m=o-1,y=o;if(1===u[m]&&1===u[y]){var g=[t[m],null,null,t[y]];0===t[m].y.cmp(t[y].y)?(g[1]=t[m].add(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg())):0===t[m].y.cmp(t[y].y.redNeg())?(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].add(t[y].neg())):(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg()));var b=[-3,-1,-5,-7,0,7,5,1,3],v=d(r[m],r[y]);for(f=Math.max(v[0].length,f),l[m]=new Array(f),l[y]=new Array(f),a=0;a=0;o--){for(var E=0;o>=0;){var _=!0;for(a=0;a=0&&E++,S=S.dblp(E),o<0)break;for(a=0;a0?s=c[a][M-1>>1]:M<0&&(s=c[a][-M-1>>1].neg()),S="affine"===s.type?S.mixedAdd(s):S.add(s))}}for(o=0;o=Math.ceil((e.bitLength()+1)/t.step)},g.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i=0&&(a=t,s=r),n.negative&&(n=n.neg(),i=i.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:n,b:i},{a,b:s}]},w.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},w.prototype.pointFromX=function(e,t){(e=new o.default(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},w.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},w.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},S.prototype.isInfinity=function(){return this.inf},S.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},S.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},S.prototype.getX=function(){return this.x.fromRed()},S.prototype.getY=function(){return this.y.fromRed()},S.prototype.mul=function(e){return e=new o.default(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},S.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},S.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},S.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},S.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},S.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},b(k,y.BasePoint),w.prototype.jpoint=function(e,t,r){return new k(this,e,t,r)},k.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},k.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},k.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},k.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},k.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},k.prototype.inspect=function(){return this.isInfinity()?"":""},k.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var E=s((function(e,t){var r=t;r.base=y,r.short=A,r.mont=null,r.edwards=null})),_=s((function(e,t){var r,n=t,i=f.assert;function o(e){"short"===e.type?this.curve=new E.short(e):"edwards"===e.type?this.curve=new E.edwards(e):this.curve=new E.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,i(this.g.validate(),"Invalid curve"),i(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function s(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new o(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=o,s("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:a.default.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),s("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:a.default.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),s("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:a.default.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),s("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:a.default.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"]}),s("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:a.default.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"]}),s("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:a.default.sha256,gRed:!1,g:["9"]}),s("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:a.default.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(e){r=void 0}s("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:a.default.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function M(e){if(!(this instanceof M))return new M(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=l.toArray(e.entropy,e.entropyEnc||"hex"),r=l.toArray(e.nonce,e.nonceEnc||"hex"),n=l.toArray(e.pers,e.persEnc||"hex");u(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var T=M;M.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},M.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=l.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length"};var O=f.assert;function R(e,t){if(e instanceof R)return e;this._importDER(e,t)||(O(e.r&&e.s,"Signature without r or s"),this.r=new o.default(e.r,16),this.s=new o.default(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var C=R;function B(){this.place=0}function N(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function L(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}R.prototype._importDER=function(e,t){e=f.toArray(e,t);var r=new B;if(48!==e[r.place++])return!1;var n=N(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var i=N(e,r);if(!1===i)return!1;var a=e.slice(r.place,i+r.place);if(r.place+=i,2!==e[r.place++])return!1;var s=N(e,r);if(!1===s)return!1;if(e.length!==s+r.place)return!1;var u=e.slice(r.place,s+r.place);if(0===a[0]){if(!(128&a[1]))return!1;a=a.slice(1)}if(0===u[0]){if(!(128&u[1]))return!1;u=u.slice(1)}return this.r=new o.default(a),this.s=new o.default(u),this.recoveryParam=null,!0},R.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=L(t),r=L(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];U(n,t.length),(n=n.concat(t)).push(2),U(n,r.length);var i=n.concat(r),o=[48];return U(o,i.length),o=o.concat(i),f.encode(o,e)};var F=function(){throw new Error("unsupported")},D=f.assert;function j(e){if(!(this instanceof j))return new j(e);"string"==typeof e&&(D(Object.prototype.hasOwnProperty.call(_,e),"Unknown curve "+e),e=_[e]),e instanceof _.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var H=j;j.prototype.keyPair=function(e){return new I(this,e)},j.prototype.keyFromPrivate=function(e,t){return I.fromPrivate(this,e,t)},j.prototype.keyFromPublic=function(e,t){return I.fromPublic(this,e,t)},j.prototype.genKeyPair=function(e){e||(e={});for(var t=new T({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||F(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new o.default(2));;){var i=new o.default(t.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},j.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},j.prototype.sign=function(e,t,r,n){"object"===(0,i.default)(r)&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new o.default(e,16));for(var a=this.n.byteLength(),s=t.getPrivate().toArray("be",a),u=e.toArray("be",a),c=new T({hash:this.hash,entropy:s,nonce:u,pers:n.pers,persEnc:n.persEnc||"utf8"}),l=this.n.sub(new o.default(1)),f=0;;f++){var h=n.k?n.k(f):new o.default(c.generate(this.n.byteLength()));if(!((h=this._truncateToN(h,!0)).cmpn(1)<=0||h.cmp(l)>=0)){var d=this.g.mul(h);if(!d.isInfinity()){var p=d.getX(),m=p.umod(this.n);if(0!==m.cmpn(0)){var y=h.invm(this.n).mul(m.mul(t.getPrivate()).iadd(e));if(0!==(y=y.umod(this.n)).cmpn(0)){var g=(d.getY().isOdd()?1:0)|(0!==p.cmp(m)?2:0);return n.canonical&&y.cmp(this.nh)>0&&(y=this.n.sub(y),g^=1),new C({r:m,s:y,recoveryParam:g})}}}}}},j.prototype.verify=function(e,t,r,n){e=this._truncateToN(new o.default(e,16)),r=this.keyFromPublic(r,n);var i=(t=new C(t,"hex")).r,a=t.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),c=u.mul(e).umod(this.n),l=u.mul(i).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(c,r.getPublic(),l)).isInfinity()&&s.eqXToP(i):!(s=this.g.mulAdd(c,r.getPublic(),l)).isInfinity()&&0===s.getX().umod(this.n).cmp(i)},j.prototype.recoverPubKey=function(e,t,r,n){D((3&r)===r,"The recovery param is more than two bits"),t=new C(t,n);var i=this.n,a=new o.default(e),s=t.r,u=t.s,c=1&r,l=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&l)throw new Error("Unable to find sencond key candinate");s=l?this.curve.pointFromX(s.add(this.curve.n),c):this.curve.pointFromX(s,c);var f=t.r.invm(i),h=i.sub(a).mul(f).umod(i),d=u.mul(f).umod(i);return this.g.mulAdd(h,s,d)},j.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new C(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")};var J=s((function(e,t){var r=t;r.version="6.5.4",r.utils=f,r.rand=function(){throw new Error("unsupported")},r.curve=E,r.curves=_,r.ec=H,r.eddsa=null})),z=J.ec;t.EC=z},7612:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.SigningKey=void 0,t.computePublicKey=m,t.recoverPublicKey=function(e,t){var r=(0,s.splitSignature)(t),n={r:(0,s.arrayify)(r.r),s:(0,s.arrayify)(r.s)};return"0x"+d().recoverPubKey((0,s.arrayify)(e),n,r.recoveryParam).encode("hex",!1)};var i=n(r(9721)),o=n(r(8985)),a=r(6918),s=r(908),u=r(3694),c=r(4327),l=r(8100),f=new c.Logger(l.version),h=null;function d(){return h||(h=new a.EC("secp256k1")),h}var p=function(){function e(t){(0,i.default)(this,e),(0,u.defineReadOnly)(this,"curve","secp256k1"),(0,u.defineReadOnly)(this,"privateKey",(0,s.hexlify)(t)),32!==(0,s.hexDataLength)(this.privateKey)&&f.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");var r=d().keyFromPrivate((0,s.arrayify)(this.privateKey));(0,u.defineReadOnly)(this,"publicKey","0x"+r.getPublic(!1,"hex")),(0,u.defineReadOnly)(this,"compressedPublicKey","0x"+r.getPublic(!0,"hex")),(0,u.defineReadOnly)(this,"_isSigningKey",!0)}return(0,o.default)(e,[{key:"_addPoint",value:function(e){var t=d().keyFromPublic((0,s.arrayify)(this.publicKey)),r=d().keyFromPublic((0,s.arrayify)(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}},{key:"signDigest",value:function(e){var t=d().keyFromPrivate((0,s.arrayify)(this.privateKey)),r=(0,s.arrayify)(e);32!==r.length&&f.throwArgumentError("bad digest length","digest",e);var n=t.sign(r,{canonical:!0});return(0,s.splitSignature)({recoveryParam:n.recoveryParam,r:(0,s.hexZeroPad)("0x"+n.r.toString(16),32),s:(0,s.hexZeroPad)("0x"+n.s.toString(16),32)})}},{key:"computeSharedSecret",value:function(e){var t=d().keyFromPrivate((0,s.arrayify)(this.privateKey)),r=d().keyFromPublic((0,s.arrayify)(m(e)));return(0,s.hexZeroPad)("0x"+t.derive(r.getPublic()).toString(16),32)}}],[{key:"isSigningKey",value:function(e){return!(!e||!e._isSigningKey)}}]),e}();function m(e,t){var r=(0,s.arrayify)(e);if(32===r.length){var n=new p(r);return t?"0x"+d().keyFromPrivate(r).getPublic(!0,"hex"):n.publicKey}return 33===r.length?t?(0,s.hexlify)(r):"0x"+d().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+d().keyFromPublic(r).getPublic(!0,"hex"):(0,s.hexlify)(r):f.throwArgumentError("invalid public or private key","key","[REDACTED]")}t.SigningKey=p},6518:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="strings/5.7.0"},5856:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatBytes32String=function(e){var t=(0,o.toUtf8Bytes)(e);if(t.length>31)throw new Error("bytes32 string must be less than 32 bytes");return(0,i.hexlify)((0,i.concat)([t,n.HashZero]).slice(0,32))},t.parseBytes32String=function(e){var t=(0,i.arrayify)(e);if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");for(var r=31;0===t[r-1];)r--;return(0,o.toUtf8String)(t.slice(0,r))};var n=r(5465),i=r(908),o=r(4997)},8645:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t._nameprepTableA1=p,t._nameprepTableB2=m,t._nameprepTableC=y,t.nameprep=function(e){if(e.match(/^[a-z0-9-]*$/i)&&e.length<=59)return e.toLowerCase();var t,r=(0,n.toUtf8CodePoints)(e);t=r.map((function(e){return u.indexOf(e)>=0||e>=65024&&e<=65039?[]:m(e)||[e]})),r=t.reduce((function(e,t){return t.forEach((function(t){e.push(t)})),e}),[]),(r=(0,n.toUtf8CodePoints)((0,n._toUtf8String)(r),n.UnicodeNormalizationForm.NFKC)).forEach((function(e){if(y(e))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),r.forEach((function(e){if(p(e))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));var i=(0,n._toUtf8String)(r);if("-"===i.substring(0,1)||"--"===i.substring(2,4)||"-"===i.substring(i.length-1))throw new Error("invalid hyphen");return i};var n=r(4997);function i(e,t){t||(t=function(e){return[parseInt(e,16)]});var r=0,n={};return e.split(",").forEach((function(e){var i=e.split(":");r+=parseInt(i[0],16),n[r]=t(i[1])})),n}function o(e){var t=0;return e.split(",").map((function(e){var r=e.split("-");return 1===r.length?r[1]="0":""===r[1]&&(r[1]="1"),{l:t+parseInt(r[0],16),h:t=parseInt(r[1],16)}}))}function a(e,t){for(var r=0,n=0;n=(r+=i.l)&&e<=r+i.h&&(e-r)%(i.d||1)==0){if(i.e&&-1!==i.e.indexOf(e-r))continue;return i}}return null}var s=o("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),u="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((function(e){return parseInt(e,16)})),c=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],l=i("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),f=i("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),h=i("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",(function(e){if(e.length%4!=0)throw new Error("bad data");for(var t=[],r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"UnicodeNormalizationForm",{enumerable:!0,get:function(){return o.UnicodeNormalizationForm}}),Object.defineProperty(t,"Utf8ErrorFuncs",{enumerable:!0,get:function(){return o.Utf8ErrorFuncs}}),Object.defineProperty(t,"Utf8ErrorReason",{enumerable:!0,get:function(){return o.Utf8ErrorReason}}),Object.defineProperty(t,"_toEscapedUtf8String",{enumerable:!0,get:function(){return o._toEscapedUtf8String}}),Object.defineProperty(t,"formatBytes32String",{enumerable:!0,get:function(){return n.formatBytes32String}}),Object.defineProperty(t,"nameprep",{enumerable:!0,get:function(){return i.nameprep}}),Object.defineProperty(t,"parseBytes32String",{enumerable:!0,get:function(){return n.parseBytes32String}}),Object.defineProperty(t,"toUtf8Bytes",{enumerable:!0,get:function(){return o.toUtf8Bytes}}),Object.defineProperty(t,"toUtf8CodePoints",{enumerable:!0,get:function(){return o.toUtf8CodePoints}}),Object.defineProperty(t,"toUtf8String",{enumerable:!0,get:function(){return o.toUtf8String}});var n=r(5856),i=r(8645),o=r(4997)},4997:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Utf8ErrorReason=t.Utf8ErrorFuncs=t.UnicodeNormalizationForm=void 0,t._toEscapedUtf8String=function(e,t){return'"'+f(e,t).map((function(e){if(e<256){switch(e){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(e>=32&&e<127)return String.fromCharCode(e)}return e<=65535?d(e):d(55296+((e-=65536)>>10&1023))+d(56320+(1023&e))})).join("")+'"'},t._toUtf8String=p,t.toUtf8Bytes=h,t.toUtf8CodePoints=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;return f(h(e,t))},t.toUtf8String=function(e,t){return p(f(e,t))};var n,i,o=r(908),a=r(4327),s=r(6518),u=new a.Logger(s.version);function c(e,t,r,n,o){if(e===i.BAD_PREFIX||e===i.UNEXPECTED_CONTINUE){for(var a=0,s=t+1;s>6==2;s++)a++;return a}return e===i.OVERRUN?r.length-t-1:0}t.UnicodeNormalizationForm=n,function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(n||(t.UnicodeNormalizationForm=n={})),t.Utf8ErrorReason=i,function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(i||(t.Utf8ErrorReason=i={}));var l=Object.freeze({error:function(e,t,r,n,i){return u.throwArgumentError("invalid codepoint at offset ".concat(t,"; ").concat(e),"bytes",r)},ignore:c,replace:function(e,t,r,n,o){return e===i.OVERLONG?(n.push(o),0):(n.push(65533),c(e,t,r))}});function f(e,t){null==t&&(t=l.error),e=(0,o.arrayify)(e);for(var r=[],n=0;n>7!=0){var s=null,u=null;if(192==(224&a))s=1,u=127;else if(224==(240&a))s=2,u=2047;else{if(240!=(248&a)){n+=t(128==(192&a)?i.UNEXPECTED_CONTINUE:i.BAD_PREFIX,n-1,e,r);continue}s=3,u=65535}if(n-1+s>=e.length)n+=t(i.OVERRUN,n-1,e,r);else{for(var c=a&(1<<8-s-1)-1,f=0;f1114111?n+=t(i.OUT_OF_RANGE,n-1-s,e,r,c):c>=55296&&c<=57343?n+=t(i.UTF16_SURROGATE,n-1-s,e,r,c):c<=u?n+=t(i.OVERLONG,n-1-s,e,r,c):r.push(c))}}else r.push(a)}return r}function h(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;t!=n.current&&(u.checkNormalize(),e=e.normalize(t));for(var r=[],i=0;i>6|192),r.push(63&a|128);else if(55296==(64512&a)){i++;var s=e.charCodeAt(i);if(i>=e.length||56320!=(64512&s))throw new Error("invalid utf-8 string");var c=65536+((1023&a)<<10)+(1023&s);r.push(c>>18|240),r.push(c>>12&63|128),r.push(c>>6&63|128),r.push(63&c|128)}else r.push(a>>12|224),r.push(a>>6&63|128),r.push(63&a|128)}return(0,o.arrayify)(r)}function d(e){var t="0000"+e.toString(16);return"\\u"+t.substring(t.length-4)}function p(e){return e.map((function(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e)))})).join("")}t.Utf8ErrorFuncs=l},6783:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="transactions/5.7.0"},1936:(e,t,r)=>{"use strict";var n=r(3355);Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionTypes=void 0,t.accessListify=_,t.computeAddress=A,t.parse=function(e){var t=(0,a.arrayify)(e);if(t[0]>127)return function(e){var t=l.decode(e);9!==t.length&&6!==t.length&&y.throwArgumentError("invalid raw transaction","rawTransaction",e);var r={nonce:b(t[0]).toNumber(),gasPrice:b(t[1]),gasLimit:b(t[2]),to:g(t[3]),value:b(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=o.BigNumber.from(t[6]).toNumber()}catch(e){return r}if(r.r=(0,a.hexZeroPad)(t[7],32),r.s=(0,a.hexZeroPad)(t[8],32),o.BigNumber.from(r.r).isZero()&&o.BigNumber.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);var n=r.v-27,i=t.slice(0,6);0!==r.chainId&&(i.push((0,a.hexlify)(r.chainId)),i.push("0x"),i.push("0x"),n-=2*r.chainId+8);var s=(0,u.keccak256)(l.encode(i));try{r.from=S(s,{r:(0,a.hexlify)(r.r),s:(0,a.hexlify)(r.s),recoveryParam:n})}catch(e){}r.hash=(0,u.keccak256)(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){var t=l.decode(e.slice(1));8!==t.length&&11!==t.length&&y.throwArgumentError("invalid component count for transaction type: 1","payload",(0,a.hexlify)(e));var r={type:1,chainId:b(t[0]).toNumber(),nonce:b(t[1]).toNumber(),gasPrice:b(t[2]),gasLimit:b(t[3]),to:g(t[4]),value:b(t[5]),data:t[6],accessList:_(t[7])};return 8===t.length||(r.hash=(0,u.keccak256)(e),P(r,t.slice(8),x)),r}(t);case 2:return function(e){var t=l.decode(e.slice(1));9!==t.length&&12!==t.length&&y.throwArgumentError("invalid component count for transaction type: 2","payload",(0,a.hexlify)(e));var r=b(t[2]),n=b(t[3]),i={type:2,chainId:b(t[0]).toNumber(),nonce:b(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:b(t[4]),to:g(t[5]),value:b(t[6]),data:t[7],accessList:_(t[8])};return 9===t.length||(i.hash=(0,u.keccak256)(e),P(i,t.slice(9),T)),i}(t)}return y.throwError("unsupported transaction type: ".concat(t[0]),h.Logger.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})},t.recoverAddress=S,t.serialize=function(e,t){if(null==e.type||0===e.type)return null!=e.accessList&&y.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",e),function(e,t){(0,c.checkProperties)(e,w);var r=[];v.forEach((function(t){var n=e[t.name]||[],i={};t.numeric&&(i.hexPad="left"),n=(0,a.arrayify)((0,a.hexlify)(n,i)),t.length&&n.length!==t.length&&n.length>0&&y.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),t.maxLength&&(n=(0,a.stripZeros)(n)).length>t.maxLength&&y.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),r.push((0,a.hexlify)(n))}));var n=0;if(null!=e.chainId?"number"!=typeof(n=e.chainId)&&y.throwArgumentError("invalid transaction.chainId","transaction",e):t&&!(0,a.isBytesLike)(t)&&t.v>28&&(n=Math.floor((t.v-35)/2)),0!==n&&(r.push((0,a.hexlify)(n)),r.push("0x"),r.push("0x")),!t)return l.encode(r);var i=(0,a.splitSignature)(t),o=27+i.recoveryParam;return 0!==n?(r.pop(),r.pop(),r.pop(),o+=2*n+8,i.v>28&&i.v!==o&&y.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t)):i.v!==o&&y.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t),r.push((0,a.hexlify)(o)),r.push((0,a.stripZeros)((0,a.arrayify)(i.r))),r.push((0,a.stripZeros)((0,a.arrayify)(i.s))),l.encode(r)}(e,t);switch(e.type){case 1:return x(e,t);case 2:return T(e,t)}return y.throwError("unsupported transaction type: ".concat(e.type),h.Logger.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:e.type})};var i=r(7921),o=r(4952),a=r(908),s=r(5465),u=r(4642),c=r(3694),l=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var r=p(void 0);if(r&&r.has(e))return r.get(e);var i={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(i,a,s):i[a]=e[a]}return i.default=e,r&&r.set(e,i),i}(r(5265)),f=r(7612),h=r(4327),d=r(6783);function p(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(p=function(e){return e?r:t})(e)}var m,y=new h.Logger(d.version);function g(e){return"0x"===e?null:(0,i.getAddress)(e)}function b(e){return"0x"===e?s.Zero:o.BigNumber.from(e)}t.TransactionTypes=m,function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(m||(t.TransactionTypes=m={}));var v=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],w={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function A(e){var t=(0,f.computePublicKey)(e);return(0,i.getAddress)((0,a.hexDataSlice)((0,u.keccak256)((0,a.hexDataSlice)(t,1)),12))}function S(e,t){return A((0,f.recoverPublicKey)((0,a.arrayify)(e),t))}function k(e,t){var r=(0,a.stripZeros)(o.BigNumber.from(e).toHexString());return r.length>32&&y.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function E(e,t){return{address:(0,i.getAddress)(e),storageKeys:(t||[]).map((function(t,r){return 32!==(0,a.hexDataLength)(t)&&y.throwArgumentError("invalid access list storageKey","accessList[".concat(e,":").concat(r,"]"),t),t.toLowerCase()}))}}function _(e){if(Array.isArray(e))return e.map((function(e,t){return Array.isArray(e)?(e.length>2&&y.throwArgumentError("access list expected to be [ address, storageKeys[] ]","value[".concat(t,"]"),e),E(e[0],e[1])):E(e.address,e.storageKeys)}));var t=Object.keys(e).map((function(t){var r=e[t].reduce((function(e,t){return e[t]=!0,e}),{});return E(t,Object.keys(r).sort())}));return t.sort((function(e,t){return e.address.localeCompare(t.address)})),t}function M(e){return _(e).map((function(e){return[e.address,e.storageKeys]}))}function T(e,t){if(null!=e.gasPrice){var r=o.BigNumber.from(e.gasPrice),n=o.BigNumber.from(e.maxFeePerGas||0);r.eq(n)||y.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:r,maxFeePerGas:n})}var s=[k(e.chainId||0,"chainId"),k(e.nonce||0,"nonce"),k(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),k(e.maxFeePerGas||0,"maxFeePerGas"),k(e.gasLimit||0,"gasLimit"),null!=e.to?(0,i.getAddress)(e.to):"0x",k(e.value||0,"value"),e.data||"0x",M(e.accessList||[])];if(t){var u=(0,a.splitSignature)(t);s.push(k(u.recoveryParam,"recoveryParam")),s.push((0,a.stripZeros)(u.r)),s.push((0,a.stripZeros)(u.s))}return(0,a.hexConcat)(["0x02",l.encode(s)])}function x(e,t){var r=[k(e.chainId||0,"chainId"),k(e.nonce||0,"nonce"),k(e.gasPrice||0,"gasPrice"),k(e.gasLimit||0,"gasLimit"),null!=e.to?(0,i.getAddress)(e.to):"0x",k(e.value||0,"value"),e.data||"0x",M(e.accessList||[])];if(t){var n=(0,a.splitSignature)(t);r.push(k(n.recoveryParam,"recoveryParam")),r.push((0,a.stripZeros)(n.r)),r.push((0,a.stripZeros)(n.s))}return(0,a.hexConcat)(["0x01",l.encode(r)])}function P(e,t,r){try{var n=b(t[0]).toNumber();if(0!==n&&1!==n)throw new Error("bad recid");e.v=n}catch(e){y.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=(0,a.hexZeroPad)(t[1],32),e.s=(0,a.hexZeroPad)(t[2],32);try{var i=(0,u.keccak256)(r(e));e.from=S(i,{r:e.r,s:e.s,recoveryParam:e.v})}catch(e){}}},3368:(e,t,r)=>{"use strict";var n,i,o=r(8847)(r(3355));void 0===(i="function"==typeof(n=function(){function e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function t(e,t){for(var r=0;r{"use strict";var n=t;n.bignum=r(1734),n.define=r(1568).define,n.base=r(2412),n.constants=r(9387),n.decoders=r(1500),n.encoders=r(7506)},1568:(e,t,r)=>{"use strict";var n=r(7506),i=r(1500),o=r(1736);function a(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}t.define=function(e,t){return new a(e,t)},a.prototype._createNamed=function(e){var t=this.name;function r(e){this._initNamed(e,t)}return o(r,e),r.prototype._initNamed=function(t,r){e.call(this,t,r)},new r(this)},a.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(i[e])),this.decoders[e]},a.prototype.decode=function(e,t,r){return this._getDecoder(t).decode(e,r)},a.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(n[e])),this.encoders[e]},a.prototype.encode=function(e,t,r){return this._getEncoder(t).encode(e,r)}},585:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1736),o=r(2719).b,a=r(1755).Buffer;function s(e,t){o.call(this,t),a.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function u(e,t){if(Array.isArray(e))this.length=0,this.value=e.map((function(e){return u.isEncoderBuffer(e)||(e=new u(e,t)),this.length+=e.length,e}),this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=a.byteLength(e);else{if(!a.isBuffer(e))return t.error("Unsupported type: "+(0,n.default)(e));this.value=e,this.length=e.length}}i(s,o),t.C=s,s.isDecoderBuffer=function(e){return e instanceof s||"object"===(0,n.default)(e)&&a.isBuffer(e.base)&&"DecoderBuffer"===e.constructor.name&&"number"==typeof e.offset&&"number"==typeof e.length&&"function"==typeof e.save&&"function"==typeof e.restore&&"function"==typeof e.isEmpty&&"function"==typeof e.readUInt8&&"function"==typeof e.skip&&"function"==typeof e.raw},s.prototype.save=function(){return{offset:this.offset,reporter:o.prototype.save.call(this)}},s.prototype.restore=function(e){var t=new s(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,o.prototype.restore.call(this,e.reporter),t},s.prototype.isEmpty=function(){return this.offset===this.length},s.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},s.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");var r=new s(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+e,this.offset+=e,r},s.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},t.R=u,u.isEncoderBuffer=function(e){return e instanceof u||"object"===(0,n.default)(e)&&"EncoderBuffer"===e.constructor.name&&"number"==typeof e.length&&"function"==typeof e.join},u.prototype.join=function(e,t){return e||(e=a.alloc(this.length)),t||(t=0),0===this.length||(Array.isArray(this.value)?this.value.forEach((function(r){r.join(e,t),t+=r.length})):("number"==typeof this.value?e[t]=this.value:"string"==typeof this.value?e.write(this.value,t):a.isBuffer(this.value)&&this.value.copy(e,t),t+=this.length)),e}},2412:(e,t,r)=>{"use strict";var n=t;n.Reporter=r(2719).b,n.DecoderBuffer=r(585).C,n.EncoderBuffer=r(585).R,n.Node=r(1371)},1371:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(2719).b,o=r(585).R,a=r(585).C,s=r(4504),u=["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"],c=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(u);function l(e,t,r){var n={};this._baseState=n,n.name=r,n.enc=e,n.parent=t||null,n.children=null,n.tag=null,n.args=null,n.reverseArgs=null,n.choice=null,n.optional=!1,n.any=!1,n.obj=!1,n.use=null,n.useDecoder=null,n.key=null,n.default=null,n.explicit=null,n.implicit=null,n.contains=null,n.parent||(n.children=[],this._wrap())}e.exports=l;var f=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];l.prototype.clone=function(){var e=this._baseState,t={};f.forEach((function(r){t[r]=e[r]}));var r=new this.constructor(t.parent);return r._baseState=t,r},l.prototype._wrap=function(){var e=this._baseState;c.forEach((function(t){this[t]=function(){var r=new this.constructor(this);return e.children.push(r),r[t].apply(r,arguments)}}),this)},l.prototype._init=function(e){var t=this._baseState;s(null===t.parent),e.call(this),t.children=t.children.filter((function(e){return e._baseState.parent===this}),this),s.equal(t.children.length,1,"Root node can have only one child")},l.prototype._useArgs=function(e){var t=this._baseState,r=e.filter((function(e){return e instanceof this.constructor}),this);e=e.filter((function(e){return!(e instanceof this.constructor)}),this),0!==r.length&&(s(null===t.children),t.children=r,r.forEach((function(e){e._baseState.parent=this}),this)),0!==e.length&&(s(null===t.args),t.args=e,t.reverseArgs=e.map((function(e){if("object"!==(0,n.default)(e)||e.constructor!==Object)return e;var t={};return Object.keys(e).forEach((function(r){r==(0|r)&&(r|=0);var n=e[r];t[n]=r})),t})))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach((function(e){l.prototype[e]=function(){var t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}})),u.forEach((function(e){l.prototype[e]=function(){var t=this._baseState,r=Array.prototype.slice.call(arguments);return s(null===t.tag),t.tag=e,this._useArgs(r),this}})),l.prototype.use=function(e){s(e);var t=this._baseState;return s(null===t.use),t.use=e,this},l.prototype.optional=function(){return this._baseState.optional=!0,this},l.prototype.def=function(e){var t=this._baseState;return s(null===t.default),t.default=e,t.optional=!0,this},l.prototype.explicit=function(e){var t=this._baseState;return s(null===t.explicit&&null===t.implicit),t.explicit=e,this},l.prototype.implicit=function(e){var t=this._baseState;return s(null===t.explicit&&null===t.implicit),t.implicit=e,this},l.prototype.obj=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},l.prototype.key=function(e){var t=this._baseState;return s(null===t.key),t.key=e,this},l.prototype.any=function(){return this._baseState.any=!0,this},l.prototype.choice=function(e){var t=this._baseState;return s(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map((function(t){return e[t]}))),this},l.prototype.contains=function(e){var t=this._baseState;return s(null===t.use),t.contains=e,this},l.prototype._decode=function(e,t){var r=this._baseState;if(null===r.parent)return e.wrapResult(r.children[0]._decode(e,t));var n,i=r.default,o=!0,s=null;if(null!==r.key&&(s=e.enterKey(r.key)),r.optional){var u=null;if(null!==r.explicit?u=r.explicit:null!==r.implicit?u=r.implicit:null!==r.tag&&(u=r.tag),null!==u||r.any){if(o=this._peekTag(e,u,r.any),e.isError(o))return o}else{var c=e.save();try{null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),o=!0}catch(e){o=!1}e.restore(c)}}if(r.obj&&o&&(n=e.enterObject()),o){if(null!==r.explicit){var l=this._decodeTag(e,r.explicit);if(e.isError(l))return l;e=l}var f=e.offset;if(null===r.use&&null===r.choice){var h;r.any&&(h=e.save());var d=this._decodeTag(e,null!==r.implicit?r.implicit:r.tag,r.any);if(e.isError(d))return d;r.any?i=e.raw(h):e=d}if(t&&t.track&&null!==r.tag&&t.track(e.path(),f,e.length,"tagged"),t&&t.track&&null!==r.tag&&t.track(e.path(),e.offset,e.length,"content"),r.any||(i=null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t)),e.isError(i))return i;if(r.any||null!==r.choice||null===r.children||r.children.forEach((function(r){r._decode(e,t)})),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){var p=new a(i);i=this._getUse(r.contains,e._reporterState.obj)._decode(p,t)}}return r.obj&&o&&(i=e.leaveObject(n)),null===r.key||null===i&&!0!==o?null!==s&&e.exitKey(s):e.leaveKey(s,r.key,i),i},l.prototype._decodeGeneric=function(e,t,r){var n=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,n.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&n.args?this._decodeObjid(t,n.args[0],n.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,n.args&&n.args[0],r):null!==n.use?this._getUse(n.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},l.prototype._getUse=function(e,t){var r=this._baseState;return r.useDecoder=this._use(e,t),s(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},l.prototype._decodeChoice=function(e,t){var r=this._baseState,n=null,i=!1;return Object.keys(r.choice).some((function(o){var a=e.save(),s=r.choice[o];try{var u=s._decode(e,t);if(e.isError(u))return!1;n={type:o,value:u},i=!0}catch(t){return e.restore(a),!1}return!0}),this),i?n:e.error("Choice not matched")},l.prototype._createEncoderBuffer=function(e){return new o(e,this.reporter)},l.prototype._encode=function(e,t,r){var n=this._baseState;if(null===n.default||n.default!==e){var i=this._encodeValue(e,t,r);if(void 0!==i&&!this._skipDefault(i,t,r))return i}},l.prototype._encodeValue=function(e,t,r){var o=this._baseState;if(null===o.parent)return o.children[0]._encode(e,t||new i);var a=null;if(this.reporter=t,o.optional&&void 0===e){if(null===o.default)return;e=o.default}var s=null,u=!1;if(o.any)a=this._createEncoderBuffer(e);else if(o.choice)a=this._encodeChoice(e,t);else if(o.contains)s=this._getUse(o.contains,r)._encode(e,t),u=!0;else if(o.children)s=o.children.map((function(r){if("null_"===r._baseState.tag)return r._encode(null,t,e);if(null===r._baseState.key)return t.error("Child should have a key");var i=t.enterKey(r._baseState.key);if("object"!==(0,n.default)(e))return t.error("Child expected, but input is not object");var o=r._encode(e[r._baseState.key],t,e);return t.leaveKey(i),o}),this).filter((function(e){return e})),s=this._createEncoderBuffer(s);else if("seqof"===o.tag||"setof"===o.tag){if(!o.args||1!==o.args.length)return t.error("Too many args for : "+o.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");var c=this.clone();c._baseState.implicit=null,s=this._createEncoderBuffer(e.map((function(r){var n=this._baseState;return this._getUse(n.args[0],e)._encode(r,t)}),c))}else null!==o.use?a=this._getUse(o.use,r)._encode(e,t):(s=this._encodePrimitive(o.tag,e),u=!0);if(!o.any&&null===o.choice){var l=null!==o.implicit?o.implicit:o.tag,f=null===o.implicit?"universal":"context";null===l?null===o.use&&t.error("Tag could be omitted only for .use()"):null===o.use&&(a=this._encodeComposite(l,u,f,s))}return null!==o.explicit&&(a=this._encodeComposite(o.explicit,!1,"context",a)),a},l.prototype._encodeChoice=function(e,t){var r=this._baseState,n=r.choice[e.type];return n||s(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),n._encode(e.value,t)},l.prototype._encodePrimitive=function(e,t){var r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},l.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},l.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(e)}},2719:(e,t,r)=>{"use strict";var n=r(1736);function i(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function o(e,t){this.path=e,this.rethrow(t)}t.b=i,i.prototype.isError=function(e){return e instanceof o},i.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},i.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},i.prototype.enterKey=function(e){return this._reporterState.path.push(e)},i.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},i.prototype.leaveKey=function(e,t,r){var n=this._reporterState;this.exitKey(e),null!==n.obj&&(n.obj[t]=r)},i.prototype.path=function(){return this._reporterState.path.join("/")},i.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},i.prototype.leaveObject=function(e){var t=this._reporterState,r=t.obj;return t.obj=e,r},i.prototype.error=function(e){var t,r=this._reporterState,n=e instanceof o;if(t=n?e:new o(r.path.map((function(e){return"["+JSON.stringify(e)+"]"})).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},i.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},n(o,Error),o.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,o),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},6520:(e,t)=>{"use strict";function r(e){var t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);var n=e[r];t[n]=r})),t}t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=r(t.tagClass),t.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"},t.tagByName=r(t.tag)},9387:(e,t,r)=>{"use strict";var n=t;n._reverse=function(e){var t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);var n=e[r];t[n]=r})),t},n.der=r(6520)},2387:(e,t,r)=>{"use strict";var n=r(1736),i=r(1734),o=r(585).C,a=r(1371),s=r(6520);function u(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new c,this.tree._init(e.body)}function c(e){a.call(this,"der",e)}function l(e,t){var r=e.readUInt8(t);if(e.isError(r))return r;var n=s.tagClass[r>>6],i=0==(32&r);if(31==(31&r)){var o=r;for(r=0;128==(128&o);){if(o=e.readUInt8(t),e.isError(o))return o;r<<=7,r|=127&o}}else r&=31;return{cls:n,primitive:i,tag:r,tagStr:s.tag[r]}}function f(e,t,r){var n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&128===n)return null;if(0==(128&n))return n;var i=127&n;if(i>4)return e.error("length octect is too long");n=0;for(var o=0;o{"use strict";var n=t;n.der=r(2387),n.pem=r(529)},529:(e,t,r)=>{"use strict";var n=r(1736),i=r(1755).Buffer,o=r(2387);function a(e){o.call(this,e),this.enc="pem"}n(a,o),e.exports=a,a.prototype.decode=function(e,t){for(var r=e.toString().split(/[\r\n]+/g),n=t.label.toUpperCase(),a=/^-----(BEGIN|END) ([^-]+)-----$/,s=-1,u=-1,c=0;c{"use strict";var n=r(1736),i=r(1755).Buffer,o=r(1371),a=r(6520);function s(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){o.call(this,"der",e)}function c(e){return e<10?"0"+e:e}e.exports=s,s.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},n(u,o),u.prototype._encodeComposite=function(e,t,r,n){var o=function(e,t,r,n){var i;if("seqof"===e?e="seq":"setof"===e&&(e="set"),a.tagByName.hasOwnProperty(e))i=a.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return n.error("Unknown tag: "+e);i=e}return i>=31?n.error("Multi-octet tag encoding unsupported"):(t||(i|=32),i|=a.tagClassByName[r||"universal"]<<6)}(e,t,r,this.reporter);if(n.length<128){var s=i.alloc(2);return s[0]=o,s[1]=n.length,this._createEncoderBuffer([s,n])}for(var u=1,c=n.length;c>=256;c>>=8)u++;var l=i.alloc(2+u);l[0]=o,l[1]=128|u;for(var f=1+u,h=n.length;h>0;f--,h>>=8)l[f]=255&h;return this._createEncoderBuffer([l,n])},u.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){for(var r=i.alloc(2*e.length),n=0;n=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}for(var a=0,s=0;s=128;u>>=7)a++}for(var c=i.alloc(a),l=c.length-1,f=e.length-1;f>=0;f--){var h=e[f];for(c[l--]=127&h;(h>>=7)>0;)c[l--]=128|127&h}return this._createEncoderBuffer(c)},u.prototype._encodeTime=function(e,t){var r,n=new Date(e);return"gentime"===t?r=[c(n.getUTCFullYear()),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[c(n.getUTCFullYear()%100),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},u.prototype._encodeNull=function(){return this._createEncoderBuffer("")},u.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!i.isBuffer(e)){var r=e.toArray();!e.sign&&128&r[0]&&r.unshift(0),e=i.from(r)}if(i.isBuffer(e)){var n=e.length;0===e.length&&n++;var o=i.alloc(n);return e.copy(o),0===e.length&&(o[0]=0),this._createEncoderBuffer(o)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);for(var a=1,s=e;s>=256;s>>=8)a++;for(var u=new Array(a),c=u.length-1;c>=0;c--)u[c]=255&e,e>>=8;return 128&u[0]&&u.unshift(0),this._createEncoderBuffer(i.from(u))},u.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},u.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},u.prototype._skipDefault=function(e,t,r){var n,i=this._baseState;if(null===i.default)return!1;var o=e.join();if(void 0===i.defaultBuffer&&(i.defaultBuffer=this._encodeValue(i.default,t,r).join()),o.length!==i.defaultBuffer.length)return!1;for(n=0;n{"use strict";var n=t;n.der=r(1068),n.pem=r(8520)},8520:(e,t,r)=>{"use strict";var n=r(1736),i=r(1068);function o(e){i.call(this,e),this.enc="pem"}n(o,i),e.exports=o,o.prototype.encode=function(e,t){for(var r=i.prototype.encode.call(this,e).toString("base64"),n=["-----BEGIN "+t.label+"-----"],o=0;o{"use strict";var n=r(8847)(r(3355)),i=r(3103);function o(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i=0;u--)if(l[u]!==f[u])return!1;for(u=l.length-1;u>=0;u--)if(!w(e[a=l[u]],t[a],r,n))return!1;return!0}(e,t,r,i))}return r?e===t:e==t}function A(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function S(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function k(e,t,r,n){var i;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof r&&(n=r,r=null),i=function(e){var t;try{e()}catch(e){t=e}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!i&&b(i,r,"Missing expected exception"+n);var o="string"==typeof n,a=!e&&i&&!r;if((!e&&s.isError(i)&&o&&S(i,r)||a)&&b(i,r,"Got unwanted exception"+n),e&&i&&r&&!S(i,r)||!e&&i)throw i}d.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return y(g(e.actual),128)+" "+e.operator+" "+y(g(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||b;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,i=m(t),o=n.indexOf("\n"+i);if(o>=0){var a=n.indexOf("\n",o+1);n=n.substring(a+1)}this.stack=n}}},s.inherits(d.AssertionError,Error),d.fail=b,d.ok=v,d.equal=function(e,t,r){e!=t&&b(e,t,r,"==",d.equal)},d.notEqual=function(e,t,r){e==t&&b(e,t,r,"!=",d.notEqual)},d.deepEqual=function(e,t,r){w(e,t,!1)||b(e,t,r,"deepEqual",d.deepEqual)},d.deepStrictEqual=function(e,t,r){w(e,t,!0)||b(e,t,r,"deepStrictEqual",d.deepStrictEqual)},d.notDeepEqual=function(e,t,r){w(e,t,!1)&&b(e,t,r,"notDeepEqual",d.notDeepEqual)},d.notDeepStrictEqual=function e(t,r,n){w(t,r,!0)&&b(t,r,n,"notDeepStrictEqual",e)},d.strictEqual=function(e,t,r){e!==t&&b(e,t,r,"===",d.strictEqual)},d.notStrictEqual=function(e,t,r){e===t&&b(e,t,r,"!==",d.notStrictEqual)},d.throws=function(e,t,r){k(!0,e,t,r)},d.doesNotThrow=function(e,t,r){k(!1,e,t,r)},d.ifError=function(e){if(e)throw e},d.strict=i((function e(t,r){t||b(t,!0,r,"==",e)}),d,{equal:d.strictEqual,deepEqual:d.deepStrictEqual,notEqual:d.notStrictEqual,notDeepEqual:d.notDeepStrictEqual}),d.strict.strict=d.strict;var E=Object.keys||function(e){var t=[];for(var r in e)u.call(e,r)&&t.push(r);return t}},4074:e=>{"use strict";"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},6732:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(e){return e&&"object"===(0,n.default)(e)&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},9954:(e,t,r)=>{"use strict";var n=r(9142),i=r(8847)(r(3355)),o=/%[sdj%]/g;t.format=function(e){if(!b(e)){for(var t=[],r=0;r=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}})),s=n[r];r=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),m(r)?n.showHidden=r:r&&t._extend(n,r),v(n.showHidden)&&(n.showHidden=!1),v(n.depth)&&(n.depth=2),v(n.colors)&&(n.colors=!1),v(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=c),f(n,e,n.depth)}function c(e,t){var r=u.styles[t];return r?"["+u.colors[r][0]+"m"+e+"["+u.colors[r][1]+"m":e}function l(e,t){return e}function f(e,r,n){if(e.customInspect&&r&&E(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var i=r.inspect(n,e);return b(i)||(i=f(e,i,n)),i}var o=function(e,t){if(v(t))return e.stylize("undefined","undefined");if(b(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return g(t)?e.stylize(""+t,"number"):m(t)?e.stylize(""+t,"boolean"):y(t)?e.stylize("null","null"):void 0}(e,r);if(o)return o;var a=Object.keys(r),s=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),k(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return h(r);if(0===a.length){if(E(r)){var u=r.name?": "+r.name:"";return e.stylize("[Function"+u+"]","special")}if(w(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(S(r))return e.stylize(Date.prototype.toString.call(r),"date");if(k(r))return h(r)}var c,l="",A=!1,_=["{","}"];return p(r)&&(A=!0,_=["[","]"]),E(r)&&(l=" [Function"+(r.name?": "+r.name:"")+"]"),w(r)&&(l=" "+RegExp.prototype.toString.call(r)),S(r)&&(l=" "+Date.prototype.toUTCString.call(r)),k(r)&&(l=" "+h(r)),0!==a.length||A&&0!=r.length?n<0?w(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),c=A?function(e,t,r,n,i){for(var o=[],a=0,s=t.length;a60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}(c,l,_)):_[0]+l+_[1]}function h(e){return"["+Error.prototype.toString.call(e)+"]"}function d(e,t,r,n,i,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?s=u.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):u.set&&(s=e.stylize("[Setter]","special")),P(n,i)||(a="["+i+"]"),s||(e.seen.indexOf(u.value)<0?(s=y(r)?f(e,u.value,null):f(e,u.value,r-1)).indexOf("\n")>-1&&(s=o?s.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),v(a)){if(o&&i.match(/^\d+$/))return s;(a=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function p(e){return Array.isArray(e)}function m(e){return"boolean"==typeof e}function y(e){return null===e}function g(e){return"number"==typeof e}function b(e){return"string"==typeof e}function v(e){return void 0===e}function w(e){return A(e)&&"[object RegExp]"===_(e)}function A(e){return"object"===(0,i.default)(e)&&null!==e}function S(e){return A(e)&&"[object Date]"===_(e)}function k(e){return A(e)&&("[object Error]"===_(e)||e instanceof Error)}function E(e){return"function"==typeof e}function _(e){return Object.prototype.toString.call(e)}function M(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(v(a)&&(a=n.env.NODE_DEBUG||""),e=e.toUpperCase(),!s[e])if(new RegExp("\\b"+e+"\\b","i").test(a)){var r=n.pid;s[e]=function(){var n=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,n)}}else s[e]=function(){};return s[e]},t.inspect=u,u.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=p,t.isBoolean=m,t.isNull=y,t.isNullOrUndefined=function(e){return null==e},t.isNumber=g,t.isString=b,t.isSymbol=function(e){return"symbol"===(0,i.default)(e)},t.isUndefined=v,t.isRegExp=w,t.isObject=A,t.isDate=S,t.isError=k,t.isFunction=E,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"===(0,i.default)(e)||void 0===e},t.isBuffer=r(6732);var T=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function x(){var e=new Date,t=[M(e.getHours()),M(e.getMinutes()),M(e.getSeconds())].join(":");return[e.getDate(),T[e.getMonth()],t].join(" ")}function P(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",x(),t.format.apply(t,arguments))},t.inherits=r(4074),t._extend=function(e,t){if(!t||!A(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}},7548:(e,t,r)=>{"use strict";var n=r(8850).Buffer;e.exports=function(e){if(e.length>=255)throw new TypeError("Alphabet too long");for(var t=new Uint8Array(256),r=0;r>>0,l=new Uint8Array(a);e[r];){var f=t[e.charCodeAt(r)];if(255===f)return;for(var h=0,d=a-1;(0!==f||h>>0,l[d]=f%256>>>0,f=f/256>>>0;if(0!==f)throw new Error("Non-zero carry");o=h,r++}for(var p=a-o;p!==a&&0===l[p];)p++;var m=n.allocUnsafe(i+(a-p));m.fill(0,0,i);for(var y=i;p!==a;)m[y++]=l[p++];return m}return{encode:function(t){if((Array.isArray(t)||t instanceof Uint8Array)&&(t=n.from(t)),!n.isBuffer(t))throw new TypeError("Expected Buffer");if(0===t.length)return"";for(var r=0,i=0,o=0,a=t.length;o!==a&&0===t[o];)o++,r++;for(var c=(a-o)*l+1>>>0,f=new Uint8Array(c);o!==a;){for(var h=t[o],d=0,p=c-1;(0!==h||d>>0,f[p]=h%s>>>0,h=h/s>>>0;if(0!==h)throw new Error("Non-zero carry");i=d,o++}for(var m=c-i;m!==c&&0===f[m];)m++;for(var y=u.repeat(r);m{"use strict";t.byteLength=function(e){var t=u(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,o=u(e),a=o[0],s=o[1],c=new i(function(e,t,r){return 3*(t+r)/4-r}(0,a,s)),l=0,f=s>0?a-4:a;for(r=0;r>16&255,c[l++]=t>>8&255,c[l++]=255&t;return 2===s&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,c[l++]=255&t),1===s&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t),c},t.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],a=16383,s=0,u=n-i;su?u:s+a));return 1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),o.join("")};for(var r=[],n=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=o.length;a0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function c(e,t,n){for(var i,o,a=[],s=t;s>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},1734:(e,t,r)=>{"use strict";e=r.nmd(e);var n=r(8847)(r(3355));!function(e,t){function i(e,t){if(!e)throw new Error(t||"Assertion failed")}function o(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function a(e,t,r){if(a.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var s;"object"===(0,n.default)(e)?e.exports=a:(void 0).BN=a,a.BN=a,a.wordSize=26;try{s="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(9033).Buffer}catch(e){}function u(e,t){var r=e.charCodeAt(t);return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void i(!1,"Invalid character in "+e)}function c(e,t,r){var n=u(e,r);return r-1>=t&&(n|=u(e,r-1)<<4),n}function l(e,t,r,n){for(var o=0,a=0,s=Math.min(e.length,r),u=t;u=49?c-49+10:c>=17?c-17+10:c,i(c>=0&&a0?e:t},a.min=function(e,t){return e.cmp(t)<0?e:t},a.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"===(0,n.default)(e))return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var o=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(o++,this.negative=1),o=0;n-=3)a=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this._strip()},a.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=c(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this._strip()},a.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},a.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=h}catch(e){a.prototype.inspect=h}else a.prototype.inspect=h;function h(){return(this.red?""}var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],p=[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],m=[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 y(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r._strip()}a.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,a=0;a>>24-n&16777215,(n+=2)>=26&&(n-=26,a--),r=0!==o||a!==this.length-1?d[6-u.length]+u+r:u+r}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=p[e],l=m[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var h=f.modrn(l).toString(e);r=(f=f.idivn(l)).isZero()?h+r:d[c-h.length]+h+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},a.prototype.toJSON=function(){return this.toString(16,2)},s&&(a.prototype.toBuffer=function(e,t){return this.toArrayLike(s,e,t)}),a.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},a.prototype.toArrayLike=function(e,t,r){this._strip();var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0");var a=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,o);return this["_toArrayLike"+("le"===t?"LE":"BE")](a,n),a},a.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,i=0,o=0;i>8&255),r>16&255),6===o?(r>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r=0&&(e[r--]=a>>8&255),r>=0&&(e[r--]=a>>16&255),6===o?(r>=0&&(e[r--]=a>>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?a.prototype._countBits=function(e){return 32-Math.clz32(e)}:a.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},a.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},a.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},a.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},a.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},a.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},a.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},a.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},a.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this._strip()},a.prototype.notn=function(e){return this.clone().inotn(e)},a.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},a.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function b(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r._strip()}function v(e,t,r){return b(e,t,r)}function w(e,t){this.x=e,this.y=t}Math.imul||(g=y),a.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?g(this,e,t):r<63?y(this,e,t):r<1024?b(this,e,t):v(this,e,t)},w.prototype.makeRBT=function(e){for(var t=new Array(e),r=a.prototype._countBits(e)-1,n=0;n>=1;return n},w.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,r+=o/67108864|0,r+=a>>>26,this.words[n]=67108863&a}return 0!==r&&(this.words[n]=r,this.length++),t?this.ineg():this},a.prototype.muln=function(e){return this.clone().imuln(e)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i&1}return t}(e);if(0===t.length)return new a(1);for(var r=this,n=0;n=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=n);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},a.prototype.shln=function(e){return this.clone().ishln(e)},a.prototype.ushln=function(e){return this.clone().iushln(e)},a.prototype.shrn=function(e){return this.clone().ishrn(e)},a.prototype.ushrn=function(e){return this.clone().iushrn(e)},a.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},a.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this._strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this._strip()},a.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,o=0|i.words[i.length-1];0!=(r=26-this._countBits(o))&&(i=i.ushln(r),n.iushln(r),o=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new a(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/o|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},a.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new a(0),mod:new a(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(n=s.div.neg()),"div"!==t&&(o=s.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:n,mod:o}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(n=s.div.neg()),{div:n,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(o=s.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:s.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new a(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new a(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new a(this.modrn(e.words[0]))}:this._wordDiv(e,t);var n,o,s},a.prototype.div=function(e){return this.divmod(e,"div",!1).div},a.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},a.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},a.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},a.prototype.modrn=function(e){var t=e<0;t&&(e=-e),i(e<=67108863);for(var r=(1<<26)%e,n=0,o=this.length-1;o>=0;o--)n=(r*n+(0|this.words[o]))%e;return t?-n:n},a.prototype.modn=function(e){return this.modrn(e)},a.prototype.idivn=function(e){var t=e<0;t&&(e=-e),i(e<=67108863);for(var r=0,n=this.length-1;n>=0;n--){var o=(0|this.words[n])+67108864*r;this.words[n]=o/e|0,r=o%e}return this._strip(),t?this.ineg():this},a.prototype.divn=function(e){return this.clone().idivn(e)},a.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new a(1),o=new a(0),s=new a(0),u=new a(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(n.isOdd()||o.isOdd())&&(n.iadd(l),o.isub(f)),n.iushrn(1),o.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(s),o.isub(u)):(r.isub(t),s.isub(n),u.isub(o))}return{a:s,b:u,gcd:r.iushln(c)}},a.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,o=new a(1),s=new a(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)o.isOdd()&&o.iadd(u),o.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(s)):(r.isub(t),s.isub(o))}return(n=0===t.cmpn(1)?o:s).cmpn(0)<0&&n.iadd(e),n},a.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},a.prototype.invm=function(e){return this.egcd(e).a.umod(e)},a.prototype.isEven=function(){return 0==(1&this.words[0])},a.prototype.isOdd=function(){return 1==(1&this.words[0])},a.prototype.andln=function(e){return this.words[0]&e},a.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},a.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},a.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},a.prototype.gtn=function(e){return 1===this.cmpn(e)},a.prototype.gt=function(e){return 1===this.cmp(e)},a.prototype.gten=function(e){return this.cmpn(e)>=0},a.prototype.gte=function(e){return this.cmp(e)>=0},a.prototype.ltn=function(e){return-1===this.cmpn(e)},a.prototype.lt=function(e){return-1===this.cmp(e)},a.prototype.lten=function(e){return this.cmpn(e)<=0},a.prototype.lte=function(e){return this.cmp(e)<=0},a.prototype.eqn=function(e){return 0===this.cmpn(e)},a.prototype.eq=function(e){return 0===this.cmp(e)},a.red=function(e){return new T(e)},a.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},a.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(e){return this.red=e,this},a.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},a.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},a.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},a.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},a.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},a.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},a.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},a.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},a.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var A={k256:null,p224:null,p192:null,p25519:null};function S(e,t){this.name=e,this.p=new a(t,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function k(){S.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function E(){S.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){S.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function M(){S.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function T(e){if("string"==typeof e){var t=a._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function x(e){T.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S.prototype._tmp=function(){var e=new a(null);return e.words=new Array(Math.ceil(this.n/13)),e},S.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},S.prototype.split=function(e,t){e.iushrn(this.n,0,t)},S.prototype.imulK=function(e){return e.imul(this.k)},o(k,S),k.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},k.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},a._prime=function(e){if(A[e])return A[e];var t;if("k256"===e)t=new k;else if("p224"===e)t=new E;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new M}return A[e]=t,t},T.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},T.prototype._verify2=function(e,t){i(0==(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},T.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(f(e,e.umod(this.m)._forceRed(this)),e)},T.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},T.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},T.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},T.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},T.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},T.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},T.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},T.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},T.prototype.isqr=function(e){return this.imul(e,e.clone())},T.prototype.sqr=function(e){return this.mul(e,e)},T.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new a(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),o=0;!n.isZero()&&0===n.andln(1);)o++,n.iushrn(1);i(!n.isZero());var s=new a(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,n),h=this.pow(e,n.addn(1).iushrn(1)),d=this.pow(e,n),p=o;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();i(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==o?(o<<=1,o|=f,(4==++s||0===n&&0===l)&&(i=this.mul(i,r[o]),s=0,o=0)):s=0}u=26}return i},T.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},T.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},a.mont=function(e){return new x(e)},o(x,T),x.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},x.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},x.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},x.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new a(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},x.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e)},2202:(e,t,r)=>{"use strict";var n,i=r(8847)(r(3355));function o(e){this.rand=e}if(e.exports=function(e){return n||(n=new o(null)),n.generate(e)},e.exports.Rand=o,o.prototype.generate=function(e){return this._rand(e)},o.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r{"use strict";var n=r(8850).Buffer;function i(e){n.isBuffer(e)||(e=n.from(e));for(var t=e.length/4|0,r=new Array(t),i=0;i>>24]^l[p>>>16&255]^f[m>>>8&255]^h[255&y]^t[g++],a=c[p>>>24]^l[m>>>16&255]^f[y>>>8&255]^h[255&d]^t[g++],s=c[m>>>24]^l[y>>>16&255]^f[d>>>8&255]^h[255&p]^t[g++],u=c[y>>>24]^l[d>>>16&255]^f[p>>>8&255]^h[255&m]^t[g++],d=o,p=a,m=s,y=u;return o=(n[d>>>24]<<24|n[p>>>16&255]<<16|n[m>>>8&255]<<8|n[255&y])^t[g++],a=(n[p>>>24]<<24|n[m>>>16&255]<<16|n[y>>>8&255]<<8|n[255&d])^t[g++],s=(n[m>>>24]<<24|n[y>>>16&255]<<16|n[d>>>8&255]<<8|n[255&p])^t[g++],u=(n[y>>>24]<<24|n[d>>>16&255]<<16|n[p>>>8&255]<<8|n[255&m])^t[g++],[o>>>=0,a>>>=0,s>>>=0,u>>>=0]}var s=[0,1,2,4,8,16,32,64,128,27,54],u=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],o=[[],[],[],[]],a=0,s=0,u=0;u<256;++u){var c=s^s<<1^s<<2^s<<3^s<<4;c=c>>>8^255&c^99,r[a]=c,n[c]=a;var l=e[a],f=e[l],h=e[f],d=257*e[c]^16843008*c;i[0][a]=d<<24|d>>>8,i[1][a]=d<<16|d>>>16,i[2][a]=d<<8|d>>>24,i[3][a]=d,d=16843009*h^65537*f^257*l^16843008*a,o[0][c]=d<<24|d>>>8,o[1][c]=d<<16|d>>>16,o[2][c]=d<<8|d>>>24,o[3][c]=d,0===a?a=s=1:(a=l^e[e[e[h^l]]],s^=e[e[s]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:o}}();function c(e){this._key=i(e),this._reset()}c.blockSize=16,c.keySize=32,c.prototype.blockSize=c.blockSize,c.prototype.keySize=c.keySize,c.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=4*(r+1),i=[],o=0;o>>24,a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a],a^=s[o/t|0]<<24):t>6&&o%t==4&&(a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a]),i[o]=i[o-t]^a}for(var c=[],l=0;l>>24]]^u.INV_SUB_MIX[1][u.SBOX[h>>>16&255]]^u.INV_SUB_MIX[2][u.SBOX[h>>>8&255]]^u.INV_SUB_MIX[3][u.SBOX[255&h]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=c},c.prototype.encryptBlockRaw=function(e){return a(e=i(e),this._keySchedule,u.SUB_MIX,u.SBOX,this._nRounds)},c.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=n.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},c.prototype.decryptBlock=function(e){var t=(e=i(e))[1];e[1]=e[3],e[3]=t;var r=a(e,this._invKeySchedule,u.INV_SUB_MIX,u.INV_SBOX,this._nRounds),o=n.allocUnsafe(16);return o.writeUInt32BE(r[0],0),o.writeUInt32BE(r[3],4),o.writeUInt32BE(r[2],8),o.writeUInt32BE(r[1],12),o},c.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},e.exports.AES=c},426:(e,t,r)=>{"use strict";var n=r(7494),i=r(8850).Buffer,o=r(3013),a=r(1736),s=r(6626),u=r(6316),c=r(7557);function l(e,t,r,a){o.call(this);var u=i.alloc(4,0);this._cipher=new n.AES(t);var l=this._cipher.encryptBlock(u);this._ghash=new s(l),r=function(e,t,r){if(12===t.length)return e._finID=i.concat([t,i.from([0,0,0,1])]),i.concat([t,i.from([0,0,0,2])]);var n=new s(r),o=t.length,a=o%16;n.update(t),a&&(a=16-a,n.update(i.alloc(a,0))),n.update(i.alloc(8,0));var u=8*o,l=i.alloc(8);l.writeUIntBE(u,0,8),n.update(l),e._finID=n.state;var f=i.from(e._finID);return c(f),f}(this,r,l),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}a(l,o),l.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=i.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},l.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=u(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i{"use strict";var n=r(5478),i=r(2184),o=r(4946);t.createCipher=t.Cipher=n.createCipher,t.createCipheriv=t.Cipheriv=n.createCipheriv,t.createDecipher=t.Decipher=i.createDecipher,t.createDecipheriv=t.Decipheriv=i.createDecipheriv,t.listCiphers=t.getCiphers=function(){return Object.keys(o)}},2184:(e,t,r)=>{"use strict";var n=r(426),i=r(8850).Buffer,o=r(8408),a=r(1408),s=r(3013),u=r(7494),c=r(7085);function l(e,t,r){s.call(this),this._cache=new f,this._last=void 0,this._cipher=new u.AES(t),this._prev=i.from(r),this._mode=e,this._autopadding=!0}function f(){this.cache=i.allocUnsafe(0)}function h(e,t,r){var s=o[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=i.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=i.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===s.type?new a(s.module,t,r,!0):"auth"===s.type?new n(s.module,t,r,!0):new l(s.module,t,r)}r(1736)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return i.concat(n)},l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");for(var r=-1;++r16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},f.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=function(e,t){var r=o[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=c(t,!1,r.key,r.iv);return h(e,n.key,n.iv)},t.createDecipheriv=h},5478:(e,t,r)=>{"use strict";var n=r(8408),i=r(426),o=r(8850).Buffer,a=r(1408),s=r(3013),u=r(7494),c=r(7085);function l(e,t,r){s.call(this),this._cache=new h,this._cipher=new u.AES(t),this._prev=o.from(r),this._mode=e,this._autopadding=!0}r(1736)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return o.concat(n)};var f=o.alloc(16,16);function h(){this.cache=o.allocUnsafe(0)}function d(e,t,r){var s=n[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=o.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof r&&(r=o.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);return"stream"===s.type?new a(s.module,t,r):"auth"===s.type?new i(s.module,t,r):new l(s.module,t,r)}l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(f))throw this._cipher.scrub(),new Error("data not multiple of block length")},l.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},h.prototype.add=function(e){this.cache=o.concat([this.cache,e])},h.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},h.prototype.flush=function(){for(var e=16-this.cache.length,t=o.allocUnsafe(e),r=-1;++r{"use strict";var n=r(8850).Buffer,i=n.alloc(16,0);function o(e){var t=n.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function a(e){this.h=e,this.state=n.alloc(16,0),this.cache=n.allocUnsafe(0)}a.prototype.ghash=function(e){for(var t=-1;++t0;t--)n[t]=n[t]>>>1|(1&n[t-1])<<31;n[0]=n[0]>>>1,r&&(n[0]=n[0]^225<<24)}this.state=o(i)},a.prototype.update=function(e){var t;for(this.cache=n.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},a.prototype.final=function(e,t){return this.cache.length&&this.ghash(n.concat([this.cache,i],16)),this.ghash(o([0,e,0,t])),this.state},e.exports=a},7557:e=>{"use strict";e.exports=function(e){for(var t,r=e.length;r--;){if(255!==(t=e.readUInt8(r))){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}},7427:(e,t,r)=>{"use strict";var n=r(6316);t.encrypt=function(e,t){var r=n(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},t.decrypt=function(e,t){var r=e._prev;e._prev=t;var i=e._cipher.decryptBlock(t);return n(i,r)}},4030:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(6316);function o(e,t,r){var o=t.length,a=i(t,e._cache);return e._cache=e._cache.slice(o),e._prev=n.concat([e._prev,r?t:a]),a}t.encrypt=function(e,t,r){for(var i,a=n.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=n.allocUnsafe(0)),!(e._cache.length<=t.length)){a=n.concat([a,o(e,t,r)]);break}i=e._cache.length,a=n.concat([a,o(e,t.slice(0,i),r)]),t=t.slice(i)}return a}},3206:(e,t,r)=>{"use strict";var n=r(8850).Buffer;function i(e,t,r){for(var n,i,a=-1,s=0;++a<8;)n=t&1<<7-a?128:0,s+=(128&(i=e._cipher.encryptBlock(e._prev)[0]^n))>>a%8,e._prev=o(e._prev,r?n:i);return s}function o(e,t){var r=e.length,i=-1,o=n.allocUnsafe(e.length);for(e=n.concat([e,n.from([t])]);++i>7;return o}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{"use strict";var n=r(8850).Buffer;function i(e,t,r){var i=e._cipher.encryptBlock(e._prev)[0]^t;return e._prev=n.concat([e._prev.slice(1),n.from([r?t:i])]),i}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{"use strict";var n=r(6316),i=r(8850).Buffer,o=r(7557);function a(e){var t=e._cipher.encryptBlockRaw(e._prev);return o(e._prev),t}t.encrypt=function(e,t){var r=Math.ceil(t.length/16),o=e._cache.length;e._cache=i.concat([e._cache,i.allocUnsafe(16*r)]);for(var s=0;s{"use strict";t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},8408:(e,t,r)=>{"use strict";var n={ECB:r(9297),CBC:r(7427),CFB:r(4030),CFB8:r(4726),CFB1:r(3206),OFB:r(1962),CTR:r(2802),GCM:r(2802)},i=r(4946);for(var o in i)i[o].module=n[i[o].mode];e.exports=i},1962:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(6316);function o(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(e,t){for(;e._cache.length{"use strict";var n=r(7494),i=r(8850).Buffer,o=r(3013);function a(e,t,r,a){o.call(this),this._cipher=new n.AES(t),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._mode=e}r(1736)(a,o),a.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},a.prototype._final=function(){this._cipher.scrub()},e.exports=a},6805:(e,t,r)=>{"use strict";var n=r(9120),i=r(8073),o=r(8408),a=r(867),s=r(7085);function u(e,t,r){if(e=e.toLowerCase(),o[e])return i.createCipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function c(e,t,r){if(e=e.toLowerCase(),o[e])return i.createDecipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}t.createCipher=t.Cipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return u(e,i.key,i.iv)},t.createCipheriv=t.Cipheriv=u,t.createDecipher=t.Decipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return c(e,i.key,i.iv)},t.createDecipheriv=t.Decipheriv=c,t.listCiphers=t.getCiphers=function(){return Object.keys(a).concat(i.getCiphers())}},9120:(e,t,r)=>{"use strict";var n=r(3013),i=r(5626),o=r(1736),a=r(8850).Buffer,s={"des-ede3-cbc":i.CBC.instantiate(i.EDE),"des-ede3":i.EDE,"des-ede-cbc":i.CBC.instantiate(i.EDE),"des-ede":i.EDE,"des-cbc":i.CBC.instantiate(i.DES),"des-ecb":i.DES};function u(e){n.call(this);var t,r=e.mode.toLowerCase(),i=s[r];t=e.decrypt?"decrypt":"encrypt";var o=e.key;a.isBuffer(o)||(o=a.from(o)),"des-ede"!==r&&"des-ede-cbc"!==r||(o=a.concat([o,o.slice(0,8)]));var u=e.iv;a.isBuffer(u)||(u=a.from(u)),this._des=i.create({key:o,iv:u,type:t})}s.des=s["des-cbc"],s.des3=s["des-ede3-cbc"],e.exports=u,o(u,n),u.prototype._update=function(e){return a.from(this._des.update(e))},u.prototype._final=function(){return a.from(this._des.final())}},867:(e,t)=>{"use strict";t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}},9782:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(1734),o=r(5010);function a(e){var t,r=e.modulus.byteLength();do{t=new i(o(r))}while(t.cmp(e.modulus)>=0||!t.umod(e.prime1)||!t.umod(e.prime2));return t}function s(e,t){var r=function(e){var t=a(e);return{blinder:t.toRed(i.mont(e.modulus)).redPow(new i(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(t),o=t.modulus.byteLength(),s=new i(e).mul(r.blinder).umod(t.modulus),u=s.toRed(i.mont(t.prime1)),c=s.toRed(i.mont(t.prime2)),l=t.coefficient,f=t.prime1,h=t.prime2,d=u.redPow(t.exponent1).fromRed(),p=c.redPow(t.exponent2).fromRed(),m=d.isub(p).imul(l).umod(f).imul(h);return p.iadd(m).imul(r.unblinder).umod(t.modulus).toArrayLike(n,"be",o)}s.getr=a,e.exports=s},6561:(e,t,r)=>{"use strict";e.exports=r(5207)},9527:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(5866),o=r(6505),a=r(1736),s=r(1628),u=r(5410),c=r(5207);function l(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function f(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function h(e){return new l(e)}function d(e){return new f(e)}Object.keys(c).forEach((function(e){c[e].id=n.from(c[e].id,"hex"),c[e.toLowerCase()]=c[e]})),a(l,o.Writable),l.prototype._write=function(e,t,r){this._hash.update(e),r()},l.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},l.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),n=s(r,e,this._hashType,this._signType,this._tag);return t?n.toString(t):n},a(f,o.Writable),f.prototype._write=function(e,t,r){this._hash.update(e),r()},f.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},f.prototype.verify=function(e,t,r){"string"==typeof t&&(t=n.from(t,r)),this.end();var i=this._hash.digest();return u(t,i,e,this._signType,this._tag)},e.exports={Sign:h,Verify:d,createSign:h,createVerify:d}},1628:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(4424),o=r(9782),a=r(6597).ec,s=r(1734),u=r(7552),c=r(1308);function l(e,t,r,o){if((e=n.from(e.toArray())).length0&&r.ishrn(n),r}function h(e,t,r){var o,a;do{for(o=n.alloc(0);8*o.length{"use strict";var n=r(8850).Buffer,i=r(1734),o=r(6597).ec,a=r(7552),s=r(1308);function u(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=t)throw new Error("invalid sig")}e.exports=function(e,t,r,c,l){var f=a(r);if("ec"===f.type){if("ecdsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=s[r.data.algorithm.curve.join(".")];if(!n)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var i=new o(n),a=r.data.subjectPrivateKey.data;return i.verify(t,e,a)}(e,t,f)}if("dsa"===f.type){if("dsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=r.data.p,o=r.data.q,s=r.data.g,c=r.data.pub_key,l=a.signature.decode(e,"der"),f=l.s,h=l.r;u(f,o),u(h,o);var d=i.mont(n),p=f.invm(o);return 0===s.toRed(d).redPow(new i(t).mul(p).mod(o)).fromRed().mul(c.toRed(d).redPow(h.mul(p).mod(o)).fromRed()).mod(n).mod(o).cmp(h)}(e,t,f)}if("rsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");t=n.concat([l,t]);for(var h=f.modulus.byteLength(),d=[1],p=0;t.length+d.length+2{"use strict";var n=r(9033).Buffer;e.exports=function(e,t){for(var r=Math.min(e.length,t.length),i=new n(r),o=0;o{"use strict";var n=r(4919),i=r(3226),o=r(9484);function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function p(e,t){if(u.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return j(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return H(e).length;default:if(n)return j(e).length;t=(""+t).toLowerCase(),n=!0}}function m(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return I(this,t,r);case"utf8":case"utf-8":return M(this,t,r);case"ascii":return x(this,t,r);case"latin1":case"binary":return P(this,t,r);case"base64":return _(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function y(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function g(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=u.from(t,n)),u.isBuffer(t))return 0===t.length?-1:b(e,t,r,n,i);if("number"==typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):b(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function b(e,t,r,n,i){var o,a=1,s=e.length,u=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,r/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var l=-1;for(o=r;os&&(r=s-u),o=r;o>=0;o--){for(var f=!0,h=0;hi&&(n=i):n=i;var o=t.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var a=0;a>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function _(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function M(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i239?4:c>223?3:c>191?2:1;if(i+f<=r)switch(f){case 1:c<128&&(l=c);break;case 2:128==(192&(o=e[i+1]))&&(u=(31&c)<<6|63&o)>127&&(l=u);break;case 3:o=e[i+1],a=e[i+2],128==(192&o)&&128==(192&a)&&(u=(15&c)<<12|(63&o)<<6|63&a)>2047&&(u<55296||u>57343)&&(l=u);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(u=(15&c)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(l=u)}null===l?(l=65533,f=1):l>65535&&(l-=65536,n.push(l>>>10&1023|55296),l=56320|1023&l),n.push(l),i+=f}return function(e){var t=e.length;if(t<=T)return String.fromCharCode.apply(String,e);for(var r="",n=0;n0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),""},u.prototype.compare=function(e,t,r,n,i){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0),s=Math.min(o,a),c=this.slice(n,i),l=e.slice(t,r),f=0;fi)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return v(this,e,t,r);case"utf8":case"utf-8":return w(this,e,t,r);case"ascii":return A(this,e,t,r);case"latin1":case"binary":return S(this,e,t,r);case"base64":return k(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var T=4096;function x(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;ii)&&(r=i);for(var o="",a=t;ar)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,r,n,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function B(e,t,r,n){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-r,2);i>>8*(n?i:1-i)}function N(e,t,r,n){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-r,4);i>>8*(n?i:3-i)&255}function L(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function U(e,t,r,n,o){return o||L(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function F(e,t,r,n,o){return o||L(e,0,r,8),i.write(e,t,r,n,52,8),r+8}u.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t0&&(i*=256);)n+=this[e+--t]*i;return n},u.prototype.readUInt8=function(e,t){return t||R(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||R(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||R(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||R(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||R(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=this[e],i=1,o=0;++o=(i*=128)&&(n-=Math.pow(2,8*t)),n},u.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=t,i=1,o=this[e+--n];n>0&&(i*=256);)o+=this[e+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return t||R(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||R(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(e,t){t||R(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(e,t){return t||R(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||R(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||R(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||R(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||R(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||R(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,r,n){e=+e,t|=0,r|=0,n||C(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[t]=255&e;++o=0&&(o*=256);)this[t+i]=e/o&255;return t+r},u.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):N(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);C(this,e,t,r,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+r},u.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);C(this,e,t,r,i-1,-i)}var o=r-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+r},u.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):N(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,r){return U(this,e,t,!0,r)},u.prototype.writeFloatBE=function(e,t,r){return U(this,e,t,!1,r)},u.prototype.writeDoubleLE=function(e,t,r){return F(this,e,t,!0,r)},u.prototype.writeDoubleBE=function(e,t,r){return F(this,e,t,!1,r)},u.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t=0;--i)e[i+t]=this[i+r];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function H(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(D,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function J(e,t,r,n){for(var i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}},3675:e=>{"use strict";e.exports={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}},593:(e,t,r)=>{"use strict";var n=r(7701),i=r(4373),o=i(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&o(e,".prototype.")>-1?i(r):r}},4373:(e,t,r)=>{"use strict";var n=r(3767),i=r(7701),o=i("%Function.prototype.apply%"),a=i("%Function.prototype.call%"),s=i("%Reflect.apply%",!0)||n.call(a,o),u=i("%Object.getOwnPropertyDescriptor%",!0),c=i("%Object.defineProperty%",!0),l=i("%Math.max%");if(c)try{c({},"a",{value:1})}catch(e){c=null}e.exports=function(e){var t=s(n,a,arguments);if(u&&c){var r=u(t,"length");r.configurable&&c(t,"length",{value:1+l(0,e.length-(arguments.length-1))})}return t};var f=function(){return s(n,o,arguments)};c?c(e.exports,"apply",{value:f}):e.exports.apply=f},7759:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(3630),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(9033).Buffer,i=r(6657),o=r(5262),a=r(1842),s=r(779);(t=e.exports).addPrefix=function(e,t){var r;if(n.isBuffer(e))r=s.varintBufferEncode(e);else{if(!a[e])throw new Error("multicodec not recognized");r=a[e]}return n.concat([r,t])},t.rmPrefix=function(e){return i.decode(e),e.slice(i.decode.bytes)},t.getCodec=function(e){var t=i.decode(e),r=o.get(t);if(void 0===r)throw new Error("Code ".concat(t," not found"));return r},t.getName=function(e){return o.get(e)},t.getNumber=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return s.varintBufferDecode(t)[0]},t.getCode=function(e){return i.decode(e)},t.getCodeVarint=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return t},t.getVarint=function(e){return i.encode(e)};var u=r(7759);Object.assign(t,u),t.print=r(9268)},5262:(e,t,r)=>{"use strict";var n=r(3630),i=new Map;for(var o in n){var a=n[o];i.set(a,o)}e.exports=Object.freeze(i)},9268:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(3630),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(6657),i=r(9033).Buffer;function o(e){return parseInt(e.toString("hex"),16)}function a(e){var t=e.toString(16);return t.length%2==1&&(t="0"+t),i.from(t,"hex")}e.exports={numberToBuffer:a,bufferToNumber:o,varintBufferEncode:function(e){return i.from(n.encode(o(e)))},varintBufferDecode:function(e){return a(n.decode(e))},varintEncode:function(e){return i.from(n.encode(e))}}},1842:(e,t,r)=>{"use strict";var n=r(3630),i=r(779).varintEncode,o={};for(var a in n){var s=n[a];o[a]=i(s)}e.exports=Object.freeze(o)},9976:(e,t,r)=>{"use strict";var n=r(7748),i=r(9033).Buffer,o={checkCIDComponents:function(e){if(null==e)return"null values are not valid CIDs";if(0!==e.version&&1!==e.version)return"Invalid version, must be a number equal to 1 or 0";if("string"!=typeof e.codec)return"codec must be string";if(0===e.version){if("dag-pb"!==e.codec)return"codec must be 'dag-pb' for CIDv0";if("base58btc"!==e.multibaseName)return"multibaseName must be 'base58btc' for CIDv0"}if(!i.isBuffer(e.multihash))return"multihash must be a Buffer";try{n.validate(e.multihash)}catch(e){var t=e.message;return t||(t="Multihash validation failed"),t}}};e.exports=o},2753:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=r(9033).Buffer,s=r(7748),u=r(6086),c=r(7223),l=r(3630),f=r(9976),h=r(3162)(function(e){function t(e,r,n,o){if((0,i.default)(this,t),h.isCID(e)){var l=e;return this.version=l.version,this.codec=l.codec,this.multihash=a.from(l.multihash),void(this.multibaseName=l.multibaseName||(0===l.version?"base58btc":"base32"))}if("string"==typeof e){var f=u.isEncoded(e);if(f){var d=u.decode(e);this.version=parseInt(d.slice(0,1).toString("hex"),16),this.codec=c.getCodec(d.slice(1)),this.multihash=c.rmPrefix(d.slice(1)),this.multibaseName=f}else this.version=0,this.codec="dag-pb",this.multihash=s.fromB58String(e),this.multibaseName="base58btc";return t.validateCID(this),void Object.defineProperty(this,"string",{value:e})}if(a.isBuffer(e)){var p=e.slice(0,1),m=parseInt(p.toString("hex"),16);if(1===m){var y=e;this.version=m,this.codec=c.getCodec(y.slice(1)),this.multihash=c.rmPrefix(y.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=e,this.multibaseName="base58btc";t.validateCID(this)}else this.version=e,this.codec=r,this.multihash=n,this.multibaseName=o||(0===e?"base58btc":"base32"),t.validateCID(this)}return(0,o.default)(t,[{key:"buffer",get:function(){var e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=a.concat([a.from("01","hex"),c.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}},{key:"prefix",get:function(){return a.concat([a.from("0".concat(this.version),"hex"),c.getCodeVarint(this.codec),s.prefix(this.multihash)])}},{key:"toV0",value:function(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");var e=s.decode(this.multihash),t=e.name,r=e.length;if("sha2-256"!==t)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==r)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new h(0,this.codec,this.multihash)}},{key:"toV1",value:function(){return new h(1,this.codec,this.multihash)}},{key:"toBaseEncodedString",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.multibaseName;if(this.string&&e===this.multibaseName)return this.string;var t=null;if(0===this.version){if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");t=s.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");t=u.encode(e,this.buffer).toString()}return e===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}},{key:e,value:function(){return"CID("+this.toString()+")"}},{key:"toString",value:function(e){return this.toBaseEncodedString(e)}},{key:"toJSON",value:function(){return{codec:this.codec,version:this.version,hash:this.multihash}}},{key:"equals",value:function(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}}],[{key:"validateCID",value:function(e){var t=f.checkCIDComponents(e);if(t)throw new Error(t)}}]),t}(Symbol.for("nodejs.util.inspect.custom")),{className:"CID",symbolName:"@ipld/js-cid/CID"});h.codecs=l,e.exports=h},3013:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(7245).Transform,o=r(3462).s;function a(e){i.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(1736)(a,i),a.prototype.update=function(e,t,r){"string"==typeof e&&(e=n.from(e,t));var i=this._update(e);return this.hashMode?this:(r&&(i=this._toString(i,r)),i)},a.prototype.setAutoPadding=function(){},a.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},a.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},a.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},a.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){n=e}finally{r(n)}},a.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},a.prototype._finalOrDigest=function(e){var t=this.__final()||n.alloc(0);return e&&(t=this._toString(t,e,!0)),t},a.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new o(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n},e.exports=a},3162:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(4727)),o=n(r(775)),a=n(r(9721)),s=n(r(8985)),u=n(r(8975)),c=n(r(5163)),l=n(r(4650)),f=n(r(1949));e.exports=function(e,t){var r=t.className,n=t.symbolName,i=Symbol.for(n),h=(0,o.default)({},r,function(e,t){(0,c.default)(d,e);var n,o,h=(n=d,o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=(0,f.default)(n);if(o){var r=(0,f.default)(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return(0,l.default)(this,e)});function d(){var e;(0,a.default)(this,d);for(var t=arguments.length,r=new Array(t),n=0;n{"use strict";var n=r(2753);t.cidV0ToV1Base32=function(e){var t=new n(e);return 0===t.version&&(t=t.toV1()),t.toString("base32")}},4308:(e,t,r)=>{"use strict";var n=r(9206),i=r(9512),o=i.hexStringToBuffer,a=i.profiles,s=r(6834).cidV0ToV1Base32;e.exports={helpers:{cidV0ToV1Base32:s},decode:function(e){var t=o(e),r=n.getCodec(t),i=n.rmPrefix(t),s=a[r];return s||(s=a.default),s.decode(i)},fromIpfs:function(e){return this.encode("ipfs-ns",e)},fromSwarm:function(e){return this.encode("swarm-ns",e)},encode:function(e,t){var r=a[e];r||(r=a.default);var i=r.encode(t);return n.addPrefix(e,i).toString("hex")},getCodec:function(e){var t=o(e);return n.getCodec(t)}}},9512:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(2753),o=r(7748),a=function(e){var t,r=e.slice(0,2),n=e.slice(2);return t="0x"===r?n:e,o.fromHexString(t)},s={swarm:function(e){var t=o.encode(a(e),"keccak-256");return new i(1,"swarm-manifest",t).buffer},ipfs:function(e){var t=o.fromB58String(e);return new i(1,"dag-pb",t).buffer},utf8:function(e){return n.from(e,"utf8")}},u={hexMultiHash:function(e){var t=new i(e);return o.decode(t.multihash).digest.toString("hex")},b58MultiHash:function(e){var t=new i(e);return o.toB58String(t.multihash)},utf8:function(e){return e.toString("utf8")}},c={"swarm-ns":{encode:s.swarm,decode:u.hexMultiHash},"ipfs-ns":{encode:s.ipfs,decode:u.b58MultiHash},"ipns-ns":{encode:s.ipfs,decode:u.b58MultiHash},default:{encode:s.utf8,decode:u.utf8}};t.hexStringToBuffer=a,t.profiles=c},4628:(e,t,r)=>{"use strict";var n,i,o=r(8847)(r(3355));i=function(e){e.version="1.2.2";var t=function(){for(var e=0,t=new Array(256),r=0;256!=r;++r)e=1&(e=1&(e=1&(e=1&(e=1&(e=1&(e=1&(e=1&(e=r)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1,t[r]=e;return"undefined"!=typeof Int32Array?new Int32Array(t):t}(),r=function(e){var t=0,r=0,n=0,i="undefined"!=typeof Int32Array?new Int32Array(4096):new Array(4096);for(n=0;256!=n;++n)i[n]=e[n];for(n=0;256!=n;++n)for(r=e[n],t=256+n;t<4096;t+=256)r=i[t]=r>>>8^e[255&r];var o=[];for(n=1;16!=n;++n)o[n-1]="undefined"!=typeof Int32Array?i.subarray(256*n,256*n+256):i.slice(256*n,256*n+256);return o}(t),n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],u=r[5],c=r[6],l=r[7],f=r[8],h=r[9],d=r[10],p=r[11],m=r[12],y=r[13],g=r[14];e.table=t,e.bstr=function(e,r){for(var n=-1^r,i=0,o=e.length;i>>8^t[255&(n^e.charCodeAt(i++))];return~n},e.buf=function(e,r){for(var b=-1^r,v=e.length-15,w=0;w>8&255]^m[e[w++]^b>>16&255]^p[e[w++]^b>>>24]^d[e[w++]]^h[e[w++]]^f[e[w++]]^l[e[w++]]^c[e[w++]]^u[e[w++]]^s[e[w++]]^a[e[w++]]^o[e[w++]]^i[e[w++]]^n[e[w++]]^t[e[w++]];for(v+=15;w>>8^t[255&(b^e[w++])];return~b},e.str=function(e,r){for(var n=-1^r,i=0,o=e.length,a=0,s=0;i>>8^t[255&(n^a)]:a<2048?n=(n=n>>>8^t[255&(n^(192|a>>6&31))])>>>8^t[255&(n^(128|63&a))]:a>=55296&&a<57344?(a=64+(1023&a),s=1023&e.charCodeAt(i++),n=(n=(n=(n=n>>>8^t[255&(n^(240|a>>8&7))])>>>8^t[255&(n^(128|a>>2&63))])>>>8^t[255&(n^(128|s>>6&15|(3&a)<<4))])>>>8^t[255&(n^(128|63&s))]):n=(n=(n=n>>>8^t[255&(n^(224|a>>12&15))])>>>8^t[255&(n^(128|a>>6&63))])>>>8^t[255&(n^(128|63&a))];return~n}},"undefined"==typeof DO_NOT_EXPORT_CRC?"object"===(0,o.default)(t)?i(t):(n=function(){var e={};return i(e),e}.call(t,r,t,e),void 0===n||(e.exports=n)):i({})},5102:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(6597),o=r(1734);e.exports=function(e){return new s(e)};var a={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function s(e){this.curveType=a[e],this.curveType||(this.curveType={name:e}),this.curve=new i.ec(this.curveType.name),this.keys=void 0}function u(e,t,r){Array.isArray(e)||(e=e.toArray());var i=new n(e);if(r&&i.length{"use strict";var n=r(1736),i=r(807),o=r(6707),a=r(1708),s=r(3013);function u(e){s.call(this,"digest"),this._hash=e}n(u,s),u.prototype._update=function(e){this._hash.update(e)},u.prototype._final=function(){return this._hash.digest()},e.exports=function(e){return"md5"===(e=e.toLowerCase())?new i:"rmd160"===e||"ripemd160"===e?new o:new u(a(e))}},5349:(e,t,r)=>{"use strict";var n=r(807);e.exports=function(e){return(new n).update(e).digest()}},4424:(e,t,r)=>{"use strict";var n=r(1736),i=r(9956),o=r(3013),a=r(8850).Buffer,s=r(5349),u=r(6707),c=r(1708),l=a.alloc(128);function f(e,t){o.call(this,"digest"),"string"==typeof t&&(t=a.from(t));var r="sha512"===e||"sha384"===e?128:64;this._alg=e,this._key=t,t.length>r?t=("rmd160"===e?new u:c(e)).update(t).digest():t.length{"use strict";var n=r(1736),i=r(8850).Buffer,o=r(3013),a=i.alloc(128),s=64;function u(e,t){o.call(this,"digest"),"string"==typeof t&&(t=i.from(t)),this._alg=e,this._key=t,t.length>s?t=e(t):t.length{"use strict";!function(e){!function(t){var r="URLSearchParams"in e,n="Symbol"in e&&"iterator"in Symbol,i="FileReader"in e&&"Blob"in e&&function(){try{return new Blob,!0}catch(e){return!1}}(),o="FormData"in e,a="ArrayBuffer"in e;if(a)var s=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],u=ArrayBuffer.isView||function(e){return e&&s.indexOf(Object.prototype.toString.call(e))>-1};function c(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(e))throw new TypeError("Invalid character in header field name");return e.toLowerCase()}function l(e){return"string"!=typeof e&&(e=String(e)),e}function f(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return n&&(t[Symbol.iterator]=function(){return t}),t}function h(e){this.map={},e instanceof h?e.forEach((function(e,t){this.append(t,e)}),this):Array.isArray(e)?e.forEach((function(e){this.append(e[0],e[1])}),this):e&&Object.getOwnPropertyNames(e).forEach((function(t){this.append(t,e[t])}),this)}function d(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function p(e){return new Promise((function(t,r){e.onload=function(){t(e.result)},e.onerror=function(){r(e.error)}}))}function m(e){var t=new FileReader,r=p(t);return t.readAsArrayBuffer(e),r}function y(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function g(){return this.bodyUsed=!1,this._initBody=function(e){var t;this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:i&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:o&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:r&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():a&&i&&(t=e)&&DataView.prototype.isPrototypeOf(t)?(this._bodyArrayBuffer=y(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):a&&(ArrayBuffer.prototype.isPrototypeOf(e)||u(e))?this._bodyArrayBuffer=y(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):r&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},i&&(this.blob=function(){var e=d(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?d(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(m)}),this.text=function(){var e,t,r,n=d(this);if(n)return n;if(this._bodyBlob)return e=this._bodyBlob,r=p(t=new FileReader),t.readAsText(e),r;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),r=new Array(t.length),n=0;n-1?n:r),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(i)}function w(e){var t=new FormData;return e.trim().split("&").forEach((function(e){if(e){var r=e.split("="),n=r.shift().replace(/\+/g," "),i=r.join("=").replace(/\+/g," ");t.append(decodeURIComponent(n),decodeURIComponent(i))}})),t}function A(e,t){t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"OK",this.headers=new h(t.headers),this.url=t.url||"",this._initBody(e)}v.prototype.clone=function(){return new v(this,{body:this._bodyInit})},g.call(v.prototype),g.call(A.prototype),A.prototype.clone=function(){return new A(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},A.error=function(){var e=new A(null,{status:0,statusText:""});return e.type="error",e};var S=[301,302,303,307,308];A.redirect=function(e,t){if(-1===S.indexOf(t))throw new RangeError("Invalid status code");return new A(null,{status:t,headers:{location:e}})},t.DOMException=e.DOMException;try{new t.DOMException}catch(e){t.DOMException=function(e,t){this.message=e,this.name=t;var r=Error(e);this.stack=r.stack},t.DOMException.prototype=Object.create(Error.prototype),t.DOMException.prototype.constructor=t.DOMException}function k(e,r){return new Promise((function(n,o){var a=new v(e,r);if(a.signal&&a.signal.aborted)return o(new t.DOMException("Aborted","AbortError"));var s=new XMLHttpRequest;function u(){s.abort()}s.onload=function(){var e,t,r={status:s.status,statusText:s.statusText,headers:(e=s.getAllResponseHeaders()||"",t=new h,e.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(e){var r=e.split(":"),n=r.shift().trim();if(n){var i=r.join(":").trim();t.append(n,i)}})),t)};r.url="responseURL"in s?s.responseURL:r.headers.get("X-Request-URL");var i="response"in s?s.response:s.responseText;n(new A(i,r))},s.onerror=function(){o(new TypeError("Network request failed"))},s.ontimeout=function(){o(new TypeError("Network request failed"))},s.onabort=function(){o(new t.DOMException("Aborted","AbortError"))},s.open(a.method,a.url,!0),"include"===a.credentials?s.withCredentials=!0:"omit"===a.credentials&&(s.withCredentials=!1),"responseType"in s&&i&&(s.responseType="blob"),a.headers.forEach((function(e,t){s.setRequestHeader(t,e)})),a.signal&&(a.signal.addEventListener("abort",u),s.onreadystatechange=function(){4===s.readyState&&a.signal.removeEventListener("abort",u)}),s.send(void 0===a._bodyInit?null:a._bodyInit)}))}k.polyfill=!0,e.fetch||(e.fetch=k,e.Headers=h,e.Request=v,e.Response=A),t.Headers=h,t.Request=v,t.Response=A,t.fetch=k,Object.defineProperty(t,"__esModule",{value:!0})}({})}("undefined"!=typeof self?self:void 0)},4293:(e,t,r)=>{"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=r(5010),t.createHash=t.Hash=r(5866),t.createHmac=t.Hmac=r(4424);var n=r(6561),i=Object.keys(n),o=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(i);t.getHashes=function(){return o};var a=r(4192);t.pbkdf2=a.pbkdf2,t.pbkdf2Sync=a.pbkdf2Sync;var s=r(6805);t.Cipher=s.Cipher,t.createCipher=s.createCipher,t.Cipheriv=s.Cipheriv,t.createCipheriv=s.createCipheriv,t.Decipher=s.Decipher,t.createDecipher=s.createDecipher,t.Decipheriv=s.Decipheriv,t.createDecipheriv=s.createDecipheriv,t.getCiphers=s.getCiphers,t.listCiphers=s.listCiphers;var u=r(8333);t.DiffieHellmanGroup=u.DiffieHellmanGroup,t.createDiffieHellmanGroup=u.createDiffieHellmanGroup,t.getDiffieHellman=u.getDiffieHellman,t.createDiffieHellman=u.createDiffieHellman,t.DiffieHellman=u.DiffieHellman;var c=r(9527);t.createSign=c.createSign,t.Sign=c.Sign,t.createVerify=c.createVerify,t.Verify=c.Verify,t.createECDH=r(5102);var l=r(6991);t.publicEncrypt=l.publicEncrypt,t.privateEncrypt=l.privateEncrypt,t.publicDecrypt=l.publicDecrypt,t.privateDecrypt=l.privateDecrypt;var f=r(6509);t.randomFill=f.randomFill,t.randomFillSync=f.randomFillSync,t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},34:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i="%[a-f0-9]{2}",o=new RegExp("("+i+")|([^%]+?)","gi"),a=new RegExp("("+i+")+","gi");function s(e,t){try{return[decodeURIComponent(e.join(""))]}catch(e){}if(1===e.length)return e;t=t||1;var r=e.slice(0,t),n=e.slice(t);return Array.prototype.concat.call([],s(r),s(n))}function u(e){try{return decodeURIComponent(e)}catch(n){for(var t=e.match(o)||[],r=1;r{"use strict";t.utils=r(319),t.Cipher=r(9591),t.DES=r(3049),t.CBC=r(4375),t.EDE=r(9413)},4375:(e,t,r)=>{"use strict";var n=r(4504),i=r(1736),o={};function a(e){n.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t{"use strict";var n=r(4504);function i(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}e.exports=i,i.prototype._init=function(){},i.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},i.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n0;n--)t+=this._buffer(e,t),r+=this._flushBuffer(i,r);return t+=this._buffer(e,t),i},i.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},i.prototype._pad=function(e,t){if(0===t)return!1;for(;t{"use strict";var n=r(4504),i=r(1736),o=r(319),a=r(9591);function s(){this.tmp=new Array(2),this.keys=null}function u(e){a.call(this,e);var t=new s;this._desState=t,this.deriveKeys(t,e.key)}i(u,a),e.exports=u,u.create=function(e){return new u(e)};var c=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];u.prototype.deriveKeys=function(e,t){e.keys=new Array(32),n.equal(t.length,this.blockSize,"Invalid key length");var r=o.readUInt32BE(t,0),i=o.readUInt32BE(t,4);o.pc1(r,i,e.tmp,0),r=e.tmp[0],i=e.tmp[1];for(var a=0;a>>1];r=o.r28shl(r,s),i=o.r28shl(i,s),o.pc2(r,i,e.keys,a)}},u.prototype._update=function(e,t,r,n){var i=this._desState,a=o.readUInt32BE(e,t),s=o.readUInt32BE(e,t+4);o.ip(a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],"encrypt"===this.type?this._encrypt(i,a,s,i.tmp,0):this._decrypt(i,a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],o.writeUInt32BE(r,a,n),o.writeUInt32BE(r,s,n+4)},u.prototype._pad=function(e,t){for(var r=e.length-t,n=t;n>>0,a=h}o.rip(s,a,n,i)},u.prototype._decrypt=function(e,t,r,n,i){for(var a=r,s=t,u=e.keys.length-2;u>=0;u-=2){var c=e.keys[u],l=e.keys[u+1];o.expand(a,e.tmp,0),c^=e.tmp[0],l^=e.tmp[1];var f=o.substitute(c,l),h=a;a=(s^o.permute(f))>>>0,s=h}o.rip(a,s,n,i)}},9413:(e,t,r)=>{"use strict";var n=r(4504),i=r(1736),o=r(9591),a=r(3049);function s(e,t){n.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),i=t.slice(8,16),o=t.slice(16,24);this.ciphers="encrypt"===e?[a.create({type:"encrypt",key:r}),a.create({type:"decrypt",key:i}),a.create({type:"encrypt",key:o})]:[a.create({type:"decrypt",key:o}),a.create({type:"encrypt",key:i}),a.create({type:"decrypt",key:r})]}function u(e){o.call(this,e);var t=new s(this.type,this.options.key);this._edeState=t}i(u,o),e.exports=u,u.create=function(e){return new u(e)},u.prototype._update=function(e,t,r,n){var i=this._edeState;i.ciphers[0]._update(e,t,r,n),i.ciphers[1]._update(r,n,r,n),i.ciphers[2]._update(r,n,r,n)},u.prototype._pad=a.prototype._pad,u.prototype._unpad=a.prototype._unpad},319:(e,t)=>{"use strict";t.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},t.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},t.ip=function(e,t,r,n){for(var i=0,o=0,a=6;a>=0;a-=2){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>>s+a&1}for(a=6;a>=0;a-=2){for(s=1;s<=25;s+=8)o<<=1,o|=t>>>s+a&1;for(s=1;s<=25;s+=8)o<<=1,o|=e>>>s+a&1}r[n+0]=i>>>0,r[n+1]=o>>>0},t.rip=function(e,t,r,n){for(var i=0,o=0,a=0;a<4;a++)for(var s=24;s>=0;s-=8)i<<=1,i|=t>>>s+a&1,i<<=1,i|=e>>>s+a&1;for(a=4;a<8;a++)for(s=24;s>=0;s-=8)o<<=1,o|=t>>>s+a&1,o<<=1,o|=e>>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.pc1=function(e,t,r,n){for(var i=0,o=0,a=7;a>=5;a--){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>s+a&1}for(s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(a=1;a<=3;a++){for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1;for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1}for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.r28shl=function(e,t){return e<>>28-t};var r=[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];t.pc2=function(e,t,n,i){for(var o=0,a=0,s=r.length>>>1,u=0;u>>r[u]&1;for(u=s;u>>r[u]&1;n[i+0]=o>>>0,n[i+1]=a>>>0},t.expand=function(e,t,r){var n=0,i=0;n=(1&e)<<5|e>>>27;for(var o=23;o>=15;o-=4)n<<=6,n|=e>>>o&63;for(o=11;o>=3;o-=4)i|=e>>>o&63,i<<=6;i|=(31&e)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=i>>>0};var n=[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];t.substitute=function(e,t){for(var r=0,i=0;i<4;i++)r<<=4,r|=n[64*i+(e>>>18-6*i&63)];for(i=0;i<4;i++)r<<=4,r|=n[256+64*i+(t>>>18-6*i&63)];return r>>>0};var i=[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];t.permute=function(e){for(var t=0,r=0;r>>i[r]&1;return t>>>0},t.padSplit=function(e,t,r){for(var n=e.toString(2);n.length{"use strict";var n=r(9033).Buffer,i=r(8557),o=r(9799),a=r(1592),s={binary:!0,hex:!0,base64:!0};t.DiffieHellmanGroup=t.createDiffieHellmanGroup=t.getDiffieHellman=function(e){var t=new n(o[e].prime,"hex"),r=new n(o[e].gen,"hex");return new a(t,r)},t.createDiffieHellman=t.DiffieHellman=function e(t,r,o,u){return n.isBuffer(r)||void 0===s[r]?e(t,"binary",r,o):(r=r||"binary",u=u||"binary",o=o||new n([2]),n.isBuffer(o)||(o=new n(o,u)),"number"==typeof t?new a(i(t,o),o,!0):(n.isBuffer(t)||(t=new n(t,r)),new a(t,o,!0)))}},1592:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(1734),o=new(r(137)),a=new i(24),s=new i(11),u=new i(10),c=new i(3),l=new i(7),f=r(8557),h=r(5010);function d(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._pub=new i(e),this}function p(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._priv=new i(e),this}e.exports=y;var m={};function y(e,t,r){this.setGenerator(t),this.__prime=new i(e),this._prime=i.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=d,this.setPrivateKey=p):this._primeCode=8}function g(e,t){var r=new n(e.toArray());return t?r.toString(t):r}Object.defineProperty(y.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),n=[r,e.toString(16)].join("_");if(n in m)return m[n];var i,h=0;if(e.isEven()||!f.simpleSieve||!f.fermatTest(e)||!o.test(e))return h+=1,h+="02"===r||"05"===r?8:4,m[n]=h,h;switch(o.test(e.shrn(1))||(h+=2),r){case"02":e.mod(a).cmp(s)&&(h+=8);break;case"05":(i=e.mod(u)).cmp(c)&&i.cmp(l)&&(h+=8);break;default:h+=4}return m[n]=h,h}(this.__prime,this.__gen)),this._primeCode}}),y.prototype.generateKeys=function(){return this._priv||(this._priv=new i(h(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},y.prototype.computeSecret=function(e){var t=(e=(e=new i(e)).toRed(this._prime)).redPow(this._priv).fromRed(),r=new n(t.toArray()),o=this.getPrime();if(r.length{"use strict";var n=r(5010);e.exports=g,g.simpleSieve=m,g.fermatTest=y;var i=r(1734),o=new i(24),a=new(r(137)),s=new i(1),u=new i(2),c=new i(5),l=(new i(16),new i(8),new i(10)),f=new i(3),h=(new i(7),new i(11)),d=new i(4),p=(new i(12),null);function m(e){for(var t=function(){if(null!==p)return p;var e=[];e[0]=2;for(var t=1,r=3;r<1048576;r+=2){for(var n=Math.ceil(Math.sqrt(r)),i=0;ie;)r.ishrn(1);if(r.isEven()&&r.iadd(s),r.testn(1)||r.iadd(u),t.cmp(u)){if(!t.cmp(c))for(;r.mod(l).cmp(f);)r.iadd(d)}else for(;r.mod(o).cmp(h);)r.iadd(d);if(m(p=r.shrn(1))&&m(r)&&y(p)&&y(r)&&a.test(p)&&a.test(r))return r}}},6597:(e,t,r)=>{"use strict";var n=t;n.version=r(8597).i8,n.utils=r(7528),n.rand=r(2202),n.curve=r(6063),n.curves=r(506),n.ec=r(8320),n.eddsa=r(8027)},1249:(e,t,r)=>{"use strict";var n=r(1734),i=r(7528),o=i.getNAF,a=i.getJSF,s=i.assert;function u(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function c(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=u,u.prototype.point=function(){throw new Error("Not implemented")},u.prototype.validate=function(){throw new Error("Not implemented")},u.prototype._fixedNafMul=function(e,t){s(e.precomputed);var r=e._getDoubles(),n=o(t,1,this._bitLength),i=(1<=a;l--)u=(u<<1)+n[l];c.push(u)}for(var f=this.jpoint(null,null,null),h=this.jpoint(null,null,null),d=i;d>0;d--){for(a=0;a=0;c--){for(var l=0;c>=0&&0===a[c];c--)l++;if(c>=0&&l++,u=u.dblp(l),c<0)break;var f=a[c];s(0!==f),u="affine"===e.type?f>0?u.mixedAdd(i[f-1>>1]):u.mixedAdd(i[-f-1>>1].neg()):f>0?u.add(i[f-1>>1]):u.add(i[-f-1>>1].neg())}return"affine"===e.type?u.toP():u},u.prototype._wnafMulAdd=function(e,t,r,n,i){var s,u,c,l=this._wnafT1,f=this._wnafT2,h=this._wnafT3,d=0;for(s=0;s=1;s-=2){var m=s-1,y=s;if(1===l[m]&&1===l[y]){var g=[t[m],null,null,t[y]];0===t[m].y.cmp(t[y].y)?(g[1]=t[m].add(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg())):0===t[m].y.cmp(t[y].y.redNeg())?(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].add(t[y].neg())):(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg()));var b=[-3,-1,-5,-7,0,7,5,1,3],v=a(r[m],r[y]);for(d=Math.max(v[0].length,d),h[m]=new Array(d),h[y]=new Array(d),u=0;u=0;s--){for(var E=0;s>=0;){var _=!0;for(u=0;u=0&&E++,S=S.dblp(E),s<0)break;for(u=0;u0?c=f[u][M-1>>1]:M<0&&(c=f[u][-M-1>>1].neg()),S="affine"===c.type?S.mixedAdd(c):S.add(c))}}for(s=0;s=Math.ceil((e.bitLength()+1)/t.step)},c.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i{"use strict";var n=r(7528),i=r(1734),o=r(1736),a=r(1249),s=n.assert;function u(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,a.call(this,"edwards",e),this.a=new i(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new i(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new i(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function c(e,t,r,n,o){a.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===n?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new i(t,16),this.y=new i(r,16),this.z=n?new i(n,16):this.curve.one,this.t=o&&new i(o,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}o(u,a),e.exports=u,u.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},u.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},u.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=n.redMul(o.redInvm()),s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");var u=s.fromRed().isOdd();return(t&&!u||!t&&u)&&(s=s.redNeg()),this.point(e,s)},u.prototype.pointFromY=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=n.redMul(o.redInvm());if(0===a.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");return s.fromRed().isOdd()!==t&&(s=s.redNeg()),this.point(s,e)},u.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===n.cmp(i)},o(c,a.BasePoint),u.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},u.prototype.point=function(e,t,r,n){return new c(this,e,t,r,n)},c.fromJSON=function(e,t){return new c(e,t[0],t[1],t[2])},c.prototype.inspect=function(){return this.isInfinity()?"":""},c.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},c.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),o=n.redAdd(t),a=o.redSub(r),s=n.redSub(t),u=i.redMul(a),c=o.redMul(s),l=i.redMul(s),f=a.redMul(o);return this.curve.point(u,c,f,l)},c.prototype._projDbl=function(){var e,t,r,n,i,o,a=this.x.redAdd(this.y).redSqr(),s=this.x.redSqr(),u=this.y.redSqr();if(this.curve.twisted){var c=(n=this.curve._mulA(s)).redAdd(u);this.zOne?(e=a.redSub(s).redSub(u).redMul(c.redSub(this.curve.two)),t=c.redMul(n.redSub(u)),r=c.redSqr().redSub(c).redSub(c)):(i=this.z.redSqr(),o=c.redSub(i).redISub(i),e=a.redSub(s).redISub(u).redMul(o),t=c.redMul(n.redSub(u)),r=c.redMul(o))}else n=s.redAdd(u),i=this.curve._mulC(this.z).redSqr(),o=n.redSub(i).redSub(i),e=this.curve._mulC(a.redISub(n)).redMul(o),t=this.curve._mulC(n).redMul(s.redISub(u)),r=n.redMul(o);return this.curve.point(e,t,r)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},c.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),o=r.redSub(t),a=i.redSub(n),s=i.redAdd(n),u=r.redAdd(t),c=o.redMul(a),l=s.redMul(u),f=o.redMul(u),h=a.redMul(s);return this.curve.point(c,l,h,f)},c.prototype._projAdd=function(e){var t,r,n=this.z.redMul(e.z),i=n.redSqr(),o=this.x.redMul(e.x),a=this.y.redMul(e.y),s=this.curve.d.redMul(o).redMul(a),u=i.redSub(s),c=i.redAdd(s),l=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(o).redISub(a),f=n.redMul(u).redMul(l);return this.curve.twisted?(t=n.redMul(c).redMul(a.redSub(this.curve._mulA(o))),r=u.redMul(c)):(t=n.redMul(c).redMul(a.redSub(o)),r=this.curve._mulC(u).redMul(c)),this.curve.point(f,t,r)},c.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},c.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},c.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},c.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},c.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()},c.prototype.getY=function(){return this.normalize(),this.y.fromRed()},c.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},c.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(n),0===this.x.cmp(t))return!0}},c.prototype.toP=c.prototype.normalize,c.prototype.mixedAdd=c.prototype.add},6063:(e,t,r)=>{"use strict";var n=t;n.base=r(1249),n.short=r(3148),n.mont=r(1105),n.edwards=r(1123)},1105:(e,t,r)=>{"use strict";var n=r(1734),i=r(1736),o=r(1249),a=r(7528);function s(e){o.call(this,"mont",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.i4=new n(4).toRed(this.red).redInvm(),this.two=new n(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function u(e,t,r){o.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new n(t,16),this.z=new n(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}i(s,o),e.exports=s,s.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===n.redSqrt().redSqr().cmp(n)},i(u,o.BasePoint),s.prototype.decodePoint=function(e,t){return this.point(a.toArray(e,t),1)},s.prototype.point=function(e,t){return new u(this,e,t)},s.prototype.pointFromJSON=function(e){return u.fromJSON(this,e)},u.prototype.precompute=function(){},u.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},u.fromJSON=function(e,t){return new u(e,t[0],t[1]||e.one)},u.prototype.inspect=function(){return this.isInfinity()?"":""},u.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},u.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),n=e.redMul(t),i=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(n,i)},u.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),o=e.x.redSub(e.z).redMul(r),a=i.redMul(n),s=t.z.redMul(o.redAdd(a).redSqr()),u=t.x.redMul(o.redISub(a).redSqr());return this.curve.point(s,u)},u.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=[];0!==t.cmpn(0);t.iushrn(1))i.push(t.andln(1));for(var o=i.length-1;o>=0;o--)0===i[o]?(r=r.diffAdd(n,this),n=n.dbl()):(n=r.diffAdd(n,this),r=r.dbl());return n},u.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},u.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},u.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},3148:(e,t,r)=>{"use strict";var n=r(7528),i=r(1734),o=r(1736),a=r(1249),s=n.assert;function u(e){a.call(this,"short",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.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(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function c(e,t,r,n){a.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new i(t,16),this.y=new i(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function l(e,t,r,n){a.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new i(0)):(this.x=new i(t,16),this.y=new i(r,16),this.z=new i(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}o(u,a),e.exports=u,u.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new i(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new i(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],s(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new i(e.a,16),b:new i(e.b,16)}})):this._getEndoBasis(r)}}},u.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:i.mont(e),r=new i(2).toRed(t).redInvm(),n=r.redNeg(),o=new i(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(o).fromRed(),n.redSub(o).fromRed()]},u.prototype._getEndoBasis=function(e){for(var t,r,n,o,a,s,u,c,l,f=this.n.ushrn(Math.floor(this.n.bitLength()/2)),h=e,d=this.n.clone(),p=new i(1),m=new i(0),y=new i(0),g=new i(1),b=0;0!==h.cmpn(0);){var v=d.div(h);c=d.sub(v.mul(h)),l=y.sub(v.mul(p));var w=g.sub(v.mul(m));if(!n&&c.cmp(f)<0)t=u.neg(),r=p,n=c.neg(),o=l;else if(n&&2==++b)break;u=c,d=h,h=c,y=p,p=l,g=m,m=w}a=c.neg(),s=l;var A=n.sqr().add(o.sqr());return a.sqr().add(s.sqr()).cmp(A)>=0&&(a=t,s=r),n.negative&&(n=n.neg(),o=o.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:n,b:o},{a,b:s}]},u.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=n.fromRed().isOdd();return(t&&!o||!t&&o)&&(n=n.redNeg()),this.point(e,n)},u.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},u.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},c.prototype.isInfinity=function(){return this.inf},c.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},c.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},c.prototype.getX=function(){return this.x.fromRed()},c.prototype.getY=function(){return this.y.fromRed()},c.prototype.mul=function(e){return e=new i(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},c.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},c.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},c.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},c.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(l,a.BasePoint),u.prototype.jpoint=function(e,t,r){return new l(this,e,t,r)},l.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},l.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},l.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},l.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},l.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},l.prototype.inspect=function(){return this.isInfinity()?"":""},l.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},506:(e,t,r)=>{"use strict";var n,i=t,o=r(7198),a=r(6063),s=r(7528).assert;function u(e){"short"===e.type?this.curve=new a.short(e):"edwards"===e.type?this.curve=new a.edwards(e):this.curve=new a.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,s(this.g.validate(),"Invalid curve"),s(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(i,e,{configurable:!0,enumerable:!0,get:function(){var r=new u(t);return Object.defineProperty(i,e,{configurable:!0,enumerable:!0,value:r}),r}})}i.PresetCurve=u,c("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:o.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("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:o.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("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:o.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("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:o.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"]}),c("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:o.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"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["9"]}),c("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:o.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{n=r(6401)}catch(e){n=void 0}c("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:o.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",n]})},8320:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(9410),a=r(7528),s=r(506),u=r(2202),c=a.assert,l=r(7791),f=r(488);function h(e){if(!(this instanceof h))return new h(e);"string"==typeof e&&(c(Object.prototype.hasOwnProperty.call(s,e),"Unknown curve "+e),e=s[e]),e instanceof s.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=h,h.prototype.keyPair=function(e){return new l(this,e)},h.prototype.keyFromPrivate=function(e,t){return l.fromPrivate(this,e,t)},h.prototype.keyFromPublic=function(e,t){return l.fromPublic(this,e,t)},h.prototype.genKeyPair=function(e){e||(e={});for(var t=new o({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||u(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new i(2));;){var a=new i(t.generate(r));if(!(a.cmp(n)>0))return a.iaddn(1),this.keyFromPrivate(a)}},h.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},h.prototype.sign=function(e,t,r,a){"object"===(0,n.default)(r)&&(a=r,r=null),a||(a={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new i(e,16));for(var s=this.n.byteLength(),u=t.getPrivate().toArray("be",s),c=e.toArray("be",s),l=new o({hash:this.hash,entropy:u,nonce:c,pers:a.pers,persEnc:a.persEnc||"utf8"}),h=this.n.sub(new i(1)),d=0;;d++){var p=a.k?a.k(d):new i(l.generate(this.n.byteLength()));if(!((p=this._truncateToN(p,!0)).cmpn(1)<=0||p.cmp(h)>=0)){var m=this.g.mul(p);if(!m.isInfinity()){var y=m.getX(),g=y.umod(this.n);if(0!==g.cmpn(0)){var b=p.invm(this.n).mul(g.mul(t.getPrivate()).iadd(e));if(0!==(b=b.umod(this.n)).cmpn(0)){var v=(m.getY().isOdd()?1:0)|(0!==y.cmp(g)?2:0);return a.canonical&&b.cmp(this.nh)>0&&(b=this.n.sub(b),v^=1),new f({r:g,s:b,recoveryParam:v})}}}}}},h.prototype.verify=function(e,t,r,n){e=this._truncateToN(new i(e,16)),r=this.keyFromPublic(r,n);var o=(t=new f(t,"hex")).r,a=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),c=u.mul(e).umod(this.n),l=u.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(c,r.getPublic(),l)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(c,r.getPublic(),l)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},h.prototype.recoverPubKey=function(e,t,r,n){c((3&r)===r,"The recovery param is more than two bits"),t=new f(t,n);var o=this.n,a=new i(e),s=t.r,u=t.s,l=1&r,h=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&h)throw new Error("Unable to find sencond key candinate");s=h?this.curve.pointFromX(s.add(this.curve.n),l):this.curve.pointFromX(s,l);var d=t.r.invm(o),p=o.sub(a).mul(d).umod(o),m=u.mul(d).umod(o);return this.g.mulAdd(p,s,m)},h.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new f(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")}},7791:(e,t,r)=>{"use strict";var n=r(1734),i=r(7528).assert;function o(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=o,o.fromPublic=function(e,t,r){return t instanceof o?t:new o(e,{pub:t,pubEnc:r})},o.fromPrivate=function(e,t,r){return t instanceof o?t:new o(e,{priv:t,privEnc:r})},o.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.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"}},o.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},o.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},o.prototype._importPrivate=function(e,t){this.priv=new n(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},o.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?i(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||i(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},o.prototype.derive=function(e){return e.validate()||i(e.validate(),"public point not validated"),e.mul(this.priv).getX()},o.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},o.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},o.prototype.inspect=function(){return""}},488:(e,t,r)=>{"use strict";var n=r(1734),i=r(7528),o=i.assert;function a(e,t){if(e instanceof a)return e;this._importDER(e,t)||(o(e.r&&e.s,"Signature without r or s"),this.r=new n(e.r,16),this.s=new n(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function s(){this.place=0}function u(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function c(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}e.exports=a,a.prototype._importDER=function(e,t){e=i.toArray(e,t);var r=new s;if(48!==e[r.place++])return!1;var o=u(e,r);if(!1===o)return!1;if(o+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var a=u(e,r);if(!1===a)return!1;var c=e.slice(r.place,a+r.place);if(r.place+=a,2!==e[r.place++])return!1;var l=u(e,r);if(!1===l)return!1;if(e.length!==l+r.place)return!1;var f=e.slice(r.place,l+r.place);if(0===c[0]){if(!(128&c[1]))return!1;c=c.slice(1)}if(0===f[0]){if(!(128&f[1]))return!1;f=f.slice(1)}return this.r=new n(c),this.s=new n(f),this.recoveryParam=null,!0},a.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=c(t),r=c(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];l(n,t.length),(n=n.concat(t)).push(2),l(n,r.length);var o=n.concat(r),a=[48];return l(a,o.length),a=a.concat(o),i.encode(a,e)}},8027:(e,t,r)=>{"use strict";var n=r(7198),i=r(506),o=r(7528),a=o.assert,s=o.parseBytes,u=r(7303),c=r(6646);function l(e){if(a("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof l))return new l(e);e=i[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=n.sha512}e.exports=l,l.prototype.sign=function(e,t){e=s(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),o=this.encodePoint(i),a=this.hashInt(o,r.pubBytes(),e).mul(r.priv()),u=n.add(a).umod(this.curve.n);return this.makeSignature({R:i,S:u,Rencoded:o})},l.prototype.verify=function(e,t,r){e=s(e),t=this.makeSignature(t);var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),o=this.g.mul(t.S());return t.R().add(n.pub().mul(i)).eq(o)},l.prototype.hashInt=function(){for(var e=this.hash(),t=0;t{"use strict";var n=r(7528),i=n.assert,o=n.parseBytes,a=n.cachedProperty;function s(e,t){this.eddsa=e,this._secret=o(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=o(t.pub)}s.fromPublic=function(e,t){return t instanceof s?t:new s(e,{pub:t})},s.fromSecret=function(e,t){return t instanceof s?t:new s(e,{secret:t})},s.prototype.secret=function(){return this._secret},a(s,"pubBytes",(function(){return this.eddsa.encodePoint(this.pub())})),a(s,"pub",(function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())})),a(s,"privBytes",(function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n})),a(s,"priv",(function(){return this.eddsa.decodeInt(this.privBytes())})),a(s,"hash",(function(){return this.eddsa.hash().update(this.secret()).digest()})),a(s,"messagePrefix",(function(){return this.hash().slice(this.eddsa.encodingLength)})),s.prototype.sign=function(e){return i(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},s.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},s.prototype.getSecret=function(e){return i(this._secret,"KeyPair is public only"),n.encode(this.secret(),e)},s.prototype.getPublic=function(e){return n.encode(this.pubBytes(),e)},e.exports=s},6646:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(7528),a=o.assert,s=o.cachedProperty,u=o.parseBytes;function c(e,t){this.eddsa=e,"object"!==(0,n.default)(t)&&(t=u(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),a(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof i&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}s(c,"S",(function(){return this.eddsa.decodeInt(this.Sencoded())})),s(c,"R",(function(){return this.eddsa.decodePoint(this.Rencoded())})),s(c,"Rencoded",(function(){return this.eddsa.encodePoint(this.R())})),s(c,"Sencoded",(function(){return this.eddsa.encodeInt(this.S())})),c.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},c.prototype.toHex=function(){return o.encode(this.toBytes(),"hex").toUpperCase()},e.exports=c},6401:e=>{"use strict";e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},7528:(e,t,r)=>{"use strict";var n=t,i=r(1734),o=r(4504),a=r(6580);n.assert=o,n.toArray=a.toArray,n.zero2=a.zero2,n.toHex=a.toHex,n.encode=a.encode,n.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!=(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!=(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"==typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new i(e,"hex","le")}},6464:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=function(){if("object"===("undefined"==typeof self?"undefined":(0,n.default)(self))&&self)return self;if("object"===("undefined"==typeof window?"undefined":(0,n.default)(window))&&window)return window;throw new Error("Unable to resolve global `this`")};e.exports=function(){if(this)return this;if("object"===("undefined"==typeof globalThis?"undefined":(0,n.default)(globalThis))&&globalThis)return globalThis;try{Object.defineProperty(Object.prototype,"__global__",{get:function(){return this},configurable:!0})}catch(e){return i()}try{return __global__||i()}finally{delete Object.prototype.__global__}}()},4258:(e,t,r)=>{"use strict";var n,i,o,a=r(9142),s=r(8847)(r(3355));o=function(){function e(e){return"function"==typeof e}var t=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},n=0,i=void 0,o=void 0,u=function(e,t){m[n]=e,m[n+1]=t,2===(n+=2)&&(o?o(y):A())},c="undefined"!=typeof window?window:void 0,l=c||{},f=l.MutationObserver||l.WebKitMutationObserver,h="undefined"==typeof self&&void 0!==a&&"[object process]"==={}.toString.call(a),d="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function p(){var e=setTimeout;return function(){return e(y,1)}}var m=new Array(1e3);function y(){for(var e=0;e{"use strict";var n=r(9033).Buffer,i=r(4858).keccak_256,o=r(3956);function a(e){return e?o.toUnicode(e,{useStd3ASCII:!0,transitional:!1}):e}t.hash=function(e){for(var t="",r=0;r<32;r++)t+="00";if(name=a(e),name){var o=name.split(".");for(r=o.length-1;r>=0;r--){var s=i(o[r]);t=i(new n(t+s,"hex"))}}return"0x"+t},t.normalize=a},3058:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847)(r(4519)),o=r(6851),a=r(9733),s=r(6597),u=(r(6740),new s.ec("secp256k1")),c=r(2922),l=c.keccak256,f=c.keccak256s,h=function(e){for(var t=f(e.slice(2)),r="0x",n=0;n<40;n++)r+=parseInt(t[n+2],16)>7?e[n+2].toUpperCase():e[n+2];return r},d=function(e){var t=new n(e.slice(2),"hex"),r="0x"+u.keyFromPrivate(t).getPublic(!1,"hex").slice(2),i=l(r);return{address:h("0x"+i.slice(-40)),privateKey:e}},p=function(e){var t=(0,i.default)(e,3),r=t[0],n=t[1],a=t[2];return o.flatten([n,a,r])},m=function(e){return[o.slice(64,o.length(e),e),o.slice(0,32,e),o.slice(32,64,e)]},y=function(e){return function(t,r){var i=u.keyFromPrivate(new n(r.slice(2),"hex")).sign(new n(t.slice(2),"hex"),{canonical:!0});return p([a.fromString(o.fromNumber(e+i.recoveryParam)),o.pad(32,o.fromNat("0x"+i.r.toString(16))),o.pad(32,o.fromNat("0x"+i.s.toString(16)))])}},g=y(27);e.exports={create:function(e){var t=l(o.concat(o.random(32),e||o.random(32))),r=o.concat(o.concat(o.random(32),t),o.random(32)),n=l(r);return d(n)},toChecksum:h,fromPrivate:d,sign:g,makeSigner:y,recover:function(e,t){var r=m(t),i={v:o.toNumber(r[0]),r:r[1].slice(2),s:r[2].slice(2)},a="0x"+u.recoverPubKey(new n(e.slice(2),"hex"),i,i.v<2?i.v:1-i.v%2).encode("hex",!1).slice(2),s=l(a);return h("0x"+s.slice(-40))},encodeSignature:p,decodeSignature:m}},1376:e=>{"use strict";var t=function(e,t){for(var r=[],n=0;n{"use strict";r(1376);var n=function(e,t){return parseInt(e.slice(2*t+2,2*t+4),16)},i=function(e){return(e.length-2)/2},o=function(e){for(var t=[],r=2,n=e.length;r>6|192);else{if(i>55295&&i<56320){if(++n==e.length)return null;var o=e.charCodeAt(n);if(o<56320||o>57343)return null;r+=t((i=65536+((1023&i)<<10)+(1023&o))>>18|240),r+=t(i>>12&63|128)}else r+=t(i>>12|224);r+=t(i>>6&63|128)}r+=t(63&i|128)}}return r},toString:function(e){for(var t="",r=0,o=i(e);r127){if(a>191&&a<224){if(r>=o)return null;a=(31&a)<<6|63&n(e,r)}else if(a>223&&a<240){if(r+1>=o)return null;a=(15&a)<<12|(63&n(e,r))<<6|63&n(e,++r)}else{if(!(a>239&&a<248))return null;if(r+2>=o)return null;a=(7&a)<<18|(63&n(e,r))<<12|(63&n(e,++r))<<6|63&n(e,++r)}++r}if(a<=65535)t+=String.fromCharCode(a);else{if(!(a<=1114111))return null;a-=65536,t+=String.fromCharCode(a>>10|55296),t+=String.fromCharCode(1023&a|56320)}}return t},fromNumber:function(e){var t=e.toString(16);return t.length%2==0?"0x"+t:"0x0"+t},toNumber:function(e){return parseInt(e.slice(2),16)},fromNat:function(e){return"0x0"===e?"0x":e.length%2==0?e:"0x0"+e.slice(2)},toNat:function(e){return"0"===e[2]?"0x"+e.slice(3):e},fromArray:a,toArray:o,fromUint8Array:function(e){return a([].slice.call(e,0))},toUint8Array:function(e){return new Uint8Array(o(e))}}},2922:e=>{"use strict";var t="0123456789abcdef".split(""),r=[1,256,65536,16777216],n=[0,8,16,24],i=[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],o=function(e){var t,r,n,o,a,s,u,c,l,f,h,d,p,m,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)o=e[0]^e[10]^e[20]^e[30]^e[40],a=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],u=e[3]^e[13]^e[23]^e[33]^e[43],c=e[4]^e[14]^e[24]^e[34]^e[44],l=e[5]^e[15]^e[25]^e[35]^e[45],f=e[6]^e[16]^e[26]^e[36]^e[46],h=e[7]^e[17]^e[27]^e[37]^e[47],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(s<<1|u>>>31),r=(p=e[9]^e[19]^e[29]^e[39]^e[49])^(u<<1|s>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=o^(c<<1|l>>>31),r=a^(l<<1|c>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=s^(f<<1|h>>>31),r=u^(h<<1|f>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=c^(d<<1|p>>>31),r=l^(p<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=f^(o<<1|a>>>31),r=h^(a<<1|o>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=m^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&m,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~m&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=i[n],e[1]^=i[n+1]},a=function(e){return function(i){var a;if("0x"===i.slice(0,2)){a=[];for(var s=2,u=i.length;s>2]|=i[d]<>2]|=a<>2]|=(192|a>>6)<>2]|=(128|63&a)<=57344?(u[y>>2]|=(224|a>>12)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<>2]|=(240|a>>18)<>2]|=(128|a>>12&63)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<=c){for(e.start=y-c,e.block=u[l],y=0;y>2]|=r[3&y],e.lastByteIndex===c)for(u[0]=u[l],y=1;y>4&15]+t[15&p]+t[p>>12&15]+t[p>>8&15]+t[p>>20&15]+t[p>>16&15]+t[p>>28&15]+t[p>>24&15];g%l==0&&(o(h),y=0)}return"0x"+m}(function(e){return{blocks:[],reset:!0,block:0,start:0,blockCount:1600-(e<<1)>>5,outputBlocks:e>>5,s:(t=[0,0,0,0,0,0,0,0,0,0],[].concat(t,t,t,t,t))};var t}(e),a)}};e.exports={keccak256:a(256),keccak512:a(512),keccak256s:a(256),keccak512s:a(512)}},9733:(e,t,r)=>{"use strict";var n=r(1734),i=r(6851),o=function(e){return new n(e.slice(2),16)},a=function(e){var t="0x"+("0x"===e.slice(0,2)?new n(e.slice(2),16):new n(e,10)).toString("hex");return"0x0"===t?"0x":t},s=function(e){return"string"==typeof e?/^0x/.test(e)?e:"0x"+e:"0x"+new n(e).toString("hex")},u=function(e){return o(e).toNumber()},c=function(e){return function(t,r){return"0x"+o(t)[e](o(r)).toString("hex")}},l=c("add"),f=c("mul"),h=c("div"),d=c("sub");e.exports={toString:function(e){return o(e).toString(10)},fromString:a,toNumber:u,fromNumber:s,toEther:function(e){return u(h(e,a("10000000000")))/1e8},fromEther:function(e){return f(s(Math.floor(1e8*e)),a("10000000000"))},toUint256:function(e){return i.pad(32,e)},add:l,mul:f,div:h,sub:d}},6740:e=>{"use strict";e.exports={encode:function(e){var t=function(e){return(t=e.toString(16)).length%2==0?t:"0"+t;var t},r=function(e,r){return e<56?t(r+e):t(r+t(e).length/2+55)+t(e)};return"0x"+function e(t){if("string"==typeof t){var n=t.slice(2);return(2!=n.length||n>="80"?r(n.length/2,128):"")+n}var i=t.map(e).join("");return r(i.length/2,192)+i}(e)},decode:function(e){var t=2,r=function(){if(t>=e.length)throw"";var r=e.slice(t,t+2);return r<"80"?(t+=2,"0x"+r):r<"c0"?i():o()},n=function(){var r=parseInt(e.slice(t,t+=2),16)%64;return r<56?r:parseInt(e.slice(t,t+=2*(r-55)),16)},i=function(){var r=n();return"0x"+e.slice(t,t+=2*r)},o=function(){for(var e=2*n()+t,i=[];t{"use strict";var n=r(8847)(r(3355));Object.defineProperty(t,"__esModule",{value:!0});var i=r(8179);function o(e){return!("string"!=typeof e||!/^(0x)?[0-9a-f]{512}$/i.test(e)||!/^(0x)?[0-9a-f]{512}$/.test(e)&&!/^(0x)?[0-9A-F]{512}$/.test(e))}function a(e,t){"object"===(0,n.default)(t)&&t.constructor===Uint8Array&&(t=i.bytesToHex(t));for(var r=i.keccak256(t).replace("0x",""),o=0;o<12;o+=4){var a=(parseInt(r.substr(o,2),16)<<8)+parseInt(r.substr(o+2,2),16)&2047,u=1<=48&&e<=57)return e-48;if(e>=65&&e<=70)return e-55;if(e>=97&&e<=102)return e-87;throw new Error("invalid bloom")}function u(e){return!("string"!=typeof e||!/^(0x)?[0-9a-f]{64}$/i.test(e)||!/^(0x)?[0-9a-f]{64}$/.test(e)&&!/^(0x)?[0-9A-F]{64}$/.test(e))}function c(e){return!("string"!=typeof e||!e.match(/^(0x)?[0-9a-fA-F]{40}$/)&&!e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/))}t.isBloom=o,t.isInBloom=a,t.isUserEthereumAddressInBloom=function(e,t){if(!o(e))throw new Error("Invalid bloom given");if(!c(t))throw new Error('Invalid ethereum address given: "'.concat(t,'"'));return a(e,i.padLeft(t,64))},t.isContractAddressInBloom=function(e,t){if(!o(e))throw new Error("Invalid bloom given");if(!c(t))throw new Error('Invalid contract address given: "'.concat(t,'"'));return a(e,t)},t.isTopicInBloom=function(e,t){if(!o(e))throw new Error("Invalid bloom given");if(!u(t))throw new Error("Invalid topic");return a(e,t)},t.isTopic=u,t.isAddress=c},8179:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7286);function i(e){if(null==e)throw new Error("cannot convert null value to array");if("string"==typeof e){var t=e.match(/^(0x)?[0-9a-fA-F]*$/);if(!t)throw new Error("invalid hexidecimal string");if("0x"!==t[1])throw new Error("hex string must have 0x prefix");(e=e.substring(2)).length%2&&(e="0"+e);for(var r=[],n=0;n=256||parseInt(String(r))!=r)return!1}return!0}(e))return o(new Uint8Array(e));throw new Error("invalid arrayify value")}function o(e){var t=arguments;return void 0!==e.slice||(e.slice=function(){var r=Array.prototype.slice.call(t);return o(new Uint8Array(Array.prototype.slice.apply(e,r)))}),e}t.keccak256=function(e){return"0x"+n.keccak_256(i(e))},t.padLeft=function(e,t){var r=/^0x/i.test(e)||"number"==typeof e,n=t-(e=e.toString().replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(r?"0x":"")+new Array(n).join("0")+e},t.bytesToHex=function(e){for(var t=[],r=0;r>>4).toString(16)),t.push((15&e[r]).toString(16));return"0x".concat(t.join("").replace(/^0+/,""))},t.toByteArray=i},7286:(e,t,r)=>{"use strict";e=r.nmd(e);var n,i=r(9142),o=r(8847)(r(3355));!function(){var a="input is invalid type",s="object"===("undefined"==typeof window?"undefined":(0,o.default)(window)),u=s?window:{};u.JS_SHA3_NO_WINDOW&&(s=!1);var c=!s&&"object"===("undefined"==typeof self?"undefined":(0,o.default)(self));!u.JS_SHA3_NO_NODE_JS&&"object"===(void 0===i?"undefined":(0,o.default)(i))&&i.versions&&i.versions.node?u=r.g:c&&(u=self);var l=!u.JS_SHA3_NO_COMMON_JS&&"object"===(0,o.default)(e)&&e.exports,f=r.amdO,h=!u.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,d="0123456789abcdef".split(""),p=[4,1024,262144,67108864],m=[0,8,16,24],y=[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],g=[224,256,384,512],b=[128,256],v=["hex","buffer","arrayBuffer","array","digest"],w={128:168,256:136};!u.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!h||!u.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===(0,o.default)(e)&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var A=function(e,t,r){return function(n){return new L(e,t,e).update(n)[r]()}},S=function(e,t,r){return function(n,i){return new L(e,t,i).update(n)[r]()}},k=function(e,t,r){return function(t,n,i,o){return x["cshake"+e].update(t,n,i,o)[r]()}},E=function(e,t,r){return function(t,n,i,o){return x["kmac"+e].update(t,n,i,o)[r]()}},_=function(e,t,r,n){for(var i=0;i>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function U(e,t,r){L.call(this,e,t,r)}L.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}for(var n,i,s=this.blocks,u=this.byteCount,c=e.length,l=this.blockCount,f=0,d=this.s;f>2]|=e[f]<>2]|=i<>2]|=(192|i>>6)<>2]|=(128|63&i)<=57344?(s[n>>2]|=(224|i>>12)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<>2]|=(240|i>>18)<>2]|=(128|i>>12&63)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<=u){for(this.start=n-u,this.block=s[l],n=0;n>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},L.prototype.encodeString=function(e){var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}var n=0,i=e.length;if(t)n=i;else for(var s=0;s=57344?n+=3:(u=65536+((1023&u)<<10|1023&e.charCodeAt(++s)),n+=4)}return n+=this.encode(8*n),this.update(e),n},L.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+d[15&e]+d[e>>12&15]+d[e>>8&15]+d[e>>20&15]+d[e>>16&15]+d[e>>28&15]+d[e>>24&15];a%t==0&&(F(r),o=0)}return i&&(e=r[o],s+=d[e>>4&15]+d[15&e],i>1&&(s+=d[e>>12&15]+d[e>>8&15]),i>2&&(s+=d[e>>20&15]+d[e>>16&15])),s},L.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&F(n)}return o&&(e=s<<2,t=n[a],u[e]=255&t,o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u},U.prototype=new L,U.prototype.finalize=function(){return this.encode(this.outputBits,!0),L.prototype.finalize.call(this)};var F=function(e){var t,r,n,i,o,a,s,u,c,l,f,h,d,p,m,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],u=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],l=e[6]^e[16]^e[26]^e[36]^e[46],f=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(d=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|c>>>31),r=o^(c<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(l<<1|f>>>31),r=s^(f<<1|l>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(h<<1|d>>>31),r=c^(d<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=l^(i<<1|o>>>31),r=f^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],m=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=p^~g&v,e[1]=m^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&p,e[7]=S^~E&m,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~p&g,e[9]=E^~m&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=y[n],e[1]^=y[n+1]};if(l)e.exports=x;else{for(I=0;I{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.createHashFunction=function(e){return function(t){var r=e();return r.update(t),n.from(r.digest())}}},1243:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9989),i=r(3135);t.keccak224=n.createHashFunction((function(){return i("keccak224")})),t.keccak256=n.createHashFunction((function(){return i("keccak256")})),t.keccak384=n.createHashFunction((function(){return i("keccak384")})),t.keccak512=n.createHashFunction((function(){return i("keccak512")}))},4893:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(5010);t.getRandomBytes=function(e){return new Promise((function(t,r){n(e,(function(e,n){e?r(e):t(n)}))}))},t.getRandomBytesSync=function(e){return n(e)}},6992:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7902),i=r(4893);t.createPrivateKey=function(){return e=this,r=function(){var e;return function(e,t){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.isZeroAddress=t.zeroAddress=t.importPublic=t.privateToAddress=t.privateToPublic=t.publicToAddress=t.pubToAddress=t.isValidPublic=t.isValidPrivate=t.generateAddress2=t.generateAddress=t.isValidChecksumAddress=t.toChecksumAddress=t.isValidAddress=t.Account=void 0;var i,o=(i=r(3894))&&i.__esModule?i:{default:i},a=r(9100),s=r(6992),u=r(3271),c=r(986),l=r(3464),f=r(9808),h=r(5725),d=r(5513),p=function(){function e(e,t,r,n){void 0===e&&(e=new a.BN(0)),void 0===t&&(t=new a.BN(0)),void 0===r&&(r=c.KECCAK256_RLP),void 0===n&&(n=c.KECCAK256_NULL),this.nonce=e,this.balance=t,this.stateRoot=r,this.codeHash=n,this._validate()}return e.fromAccountData=function(t){var r=t.nonce,n=t.balance,i=t.stateRoot,o=t.codeHash;return new e(r?new a.BN((0,l.toBuffer)(r)):void 0,n?new a.BN((0,l.toBuffer)(n)):void 0,i?(0,l.toBuffer)(i):void 0,o?(0,l.toBuffer)(o):void 0)},e.fromRlpSerializedAccount=function(e){var t=a.rlp.decode(e);if(!Array.isArray(t))throw new Error("Invalid serialized account input. Must be array");return this.fromValuesArray(t)},e.fromValuesArray=function(t){var r=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(t,4),n=r[0],i=r[1],o=r[2],s=r[3];return new e(new a.BN(n),new a.BN(i),o,s)},e.prototype._validate=function(){if(this.nonce.lt(new a.BN(0)))throw new Error("nonce must be greater than zero");if(this.balance.lt(new a.BN(0)))throw new Error("balance must be greater than zero");if(32!==this.stateRoot.length)throw new Error("stateRoot must have a length of 32");if(32!==this.codeHash.length)throw new Error("codeHash must have a length of 32")},e.prototype.raw=function(){return[(0,d.bnToUnpaddedBuffer)(this.nonce),(0,d.bnToUnpaddedBuffer)(this.balance),this.stateRoot,this.codeHash]},e.prototype.serialize=function(){return a.rlp.encode(this.raw())},e.prototype.isContract=function(){return!this.codeHash.equals(c.KECCAK256_NULL)},e.prototype.isEmpty=function(){return this.balance.isZero()&&this.nonce.isZero()&&this.codeHash.equals(c.KECCAK256_NULL)},e}();t.Account=p,t.isValidAddress=function(e){try{(0,h.assertIsString)(e)}catch(e){return!1}return/^0x[0-9a-fA-F]{40}$/.test(e)},t.toChecksumAddress=function(e,t){(0,h.assertIsHexString)(e);var r=(0,u.stripHexPrefix)(e).toLowerCase(),n="";t&&(n=(0,d.toType)(t,d.TypeOutput.BN).toString()+"0x");for(var i=(0,f.keccakFromString)(n+r).toString("hex"),o="0x",a=0;a=8?o+=r[a].toUpperCase():o+=r[a];return o},t.isValidChecksumAddress=function(e,r){return(0,t.isValidAddress)(e)&&(0,t.toChecksumAddress)(e,r)===e},t.generateAddress=function(e,t){(0,h.assertIsBuffer)(e),(0,h.assertIsBuffer)(t);var r=new a.BN(t);return r.isZero()?(0,f.rlphash)([e,null]).slice(-20):(0,f.rlphash)([e,n.from(r.toArray())]).slice(-20)},t.generateAddress2=function(e,t,r){return(0,h.assertIsBuffer)(e),(0,h.assertIsBuffer)(t),(0,h.assertIsBuffer)(r),(0,o.default)(20===e.length),(0,o.default)(32===t.length),(0,f.keccak256)(n.concat([n.from("ff","hex"),e,t,(0,f.keccak256)(r)])).slice(-20)},t.isValidPrivate=function(e){return(0,s.privateKeyVerify)(e)},t.isValidPublic=function(e,t){return void 0===t&&(t=!1),(0,h.assertIsBuffer)(e),64===e.length?(0,s.publicKeyVerify)(n.concat([n.from([4]),e])):!!t&&(0,s.publicKeyVerify)(e)},t.pubToAddress=function(e,t){return void 0===t&&(t=!1),(0,h.assertIsBuffer)(e),t&&64!==e.length&&(e=n.from((0,s.publicKeyConvert)(e,!1).slice(1))),(0,o.default)(64===e.length),(0,f.keccak)(e).slice(-20)},t.publicToAddress=t.pubToAddress,t.privateToPublic=function(e){return(0,h.assertIsBuffer)(e),n.from((0,s.publicKeyCreate)(e,!1)).slice(1)},t.privateToAddress=function(e){return(0,t.publicToAddress)((0,t.privateToPublic)(e))},t.importPublic=function(e){return(0,h.assertIsBuffer)(e),64!==e.length&&(e=n.from((0,s.publicKeyConvert)(e,!1).slice(1))),e},t.zeroAddress=function(){var e=(0,l.zeros)(20);return(0,l.bufferToHex)(e)},t.isZeroAddress=function(e){try{(0,h.assertIsString)(e)}catch(e){return!1}return(0,t.zeroAddress)()===e}},1984:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.Address=void 0;var i,o=(i=r(3894))&&i.__esModule?i:{default:i},a=r(9100),s=r(3464),u=r(1968),c=function(){function e(e){(0,o.default)(20===e.length,"Invalid address length"),this.buf=e}return e.zero=function(){return new e((0,s.zeros)(20))},e.fromString=function(t){return(0,o.default)((0,u.isValidAddress)(t),"Invalid address"),new e((0,s.toBuffer)(t))},e.fromPublicKey=function(t){return(0,o.default)(n.isBuffer(t),"Public key should be Buffer"),new e((0,u.pubToAddress)(t))},e.fromPrivateKey=function(t){return(0,o.default)(n.isBuffer(t),"Private key should be Buffer"),new e((0,u.privateToAddress)(t))},e.generate=function(t,r){return(0,o.default)(a.BN.isBN(r)),new e((0,u.generateAddress)(t.buf,r.toArrayLike(n)))},e.generate2=function(t,r,i){return(0,o.default)(n.isBuffer(r)),(0,o.default)(n.isBuffer(i)),new e((0,u.generateAddress2)(t.buf,r,i))},e.prototype.equals=function(e){return this.buf.equals(e.buf)},e.prototype.isZero=function(){return this.equals(e.zero())},e.prototype.isPrecompileOrSystemAddress=function(){var e=new a.BN(this.buf),t=new a.BN(0),r=new a.BN("ffff","hex");return e.gte(t)&&e.lte(r)},e.prototype.toString=function(){return"0x"+this.buf.toString("hex")},e.prototype.toBuffer=function(){return n.from(this.buf)},e}();t.Address=c},3464:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a};Object.defineProperty(t,"__esModule",{value:!0}),t.bufArrToArr=t.arrToBufArr=t.validateNoLeadingZeroes=t.baToJSON=t.toUtf8=t.addHexPrefix=t.toUnsigned=t.fromSigned=t.bufferToHex=t.bufferToInt=t.toBuffer=t.unpadHexString=t.unpadArray=t.unpadBuffer=t.setLengthRight=t.setLengthLeft=t.zeros=t.intToBuffer=t.intToHex=void 0;var o=r(9100),a=r(3271),s=r(5725);t.intToHex=function(e){if(!Number.isSafeInteger(e)||e<0)throw new Error("Received an invalid integer type: ".concat(e));return"0x".concat(e.toString(16))},t.intToBuffer=function(e){var r=(0,t.intToHex)(e);return n.from((0,a.padToEven)(r.slice(2)),"hex")},t.zeros=function(e){return n.allocUnsafe(e).fill(0)};var u=function(e,r,n){var i=(0,t.zeros)(r);return n?e.length0&&"0"===t.toString();)t=(e=e.slice(1))[0];return e};t.unpadBuffer=function(e){return(0,s.assertIsBuffer)(e),c(e)},t.unpadArray=function(e){return(0,s.assertIsArray)(e),c(e)},t.unpadHexString=function(e){return(0,s.assertIsHexString)(e),e=(0,a.stripHexPrefix)(e),c(e)},t.toBuffer=function(e){if(null==e)return n.allocUnsafe(0);if(n.isBuffer(e))return n.from(e);if(Array.isArray(e)||e instanceof Uint8Array)return n.from(e);if("string"==typeof e){if(!(0,a.isHexString)(e))throw new Error("Cannot convert string to buffer. toBuffer only supports 0x-prefixed hex strings and this string was given: ".concat(e));return n.from((0,a.padToEven)((0,a.stripHexPrefix)(e)),"hex")}if("number"==typeof e)return(0,t.intToBuffer)(e);if(o.BN.isBN(e)){if(e.isNeg())throw new Error("Cannot convert negative BN to buffer. Given: ".concat(e));return e.toArrayLike(n)}if(e.toArray)return n.from(e.toArray());if(e.toBuffer)return n.from(e.toBuffer());throw new Error("invalid type")},t.bufferToInt=function(e){return new o.BN((0,t.toBuffer)(e)).toNumber()},t.bufferToHex=function(e){return"0x"+(e=(0,t.toBuffer)(e)).toString("hex")},t.fromSigned=function(e){return new o.BN(e).fromTwos(256)},t.toUnsigned=function(e){return n.from(e.toTwos(256).toArray())},t.addHexPrefix=function(e){return"string"!=typeof e||(0,a.isHexPrefixed)(e)?e:"0x"+e},t.toUtf8=function(e){if((e=(0,a.stripHexPrefix)(e)).length%2!=0)throw new Error("Invalid non-even hex string input for toUtf8() provided");return n.from(e.replace(/^(00)+|(00)+$/g,""),"hex").toString("utf8")},t.baToJSON=function(e){if(n.isBuffer(e))return"0x".concat(e.toString("hex"));if(e instanceof Array){for(var r=[],i=0;i=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),o=n.next();!o.done;o=n.next()){var a=i(o.value,2),s=a[0],u=a[1];if(void 0!==u&&u.length>0&&0===u[0])throw new Error("".concat(s," cannot have leading zeroes, received: ").concat(u.toString("hex")))}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}},t.arrToBufArr=function e(t){return Array.isArray(t)?t.map((function(t){return e(t)})):n.from(t)},t.bufArrToArr=function e(t){return Array.isArray(t)?t.map((function(t){return e(t)})):Uint8Array.from(null!=t?t:[])}},986:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.KECCAK256_RLP=t.KECCAK256_RLP_S=t.KECCAK256_RLP_ARRAY=t.KECCAK256_RLP_ARRAY_S=t.KECCAK256_NULL=t.KECCAK256_NULL_S=t.TWO_POW256=t.MAX_INTEGER=t.MAX_UINT64=void 0;var n=r(9033),i=r(9100);t.MAX_UINT64=new i.BN("ffffffffffffffff",16),t.MAX_INTEGER=new i.BN("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16),t.TWO_POW256=new i.BN("10000000000000000000000000000000000000000000000000000000000000000",16),t.KECCAK256_NULL_S="c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",t.KECCAK256_NULL=n.Buffer.from(t.KECCAK256_NULL_S,"hex"),t.KECCAK256_RLP_ARRAY_S="1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",t.KECCAK256_RLP_ARRAY=n.Buffer.from(t.KECCAK256_RLP_ARRAY_S,"hex"),t.KECCAK256_RLP_S="56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",t.KECCAK256_RLP=n.Buffer.from(t.KECCAK256_RLP_S,"hex")},9100:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};Object.defineProperty(t,"__esModule",{value:!0}),t.rlp=t.BN=void 0;var o,a=(o=r(1734))&&o.__esModule?o:{default:o};t.BN=a.default;var s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t}(r(6905));t.rlp=s},9808:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.rlphash=t.ripemd160FromArray=t.ripemd160FromString=t.ripemd160=t.sha256FromArray=t.sha256FromString=t.sha256=t.keccakFromArray=t.keccakFromHexString=t.keccakFromString=t.keccak256=t.keccak=void 0;var i=r(1243),o=r(5866),a=r(9100),s=r(3464),u=r(5725);t.keccak=function(e,t){switch(void 0===t&&(t=256),(0,u.assertIsBuffer)(e),t){case 224:return(0,i.keccak224)(e);case 256:return(0,i.keccak256)(e);case 384:return(0,i.keccak384)(e);case 512:return(0,i.keccak512)(e);default:throw new Error("Invald algorithm: keccak".concat(t))}},t.keccak256=function(e){return(0,t.keccak)(e)},t.keccakFromString=function(e,r){void 0===r&&(r=256),(0,u.assertIsString)(e);var i=n.from(e,"utf8");return(0,t.keccak)(i,r)},t.keccakFromHexString=function(e,r){return void 0===r&&(r=256),(0,u.assertIsHexString)(e),(0,t.keccak)((0,s.toBuffer)(e),r)},t.keccakFromArray=function(e,r){return void 0===r&&(r=256),(0,u.assertIsArray)(e),(0,t.keccak)((0,s.toBuffer)(e),r)};var c=function(e){return e=(0,s.toBuffer)(e),o("sha256").update(e).digest()};t.sha256=function(e){return(0,u.assertIsBuffer)(e),c(e)},t.sha256FromString=function(e){return(0,u.assertIsString)(e),c(e)},t.sha256FromArray=function(e){return(0,u.assertIsArray)(e),c(e)};var l=function(e,t){e=(0,s.toBuffer)(e);var r=o("rmd160").update(e).digest();return!0===t?(0,s.setLengthLeft)(r,32):r};t.ripemd160=function(e,t){return(0,u.assertIsBuffer)(e),l(e,t)},t.ripemd160FromString=function(e,t){return(0,u.assertIsString)(e),l(e,t)},t.ripemd160FromArray=function(e,t){return(0,u.assertIsArray)(e),l(e,t)},t.rlphash=function(e){return(0,t.keccak)(a.rlp.encode(e))}},5725:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.assertIsString=t.assertIsArray=t.assertIsBuffer=t.assertIsHexString=void 0;var i=r(3271);t.assertIsHexString=function(e){if(!(0,i.isHexString)(e)){var t="This method only supports 0x-prefixed hex strings but input was: ".concat(e);throw new Error(t)}},t.assertIsBuffer=function(e){if(!n.isBuffer(e)){var t="This method only supports Buffer but input was: ".concat(e);throw new Error(t)}},t.assertIsArray=function(e){if(!Array.isArray(e)){var t="This method only supports number arrays but input was: ".concat(e);throw new Error(t)}},t.assertIsString=function(e){if("string"!=typeof e){var t="This method only supports strings but input was: ".concat(e);throw new Error(t)}}},3062:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.isHexString=t.getKeys=t.fromAscii=t.fromUtf8=t.toAscii=t.arrayContainsArray=t.getBinarySize=t.padToEven=t.stripHexPrefix=t.isHexPrefixed=void 0,i(r(986),t),i(r(1968),t),i(r(1984),t),i(r(9808),t),i(r(6081),t),i(r(3464),t),i(r(1677),t),i(r(9100),t),i(r(5513),t);var o=r(3271);Object.defineProperty(t,"isHexPrefixed",{enumerable:!0,get:function(){return o.isHexPrefixed}}),Object.defineProperty(t,"stripHexPrefix",{enumerable:!0,get:function(){return o.stripHexPrefix}}),Object.defineProperty(t,"padToEven",{enumerable:!0,get:function(){return o.padToEven}}),Object.defineProperty(t,"getBinarySize",{enumerable:!0,get:function(){return o.getBinarySize}}),Object.defineProperty(t,"arrayContainsArray",{enumerable:!0,get:function(){return o.arrayContainsArray}}),Object.defineProperty(t,"toAscii",{enumerable:!0,get:function(){return o.toAscii}}),Object.defineProperty(t,"fromUtf8",{enumerable:!0,get:function(){return o.fromUtf8}}),Object.defineProperty(t,"fromAscii",{enumerable:!0,get:function(){return o.fromAscii}}),Object.defineProperty(t,"getKeys",{enumerable:!0,get:function(){return o.getKeys}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return o.isHexString}})},3271:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847)(r(3355));function o(e){if("string"!=typeof e)throw new Error("[isHexPrefixed] input must be type 'string', received type ".concat((0,i.default)(e)));return"0"===e[0]&&"x"===e[1]}function a(e){var t=e;if("string"!=typeof t)throw new Error("[padToEven] value must be type 'string', received ".concat((0,i.default)(t)));return t.length%2&&(t="0".concat(t)),t}Object.defineProperty(t,"__esModule",{value:!0}),t.isHexString=t.getKeys=t.fromAscii=t.fromUtf8=t.toAscii=t.arrayContainsArray=t.getBinarySize=t.padToEven=t.stripHexPrefix=t.isHexPrefixed=void 0,t.isHexPrefixed=o,t.stripHexPrefix=function(e){if("string"!=typeof e)throw new Error("[stripHexPrefix] input must be type 'string', received ".concat((0,i.default)(e)));return o(e)?e.slice(2):e},t.padToEven=a,t.getBinarySize=function(e){if("string"!=typeof e)throw new Error("[getBinarySize] method requires input type 'string', recieved ".concat((0,i.default)(e)));return n.byteLength(e,"utf8")},t.arrayContainsArray=function(e,t,r){if(!0!==Array.isArray(e))throw new Error("[arrayContainsArray] method requires input 'superset' to be an array, got type '".concat((0,i.default)(e),"'"));if(!0!==Array.isArray(t))throw new Error("[arrayContainsArray] method requires input 'subset' to be an array, got type '".concat((0,i.default)(t),"'"));return t[r?"some":"every"]((function(t){return e.indexOf(t)>=0}))},t.toAscii=function(e){var t="",r=0,n=e.length;for("0x"===e.substring(0,2)&&(r=2);r{"use strict";var n=r(9033).Buffer,i=r(8847)(r(3355));Object.defineProperty(t,"__esModule",{value:!0}),t.defineProperties=void 0;var o,a=(o=r(3894))&&o.__esModule?o:{default:o},s=r(3271),u=r(9100),c=r(3464);t.defineProperties=function(e,t,r){if(e.raw=[],e._fields=[],e.toJSON=function(t){if(void 0===t&&(t=!1),t){var r={};return e._fields.forEach((function(t){r[t]="0x".concat(e[t].toString("hex"))})),r}return(0,c.baToJSON)(e.raw)},e.serialize=function(){return u.rlp.encode(e.raw)},t.forEach((function(t,r){function i(){return e.raw[r]}function o(i){"00"!==(i=(0,c.toBuffer)(i)).toString("hex")||t.allowZero||(i=n.allocUnsafe(0)),t.allowLess&&t.length?(i=(0,c.unpadBuffer)(i),(0,a.default)(t.length>=i.length,"The field ".concat(t.name," must not have more ").concat(t.length," bytes"))):t.allowZero&&0===i.length||!t.length||(0,a.default)(t.length===i.length,"The field ".concat(t.name," must have byte length of ").concat(t.length)),e.raw[r]=i}e._fields.push(t.name),Object.defineProperty(e,t.name,{enumerable:!0,configurable:!0,get:i,set:o}),t.default&&(e[t.name]=t.default),t.alias&&Object.defineProperty(e,t.alias,{enumerable:!1,configurable:!0,set:o,get:i})})),r)if("string"==typeof r&&(r=n.from((0,s.stripHexPrefix)(r),"hex")),n.isBuffer(r)&&(r=u.rlp.decode(r)),Array.isArray(r)){if(r.length>e._fields.length)throw new Error("wrong number of fields in data");r.forEach((function(t,r){e[e._fields[r]]=(0,c.toBuffer)(t)}))}else{if("object"!==(0,i.default)(r))throw new Error("invalid data");var o=Object.keys(r);t.forEach((function(t){-1!==o.indexOf(t.name)&&(e[t.name]=r[t.name]),-1!==o.indexOf(t.alias)&&(e[t.alias]=r[t.alias])}))}}},6081:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.hashPersonalMessage=t.isValidSignature=t.fromRpcSig=t.toCompactSig=t.toRpcSig=t.ecrecover=t.ecsign=void 0;var i=r(6992),o=r(9100),a=r(3464),s=r(9808),u=r(5725),c=r(5513);function l(e,t){var r=(0,c.toType)(e,c.TypeOutput.BN);if(r.eqn(0)||r.eqn(1))return(0,c.toType)(e,c.TypeOutput.BN);if(!t)return r.subn(27);var n=(0,c.toType)(t,c.TypeOutput.BN);return r.sub(n.muln(2).addn(35))}function f(e){var t=new o.BN(e);return t.eqn(0)||t.eqn(1)}t.ecsign=function(e,t,r){var o=(0,i.ecdsaSign)(e,t),a=o.signature,s=o.recid,u=n.from(a.slice(0,32)),l=n.from(a.slice(32,64));if(!r||"number"==typeof r){if(r&&!Number.isSafeInteger(r))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative input type)");return{r:u,s:l,v:r?s+(2*r+35):s+27}}return{r:u,s:l,v:(0,c.toType)(r,c.TypeOutput.BN).muln(2).addn(35).addn(s).toArrayLike(n)}},t.ecrecover=function(e,t,r,o,s){var u=n.concat([(0,a.setLengthLeft)(r,32),(0,a.setLengthLeft)(o,32)],64),c=l(t,s);if(!f(c))throw new Error("Invalid signature v value");var h=(0,i.ecdsaRecover)(u,c.toNumber(),e);return n.from((0,i.publicKeyConvert)(h,!1).slice(1))},t.toRpcSig=function(e,t,r,i){if(!f(l(e,i)))throw new Error("Invalid signature v value");return(0,a.bufferToHex)(n.concat([(0,a.setLengthLeft)(t,32),(0,a.setLengthLeft)(r,32),(0,a.toBuffer)(e)]))},t.toCompactSig=function(e,t,r,i){if(!f(l(e,i)))throw new Error("Invalid signature v value");var o=(0,c.toType)(e,c.TypeOutput.Number),s=r;return(o>28&&o%2==1||1===o||28===o)&&((s=n.from(r))[0]|=128),(0,a.bufferToHex)(n.concat([(0,a.setLengthLeft)(t,32),(0,a.setLengthLeft)(s,32)]))},t.fromRpcSig=function(e){var t,r,n,i=(0,a.toBuffer)(e);if(i.length>=65)t=i.slice(0,32),r=i.slice(32,64),n=(0,a.bufferToInt)(i.slice(64));else{if(64!==i.length)throw new Error("Invalid signature length");t=i.slice(0,32),r=i.slice(32,64),n=(0,a.bufferToInt)(i.slice(32,33))>>7,r[0]&=127}return n<27&&(n+=27),{v:n,r:t,s:r}},t.isValidSignature=function(e,t,r,n,i){void 0===n&&(n=!0);var a=new o.BN("7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0",16),s=new o.BN("fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141",16);if(32!==t.length||32!==r.length)return!1;if(!f(l(e,i)))return!1;var u=new o.BN(t),c=new o.BN(r);return!(u.isZero()||u.gt(s)||c.isZero()||c.gt(s)||n&&1===c.cmp(a))},t.hashPersonalMessage=function(e){(0,u.assertIsBuffer)(e);var t=n.from("Ethereum Signed Message:\n".concat(e.length),"utf-8");return(0,s.keccak)(n.concat([t,e]))}},5513:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.toType=t.TypeOutput=t.bnToRlp=t.bnToUnpaddedBuffer=t.bnToHex=void 0;var i,o=r(9100),a=r(3271),s=r(3464);function u(e){return(0,s.unpadBuffer)(e.toArrayLike(n))}t.bnToHex=function(e){return"0x".concat(e.toString(16))},t.bnToUnpaddedBuffer=u,t.bnToRlp=function(e){return u(e)},function(e){e[e.Number=0]="Number",e[e.BN=1]="BN",e[e.Buffer=2]="Buffer",e[e.PrefixedHexString=3]="PrefixedHexString"}(i=t.TypeOutput||(t.TypeOutput={})),t.toType=function(e,t){if(null===e)return null;if(void 0!==e){if("string"==typeof e&&!(0,a.isHexString)(e))throw new Error("A string must be provided with a 0x-prefix, given: ".concat(e));if("number"==typeof e&&!Number.isSafeInteger(e))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative input type)");var r=(0,s.toBuffer)(e);if(t===i.Buffer)return r;if(t===i.BN)return new o.BN(r);if(t===i.Number){var n=new o.BN(r),u=new o.BN(Number.MAX_SAFE_INTEGER.toString());if(n.gt(u))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative output type)");return n.toNumber()}return"0x".concat(r.toString("hex"))}}},7130:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(7277),a=new i(0),s=new i(-1),u={noether:"0",wei:"1",kwei:"1000",Kwei:"1000",babbage:"1000",femtoether:"1000",mwei:"1000000",Mwei:"1000000",lovelace:"1000000",picoether:"1000000",gwei:"1000000000",Gwei:"1000000000",shannon:"1000000000",nanoether:"1000000000",nano:"1000000000",szabo:"1000000000000",microether:"1000000000000",micro:"1000000000000",finney:"1000000000000000",milliether:"1000000000000000",milli:"1000000000000000",ether:"1000000000000000000",kether:"1000000000000000000000",grand:"1000000000000000000000",mether:"1000000000000000000000000",gether:"1000000000000000000000000000",tether:"1000000000000000000000000000000"};function c(e){var t=e?e.toLowerCase():"ether",r=u[t];if("string"!=typeof r)throw new Error("[ethjs-unit] the unit provided "+e+" doesn't exists, please use the one of the following units "+JSON.stringify(u,null,2));return new i(r,10)}function l(e){if("string"==typeof e){if(!e.match(/^-?[0-9.]+$/))throw new Error("while converting number to string, invalid number value '"+e+"', should be a number matching (^-?[0-9.]+).");return e}if("number"==typeof e)return String(e);if("object"===(0,n.default)(e)&&e.toString&&(e.toTwos||e.dividedToIntegerBy))return e.toPrecision?String(e.toPrecision()):e.toString(10);throw new Error("while converting number to string, invalid number value '"+e+"' type "+(0,n.default)(e)+".")}e.exports={unitMap:u,numberToString:l,getValueOfUnit:c,fromWei:function(e,t,r){var n=o(e),i=n.lt(a),l=c(t),f=u[t].length-1||1,h=r||{};i&&(n=n.mul(s));for(var d=n.mod(l).toString(10);d.length2)throw new Error("[ethjs-unit] while converting number "+e+" to wei, too many decimal points");var h=f[0],d=f[1];if(h||(h="0"),d||(d="0"),d.length>o)throw new Error("[ethjs-unit] while converting number "+e+" to wei, too many decimal places");for(;d.length{"use strict";var t=Object.prototype.hasOwnProperty,r="~";function n(){}function i(e,t,r){this.fn=e,this.context=t,this.once=r||!1}function o(e,t,n,o,a){if("function"!=typeof n)throw new TypeError("The listener must be a function");var s=new i(n,o||e,a),u=r?r+t:t;return e._events[u]?e._events[u].fn?e._events[u]=[e._events[u],s]:e._events[u].push(s):(e._events[u]=s,e._eventsCount++),e}function a(e,t){0==--e._eventsCount?e._events=new n:delete e._events[t]}function s(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(r=!1)),s.prototype.eventNames=function(){var e,n,i=[];if(0===this._eventsCount)return i;for(n in e=this._events)t.call(e,n)&&i.push(r?n.slice(1):n);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(e)):i},s.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,o=n.length,a=new Array(o);i{"use strict";var n=r(8847)(r(3355)),i=Object.create||function(e){var t=function(){};return t.prototype=e,new t},o=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return r},a=Function.prototype.bind||function(e){var t=this;return function(){return t.apply(e,arguments)}};function s(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=i(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0}e.exports=s,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._maxListeners=void 0;var u,c=10;try{var l={};Object.defineProperty&&Object.defineProperty(l,"x",{value:0}),u=0===l.x}catch(e){u=!1}function f(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}function h(e,t,r){if(t)e.call(r);else for(var n=e.length,i=S(e,n),o=0;o0&&u.length>a){u.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+u.length+' "'+String(t)+'" listeners added. Use emitter.setMaxListeners() to increase limit.');c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=u.length,"object"===("undefined"==typeof console?"undefined":(0,n.default)(console))&&console.warn&&console.warn("%s: %s",c.name,c.message)}}else u=s[t]=r,++e._eventsCount;return e}function b(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var e=new Array(arguments.length),t=0;t1&&(t=arguments[1]),t instanceof Error)throw t;var u=new Error('Unhandled "error" event. ('+t+")");throw u.context=t,u}if(!(r=a[e]))return!1;var c="function"==typeof r;switch(n=arguments.length){case 1:h(r,c,this);break;case 2:d(r,c,this,arguments[1]);break;case 3:p(r,c,this,arguments[1],arguments[2]);break;case 4:m(r,c,this,arguments[1],arguments[2],arguments[3]);break;default:for(i=new Array(n-1),o=1;o=0;a--)if(r[a]===t||r[a].listener===t){s=r[a].listener,o=a;break}if(o<0)return this;0===o?r.shift():function(e,t){for(var r=t,n=r+1,i=e.length;n=0;n--)this.removeListener(e,t[n]);return this},s.prototype.listeners=function(e){return w(this,e,!0)},s.prototype.rawListeners=function(e){return w(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):A.call(e,t)},s.prototype.listenerCount=A,s.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]}},7085:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(807);e.exports=function(e,t,r,o){if(n.isBuffer(e)||(e=n.from(e,"binary")),t&&(n.isBuffer(t)||(t=n.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var a=r/8,s=n.alloc(a),u=n.alloc(o||0),c=n.alloc(0);a>0||o>0;){var l=new i;l.update(c),l.update(e),t&&l.update(t),c=l.digest();var f=0;if(a>0){var h=s.length-a;f=Math.min(a,c.length),c.copy(s,h,0,f),a-=f}if(f0){var d=u.length-o,p=Math.min(o,c.length-f);c.copy(u,d,f,f+p),o-=p}}return c.fill(0),{key:s,iv:u}}},8184:(e,t,r)=>{"use strict";var n=r(1493),i=Object.prototype.toString,o=Object.prototype.hasOwnProperty,a=function(e,t,r){for(var n=0,i=e.length;n=3&&(o=r),"[object Array]"===i.call(e)?a(e,t,o):"string"==typeof e?s(e,t,o):u(e,t,o)}},3161:e=>{"use strict";var t="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,i="[object Function]";e.exports=function(e){var o=this;if("function"!=typeof o||n.call(o)!==i)throw new TypeError(t+o);for(var a,s=r.call(arguments,1),u=function(){if(this instanceof a){var t=o.apply(this,s.concat(r.call(arguments)));return Object(t)===t?t:this}return o.apply(e,s.concat(r.call(arguments)))},c=Math.max(0,o.length-s.length),l=[],f=0;f{"use strict";var n=r(3161);e.exports=Function.prototype.bind||n},7701:(e,t,r)=>{"use strict";var n,i=r(8847)(r(3355)),o=SyntaxError,a=Function,s=TypeError,u=function(e){try{return a('"use strict"; return ('+e+").constructor;")()}catch(e){}},c=Object.getOwnPropertyDescriptor;if(c)try{c({},"")}catch(e){c=null}var l=function(){throw new s},f=c?function(){try{return l}catch(e){try{return c(arguments,"callee").get}catch(e){return l}}}():l,h=r(8489)(),d=Object.getPrototypeOf||function(e){return e.__proto__},p={},m="undefined"==typeof Uint8Array?n:d(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":h?d([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":p,"%AsyncGenerator%":p,"%AsyncGeneratorFunction%":p,"%AsyncIteratorPrototype%":p,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":a,"%GeneratorFunction%":p,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":h?d(d([][Symbol.iterator]())):n,"%JSON%":"object"===("undefined"==typeof JSON?"undefined":(0,i.default)(JSON))?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&h?d((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&h?d((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":h?d(""[Symbol.iterator]()):n,"%Symbol%":h?Symbol:n,"%SyntaxError%":o,"%ThrowTypeError%":f,"%TypedArray%":m,"%TypeError%":s,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},g=function e(t){var r;if("%AsyncFunction%"===t)r=u("async function () {}");else if("%GeneratorFunction%"===t)r=u("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=u("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(r=d(i.prototype))}return y[t]=r,r},b={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},v=r(3767),w=r(1888),A=v.call(Function.call,Array.prototype.concat),S=v.call(Function.apply,Array.prototype.splice),k=v.call(Function.call,String.prototype.replace),E=v.call(Function.call,String.prototype.slice),_=v.call(Function.call,RegExp.prototype.exec),M=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,T=/\\(\\)?/g,x=function(e){var t=E(e,0,1),r=E(e,-1);if("%"===t&&"%"!==r)throw new o("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new o("invalid intrinsic syntax, expected opening `%`");var n=[];return k(e,M,(function(e,t,r,i){n[n.length]=r?k(i,T,"$1"):t||e})),n},P=function(e,t){var r,n=e;if(w(b,n)&&(n="%"+(r=b[n])[0]+"%"),w(y,n)){var i=y[n];if(i===p&&(i=g(n)),void 0===i&&!t)throw new s("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:i}}throw new o("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new s("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new s('"allowMissing" argument must be a boolean');if(null===_(/^%?[^%]*%?$/,e))throw new o("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=x(e),n=r.length>0?r[0]:"",i=P("%"+n+"%",t),a=i.name,u=i.value,l=!1,f=i.alias;f&&(n=f[0],S(r,A([0,1],f)));for(var h=1,d=!0;h=r.length){var b=c(u,p);u=(d=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:u[p]}else d=w(u,p),u=u[p];d&&!l&&(y[a]=u)}}return u}},2948:(e,t,r)=>{"use strict";var n;n="undefined"!=typeof window?window:void 0!==r.g?r.g:"undefined"!=typeof self?self:{},e.exports=n},3820:(e,t,r)=>{"use strict";var n=r(7701)("%Object.getOwnPropertyDescriptor%",!0);if(n)try{n([],"length")}catch(e){n=null}e.exports=n},8489:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i="undefined"!=typeof Symbol&&Symbol,o=r(7027);e.exports=function(){return"function"==typeof i&&"function"==typeof Symbol&&"symbol"===(0,n.default)(i("foo"))&&"symbol"===(0,n.default)(Symbol("bar"))&&o()}},7027:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"===(0,n.default)(Symbol.iterator))return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var i=Object.getOwnPropertySymbols(e);if(1!==i.length||i[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(42!==o.value||!0!==o.enumerable)return!1}return!0}},1191:(e,t,r)=>{"use strict";var n=r(7027);e.exports=function(){return n()&&!!Symbol.toStringTag}},1888:(e,t,r)=>{"use strict";var n=r(3767);e.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},2353:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(6505).Transform;function o(e){i.call(this),this._block=n.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(1736)(o,i),o.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)},o.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},o.prototype.update=function(e,t){if(function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError("Data must be a string or a buffer")}(e),this._finalized)throw new Error("Digest already called");n.isBuffer(e)||(e=n.from(e,t));for(var r=this._block,i=0;this._blockOffset+e.length-i>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},o.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=o},7198:(e,t,r)=>{"use strict";var n=t;n.utils=r(4268),n.common=r(4696),n.sha=r(9310),n.ripemd=r(9294),n.hmac=r(3201),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},4696:(e,t,r)=>{"use strict";var n=r(4268),i=r(4504);function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}t.BlockHash=o,o.prototype.update=function(e,t){if(e=n.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var i=0;i>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o{"use strict";var n=r(4268),i=r(4504);function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(n.toArray(t,r))}e.exports=o,o.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t{"use strict";var n=r(4268),i=r(4696),o=n.rotl32,a=n.sum32,s=n.sum32_3,u=n.sum32_4,c=i.BlockHash;function l(){if(!(this instanceof l))return new l;c.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function f(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function h(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function d(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}n.inherits(l,c),t.ripemd160=l,l.blockSize=512,l.outSize=160,l.hmacStrength=192,l.padLength=64,l.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],c=this.h[3],l=this.h[4],b=r,v=n,w=i,A=c,S=l,k=0;k<80;k++){var E=a(o(u(r,f(k,n,i,c),e[p[k]+t],h(k)),y[k]),l);r=l,l=c,c=o(i,10),i=n,n=E,E=a(o(u(b,f(79-k,v,w,A),e[m[k]+t],d(k)),g[k]),S),b=S,S=A,A=o(w,10),w=v,v=E}E=s(this.h[1],i,A),this.h[1]=s(this.h[2],c,S),this.h[2]=s(this.h[3],l,b),this.h[3]=s(this.h[4],r,v),this.h[4]=s(this.h[0],n,w),this.h[0]=E},l.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"little"):n.split32(this.h,"little")};var p=[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],m=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],y=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],g=[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]},9310:(e,t,r)=>{"use strict";t.sha1=r(8142),t.sha224=r(4909),t.sha256=r(7682),t.sha384=r(4532),t.sha512=r(6515)},8142:(e,t,r)=>{"use strict";var n=r(4268),i=r(4696),o=r(70),a=n.rotl32,s=n.sum32,u=n.sum32_5,c=o.ft_1,l=i.BlockHash,f=[1518500249,1859775393,2400959708,3395469782];function h(){if(!(this instanceof h))return new h;l.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}n.inherits(h,l),e.exports=h,h.blockSize=512,h.outSize=160,h.hmacStrength=80,h.padLength=64,h.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(4268),i=r(7682);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,7),"big"):n.split32(this.h.slice(0,7),"big")}},7682:(e,t,r)=>{"use strict";var n=r(4268),i=r(4696),o=r(70),a=r(4504),s=n.sum32,u=n.sum32_4,c=n.sum32_5,l=o.ch32,f=o.maj32,h=o.s0_256,d=o.s1_256,p=o.g0_256,m=o.g1_256,y=i.BlockHash,g=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function b(){if(!(this instanceof b))return new b;y.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=g,this.W=new Array(64)}n.inherits(b,y),e.exports=b,b.blockSize=512,b.outSize=256,b.hmacStrength=192,b.padLength=64,b.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(4268),i=r(6515);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,12),"big"):n.split32(this.h.slice(0,12),"big")}},6515:(e,t,r)=>{"use strict";var n=r(4268),i=r(4696),o=r(4504),a=n.rotr64_hi,s=n.rotr64_lo,u=n.shr64_hi,c=n.shr64_lo,l=n.sum64,f=n.sum64_hi,h=n.sum64_lo,d=n.sum64_4_hi,p=n.sum64_4_lo,m=n.sum64_5_hi,y=n.sum64_5_lo,g=i.BlockHash,b=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=b,this.W=new Array(160)}function w(e,t,r,n,i){var o=e&r^~e&i;return o<0&&(o+=4294967296),o}function A(e,t,r,n,i,o){var a=t&n^~t&o;return a<0&&(a+=4294967296),a}function S(e,t,r,n,i){var o=e&r^e&i^r&i;return o<0&&(o+=4294967296),o}function k(e,t,r,n,i,o){var a=t&n^t&o^n&o;return a<0&&(a+=4294967296),a}function E(e,t){var r=a(e,t,28)^a(t,e,2)^a(t,e,7);return r<0&&(r+=4294967296),r}function _(e,t){var r=s(e,t,28)^s(t,e,2)^s(t,e,7);return r<0&&(r+=4294967296),r}function M(e,t){var r=s(e,t,14)^s(e,t,18)^s(t,e,9);return r<0&&(r+=4294967296),r}function T(e,t){var r=a(e,t,1)^a(e,t,8)^u(e,t,7);return r<0&&(r+=4294967296),r}function x(e,t){var r=s(e,t,1)^s(e,t,8)^c(e,t,7);return r<0&&(r+=4294967296),r}function P(e,t){var r=s(e,t,19)^s(t,e,29)^c(e,t,6);return r<0&&(r+=4294967296),r}n.inherits(v,g),e.exports=v,v.blockSize=1024,v.outSize=512,v.hmacStrength=192,v.padLength=128,v.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(4268).rotr32;function i(e,t,r){return e&t^~e&r}function o(e,t,r){return e&t^e&r^t&r}function a(e,t,r){return e^t^r}t.ft_1=function(e,t,r,n){return 0===e?i(t,r,n):1===e||3===e?a(t,r,n):2===e?o(t,r,n):void 0},t.ch32=i,t.maj32=o,t.p32=a,t.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},t.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},t.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},4268:(e,t,r)=>{"use strict";var n=r(4504),i=r(1736);function o(e,t){return 55296==(64512&e.charCodeAt(t))&&!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1))}function a(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function s(e){return 1===e.length?"0"+e:e}function u(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=i,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),i=0;i>6|192,r[n++]=63&a|128):o(e,i)?(a=65536+((1023&a)<<10)+(1023&e.charCodeAt(++i)),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=63&a|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=63&a|128)}else for(i=0;i>>0}return a},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,n){return(t+n>>>0>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,o,a,s){var u=0,c=t;return u+=(c=c+n>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,n,i,o,a,s){return t+n+o+s>>>0},t.sum64_5_hi=function(e,t,r,n,i,o,a,s,u,c){var l=0,f=t;return l+=(f=f+n>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,n,i,o,a,s,u,c){return t+n+o+s+c>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},9410:(e,t,r)=>{"use strict";var n=r(7198),i=r(6580),o=r(4504);function a(e){if(!(this instanceof a))return new a(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=i.toArray(e.entropy,e.entropyEnc||"hex"),r=i.toArray(e.nonce,e.nonceEnc||"hex"),n=i.toArray(e.pers,e.persEnc||"hex");o(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}e.exports=a,a.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},a.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=i.toArray(r,n||"hex"),this._update(r));for(var o=[];o.length{"use strict";var n=r(9519),i=r(1143),o=e.exports;for(var a in n)n.hasOwnProperty(a)&&(o[a]=n[a]);function s(e){if("string"==typeof e&&(e=i.parse(e)),e.protocol||(e.protocol="https:"),"https:"!==e.protocol)throw new Error('Protocol "'+e.protocol+'" not supported. Expected "https:"');return e}o.request=function(e,t){return e=s(e),n.request.call(this,e,t)},o.get=function(e,t){return e=s(e),n.get.call(this,e,t)}},2996:(e,t,r)=>{"use strict";var n;r(8847)(r(3355)),void 0===(n=function(){return e=[new Uint32Array([2157250,2157314,2157378,2157442,2157506,2157570,2157634,0,2157698,2157762,2157826,2157890,2157954,0,2158018,0]),new Uint32Array([2179041,6291456,2179073,6291456,2179105,6291456,2179137,6291456,2179169,6291456,2179201,6291456,2179233,6291456,2179265,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([0,2113729,2197345,2197377,2113825,2197409,2197441,2113921,2197473,2114017,2197505,2197537,2197569,2197601,2197633,2197665]),new Uint32Array([6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,23068672,23068672,23068672,0,0,0,0,23068672]),new Uint32Array([14680064,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,14680064,14680064]),new Uint32Array([2196001,2196033,2196065,2196097,2196129,2196161,2196193,2196225,2196257,2196289,2196321,2196353,2196385,2196417,2196449,2196481]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,6291456,0,0,0,0,0]),new Uint32Array([2097281,2105921,2097729,2106081,0,2097601,2162337,2106017,2133281,2097505,2105889,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([2177025,6291456,2177057,6291456,2177089,6291456,2177121,6291456,2177153,6291456,2177185,6291456,2177217,6291456,2177249,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,0,6291456,6291456,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456]),new Uint32Array([2134435,2134531,2134627,2134723,2134723,2134819,2134819,2134915,2134915,2135011,2105987,2135107,2135203,2135299,2131587,2135395]),new Uint32Array([0,0,0,0,0,0,0,6291456,2168673,2169249,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2147906,2147970,2148034,2148098,2148162,2148226,2148290,2148354,2147906,2147970,2148034,2148098,2148162,2148226,2148290,2148354]),new Uint32Array([2125219,2125315,2152834,2152898,2125411,2152962,2153026,2125506,2125507,2125603,2153090,2153154,2153218,2153282,2153346,2105348]),new Uint32Array([2203393,6291456,2203425,6291456,2203457,6291456,2203489,6291456,6291456,6291456,6291456,2203521,6291456,2181281,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,6291456,2145538,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,6291456]),new Uint32Array([2139426,2160834,2160898,2160962,2134242,2161026,2161090,2161154,2161218,2161282,2161346,2161410,2138658,2161474,2161538,2134722]),new Uint32Array([2119939,2124930,2125026,2106658,2125218,2128962,2129058,2129154,2129250,2129346,2129442,2108866,2108770,2150466,2150530,2150594]),new Uint32Array([2201601,6291456,2201633,6291456,2201665,6291456,2201697,6291456,2201729,6291456,2201761,6291456,2201793,6291456,2201825,6291456]),new Uint32Array([2193537,2193569,2193601,2193633,2193665,2193697,2193729,2193761,2193793,2193825,2193857,2193889,2193921,2193953,2193985,2194017]),new Uint32Array([6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2190561,6291456,2190593,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2190625,6291456,2190657,6291456,23068672]),new Uint32Array([2215905,2215937,2215969,2216001,2216033,2216065,2216097,2216129,2216161,2216193,2216225,2216257,2105441,2216289,2216321,2216353]),new Uint32Array([23068672,18884130,23068672,23068672,23068672,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2191233,2191265,2191297,2191329,2191361,2191393,2191425,2117377,2191457,2191489,2191521,2191553,2191585,2191617,2191649,2117953]),new Uint32Array([2132227,2132323,2132419,2132419,2132515,2132515,2132611,2132707,2132707,2132803,2132899,2132899,2132995,2132995,2133091,2133187]),new Uint32Array([0,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,6291456,0,0]),new Uint32Array([2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,10609889,10610785,10609921,10610817,2222241]),new Uint32Array([6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0]),new Uint32Array([2219969,2157121,2157441,2157505,2157889,2157953,2220001,2158465,2158529,10575617,2156994,2157058,2129923,2130019,2157122,2157186]),new Uint32Array([6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2185249,6291456,2185281,6291456,2185313,6291456,2185345,6291456,2185377,6291456,2185409,6291456,2185441,6291456,2185473,6291456]),new Uint32Array([0,0,0,0,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,0,0,23068672,23068672,23068672,6291456,0]),new Uint32Array([2183361,6291456,2183393,6291456,2183425,6291456,2183457,6291456,2183489,6291456,2183521,6291456,2183553,6291456,2183585,6291456]),new Uint32Array([2192161,2192193,2192225,2192257,2192289,2192321,2192353,2192385,2192417,2192449,2192481,2192513,2192545,2192577,2192609,2192641]),new Uint32Array([2212001,2212033,2212065,2212097,2212129,2212161,2212193,2212225,2212257,2212289,2212321,2212353,2212385,2212417,2212449,2207265]),new Uint32Array([2249825,2249857,2249889,2249921,2249954,2250018,2250082,2250145,2250177,2250209,2250241,2250274,2250337,2250370,2250433,2250465]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2147905,2147969,2148033,2148097,2148161,2148225,2148289,2148353]),new Uint32Array([10485857,6291456,2197217,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,23068672,23068672]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2180353,2180385,2144033,2180417,2180449,2180481,2180513,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,10610209,10610465,10610241,10610753,10609857]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,0,0]),new Uint32Array([2223842,2223906,2223970,2224034,2224098,2224162,2224226,2224290,2224354,2224418,2224482,2224546,2224610,2224674,2224738,2224802]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([23068672,23068672,23068672,18923650,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,18923714,23068672,23068672]),new Uint32Array([2126179,2125538,2126275,2126371,2126467,2125634,2126563,2105603,2105604,2125346,2126659,2126755,2126851,2098179,2098181,2098182]),new Uint32Array([2227426,2227490,2227554,2227618,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2192353,2240642,2240642,2240705,2240737,2240737,2240769,2240802,2240866,2240929,2240961,2240993,2241025,2241057,2241089,2241121]),new Uint32Array([6291456,2170881,2170913,2170945,6291456,2170977,6291456,2171009,2171041,6291456,6291456,6291456,2171073,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2132226,2132514,2163586,2132610,2160386,2133090,2133186,2160450,2160514,2160578,2133570,2106178,2160642,2133858,2160706,2160770]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,10532162,10532226,10532290,10532354,10532418,10532482,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,23068672]),new Uint32Array([2098209,2108353,2108193,2108481,2170241,2111713,2105473,2105569,2105601,2112289,2112481,2098305,2108321,0,0,0]),new Uint32Array([2209121,2209153,2209185,2209217,2209249,2209281,2209313,2209345,2209377,2209409,2209441,2209473,2207265,2209505,2209537,2209569]),new Uint32Array([2189025,6291456,2189057,6291456,2189089,6291456,2189121,6291456,2189153,6291456,2189185,6291456,2189217,6291456,2189249,6291456]),new Uint32Array([2173825,2153473,2173857,2173889,2173921,2173953,2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233057]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2165764,2140004]),new Uint32Array([2215105,6291456,2215137,6291456,6291456,2215169,2215201,6291456,6291456,6291456,2215233,2215265,2215297,2215329,2215361,2215393]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,23068672,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([10505091,10505187,10505283,10505379,10505475,10505571,10505667,10505763,10505859,10505955,10506051,10506147,10506243,10506339,10506435,10506531]),new Uint32Array([2229730,2229794,2229858,2229922,2229986,2230050,2230114,2230178,2230242,2230306,2230370,2230434,2230498,2230562,2230626,2230690]),new Uint32Array([2105505,2098241,2108353,2108417,2105825,0,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177]),new Uint32Array([6291456,6291456,6291456,6291456,10502115,10502178,10502211,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456]),new Uint32Array([2190305,6291456,2190337,6291456,2190369,6291456,2190401,6291456,2190433,6291456,2190465,6291456,2190497,6291456,2190529,6291456]),new Uint32Array([2173793,2173985,2174017,6291456,2173761,2173697,6291456,2174689,6291456,2174017,2174721,6291456,6291456,2174753,2174785,2174817]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2099521,2099105,2120705,2098369,2120801,2103361,2097985,2098433,2121377,2121473,2099169,2099873,2098401,2099393,2152609,2100033]),new Uint32Array([2132898,2163842,2163906,2133282,2132034,2131938,2137410,2132802,2132706,2164866,2133282,2160578,2165186,2165186,6291456,6291456]),new Uint32Array([10500003,10500099,10500195,10500291,10500387,10500483,10500579,10500675,10500771,10500867,10500963,10501059,10501155,10501251,10501347,10501443]),new Uint32Array([2163458,2130978,2131074,2131266,2131362,2163522,2160130,2132066,2131010,2131106,2106018,2131618,2131298,2132034,2131938,2137410]),new Uint32Array([2212961,2116993,2212993,2213025,2213057,2213089,2213121,2213153,2213185,2213217,2213249,2209633,2213281,2213313,2213345,2213377]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2113729,2113825,2113921,2114017,2114113,2114209,2114305,2114401,2114497,2114593,2114689,2114785,2114881,2114977,2115073,2115169]),new Uint32Array([2238177,2238209,2238241,2238273,2238305,2238337,2238337,2217537,2238369,2238401,2238433,2238465,2215649,2238497,2238529,2238561]),new Uint32Array([2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905]),new Uint32Array([6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,0]),new Uint32Array([6291456,0,6291456,2145026,0,6291456,2145090,0,6291456,6291456,0,0,23068672,0,23068672,23068672]),new Uint32Array([2099233,2122017,2200673,2098113,2121537,2103201,2200705,2104033,2121857,2121953,2122401,2099649,2099969,2123009,2100129,2100289]),new Uint32Array([6291456,23068672,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,23068672,23068672,0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0]),new Uint32Array([2187681,2187713,2187745,2187777,2187809,2187841,2187873,2187905,2187937,2187969,2188001,2188033,2188065,2188097,2188129,2188161]),new Uint32Array([0,10554498,10554562,10554626,10554690,10554754,10554818,10554882,10554946,10555010,10555074,6291456,6291456,0,0,0]),new Uint32Array([2235170,2235234,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0]),new Uint32Array([2181153,6291456,2188897,6291456,6291456,2188929,6291456,6291456,6291456,6291456,6291456,6291456,2111905,2100865,2188961,2188993]),new Uint32Array([2100833,2100897,0,0,2101569,2101697,2101825,2101953,2102081,2102209,10575617,2187041,10502177,10489601,10489697,2112289]),new Uint32Array([6291456,2172833,6291456,2172865,2172897,2172929,2172961,6291456,2172993,6291456,2173025,6291456,2173057,6291456,2173089,6291456]),new Uint32Array([6291456,0,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,0,0,23068672,6291456,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,2190721]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,23068672,6291456,6291456]),new Uint32Array([2184993,6291456,2185025,6291456,2185057,6291456,2185089,6291456,2185121,6291456,2185153,6291456,2185185,6291456,2185217,6291456]),new Uint32Array([2115265,2115361,2115457,2115553,2115649,2115745,2115841,2115937,2116033,2116129,2116225,2116321,2150658,2150722,2200225,6291456]),new Uint32Array([2168321,6291456,2168353,6291456,2168385,6291456,2168417,6291456,2168449,6291456,2168481,6291456,2168513,6291456,2168545,6291456]),new Uint32Array([23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,0,6291456,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,2186625,0,0,6291456,6291456,2186657,2186689,2186721,2173505,0,10496067,10496163,10496259]),new Uint32Array([2178785,6291456,2178817,6291456,2178849,6291456,2178881,6291456,2178913,6291456,2178945,6291456,2178977,6291456,2179009,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0]),new Uint32Array([2097152,0,0,0,2097152,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,2197857,2197889,2197921,2197953,2197985,2198017,0,0,2198049,2198081,2198113,2198145,2198177,2198209]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2098209,2167297,2111137,6291456]),new Uint32Array([2171393,6291456,2171425,6291456,2171457,6291456,2171489,6291456,2171521,6291456,2171553,6291456,2171585,6291456,2171617,6291456]),new Uint32Array([2206753,2206785,2195457,2206817,2206849,2206881,2206913,2197153,2197153,2206945,2117857,2206977,2207009,2207041,2207073,2207105]),new Uint32Array([0,0,0,0,0,0,0,23068672,0,0,0,0,2144834,2144898,0,2144962]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,23068672]),new Uint32Array([2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,0,2105505,2098241]),new Uint32Array([6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,2202049,6291456,2202081,6291456,2202113,6291456,2202145,6291456,2202177,6291456,2202209,6291456,2202241,6291456]),new Uint32Array([10501155,10501251,10501347,10501443,10501539,10501635,10501731,10501827,10501923,10502019,2141731,2105505,2098177,2155586,2166530,0]),new Uint32Array([2102081,2102209,2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,2100833,2100737,2098337,2101441]),new Uint32Array([2146882,2146946,2147010,2147074,2147138,2147202,2147266,2147330,2146882,2146946,2147010,2147074,2147138,2147202,2147266,2147330]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([10502307,10502403,10502499,10502595,10502691,10502787,10502883,10502979,10503075,10503171,10503267,10503363,10503459,10503555,10503651,10503747]),new Uint32Array([2179937,2179969,2180001,2180033,2156545,2180065,2156577,2180097,2180129,2180161,2180193,2180225,2180257,2180289,2156737,2180321]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,0,0,0,6291456,0,0,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0]),new Uint32Array([2227682,2227746,2227810,2227874,2227938,2228002,2228066,2228130,2228194,2228258,2228322,2228386,2228450,2228514,2228578,2228642]),new Uint32Array([2105601,2169121,2108193,2170049,2181025,2181057,2112481,2108321,2108289,2181089,2170497,2100865,2181121,2173601,2173633,2173665]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2180641,6291456,6291456,6291456]),new Uint32Array([0,6291456,6291456,6291456,0,6291456,0,6291456,0,0,6291456,6291456,0,6291456,6291456,6291456]),new Uint32Array([2178273,6291456,2178305,6291456,2178337,6291456,2178369,6291456,2178401,6291456,2178433,6291456,2178465,6291456,2178497,6291456]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,6291456,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,14680064,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456]),new Uint32Array([2237377,2237409,2236225,2237441,2237473,2217441,2215521,2215553,2217473,2237505,2237537,2209697,2237569,2215585,2237601,2237633]),new Uint32Array([2221985,2165601,2165601,2165665,2165665,2222017,2222017,2165729,2165729,2158913,2158913,2158913,2158913,2097281,2097281,2105921]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2149634,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2176897,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,2176929,6291456,2176961,6291456,2176993,6291456]),new Uint32Array([2172641,6291456,2172673,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2172705,2172737,6291456,2172769,2172801,6291456]),new Uint32Array([2099173,2104196,2121667,2099395,2121763,2152258,2152322,2098946,2152386,2121859,2121955,2099333,2122051,2104324,2099493,2122147]),new Uint32Array([6291456,6291456,6291456,2145794,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,2145858,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,0,0,6291456,0]),new Uint32Array([0,2105921,2097729,0,2097377,0,0,2106017,0,2097505,2105889,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2239074,2239138,2239201,2239233,2239265,2239297,2239329,2239361,0,2239393,2239425,2239425,2239458,2239521,2239553,2209569]),new Uint32Array([14680064,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,6291456,23068672]),new Uint32Array([2108321,2108289,2113153,2098209,2180897,2180929,2180961,2111137,2098241,2108353,2170241,2170273,2180993,2105825,6291456,2105473]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2146114,6291456,6291456,6291456,0,0,0]),new Uint32Array([2105921,2105921,2105921,2222049,2222049,2130977,2130977,2130977,2130977,2160065,2160065,2160065,2160065,2097729,2097729,2097729]),new Uint32Array([2218145,2214785,2207937,2218177,2218209,2192993,2210113,2212769,2218241,2218273,2216129,2218305,2216161,2218337,2218369,2218401]),new Uint32Array([0,0,0,2156546,2156610,2156674,2156738,2156802,0,0,0,0,0,2156866,23068672,2156930]),new Uint32Array([23068672,23068672,23068672,0,0,0,0,23068672,23068672,0,0,23068672,23068672,23068672,0,0]),new Uint32Array([2213409,2213441,2213473,2213505,2213537,2213569,2213601,2213633,2213665,2195681,2213697,2213729,2213761,2213793,2213825,2213857]),new Uint32Array([2100033,2099233,2122017,2200673,2098113,2121537,2103201,2200705,2104033,2121857,2121953,2122401,2099649,2099969,2123009,2100129]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2201857,6291456,2201889,6291456,2201921,6291456,2201953,6291456,2201985,6291456,2202017,6291456,2176193,2176257,23068672,23068672]),new Uint32Array([6291456,6291456,23068672,23068672,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2188193,2188225,2188257,2188289,2188321,2188353,2188385,2188417,2188449,2188481,2188513,2188545,2188577,2188609,2188641,0]),new Uint32Array([10554529,2221089,0,10502113,10562017,10537921,10538049,2221121,2221153,0,0,0,0,0,0,0]),new Uint32Array([2213889,2213921,2213953,2213985,2214017,2214049,2214081,2194177,2214113,2214145,2214177,2214209,2214241,2214273,2214305,2214337]),new Uint32Array([2166978,2167042,2099169,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2180545,6291456,6291456,6291456]),new Uint32Array([10518915,10519011,10519107,10519203,2162242,2162306,2159554,2162370,2159362,2159618,2105922,2162434,2159746,2162498,2159810,2159874]),new Uint32Array([2161730,2161794,2135586,2161858,2161922,2137186,2131810,2160290,2135170,2161986,2137954,2162050,2162114,2162178,10518723,10518819]),new Uint32Array([10506627,10506723,10506819,10506915,10507011,10507107,10507203,10507299,10507395,10507491,10507587,10507683,10507779,10507875,10507971,10508067]),new Uint32Array([6291456,23068672,23068672,23068672,0,23068672,23068672,0,0,0,0,0,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0]),new Uint32Array([2175873,2175905,2175937,2175969,2176001,2176033,2176065,2176097,2176129,2176161,2176193,2176225,2176257,2176289,2176321,2176353]),new Uint32Array([2140006,2140198,2140390,2140582,2140774,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,23068672,23068672,23068672]),new Uint32Array([2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241]),new Uint32Array([0,23068672,0,0,0,0,0,0,0,2145154,2145218,2145282,6291456,0,2145346,0]),new Uint32Array([0,0,0,0,10531458,10495395,2148545,2143201,2173473,2148865,2173505,0,2173537,0,2173569,2149121]),new Uint32Array([10537282,10495683,2148738,2148802,2148866,0,6291456,2148930,2186593,2173473,2148737,2148865,2148802,10495779,10495875,10495971]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2215425,2215457,2215489,2215521,2215553,2215585,2215617,2215649,2215681,2215713,2215745,2215777,2192033,2215809,2215841,2215873]),new Uint32Array([2242049,2242081,2242113,2242145,2242177,2242209,2242241,2242273,2215937,2242305,2242338,2242401,2242433,2242465,2242497,2216001]),new Uint32Array([10554529,2221089,0,0,10562017,10502113,10538049,10537921,2221185,10489601,10489697,10609889,10609921,2141729,2141793,10610273]),new Uint32Array([2141923,2142019,2142115,2142211,2142307,2142403,2142499,2142595,2142691,0,0,0,0,0,0,0]),new Uint32Array([0,2221185,2221217,10609857,10609857,10489601,10489697,10609889,10609921,2141729,2141793,2221345,2221377,2221409,2221441,2187105]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,18923970,23068672,23068672,23068672,0,6291456,6291456]),new Uint32Array([2183105,6291456,2183137,6291456,2183169,6291456,2183201,6291456,2183233,6291456,2183265,6291456,2183297,6291456,2183329,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([2134434,2134818,2097666,2097186,2097474,2097698,2105986,2131586,2132450,2131874,2131778,2135970,2135778,2161602,2136162,2161666]),new Uint32Array([2236865,2236897,2236930,2236993,2237025,2235681,2237058,2237121,2237153,2237185,2237217,2217281,2237250,2191233,2237313,2237345]),new Uint32Array([2190049,6291456,2190081,6291456,2190113,6291456,2190145,6291456,2190177,6291456,2190209,6291456,2190241,6291456,2190273,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2101922,2102050,2102178,2102306,10498755,10498851,10498947,10499043,10499139,10499235,10499331,10499427,10499523,10489604,10489732,10489860]),new Uint32Array([2166914,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2181601,2170561,2181633,2181665,2170753,2181697,2172897,2170881,2181729,2170913,2172929,2113441,2181761,2181793,2171009,2173761]),new Uint32Array([0,2105921,2097729,2106081,0,2097601,2162337,2106017,2133281,2097505,0,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([2248001,2248033,2248066,2248130,2248193,2248226,2248289,2248322,2248385,2248417,2216673,2248450,2248514,2248577,2248610,2248673]),new Uint32Array([6291456,6291456,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,0,0,0]),new Uint32Array([2169729,6291456,2169761,6291456,2169793,6291456,2169825,6291456,2169857,2169889,6291456,2169921,6291456,2143329,6291456,2098305]),new Uint32Array([2162178,2163202,2163266,2135170,2136226,2161986,2137954,2159426,2159490,2163330,2159554,2163394,2159682,2139522,2136450,2159746]),new Uint32Array([2173953,2173985,0,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2174209,2174241,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,4271169,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2174273]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,0,0,0,0,0,0,0,6291456,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,2190785,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2189793,6291456,2189825,6291456,2189857,6291456,2189889,6291456,2189921,6291456,2189953,6291456,2189985,6291456,2190017,6291456]),new Uint32Array([2105601,2112289,2108193,2112481,2112577,0,2098305,2108321,2108289,2100865,2113153,2108481,2113345,0,2098209,2111137]),new Uint32Array([2172129,6291456,2172161,6291456,2172193,6291456,2172225,6291456,2172257,6291456,2172289,6291456,2172321,6291456,2172353,6291456]),new Uint32Array([2214753,6291456,2214785,6291456,6291456,2214817,2214849,2214881,2214913,2214945,2214977,2215009,2215041,2215073,2194401,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([0,0,0,0,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([10610305,10610337,10575617,2221761,10610401,10610433,10502177,0,10610465,10610497,10610529,10610561,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,23068672,0,0,0,0,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2187105,2187137,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2199393,2199425,2199457,2199489,2199521,2199553,2199585,2199617,2199649,2199681,2199713,2199745,2199777,2199809,2199841,0]),new Uint32Array([2217249,2217281,2217313,2217345,2217377,2217409,2217441,2217473,2215617,2217505,2217537,2217569,2214753,2217601,2217633,2217665]),new Uint32Array([2170273,2170305,6291456,2170337,2170369,6291456,2170401,2170433,2170465,6291456,6291456,6291456,2170497,2170529,6291456,2170561]),new Uint32Array([2188673,6291456,2188705,2188737,2188769,6291456,6291456,2188801,6291456,2188833,6291456,2188865,6291456,2180929,2181505,2180897]),new Uint32Array([10489988,10490116,10490244,10490372,10490500,10490628,10490756,10490884,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2147393,2147457,2147521,2147585,2147649,2147713,2147777,2147841]),new Uint32Array([23068672,23068672,0,23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2241153,2241185,2241217,2215809,2241250,2241313,2241345,2241377,2217921,2241377,2241409,2215873,2241441,2241473,2241505,2241537]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2220417,2220417,2220449,2220449,2220481,2220481,2220513,2220513,2220545,2220545,2220577,2220577,2220609,2220609,2220641,2220641]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,2144002,0,6291456,6291456,0,0,6291456,6291456,6291456]),new Uint32Array([2167105,2167137,2167169,2167201,2167233,2167265,2167297,2167329,2167361,2167393,2167425,2167457,2167489,2167521,2167553,2167585]),new Uint32Array([10575521,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193]),new Uint32Array([2234146,2234210,2234274,2234338,2234402,2234466,2234530,2234594,2234658,2234722,2234786,2234850,2234914,2234978,2235042,2235106]),new Uint32Array([0,0,0,0,0,0,0,2180577,0,0,0,0,0,2180609,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,0,0,6291456,6291456]),new Uint32Array([2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2242529,2242561,2242593,2242625,2242657,2242689,2242721,2242753,2207937,2218177,2242785,2242817,2242849,2242882,2242945,2242977]),new Uint32Array([2118049,2105345,2118241,2105441,2118433,2118529,2118625,2118721,2118817,2200257,2200289,2191809,2200321,2200353,2200385,2200417]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([2185505,6291456,2185537,6291456,2185569,6291456,2185601,6291456,2185633,6291456,2185665,6291456,2185697,6291456,2185729,6291456]),new Uint32Array([2231970,2232034,2232098,2232162,2232226,2232290,2232354,2232418,2232482,2232546,2232610,2232674,2232738,2232802,2232866,2232930]),new Uint32Array([2218625,2246402,2246466,2246530,2246594,2246657,2246689,2246689,2218657,2219681,2246721,2246753,2246785,2246818,2246881,2208481]),new Uint32Array([2197025,2197057,2197089,2197121,2197153,2197185,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2219137,2216961,2219169,2219201,2219233,2219265,2219297,2217025,2215041,2219329,2217057,2219361,2217089,2219393,2197153,2219426]),new Uint32Array([23068672,23068672,23068672,0,0,0,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713]),new Uint32Array([2243522,2243585,2243617,2243649,2243681,2210113,2243713,2243746,2243810,2243874,2243937,2243970,2244033,2244065,2244097,2244129]),new Uint32Array([2178017,6291456,2178049,6291456,2178081,6291456,2178113,6291456,2178145,6291456,2178177,6291456,2178209,6291456,2178241,6291456]),new Uint32Array([10553858,2165314,10518722,6291456,10518818,0,10518914,2130690,10519010,2130786,10519106,2130882,10519202,2165378,10554050,2165506]),new Uint32Array([0,0,2135491,2135587,2135683,2135779,2135875,2135971,2135971,2136067,2136163,2136259,2136355,2136355,2136451,2136547]),new Uint32Array([23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2220033,2220033,2220065,2220065,2220065,2220065,2220097,2220097,2220097,2220097,2220129,2220129,2220129,2220129,2220161,2220161]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2100897,2100898,2100899,2150018,2100865,2100866,2100867,2100868,2150082,2108481,2109858,2109859,2105569,2105505,2098241,2105601]),new Uint32Array([2097217,2097505,2097505,2097505,2097505,2165570,2165570,2165634,2165634,2165698,2165698,2097858,2097858,0,0,2097152]),new Uint32Array([23068672,6291456,23068672,23068672,23068672,6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,23068672,23068672]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([10503843,10503939,10504035,10504131,10504227,10504323,10504419,10504515,10504611,10504707,10504803,10504899,10504995,10491140,10491268,0]),new Uint32Array([2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2173761,2174017,2174049]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2134145,2097153,2134241,2105953,2132705,2130977,2160065,2131297,2162049,2133089,2160577,2133857,2235297,2220769,2235329,2235361]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2222401,2222433,2222465,10531394,2222497,2222529,2222561,0,2222593,2222625,2222657,2222689,2222721,2222753,2222785,0]),new Uint32Array([2184481,6291456,2184513,6291456,2184545,6291456,2184577,6291456,2184609,6291456,2184641,6291456,2184673,6291456,2184705,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0,0,0,0,0,0,0,0]),new Uint32Array([2105570,2156034,2126947,2156098,2153666,2127043,2127139,2156162,0,2127235,2156226,2156290,2156354,2156418,2127331,2127427]),new Uint32Array([2215905,2207041,2153185,2241569,2241601,2241633,2241665,2241697,2241730,2241793,2241825,2241857,2241889,2241921,2241954,2242017]),new Uint32Array([2203777,6291456,2203809,6291456,2203841,6291456,2203873,6291456,2203905,6291456,2173121,2180993,2181249,2203937,2181313,0]),new Uint32Array([2168577,6291456,2168609,6291456,2168641,6291456,2168673,6291456,2168705,6291456,2168737,6291456,2168769,6291456,2168801,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,23068672,23068672,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,0,23068672,23068672,23068672,0,0]),new Uint32Array([2210113,2195521,2210145,2210177,2210209,2210241,2210273,2210305,2210337,2210369,2210401,2210433,2210465,2210497,2210529,2210561]),new Uint32Array([6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([2228706,2228770,2228834,2228898,2228962,2229026,2229090,2229154,2229218,2229282,2229346,2229410,2229474,2229538,2229602,2229666]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,18874368,18874368,18874368,0,0]),new Uint32Array([2133089,2133281,2133281,2133281,2133281,2160577,2160577,2160577,2160577,2097441,2097441,2097441,2097441,2133857,2133857,2133857]),new Uint32Array([6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2173825,2153473,2173857,2173889,2173921,2173953,2173985,2174017,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233089]),new Uint32Array([2178529,6291456,2178561,6291456,2178593,6291456,2178625,6291456,2178657,6291456,2178689,6291456,2178721,6291456,2178753,6291456]),new Uint32Array([2221025,2221025,2221057,2221057,2159329,2159329,2159329,2159329,2097217,2097217,2158914,2158914,2158978,2158978,2159042,2159042]),new Uint32Array([2208161,2208193,2208225,2208257,2194433,2208289,2208321,2208353,2208385,2208417,2208449,2208481,2208513,2208545,2208577,2208609]),new Uint32Array([2169217,6291456,2169249,6291456,2169281,6291456,2169313,6291456,2169345,6291456,2169377,6291456,2169409,6291456,2169441,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([2133187,2133283,2133283,2133379,2133475,2133571,2133667,2133667,2133763,2133859,2133955,2134051,2134147,2134147,2134243,2134339]),new Uint32Array([2197697,2114113,2114209,2197729,2197761,2114305,2197793,2114401,2114497,2197825,2114593,2114689,2114785,2114881,2114977,0]),new Uint32Array([2193089,2193121,2193153,2193185,2117665,2117569,2193217,2193249,2193281,2193313,2193345,2193377,2193409,2193441,2193473,2193505]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2184225,6291456,2184257,6291456,2184289,6291456,2184321,6291456,2184353,6291456,2184385,6291456,2184417,6291456,2184449,6291456]),new Uint32Array([2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2100833,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2098657,2098049,2200737,2123489,2123681,2200769,2098625,2100321,2098145,2100449,2098017,2098753,2200801,2200833,2200865,0]),new Uint32Array([23068672,23068672,23068672,0,0,0,0,0,0,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,0,2098241,2108353,2108417,2105825,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2181153,2105505,2181185,2167617,2180993]),new Uint32Array([2160002,2160066,2160130,2160194,2160258,2132066,2131010,2131106,2106018,2131618,2160322,2131298,2132034,2131938,2137410,2132226]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,6291456]),new Uint32Array([2183617,6291456,2183649,6291456,2183681,6291456,2183713,6291456,2183745,6291456,2183777,6291456,2183809,6291456,2183841,6291456]),new Uint32Array([0,6291456,6291456,0,6291456,0,0,6291456,6291456,0,6291456,0,0,6291456,0,0]),new Uint32Array([2250977,2251009,2251041,2251073,2195009,2251106,2251169,2251201,2251233,2251265,2251297,2251330,2251394,2251457,2251489,2251521]),new Uint32Array([2205729,2205761,2205793,2205825,2205857,2205889,2205921,2205953,2205985,2206017,2206049,2206081,2206113,2206145,2206177,2206209]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2143170,2168993,6291456,2169025,6291456,2169057,6291456,2169089,6291456,2143234,2169121,6291456,2169153,6291456,2169185,6291456]),new Uint32Array([23068672,23068672,2190689,6291456,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2248706,2248769,2248801,2248833,2248865,2248897,2248929,2248962,2249026,2249090,2249154,2240705,2249217,2249249,2249281,2249313]),new Uint32Array([10485857,6291456,6291456,6291456,6291456,6291456,6291456,6291456,10495394,6291456,2098209,6291456,6291456,2097152,6291456,10531394]),new Uint32Array([0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([14680064,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2173985,2173953,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889]),new Uint32Array([6291456,2186977,6291456,6291456,6291456,6291456,6291456,10537858,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2209601,2209633,2209665,2209697,2209729,2209761,2209793,2209825,2209857,2209889,2209921,2209953,2209985,2210017,2210049,2210081]),new Uint32Array([10501539,10501635,10501731,10501827,10501923,10502019,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905]),new Uint32Array([2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2174017,2174017,2174049]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2194561,2194593,2194625,2119777,2119873,2194657,2194689,2194721,2194753,2194785,2194817,2194849,2194881,2194913,2194945,2194977]),new Uint32Array([2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569]),new Uint32Array([2222818,2222882,2222946,2223010,2223074,2223138,2223202,2223266,2223330,2223394,2223458,2223522,2223586,2223650,2223714,2223778]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672]),new Uint32Array([0,2179553,2179585,2179617,2179649,2144001,2179681,2179713,2179745,2179777,2179809,2156705,2179841,2156833,2179873,2179905]),new Uint32Array([6291456,23068672,6291456,2145602,23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,6291456,0,0]),new Uint32Array([2196513,2196545,2196577,2196609,2196641,2196673,2196705,2196737,2196769,2196801,2196833,2196865,2196897,2196929,2196961,2196993]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2177281,6291456,2177313,6291456,2177345,6291456,2177377,6291456,2177409,6291456,2177441,6291456,2177473,6291456,2177505,6291456]),new Uint32Array([2187137,2221473,2221505,2221537,2221569,6291456,6291456,10610209,10610241,10537986,10537986,10537986,10537986,10609857,10609857,10609857]),new Uint32Array([2243009,2243041,2216033,2243074,2243137,2243169,2243201,2219617,2243233,2243265,2243297,2243329,2243362,2243425,2243457,2243489]),new Uint32Array([10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,2097152,4194304,4194304,0,0]),new Uint32Array([2143042,6291456,2143106,2143106,2168833,6291456,2168865,6291456,6291456,2168897,6291456,2168929,6291456,2168961,6291456,2143170]),new Uint32Array([6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2204193,2204225,2204257,2204289,2204321,2204353,2204385,2204417,2204449,2204481,2204513,2204545,2204577,2204609,2204641,2204673]),new Uint32Array([2202753,6291456,2202785,6291456,2202817,6291456,2202849,6291456,2202881,6291456,2202913,6291456,2202945,6291456,2202977,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321]),new Uint32Array([2147394,2147458,2147522,2147586,2147650,2147714,2147778,2147842,2147394,2147458,2147522,2147586,2147650,2147714,2147778,2147842]),new Uint32Array([2253313,2253346,2253409,2253441,2253473,2253505,2253537,2253569,2253601,2253634,2219393,2253697,2253729,2253761,2253793,2253825]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([2162562,2162626,2131362,2162690,2159938,2160002,2162754,2162818,2160130,2162882,2160194,2160258,2160834,2160898,2161026,2161090]),new Uint32Array([2175361,2175393,2175425,2175457,2175489,2175521,2175553,2175585,2175617,2175649,2175681,2175713,2175745,2175777,2175809,2175841]),new Uint32Array([2253858,2253921,2253954,2254018,2254082,2196737,2254145,2196865,2254177,2254209,2254241,2254273,2197025,2254306,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2202113,2204129,2188705,2204161]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([2173985,2174017,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113,2173985,2173953]),new Uint32Array([2101569,2101697,2101825,2101953,2102081,2102209,2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209]),new Uint32Array([2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,0,2108417,0,2111713,2100897,2111905]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0]),new Uint32Array([2175425,2175489,2175809,2175905,2175937,2175937,2176193,2176417,2180865,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,2143298,2143298,2143298,2143362,2143362,2143362,2143426,2143426,2143426,2171105,6291456,2171137]),new Uint32Array([2120162,2120258,2151618,2151682,2151746,2151810,2151874,2151938,2152002,2120035,2120131,2120227,2152066,2120323,2152130,2120419]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2195361,2142433,2236065,2236097,2236129,2236161,2118241,2117473,2236193,2236225,2236257,2236289,0,0,0,0]),new Uint32Array([2189281,6291456,2189313,6291456,2189345,6291456,2189377,6291456,2189409,6291456,2189441,6291456,2189473,6291456,2189505,6291456]),new Uint32Array([6291456,6291456,2145922,6291456,6291456,6291456,6291456,2145986,6291456,6291456,6291456,6291456,2146050,6291456,6291456,6291456]),new Uint32Array([2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,10502113,10562017,10610401,10502177,10610433,10538049]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,2186401,0,2186433,0,2186465,0,2186497]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,23068672,23068672,23068672]),new Uint32Array([0,0,2198241,2198273,2198305,2198337,2198369,2198401,0,0,2198433,2198465,2198497,0,0,0]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,6291456,0,23068672,23068672,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,0,0,23068672,6291456,23068672,23068672]),new Uint32Array([0,2105921,2097729,0,2097377,0,0,2106017,2133281,2097505,2105889,0,2097697,2135777,2097633,2097441]),new Uint32Array([2197889,2197921,2197953,2197985,2198017,2198049,2198081,2198113,2198145,2198177,2198209,2198241,2198273,2198305,2198337,2198369]),new Uint32Array([2132514,2132610,2160386,2133090,2133186,2160450,2160514,2133282,2160578,2133570,2106178,2160642,2133858,2160706,2160770,2134146]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,23068672,6291456,23068672,23068672,6291456,23068672,0,0,0,0,0,0,0,0]),new Uint32Array([2184737,6291456,2184769,6291456,2184801,6291456,2184833,6291456,2184865,6291456,2184897,6291456,2184929,6291456,2184961,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,2186753,6291456,6291456,6291456,6291456,2186785,2186817,2186849,2173569,2186881,10496355,10495395,10575521]),new Uint32Array([0,0,2097729,0,0,0,0,2106017,0,2097505,0,2097185,0,2135777,2097633,2097441]),new Uint32Array([2189537,6291456,2189569,6291456,2189601,6291456,2189633,6291456,2189665,6291456,2189697,6291456,2189729,6291456,2189761,6291456]),new Uint32Array([2202497,6291456,2202529,6291456,2202561,6291456,2202593,6291456,2202625,6291456,2202657,6291456,2202689,6291456,2202721,6291456]),new Uint32Array([2245217,2218369,2245249,2245282,2245345,2245377,2245410,2245474,2245537,2245569,2245601,2245633,2245665,2245665,2245697,2245729]),new Uint32Array([6291456,0,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,0,0,0,0,0,0,23068672,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,6291456,23068672,6291456,23068672,6291456,6291456,6291456,6291456,23068672,23068672]),new Uint32Array([0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2097281,2105921,2097729,2106081,2097377,2097601,2162337,2106017,2133281,2097505,0,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([2176641,6291456,2176673,6291456,2176705,6291456,2176737,6291456,2176769,6291456,2176801,6291456,2176833,6291456,2176865,6291456]),new Uint32Array([2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113,2173985,2173953,2174369,2174369,0,0,2100833,2100737]),new Uint32Array([2116513,2190817,2190849,2190881,2190913,2190945,2116609,2190977,2191009,2191041,2191073,2117185,2191105,2191137,2191169,2191201]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,6291456,6291456,6291456]),new Uint32Array([0,0,0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456]),new Uint32Array([2167617,2167649,2167681,2167713,2167745,2167777,2167809,6291456,2167841,2167873,2167905,2167937,2167969,2168001,2168033,4240130]),new Uint32Array([2165122,2163970,2164034,2164098,2164162,2164226,2164290,2164354,2164418,2164482,2164546,2133122,2134562,2132162,2132834,2136866]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,2186209,2186241,2186273,2186305,2186337,2186369,0,0]),new Uint32Array([2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([0,0,23068672,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456]),new Uint32Array([0,10537921,10610689,10610273,10610497,10610529,10610305,10610721,10489601,10489697,10610337,10575617,10554529,2221761,2197217,10496577]),new Uint32Array([2105473,2105569,2105601,2112289,0,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441]),new Uint32Array([2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481]),new Uint32Array([2125346,2153410,2153474,2127394,2153538,2153602,2153666,2153730,2105507,2105476,2153794,2153858,2153922,2153986,2154050,2105794]),new Uint32Array([2200449,2119681,2200481,2153313,2199873,2199905,2199937,2200513,2200545,2200577,2200609,2119105,2119201,2119297,2119393,2119489]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2175777,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2222273,2197217,2221473,2221505,2221089,2222305,2200865,2099681,2104481,2222337,2099905,2120737,2222369,2103713,2100225,2098785]),new Uint32Array([2201377,6291456,2201409,6291456,2201441,6291456,2201473,6291456,2201505,6291456,2201537,6291456,2201569,6291456,6291456,23068672]),new Uint32Array([2174081,2174113,2174145,2174177,2149057,2233057,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793]),new Uint32Array([2200897,6291456,2200929,6291456,2200961,6291456,2200993,6291456,2201025,6291456,2180865,6291456,2201057,6291456,2201089,6291456]),new Uint32Array([0,0,0,0,0,23068672,23068672,0,6291456,6291456,6291456,0,0,0,0,0]),new Uint32Array([2161154,2161410,2138658,2161474,2161538,2097666,2097186,2097474,2162946,2132450,2163010,2163074,2136162,2163138,2161666,2161730]),new Uint32Array([2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953]),new Uint32Array([0,0,0,0,0,0,23068672,23068672,0,0,0,0,2145410,2145474,0,6291456]),new Uint32Array([2244161,2216065,2212769,2244193,2244225,2244257,2244290,2244353,2244385,2244417,2244449,2218273,2244481,2244514,2244577,2244609]),new Uint32Array([2125730,2125699,2125795,2125891,2125987,2154114,2154178,2154242,2154306,2154370,2154434,2154498,2126082,2126178,2126274,2126083]),new Uint32Array([2237665,2237697,2237697,2237697,2237730,2237793,2237825,2237857,2237890,2237953,2237985,2238017,2238049,2238081,2238113,2238145]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2150146,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,0,0,23068672,23068672,23068672,0,0]),new Uint32Array([2214369,2238593,2238625,2238657,2238689,2238721,2238753,2238785,2238817,2238850,2238913,2238945,2238977,2235457,2239009,2239041]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([2252066,2252130,2252193,2252225,2252257,2252290,2252353,2252385,2252417,2252449,2252481,2252513,2252545,2252578,2252641,2252673]),new Uint32Array([2197697,2114113,2114209,2197729,2197761,2114305,2197793,2114401,2114497,2197825,2114593,2114689,2114785,2114881,2114977,2197857]),new Uint32Array([2224866,2224930,2224994,2225058,2225122,2225186,2225250,2225314,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2219490,2219554,2219617,2219649,2219681,2219714,2219778,2219842,2219905,2219937,0,0,0,0,0,0]),new Uint32Array([6291456,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456]),new Uint32Array([2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289]),new Uint32Array([2174081,2174113,2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113,2173985,2173953,2148481,2173601,2173633,2173665]),new Uint32Array([2220161,2220161,2220193,2220193,2220193,2220193,2220225,2220225,2220225,2220225,2220257,2220257,2220257,2220257,2220289,2220289]),new Uint32Array([2192673,2192705,2192737,2192769,2192801,2192833,2192865,2118049,2192897,2117473,2117761,2192929,2192961,2192993,2193025,2193057]),new Uint32Array([2179297,6291456,2179329,6291456,2179361,6291456,2179393,6291456,2179425,6291456,2179457,6291456,2179489,6291456,2179521,6291456]),new Uint32Array([6291456,6291456,6291456,23068672,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2235745,2235777,2193633,2235809,2235841,2235873,2235905,2235937,2235969,2116513,2116705,2236001,2200513,2199905,2200545,2236033]),new Uint32Array([2113153,2108481,2113345,2113441,2232993,2233025,0,0,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761]),new Uint32Array([2170593,6291456,2170625,6291456,2170657,6291456,2170689,2170721,6291456,2170753,6291456,6291456,2170785,6291456,2170817,2170849]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2166786,2166850,0,0,0,0]),new Uint32Array([23068672,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,10575617,2187041,10502177,10489601,10489697,0]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2134562,2132162,2132834,2136866,2136482,2164610,2164674,2164738,2164802,2132802,2132706,2164866,2132898,2164930,2164994,2165058]),new Uint32Array([6291456,6291456,2098337,2101441,10531458,2153473,6291456,6291456,10531522,2100737,2108193,6291456,2106499,2106595,2106691,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0]),new Uint32Array([2233122,2233186,2233250,2233314,2233378,2233442,2233506,2233570,2233634,2233698,2233762,2233826,2233890,2233954,2234018,2234082]),new Uint32Array([23068672,6291456,23068672,23068672,23068672,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2205217,2205249,2205281,2205313,2205345,2205377,2205409,2205441,2205473,2205505,2205537,2205569,2205601,2205633,2205665,2205697]),new Uint32Array([6291456,0,6291456,0,0,0,6291456,6291456,6291456,6291456,0,0,23068672,6291456,23068672,23068672]),new Uint32Array([2173601,2173761,2174081,2173569,2174241,2174113,2173953,6291456,2174305,6291456,2174337,6291456,2174369,6291456,2174401,6291456]),new Uint32Array([6291456,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2152450,2152514,2099653,2104452,2099813,2122243,2099973,2152578,2122339,2122435,2122531,2122627,2122723,2104580,2122819,2152642]),new Uint32Array([2236385,2236417,2236449,2236482,2236545,2215425,2236577,2236609,2236641,2236673,2215457,2236705,2236737,2236770,2215489,2236833]),new Uint32Array([2163394,2159746,2163458,2131362,2163522,2160130,2163778,2132226,2163842,2132898,2163906,2161410,2138658,2097666,2136162,2163650]),new Uint32Array([2218721,2246913,2246946,2216385,2247010,2247074,2215009,2247137,2247169,2216481,2247201,2247233,2247266,2247330,2247330,0]),new Uint32Array([2129730,2129762,2129858,2129731,2129827,2156482,2156482,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,0,0,0,0,6291456,0,0]),new Uint32Array([2203969,2204001,2181377,2204033,2204065,6291456,2204097,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([2169473,6291456,2169505,6291456,2169537,6291456,2169569,6291456,2169601,6291456,2169633,6291456,2169665,6291456,2169697,6291456]),new Uint32Array([2141542,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2220801,2220801,2220801,2220801,2220833,2220833,2220865,2220865,2220865,2220865,2220897,2220897,2220897,2220897,2139873,2139873]),new Uint32Array([0,0,0,0,0,23068672,23068672,0,0,0,0,0,0,0,6291456,0]),new Uint32Array([2214849,2218433,2218465,2218497,2218529,2218561,2214881,2218593,2218625,2218657,2218689,2218721,2218753,2216545,2218785,2218817]),new Uint32Array([23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0,6291456]),new Uint32Array([2136482,2164610,2164674,2164738,2164802,2132802,2132706,2164866,2132898,2164930,2164994,2165058,2165122,2132802,2132706,2164866]),new Uint32Array([2207649,2207681,2207713,2207745,2207777,2207809,2207841,2207873,2207905,2207937,2207969,2208001,2208033,2208065,2208097,2208129]),new Uint32Array([2123683,2105092,2152706,2123779,2105220,2152770,2100453,2098755,2123906,2124002,2124098,2124194,2124290,2124386,2124482,2124578]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,6291456,0,0,0,0,0,0,0,10485857]),new Uint32Array([6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([10508163,10508259,10508355,10508451,2200129,2200161,2192737,2200193,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2203553,6291456,2203585,6291456,6291456,6291456,2203617,6291456,2203649,6291456,2203681,6291456,2203713,6291456,2203745,6291456]),new Uint32Array([18884449,18884065,23068672,18884417,18884034,18921185,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,18874368]),new Uint32Array([2247393,2247426,2247489,2247521,2247553,2247586,2247649,2247681,2247713,2247745,2247777,2247810,2247873,2247905,2247937,2247969]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,23068672]),new Uint32Array([2134145,2097153,2134241,0,2132705,2130977,2160065,2131297,0,2133089,2160577,2133857,2235297,0,2235329,0]),new Uint32Array([2182593,6291456,2182625,6291456,2182657,6291456,2182689,6291456,2182721,6291456,2182753,6291456,2182785,6291456,2182817,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2102402,2102403,6291456,2110050]),new Uint32Array([2149890,2108323,2149954,6291456,2113441,6291456,2149057,6291456,2113441,6291456,2105473,2167265,2111137,2105505,6291456,2108353]),new Uint32Array([2219105,2219137,2195233,2251554,2251617,2251649,2251681,2251713,2251746,2251810,2251873,2251905,2251937,2251970,2252033,2219169]),new Uint32Array([2203009,6291456,2203041,6291456,2203073,6291456,2203105,6291456,2203137,6291456,2203169,6291456,2203201,6291456,2203233,6291456]),new Uint32Array([2128195,2128291,2128387,2128483,2128579,2128675,2128771,2128867,2128963,2129059,2129155,2129251,2129347,2129443,2129539,2129635]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2140964,2141156,2140966,2141158,2141350]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2225378,2225442,2225506,2225570,2225634,2225698,2225762,2225826,2225890,2225954,2226018,2226082,2226146,2226210,2226274,2226338]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417]),new Uint32Array([2108353,2108417,0,2105601,2108193,2157121,2157313,2157377,2157441,2100897,6291456,2108419,2173953,2173633,2173633,2173953]),new Uint32Array([2111713,2173121,2111905,2098177,2173153,2173185,2173217,2113153,2113345,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,2190753]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,2197249,6291456,2117377,2197281,2197313,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,0,0,0,0,0,0,23068672,0,0,0,0,0,6291456,6291456,6291456]),new Uint32Array([2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0]),new Uint32Array([0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,23068672,23068672,23068672]),new Uint32Array([2173281,6291456,2173313,6291456,2173345,6291456,2173377,6291456,0,0,10532546,6291456,6291456,6291456,10562017,2173441]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0]),new Uint32Array([23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2159426,2159490,2159554,2159362,2159618,2159682,2139522,2136450,2159746,2159810,2159874,2130978,2131074,2131266,2131362,2159938]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2203233,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2203265,6291456,2203297,6291456,2203329,2203361,6291456]),new Uint32Array([6291456,6291456,2148418,2148482,2148546,0,6291456,2148610,2186529,2186561,2148417,2148545,2148482,10495778,2143969,10495778]),new Uint32Array([2134146,2139426,2160962,2134242,2161218,2161282,2161346,2161410,2138658,2134722,2134434,2134818,2097666,2097346,2097698,2105986]),new Uint32Array([2198881,2198913,2198945,2198977,2199009,2199041,2199073,2199105,2199137,2199169,2199201,2199233,2199265,2199297,2199329,2199361]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([10610561,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193]),new Uint32Array([2183873,6291456,2183905,6291456,2183937,6291456,2183969,6291456,2184001,6291456,2184033,6291456,2184065,6291456,2184097,6291456]),new Uint32Array([2244642,2244706,2244769,2244801,2218305,2244833,2244865,2244897,2244929,2244961,2244993,2245026,2245089,2245122,2245185,0]),new Uint32Array([6291456,6291456,2116513,2116609,2116705,2116801,2199873,2199905,2199937,2199969,2190913,2200001,2200033,2200065,2200097,2191009]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,2180673,2180705,2180737,2180769,2180801,2180833,0,0]),new Uint32Array([2098081,2099521,2099105,2120705,2098369,2120801,2103361,2097985,2098433,2121377,2121473,2099169,2099873,2098401,2099393,2152609]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2150402]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,2145666,2145730,6291456,6291456]),new Uint32Array([2173921,2173953,2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233057,2148481,2173601,2173633,2173665]),new Uint32Array([2187073,6291456,6291456,6291456,6291456,2098241,2098241,2108353,2100897,2111905,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2102404,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,2100612,6291456,6291456,6291456,6291456,6291456,6291456,6291456,10485857]),new Uint32Array([2149057,2233057,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889]),new Uint32Array([2217697,2217729,2217761,2217793,2217825,2217857,2217889,2217921,2217953,2215873,2217985,2215905,2218017,2218049,2218081,2218113]),new Uint32Array([2211233,2218849,2216673,2218881,2218913,2218945,2218977,2219009,2216833,2219041,2215137,2219073,2216865,2209505,2219105,2216897]),new Uint32Array([2240097,2240129,2240161,2240193,2240225,2240257,2240289,2240321,2240353,2240386,2240449,2240481,2240513,2240545,2207905,2240578]),new Uint32Array([6291456,6291456,2202273,6291456,2202305,6291456,2202337,6291456,2202369,6291456,2202401,6291456,2202433,6291456,2202465,6291456]),new Uint32Array([0,23068672,23068672,18923394,23068672,18923458,18923522,18884099,18923586,18884195,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2201121,6291456,2201153,6291456,2201185,6291456,2201217,6291456,2201249,6291456,2201281,6291456,2201313,6291456,2201345,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456]),new Uint32Array([2211041,2211073,2211105,2211137,2211169,2211201,2211233,2211265,2211297,2211329,2211361,2211393,2211425,2211457,2211489,2211521]),new Uint32Array([2181825,6291456,2181857,6291456,2181889,6291456,2181921,6291456,2181953,6291456,2181985,6291456,2182017,6291456,2182049,6291456]),new Uint32Array([2162337,2097633,2097633,2097633,2097633,2132705,2132705,2132705,2132705,2097153,2097153,2097153,2097153,2133089,2133089,2133089]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,2148545,6291456,2173473,6291456,2148865,6291456,2173505,6291456,2173537,6291456,2173569,6291456,2149121,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2174017,2174017,2174049,2174081,2174113]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2207137,2207169,2207201,2207233,2207265,2207297,2207329,2207361,2207393,2207425,2207457,2207489,2207521,2207553,2207585,2207617]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,6291456,6291456,0,23068672,23068672,0,0,0,0,0,0]),new Uint32Array([2198401,2198433,2198465,2198497,0,2198529,2198561,2198593,2198625,2198657,2198689,2198721,2198753,2198785,2198817,2198849]),new Uint32Array([2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,0,0]),new Uint32Array([2216385,2118721,2216417,2216449,2216481,2216513,2216545,2211233,2216577,2216609,2216641,2216673,2216705,2216737,2216737,2216769]),new Uint32Array([2216801,2216833,2216865,2216897,2216929,2216961,2216993,2215169,2217025,2217057,2217089,2217121,2217154,2217217,0,0]),new Uint32Array([2210593,2191809,2210625,2210657,2210689,2210721,2210753,2210785,2210817,2210849,2191297,2210881,2210913,2210945,2210977,2211009]),new Uint32Array([0,0,2105825,0,0,2111905,2105473,0,0,2112289,2108193,2112481,2112577,0,2098305,2108321]),new Uint32Array([0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,2097153,2134241,0,2132705,0,0,2131297,0,2133089,0,2133857,0,2220769,0,2235361]),new Uint32Array([14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,6291456,6291456,14680064]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([2171873,6291456,2171905,6291456,2171937,6291456,2171969,6291456,2172001,6291456,2172033,6291456,2172065,6291456,2172097,6291456]),new Uint32Array([2220929,2220929,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2133857,2134145,2134145,2134145,2134145,2134241,2134241,2134241,2134241,2105889,2105889,2105889,2105889,2097185,2097185,2097185]),new Uint32Array([2173697,2173761,2173793,2174113,2173985,2173953,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,10499619,10499715,10499811,10499907]),new Uint32Array([0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,0,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,2144322,2144386,2144450,2144514,2144578,2144642,2144706,2144770]),new Uint32Array([23068672,23068672,23068672,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456]),new Uint32Array([2113153,2108481,2113345,2113441,2098209,2111137,0,2098241,2108353,2108417,2105825,0,0,2111905,2105473,2105569]),new Uint32Array([2236321,2236353,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2152194,2121283,2103684,2103812,2097986,2098533,2097990,2098693,2098595,2098853,2099013,2103940,2121379,2121475,2121571,2104068]),new Uint32Array([2206241,2206273,2206305,2206337,2206369,2206401,2206433,2206465,2206497,2206529,2206561,2206593,2206625,2206657,2206689,2206721]),new Uint32Array([6291456,6291456,6291456,6291456,16777216,16777216,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,23068672,23068672,10538818,10538882,6291456,6291456,2150338]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2214369,2214401,2214433,2214465,2214497,2214529,2214561,2214593,2194977,2214625,2195073,2214657,2214689,2214721,6291456,6291456]),new Uint32Array([2097152,2097152,2097152,2097152,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2182081,6291456,2182113,6291456,2182145,6291456,2182177,6291456,2182209,6291456,2182241,6291456,2182273,6291456,2182305,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2146881,2146945,2147009,2147073,2147137,2147201,2147265,2147329]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,23068672,23068672]),new Uint32Array([0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2122915,2123011,2123107,2104708,2123203,2123299,2123395,2100133,2104836,2100290,2100293,2104962,2104964,2098052,2123491,2123587]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([6291456,2171169,6291456,2171201,6291456,2171233,6291456,2171265,6291456,2171297,6291456,2171329,6291456,6291456,2171361,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,2148994,2149058,2149122,0,6291456,2149186,2186945,2173537,2148993,2149121,2149058,10531458,10496066,0]),new Uint32Array([2195009,2195041,2195073,2195105,2195137,2195169,2195201,2195233,2195265,2195297,2195329,2195361,2195393,2195425,2195457,2195489]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,0,0,6291456,6291456]),new Uint32Array([2182849,6291456,2182881,6291456,2182913,6291456,2182945,6291456,2182977,6291456,2183009,6291456,2183041,6291456,2183073,6291456]),new Uint32Array([2211553,2210081,2211585,2211617,2211649,2211681,2211713,2211745,2211777,2211809,2209569,2211841,2211873,2211905,2211937,2211969]),new Uint32Array([2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2166594,2127298,2166658,2142978,2141827,2166722]),new Uint32Array([2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233057,2148481,2173601,2173633,2173665,2173697,2173729]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,2185761,2185793,2185825,2185857,2185889,2185921,0,0]),new Uint32Array([6291456,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,6291456]),new Uint32Array([0,0,0,2220961,2220961,2220961,2220961,2144193,2144193,2159201,2159201,2159265,2159265,2144194,2220993,2220993]),new Uint32Array([2192641,2235393,2235425,2152257,2116609,2235457,2235489,2200065,2235521,2235553,2235585,2212449,2235617,2235649,2235681,2235713]),new Uint32Array([2194049,2194081,2194113,2194145,2194177,2194209,2194241,2194273,2194305,2194337,2194369,2194401,2194433,2194465,2194497,2194529]),new Uint32Array([2196673,2208641,2208673,2208705,2208737,2208769,2208801,2208833,2208865,2208897,2208929,2208961,2208993,2209025,2209057,2209089]),new Uint32Array([2191681,2191713,2191745,2191777,2153281,2191809,2191841,2191873,2191905,2191937,2191969,2192001,2192033,2192065,2192097,2192129]),new Uint32Array([2230946,2231010,2231074,2231138,2231202,2231266,2231330,2231394,2231458,2231522,2231586,2231650,2231714,2231778,2231842,2231906]),new Uint32Array([14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2185953,2185985,2186017,2186049,2186081,2186113,2186145,2186177]),new Uint32Array([2139811,2139907,2097284,2105860,2105988,2106116,2106244,2097444,2097604,2097155,10485778,10486344,2106372,6291456,0,0]),new Uint32Array([2110051,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2172385,6291456,2172417,6291456,2172449,6291456,2172481,6291456,2172513,6291456,2172545,6291456,2172577,6291456,2172609,6291456]),new Uint32Array([0,0,23068672,23068672,6291456,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2249345,2249377,2249409,2249441,2249473,2249505,2249537,2249570,2210209,2249633,2249665,2249697,2249729,2249761,2249793,2216769]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([2187169,2187201,2187233,2187265,2187297,2187329,2187361,2187393,2187425,2187457,2187489,2187521,2187553,2187585,2187617,2187649]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,0,6291456,6291456,0,0,0,6291456,6291456,6291456,0,0,0,6291456,6291456]),new Uint32Array([2182337,6291456,2182369,6291456,2182401,6291456,2182433,6291456,2182465,6291456,2182497,6291456,2182529,6291456,2182561,6291456]),new Uint32Array([2138179,2138275,2138371,2138467,2134243,2134435,2138563,2138659,2138755,2138851,2138947,2139043,2138947,2138755,2139139,2139235]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([0,0,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2250498,2250562,2250625,2250657,2208321,2250689,2250721,2250753,2250785,2250817,2250849,2218945,2250881,2250913,2250945,0]),new Uint32Array([2170369,2105569,2098305,2108481,2173249,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456]),new Uint32Array([2100897,2111905,2105473,2105569,2105601,0,2108193,0,0,0,2098305,2108321,2108289,2100865,2113153,2108481]),new Uint32Array([2100897,2100897,2105569,2105569,6291456,2112289,2149826,6291456,6291456,2112481,2112577,2098177,2098177,2098177,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,6291456,6291456,6291456]),new Uint32Array([6291456,2169953,2169985,6291456,2170017,6291456,2170049,2170081,6291456,2170113,2170145,2170177,6291456,6291456,2170209,2170241]),new Uint32Array([6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2220641,2220641,2220673,2220673,2220673,2220673,2220705,2220705,2220705,2220705,2220737,2220737,2220737,2220737,2220769,2220769]),new Uint32Array([2127650,2127746,2127842,2127938,2128034,2128130,2128226,2128322,2128418,2127523,2127619,2127715,2127811,2127907,2128003,2128099]),new Uint32Array([2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177]),new Uint32Array([0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2204705,2204737,2204769,2204801,2204833,2204865,2204897,2204929,2204961,2204993,2205025,2205057,2205089,2205121,2205153,2205185]),new Uint32Array([2176385,6291456,2176417,6291456,2176449,6291456,2176481,6291456,2176513,6291456,2176545,6291456,2176577,6291456,2176609,6291456]),new Uint32Array([2195521,2195553,2195585,2195617,2195649,2195681,2117857,2195713,2195745,2195777,2195809,2195841,2195873,2195905,2195937,2195969]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456]),new Uint32Array([2173921,2173953,2173985,2174017,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113]),new Uint32Array([2131586,2132450,2135970,2135778,2161602,2136162,2163650,2161794,2135586,2163714,2137186,2131810,2160290,2135170,2097506,2159554]),new Uint32Array([2134145,2097153,2134241,2105953,2132705,2130977,2160065,2131297,2162049,2133089,2160577,2133857,0,0,0,0]),new Uint32Array([2116513,2116609,2116705,2116801,2116897,2116993,2117089,2117185,2117281,2117377,2117473,2117569,2117665,2117761,2117857,2117953]),new Uint32Array([2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,2100802,2101154,2101282,2101410,2101538,2101666,2101794]),new Uint32Array([2100289,2098657,2098049,2200737,2123489,2123681,2200769,2098625,2100321,2098145,2100449,2098017,2098753,2098977,2150241,2150305]),new Uint32Array([6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,2109955,6291456,6291456,0,0,0,0]),new Uint32Array([18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,6291456,0,0]),new Uint32Array([2130979,2131075,2131075,2131171,2131267,2131363,2131459,2131555,2131651,2131651,2131747,2131843,2131939,2132035,2132131,2132227]),new Uint32Array([0,2177793,6291456,2177825,6291456,2177857,6291456,2177889,6291456,2177921,6291456,2177953,6291456,2177985,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2113345,0,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289]),new Uint32Array([2136643,2136739,2136835,2136931,2137027,2137123,2137219,2137315,2137411,2137507,2137603,2137699,2137795,2137891,2137987,2138083]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([2174433,6291456,2174465,6291456,2174497,6291456,2174529,6291456,2174561,6291456,2174593,6291456,2174625,6291456,2174657,6291456]),new Uint32Array([0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441]),new Uint32Array([10496547,10496643,2105505,2149698,6291456,10496739,10496835,2170273,6291456,2149762,2105825,2111713,2111713,2111713,2111713,2168673]),new Uint32Array([6291456,2143490,2143490,2143490,2171649,6291456,2171681,2171713,2171745,6291456,2171777,6291456,2171809,6291456,2171841,6291456]),new Uint32Array([2159106,2159106,2159170,2159170,2159234,2159234,2159298,2159298,2159298,2159362,2159362,2159362,2106401,2106401,2106401,2106401]),new Uint32Array([2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137]),new Uint32Array([2108417,2181217,2181249,2181281,2170433,2170401,2181313,2181345,2181377,2181409,2181441,2181473,2181505,2181537,2170529,2181569]),new Uint32Array([2218433,2245761,2245793,2245825,2245857,2245890,2245953,2245986,2209665,2246050,2246113,2246146,2246210,2246274,2246337,2246369]),new Uint32Array([2230754,2230818,2230882,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2184129,6291456,2184161,6291456,2184193,6291456,6291456,6291456,6291456,6291456,2146818,2183361,6291456,6291456,2142978,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2135170,2097506,2130691,2130787,2130883,2163970,2164034,2164098,2164162,2164226,2164290,2164354,2164418,2164482,2164546,2133122]),new Uint32Array([2108515,2108611,2100740,2108707,2108803,2108899,2108995,2109091,2109187,2109283,2109379,2109475,2109571,2109667,2109763,2100738]),new Uint32Array([2102788,2102916,2103044,2120515,2103172,2120611,2120707,2098373,2103300,2120803,2120899,2120995,2103428,2103556,2121091,2121187]),new Uint32Array([2158082,2158146,0,2158210,2158274,0,2158338,2158402,2158466,2129922,2158530,2158594,2158658,2158722,2158786,2158850]),new Uint32Array([10499619,10499715,10499811,10499907,10500003,10500099,10500195,10500291,10500387,10500483,10500579,10500675,10500771,10500867,10500963,10501059]),new Uint32Array([2239585,2239618,2239681,2239713,0,2191969,2239745,2239777,2192033,2239809,2239841,2239874,2239937,2239970,2240033,2240065]),new Uint32Array([2252705,2252738,2252801,2252833,2252865,2252897,2252930,2252994,2253057,2253089,2253121,2253154,2253217,2253250,2219361,2219361]),new Uint32Array([2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,10538050,10538114,10538178,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2226402,2226466,2226530,2226594,2226658,2226722,2226786,2226850,2226914,2226978,2227042,2227106,2227170,2227234,2227298,2227362]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,2144066,2144130,2144194,2144258,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,6291456,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([2124674,2124770,2123875,2123971,2124067,2124163,2124259,2124355,2124451,2124547,2124643,2124739,2124835,2124931,2125027,2125123]),new Uint32Array([2168065,6291456,2168097,6291456,2168129,6291456,2168161,6291456,2168193,6291456,2168225,6291456,2168257,6291456,2168289,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,2100610,2100611,6291456,2107842,2107843,6291456,6291456,6291456,6291456,10537922,6291456,10537986,6291456]),new Uint32Array([2174849,2174881,2174913,2174945,2174977,2175009,2175041,2175073,2175105,2175137,2175169,2175201,2175233,2175265,2175297,2175329]),new Uint32Array([2154562,2154626,2154690,2154754,2141858,2154818,2154882,2127298,2154946,2127298,2155010,2155074,2155138,2155202,2155266,2155202]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,23068672,0]),new Uint32Array([2200641,2150786,2150850,2150914,2150978,2151042,2106562,2151106,2150562,2151170,2151234,2151298,2151362,2151426,2151490,2151554]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,6291456,6291456]),new Uint32Array([2220289,2220289,2220321,2220321,2220321,2220321,2220353,2220353,2220353,2220353,2220385,2220385,2220385,2220385,2220417,2220417]),new Uint32Array([2155330,2155394,0,2155458,2155522,2155586,2105732,0,2155650,2155714,2155778,2125314,2155842,2155906,2126274,2155970]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,6291456,23068672,23068672,6291456,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0]),new Uint32Array([2097729,2106017,2106017,2106017,2106017,2131297,2131297,2131297,2131297,2106081,2106081,2162049,2162049,2105953,2105953,2162337]),new Uint32Array([2097185,2097697,2097697,2097697,2097697,2135777,2135777,2135777,2135777,2097377,2097377,2097377,2097377,2097601,2097601,2097217]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,23068672]),new Uint32Array([2139331,2139427,2139523,2139043,2133571,2132611,2139619,2139715,0,0,0,0,0,0,0,0]),new Uint32Array([2174113,2174145,2100897,2098177,2108289,2100865,2173601,2173633,2173985,2174113,2174145,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,23068672,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,18923778,23068672,23068672,23068672,23068672,18923842,23068672,23068672,23068672,23068672,18923906,23068672,23068672,23068672]),new Uint32Array([2134145,2097153,2134241,0,2132705,2130977,2160065,2131297,0,2133089,0,2133857,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2177537,6291456,2177569,6291456,2177601,6291456,2177633,6291456,2177665,6291456,2177697,6291456,2177729,6291456,2177761,6291456]),new Uint32Array([2212481,2212513,2212545,2212577,2197121,2212609,2212641,2212673,2212705,2212737,2212769,2212801,2212833,2212865,2212897,2212929]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2098241,2108353,2170209,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,6291456,2108193,2172417,2112481,2098177]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456])],t=new Uint16Array([616,616,565,147,161,411,330,2,131,131,328,454,241,408,86,86,696,113,285,350,325,301,473,214,639,232,447,64,369,598,124,672,567,223,621,154,107,86,86,86,86,86,86,505,86,68,634,86,218,218,218,218,486,218,218,513,188,608,216,86,217,463,668,85,700,360,184,86,86,86,647,402,153,10,346,718,662,260,145,298,117,1,443,342,138,54,563,86,240,572,218,70,387,86,118,460,641,602,86,86,306,218,86,692,86,86,86,86,86,162,707,86,458,26,86,218,638,86,86,86,86,86,65,449,86,86,306,183,86,58,391,667,86,157,131,131,131,131,86,433,131,406,31,218,247,86,86,693,218,581,351,86,438,295,69,462,45,126,173,650,14,295,69,97,168,187,641,78,523,390,69,108,287,664,173,219,83,295,69,108,431,426,173,694,412,115,628,52,257,398,641,118,501,121,69,579,151,423,173,620,464,121,69,382,151,476,173,27,53,121,86,594,578,226,173,86,632,130,86,96,228,268,641,622,563,86,86,21,148,650,131,131,321,43,144,343,381,531,131,131,178,20,86,399,156,375,164,541,30,60,715,198,92,118,131,131,86,86,306,407,86,280,457,196,488,358,131,131,244,86,86,143,86,86,86,86,86,667,563,86,86,86,86,86,86,86,86,86,86,86,86,86,336,363,86,86,336,86,86,380,678,67,86,86,86,678,86,86,86,512,86,307,86,708,86,86,86,86,86,528,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,563,307,86,86,86,86,86,104,450,337,86,720,86,32,450,397,86,86,86,587,218,558,708,708,293,708,86,86,86,86,86,694,205,86,8,86,86,86,86,549,86,667,697,697,679,86,458,460,86,86,650,86,708,543,86,86,86,245,86,86,86,140,218,127,708,708,458,197,131,131,131,131,500,86,86,483,251,86,306,510,515,86,722,86,86,86,65,201,86,86,483,580,470,86,86,86,368,131,131,131,694,114,110,555,86,86,123,721,163,142,713,418,86,317,675,209,218,218,218,371,545,592,629,490,603,199,46,320,525,680,310,279,388,111,42,252,593,607,235,617,410,377,50,548,135,356,17,520,189,116,392,600,349,332,482,699,690,535,119,106,451,71,152,667,131,218,218,265,671,637,492,504,533,683,269,269,658,86,86,86,86,86,86,86,86,86,491,619,86,86,6,86,86,86,86,86,86,86,86,86,86,86,229,86,86,86,86,86,86,86,86,86,86,86,86,667,86,86,171,131,118,131,656,206,234,571,89,334,670,246,311,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,534,86,86,86,86,86,86,82,86,86,86,86,86,430,86,86,86,86,86,86,86,86,86,599,86,324,86,470,69,640,264,131,626,101,174,86,86,667,233,105,73,374,394,221,204,84,28,326,86,86,471,86,86,86,109,573,86,171,200,200,200,200,218,218,86,86,86,86,460,131,131,131,86,506,86,86,86,86,86,220,404,34,614,47,442,305,25,612,338,601,648,7,344,255,131,131,51,86,312,507,563,86,86,86,86,588,86,86,86,86,86,530,511,86,458,3,435,384,556,522,230,527,86,118,86,86,717,86,137,273,79,181,484,23,93,112,655,249,417,703,370,87,98,313,684,585,155,465,596,481,695,18,416,428,61,701,706,282,643,495,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,549,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,549,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,307,86,86,86,171,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,650,131,422,542,420,263,24,172,86,86,86,86,86,566,86,86,132,540,395,353,494,519,19,485,284,472,131,131,131,16,714,86,211,708,86,86,86,694,698,86,86,483,704,708,218,272,86,86,120,86,159,478,86,307,247,86,86,663,597,459,627,667,86,86,277,455,39,302,86,250,86,86,86,271,99,452,306,281,329,400,200,86,86,362,549,352,646,461,323,586,86,86,4,708,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,717,86,518,86,86,650,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,125,554,480,300,613,72,333,288,561,544,604,48,719,91,169,176,590,224,76,191,29,559,560,231,537,166,477,538,256,437,131,131,469,167,40,0,685,266,441,705,239,642,475,568,640,610,299,673,517,318,385,22,202,180,179,359,424,215,90,66,521,653,467,682,453,409,479,88,131,661,35,303,15,262,666,630,712,131,131,618,659,175,218,195,347,193,227,261,150,165,709,546,294,569,710,270,413,376,524,55,242,38,419,529,170,657,3,304,122,379,278,131,651,86,67,576,458,458,131,131,86,86,86,86,86,86,86,118,309,86,86,547,86,86,86,86,667,650,664,131,131,86,86,56,131,131,131,131,131,131,131,131,86,307,86,86,86,664,238,650,86,86,717,86,118,86,86,315,86,59,86,86,574,549,131,131,340,57,436,86,86,86,86,86,86,458,708,499,691,62,86,650,86,86,694,86,86,86,319,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,171,86,549,694,131,131,131,131,131,131,131,131,131,77,86,86,139,86,502,86,86,86,667,595,131,131,131,86,12,86,13,86,609,131,131,131,131,86,86,86,625,86,669,86,86,182,129,86,5,694,104,86,86,86,86,131,131,86,86,386,171,86,86,86,345,86,324,86,589,86,213,36,131,131,131,131,131,86,86,86,86,104,131,131,131,141,290,80,677,86,86,86,267,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,667,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,515,86,86,33,136,669,86,711,515,86,86,550,640,86,104,708,515,86,159,372,717,86,86,444,515,86,86,663,37,86,563,460,86,390,624,702,131,131,131,131,389,59,708,86,86,341,208,708,635,295,69,108,431,508,100,190,131,131,131,131,131,131,131,131,86,86,86,649,516,660,131,131,86,86,86,218,631,708,131,131,131,131,131,131,131,131,131,131,86,86,341,575,238,514,131,131,86,86,86,218,291,708,307,131,86,86,306,367,708,131,131,131,86,378,697,86,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,615,253,86,86,86,292,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,104,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,69,86,341,553,549,86,307,86,86,645,275,455,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,708,131,131,131,131,131,131,86,86,86,86,86,86,667,460,86,86,86,86,86,86,86,86,86,86,86,86,717,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,667,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,171,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,104,86,667,459,131,131,131,131,131,131,86,458,225,86,86,86,516,549,11,390,405,86,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,460,44,218,197,711,515,131,131,131,131,664,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,307,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,308,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,640,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,118,307,104,286,591,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,549,86,86,681,86,86,75,185,314,582,86,358,496,474,86,104,131,86,86,86,86,146,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,171,86,640,131,131,131,131,131,131,131,131,246,503,689,339,674,81,258,415,439,128,562,366,414,246,503,689,583,222,557,316,636,665,186,355,95,670,246,503,689,339,674,557,258,415,439,186,355,95,670,246,503,689,446,644,536,652,331,532,335,440,274,421,297,570,74,425,364,425,606,552,403,509,134,365,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,218,218,218,498,218,218,577,627,551,497,572,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,553,354,236,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,296,455,131,131,456,243,103,86,41,459,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,9,276,158,716,393,564,383,489,401,654,210,654,131,131,131,640,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,650,86,86,86,86,86,86,717,667,563,563,563,86,549,102,686,133,246,605,86,448,86,86,207,307,131,131,131,641,86,177,611,445,373,194,584,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,308,307,171,86,86,86,86,86,86,86,717,86,86,86,86,86,460,131,131,650,86,86,86,694,708,86,86,694,86,458,131,131,131,131,131,131,667,694,289,650,667,131,131,86,640,131,131,664,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,171,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,460,86,86,86,86,86,86,86,86,86,86,86,86,86,458,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,640,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,466,203,149,429,94,432,160,687,539,63,237,283,192,248,348,259,427,526,396,676,254,468,487,212,327,623,49,633,322,493,434,688,357,361,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131]),{mapStr:"صلى الله عليه وسلمجل جلالهキロメートルrad∕s2エスクードキログラムキロワットグラムトンクルゼイロサンチームパーセントピアストルファラッドブッシェルヘクタールマンションミリバールレントゲン′′′′1⁄10viii(10)(11)(12)(13)(14)(15)(16)(17)(18)(19)(20)∫∫∫∫(오전)(오후)アパートアルファアンペアイニングエーカーカラットカロリーキュリーギルダークローネサイクルシリングバーレルフィートポイントマイクロミクロンメガトンリットルルーブル株式会社kcalm∕s2c∕kgاكبرمحمدصلعمرسولریال1⁄41⁄23⁄4 ̈́ྲཱྀླཱྀ ̈͂ ̓̀ ̓́ ̓͂ ̔̀ ̔́ ̔͂ ̈̀‵‵‵a/ca/sc/oc/utelfax1⁄71⁄91⁄32⁄31⁄52⁄53⁄54⁄51⁄65⁄61⁄83⁄85⁄87⁄8xii0⁄3∮∮∮(1)(2)(3)(4)(5)(6)(7)(8)(9)(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)(l)(m)(n)(o)(p)(q)(r)(s)(t)(u)(v)(w)(x)(y)(z)::====(ᄀ)(ᄂ)(ᄃ)(ᄅ)(ᄆ)(ᄇ)(ᄉ)(ᄋ)(ᄌ)(ᄎ)(ᄏ)(ᄐ)(ᄑ)(ᄒ)(가)(나)(다)(라)(마)(바)(사)(아)(자)(차)(카)(타)(파)(하)(주)(一)(二)(三)(四)(五)(六)(七)(八)(九)(十)(月)(火)(水)(木)(金)(土)(日)(株)(有)(社)(名)(特)(財)(祝)(労)(代)(呼)(学)(監)(企)(資)(協)(祭)(休)(自)(至)pte10月11月12月ergltdアールインチウォンオンスオームカイリガロンガンマギニーケースコルナコーポセンチダースノットハイツパーツピクルフランペニヒヘルツペンスページベータボルトポンドホールホーンマイルマッハマルクヤードヤールユアンルピー10点11点12点13点14点15点16点17点18点19点20点21点22点23点24点hpabardm2dm3khzmhzghzthzmm2cm2km2mm3cm3km3kpampagpalogmilmolppmv∕ma∕m10日11日12日13日14日15日16日17日18日19日20日21日22日23日24日25日26日27日28日29日30日31日galffifflשּׁשּׂ ٌّ ٍّ َّ ُّ ِّ ّٰـَّـُّـِّتجمتحجتحمتخمتمجتمحتمخجمححميحمىسحجسجحسجىسمحسمجسممصححصممشحمشجيشمخشممضحىضخمطمحطممطميعجمعممعمىغممغميغمىفخمقمحقمملحملحيلحىلججلخملمحمحجمحيمجحمجممخممجخهمجهممنحمنحىنجمنجىنمينمىيممبخيتجيتجىتخيتخىتميتمىجميجحىجمىسخىصحيشحيضحيلجيلمييحييجييميمميقمينحيعميكمينجحمخيلجمكممجحيحجيمجيفميبحيسخينجيصلےقلے𝅘𝅥𝅮𝅘𝅥𝅯𝅘𝅥𝅰𝅘𝅥𝅱𝅘𝅥𝅲𝆹𝅥𝅮𝆺𝅥𝅮𝆹𝅥𝅯𝆺𝅥𝅯〔s〕ppv〔本〕〔三〕〔二〕〔安〕〔点〕〔打〕〔盗〕〔勝〕〔敗〕 ̄ ́ ̧ssi̇ijl·ʼndžljnjdz ̆ ̇ ̊ ̨ ̃ ̋ ιեւاٴوٴۇٴيٴक़ख़ग़ज़ड़ढ़फ़य़ড়ঢ়য়ਲ਼ਸ਼ਖ਼ਗ਼ਜ਼ਫ਼ଡ଼ଢ଼ําໍາຫນຫມགྷཌྷདྷབྷཛྷཀྵཱཱིུྲྀླྀྒྷྜྷྡྷྦྷྫྷྐྵaʾἀιἁιἂιἃιἄιἅιἆιἇιἠιἡιἢιἣιἤιἥιἦιἧιὠιὡιὢιὣιὤιὥιὦιὧιὰιαιάιᾶι ͂ὴιηιήιῆιὼιωιώιῶι ̳!! ̅???!!?rs°c°fnosmtmivix⫝̸ ゙ ゚よりコト333435참고주의363738394042444546474849503月4月5月6月7月8月9月hgevギガデシドルナノピコビルペソホンリラレムdaauovpciu平成昭和大正明治naμakakbmbgbpfnfμfμgmgμlmldlklfmnmμmpsnsμsmsnvμvkvpwnwμwmwkwkωmωbqcccddbgyhainkkktlnlxphprsrsvwbstմնմեմիվնմխיִײַשׁשׂאַאָאּבּגּדּהּוּזּטּיּךּכּלּמּנּסּףּפּצּקּרּתּוֹבֿכֿפֿאלئائەئوئۇئۆئۈئېئىئجئحئمئيبجبمبىبيتىتيثجثمثىثيخحضجضمطحظمغجفجفحفىفيقحقىقيكاكجكحكخكلكىكينخنىنيهجهىهييىذٰرٰىٰئرئزئنبزبنترتزتنثرثزثنمانرنزننيريزئخئهبهتهصخنههٰثهسهشهطىطيعىعيغىغيسىسيشىشيصىصيضىضيشخشرسرصرضراً ًـًـّ ْـْلآلألإ𝅗𝅥0,1,2,3,4,5,6,7,8,9,wzhvsdwcmcmddjほかココàáâãäåæçèéêëìíîïðñòóôõöøùúûüýþāăąćĉċčďđēĕėęěĝğġģĥħĩīĭįĵķĺļľłńņňŋōŏőœŕŗřśŝşšţťŧũūŭůűųŵŷÿźżɓƃƅɔƈɖɗƌǝəɛƒɠɣɩɨƙɯɲɵơƣƥʀƨʃƭʈưʊʋƴƶʒƹƽǎǐǒǔǖǘǚǜǟǡǣǥǧǩǫǭǯǵƕƿǹǻǽǿȁȃȅȇȉȋȍȏȑȓȕȗșțȝȟƞȣȥȧȩȫȭȯȱȳⱥȼƚⱦɂƀʉʌɇɉɋɍɏɦɹɻʁʕͱͳʹͷ;ϳέίόύβγδεζθκλνξοπρστυφχψϊϋϗϙϛϝϟϡϣϥϧϩϫϭϯϸϻͻͼͽѐёђѓєѕіїјљњћќѝўџабвгдежзийклмнопрстуфхцчшщъыьэюяѡѣѥѧѩѫѭѯѱѳѵѷѹѻѽѿҁҋҍҏґғҕҗҙқҝҟҡңҥҧҩҫҭүұҳҵҷҹһҽҿӂӄӆӈӊӌӎӑӓӕӗәӛӝӟӡӣӥӧөӫӭӯӱӳӵӷӹӻӽӿԁԃԅԇԉԋԍԏԑԓԕԗԙԛԝԟԡԣԥԧԩԫԭԯաբգդզէըթժլծկհձղճյշոչպջռստրցփքօֆ་ⴧⴭნᏰᏱᏲᏳᏴᏵꙋɐɑᴂɜᴖᴗᴝᴥɒɕɟɡɥɪᵻʝɭᶅʟɱɰɳɴɸʂƫᴜʐʑḁḃḅḇḉḋḍḏḑḓḕḗḙḛḝḟḡḣḥḧḩḫḭḯḱḳḵḷḹḻḽḿṁṃṅṇṉṋṍṏṑṓṕṗṙṛṝṟṡṣṥṧṩṫṭṯṱṳṵṷṹṻṽṿẁẃẅẇẉẋẍẏẑẓẕạảấầẩẫậắằẳẵặẹẻẽếềểễệỉịọỏốồổỗộớờởỡợụủứừửữựỳỵỷỹỻỽỿἐἑἒἓἔἕἰἱἲἳἴἵἶἷὀὁὂὃὄὅὑὓὕὗᾰᾱὲΐῐῑὶΰῠῡὺῥ`ὸ‐+−∑〈〉ⰰⰱⰲⰳⰴⰵⰶⰷⰸⰹⰺⰻⰼⰽⰾⰿⱀⱁⱂⱃⱄⱅⱆⱇⱈⱉⱊⱋⱌⱍⱎⱏⱐⱑⱒⱓⱔⱕⱖⱗⱘⱙⱚⱛⱜⱝⱞⱡɫᵽɽⱨⱪⱬⱳⱶȿɀⲁⲃⲅⲇⲉⲋⲍⲏⲑⲓⲕⲗⲙⲛⲝⲟⲡⲣⲥⲧⲩⲫⲭⲯⲱⲳⲵⲷⲹⲻⲽⲿⳁⳃⳅⳇⳉⳋⳍⳏⳑⳓⳕⳗⳙⳛⳝⳟⳡⳣⳬⳮⳳⵡ母龟丨丶丿乙亅亠人儿入冂冖冫几凵刀力勹匕匚匸卜卩厂厶又口囗士夂夊夕女子宀寸小尢尸屮山巛工己巾干幺广廴廾弋弓彐彡彳心戈戶手支攴文斗斤方无曰欠止歹殳毋比毛氏气爪父爻爿片牙牛犬玄玉瓜瓦甘生用田疋疒癶白皮皿目矛矢石示禸禾穴立竹米糸缶网羊羽老而耒耳聿肉臣臼舌舛舟艮色艸虍虫血行衣襾見角言谷豆豕豸貝赤走足身車辛辰辵邑酉釆里長門阜隶隹雨靑非面革韋韭音頁風飛食首香馬骨高髟鬥鬯鬲鬼魚鳥鹵鹿麥麻黃黍黑黹黽鼎鼓鼠鼻齊齒龍龜龠.〒卄卅ᄁᆪᆬᆭᄄᆰᆱᆲᆳᆴᆵᄚᄈᄡᄊ짜ᅢᅣᅤᅥᅦᅧᅨᅩᅪᅫᅬᅭᅮᅯᅰᅱᅲᅳᅴᅵᄔᄕᇇᇈᇌᇎᇓᇗᇙᄜᇝᇟᄝᄞᄠᄢᄣᄧᄩᄫᄬᄭᄮᄯᄲᄶᅀᅇᅌᇱᇲᅗᅘᅙᆄᆅᆈᆑᆒᆔᆞᆡ上中下甲丙丁天地問幼箏우秘男適優印注項写左右医宗夜テヌモヨヰヱヲꙁꙃꙅꙇꙉꙍꙏꙑꙓꙕꙗꙙꙛꙝꙟꙡꙣꙥꙧꙩꙫꙭꚁꚃꚅꚇꚉꚋꚍꚏꚑꚓꚕꚗꚙꚛꜣꜥꜧꜩꜫꜭꜯꜳꜵꜷꜹꜻꜽꜿꝁꝃꝅꝇꝉꝋꝍꝏꝑꝓꝕꝗꝙꝛꝝꝟꝡꝣꝥꝧꝩꝫꝭꝯꝺꝼᵹꝿꞁꞃꞅꞇꞌꞑꞓꞗꞙꞛꞝꞟꞡꞣꞥꞧꞩɬʞʇꭓꞵꞷꬷꭒᎠᎡᎢᎣᎤᎥᎦᎧᎨᎩᎪᎫᎬᎭᎮᎯᎰᎱᎲᎳᎴᎵᎶᎷᎸᎹᎺᎻᎼᎽᎾᎿᏀᏁᏂᏃᏄᏅᏆᏇᏈᏉᏊᏋᏌᏍᏎᏏᏐᏑᏒᏓᏔᏕᏖᏗᏘᏙᏚᏛᏜᏝᏞᏟᏠᏡᏢᏣᏤᏥᏦᏧᏨᏩᏪᏫᏬᏭᏮᏯ豈更賈滑串句契喇奈懶癩羅蘿螺裸邏樂洛烙珞落酪駱亂卵欄爛蘭鸞嵐濫藍襤拉臘蠟廊朗浪狼郎來冷勞擄櫓爐盧蘆虜路露魯鷺碌祿綠菉錄論壟弄籠聾牢磊賂雷壘屢樓淚漏累縷陋勒肋凜凌稜綾菱陵讀拏諾丹寧怒率異北磻便復不泌數索參塞省葉說殺沈拾若掠略亮兩凉梁糧良諒量勵呂廬旅濾礪閭驪麗黎曆歷轢年憐戀撚漣煉璉秊練聯輦蓮連鍊列劣咽烈裂廉念捻殮簾獵令囹嶺怜玲瑩羚聆鈴零靈領例禮醴隸惡了僚寮尿料燎療蓼遼暈阮劉杻柳流溜琉留硫紐類戮陸倫崙淪輪律慄栗隆利吏履易李梨泥理痢罹裏裡離匿溺吝燐璘藺隣鱗麟林淋臨笠粒狀炙識什茶刺切度拓糖宅洞暴輻降廓兀嗀塚晴凞猪益礼神祥福靖精蘒諸逸都飯飼館鶴郞隷侮僧免勉勤卑喝嘆器塀墨層悔慨憎懲敏既暑梅海渚漢煮爫琢碑祉祈祐祖禍禎穀突節縉繁署者臭艹著褐視謁謹賓贈辶難響頻恵𤋮舘並况全侀充冀勇勺啕喙嗢墳奄奔婢嬨廒廙彩徭惘慎愈慠戴揄搜摒敖望杖滛滋瀞瞧爵犯瑱甆画瘝瘟盛直睊着磌窱类絛缾荒華蝹襁覆調請諭變輸遲醙鉶陼韛頋鬒𢡊𢡄𣏕㮝䀘䀹𥉉𥳐𧻓齃龎עםٱٻپڀٺٿٹڤڦڄڃچڇڍڌڎڈژڑکگڳڱںڻۀہھۓڭۋۅۉ、〖〗—–_{}【】《》「」『』[]#&*-<>\\$%@ءؤة\"'^|~⦅⦆・ゥャ¢£¬¦¥₩│←↑→↓■○𐐨𐐩𐐪𐐫𐐬𐐭𐐮𐐯𐐰𐐱𐐲𐐳𐐴𐐵𐐶𐐷𐐸𐐹𐐺𐐻𐐼𐐽𐐾𐐿𐑀𐑁𐑂𐑃𐑄𐑅𐑆𐑇𐑈𐑉𐑊𐑋𐑌𐑍𐑎𐑏𐓘𐓙𐓚𐓛𐓜𐓝𐓞𐓟𐓠𐓡𐓢𐓣𐓤𐓥𐓦𐓧𐓨𐓩𐓪𐓫𐓬𐓭𐓮𐓯𐓰𐓱𐓲𐓳𐓴𐓵𐓶𐓷𐓸𐓹𐓺𐓻𐳀𐳁𐳂𐳃𐳄𐳅𐳆𐳇𐳈𐳉𐳊𐳋𐳌𐳍𐳎𐳏𐳐𐳑𐳒𐳓𐳔𐳕𐳖𐳗𐳘𐳙𐳚𐳛𐳜𐳝𐳞𐳟𐳠𐳡𐳢𐳣𐳤𐳥𐳦𐳧𐳨𐳩𐳪𐳫𐳬𐳭𐳮𐳯𐳰𐳱𐳲𑣀𑣁𑣂𑣃𑣄𑣅𑣆𑣇𑣈𑣉𑣊𑣋𑣌𑣍𑣎𑣏𑣐𑣑𑣒𑣓𑣔𑣕𑣖𑣗𑣘𑣙𑣚𑣛𑣜𑣝𑣞𑣟ıȷ∇∂𞤢𞤣𞤤𞤥𞤦𞤧𞤨𞤩𞤪𞤫𞤬𞤭𞤮𞤯𞤰𞤱𞤲𞤳𞤴𞤵𞤶𞤷𞤸𞤹𞤺𞤻𞤼𞤽𞤾𞤿𞥀𞥁𞥂𞥃ٮڡٯ字双多解交映無前後再新初終販声吹演投捕遊指禁空合満申割営配得可丽丸乁𠄢你侻倂偺備像㒞𠘺兔兤具𠔜㒹內𠕋冗冤仌冬𩇟刃㓟刻剆剷㔕包匆卉博即卽卿𠨬灰及叟𠭣叫叱吆咞吸呈周咢哶唐啓啣善喫喳嗂圖圗噑噴壮城埴堍型堲報墬𡓤売壷夆夢奢𡚨𡛪姬娛娧姘婦㛮嬈嬾𡧈寃寘寳𡬘寿将㞁屠峀岍𡷤嵃𡷦嵮嵫嵼巡巢㠯巽帨帽幩㡢𢆃㡼庰庳庶𪎒𢌱舁弢㣇𣊸𦇚形彫㣣徚忍志忹悁㤺㤜𢛔惇慈慌慺憲憤憯懞戛扝抱拔捐𢬌挽拼捨掃揤𢯱搢揅掩㨮摩摾撝摷㩬敬𣀊旣書晉㬙㬈㫤冒冕最暜肭䏙朡杞杓𣏃㭉柺枅桒𣑭梎栟椔楂榣槪檨𣚣櫛㰘次𣢧歔㱎歲殟殻𣪍𡴋𣫺汎𣲼沿泍汧洖派浩浸涅𣴞洴港湮㴳滇𣻑淹潮𣽞𣾎濆瀹瀛㶖灊災灷炭𠔥煅𤉣熜爨牐𤘈犀犕𤜵𤠔獺王㺬玥㺸瑇瑜璅瓊㼛甤𤰶甾𤲒𢆟瘐𤾡𤾸𥁄㿼䀈𥃳𥃲𥄙𥄳眞真瞋䁆䂖𥐝硎䃣𥘦𥚚𥛅秫䄯穊穏𥥼𥪧䈂𥮫篆築䈧𥲀糒䊠糨糣紀𥾆絣䌁緇縂繅䌴𦈨𦉇䍙𦋙罺𦌾羕翺𦓚𦔣聠𦖨聰𣍟䏕育脃䐋脾媵𦞧𦞵𣎓𣎜舄辞䑫芑芋芝劳花芳芽苦𦬼茝荣莭茣莽菧荓菊菌菜𦰶𦵫𦳕䔫蓱蓳蔖𧏊蕤𦼬䕝䕡𦾱𧃒䕫虐虧虩蚩蚈蜎蛢蜨蝫螆蟡蠁䗹衠𧙧裗裞䘵裺㒻𧢮𧥦䚾䛇誠𧲨貫賁贛起𧼯𠠄跋趼跰𠣞軔𨗒𨗭邔郱鄑𨜮鄛鈸鋗鋘鉼鏹鐕𨯺開䦕閷𨵷䧦雃嶲霣𩅅𩈚䩮䩶韠𩐊䪲𩒖頩𩖶飢䬳餩馧駂駾䯎𩬰鱀鳽䳎䳭鵧𪃎䳸𪄅𪈎𪊑䵖黾鼅鼏鼖𪘀",mapChar:function(r){return r>=196608?r>=917760&&r<=917999?18874368:0:e[t[r>>4]][15&r]}};var e,t}.apply(t,[]))||(e.exports=n)},4489:(e,t,r)=>{"use strict";var n=r(8847)(r(3106));function i(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return o(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r= 0x80 (not a basic code point)","invalid-input":"Invalid input"},h=Math.floor,d=String.fromCharCode;function p(e){throw new RangeError(f[e])}function m(e,t){var r=e.split("@"),n="";r.length>1&&(n=r[0]+"@",e=r[1]);var i=function(e,t){for(var r=[],n=e.length;n--;)r[n]=t(e[n]);return r}((e=e.replace(l,".")).split("."),t).join(".");return n+i}function y(e){for(var t=[],r=0,n=e.length;r=55296&&i<=56319&&r>1,e+=h(e/t);e>455;n+=s)e=h(e/35);return h(n+36*e/(e+38))},v=function(e){var t,r=[],n=e.length,i=0,o=128,u=72,c=e.lastIndexOf("-");c<0&&(c=0);for(var l=0;l=128&&p("not-basic"),r.push(e.charCodeAt(l));for(var f=c>0?c+1:0;f=n&&p("invalid-input");var g=(t=e.charCodeAt(f++))-48<10?t-22:t-65<26?t-65:t-97<26?t-97:s;(g>=s||g>h((a-i)/m))&&p("overflow"),i+=g*m;var v=y<=u?1:y>=u+26?26:y-u;if(gh(a/w)&&p("overflow"),m*=w}var A=r.length+1;u=b(i-d,A,0==d),h(i/A)>a-o&&p("overflow"),o+=h(i/A),i%=A,r.splice(i++,0,o)}return String.fromCodePoint.apply(String,r)},w=function(e){var t,r=[],n=(e=y(e)).length,o=128,u=0,c=72,l=i(e);try{for(l.s();!(t=l.n()).done;){var f=t.value;f<128&&r.push(d(f))}}catch(e){l.e(e)}finally{l.f()}var m=r.length,v=m;for(m&&r.push("-");v=o&&kh((a-u)/E)&&p("overflow"),u+=(A-o)*E,o=A;var _,M=i(e);try{for(M.s();!(_=M.n()).done;){var T=_.value;if(Ta&&p("overflow"),T==o){for(var x=u,P=s;;P+=s){var I=P<=c?1:P>=c+26?26:P-c;if(x{"use strict";var n,i;r(8847)(r(3355)),n=[r(4489),r(2996)],void 0===(i=function(e,t){return function(e,t){function r(r,n,i){for(var o=[],a=e.ucs2.decode(r),s=0;s>23,h=l>>21&3,d=l>>5&65535,p=31&l,m=t.mapStr.substr(d,p);if(0===h||n&&1&f)throw new Error("Illegal char "+c);1===h?o.push(m):2===h?o.push(i?m:c):3===h&&o.push(c)}return o.join("").normalize("NFC")}function n(t,n,o){void 0===o&&(o=!1);var a=r(t,o,n).split(".");return(a=a.map((function(t){return t.startsWith("xn--")?i(t=e.decode(t.substring(4)),o,!1):i(t,o,n),t}))).join(".")}function i(e,n,i){if("-"===e[2]&&"-"===e[3])throw new Error("Failed to validate "+e);if(e.startsWith("-")||e.endsWith("-"))throw new Error("Failed to validate "+e);if(e.includes("."))throw new Error("Failed to validate "+e);if(r(e,n,i)!==e)throw new Error("Failed to validate "+e);var o=e.codePointAt(0);if(t.mapChar(o)&2<<23)throw new Error("Label contains illegal character: "+o)}return{toUnicode:function(e,t){return void 0===t&&(t={}),n(e,!1,"useStd3ASCII"in t&&t.useStd3ASCII)},toAscii:function(t,r){void 0===r&&(r={});var i,o=!("transitional"in r)||r.transitional,a="useStd3ASCII"in r&&r.useStd3ASCII,s="verifyDnsLength"in r&&r.verifyDnsLength,u=n(t,o,a).split(".").map(e.toASCII),c=u.join(".");if(s){if(c.length<1||c.length>253)throw new Error("DNS name has wrong length: "+c);for(i=0;i63)throw new Error("DNS label has wrong length: "+l)}}return c}}}(e,t)}.apply(t,n))||(e.exports=i)},3226:(e,t)=>{"use strict";t.read=function(e,t,r,n,i){var o,a,s=8*i-n-1,u=(1<>1,l=-7,f=r?i-1:0,h=r?-1:1,d=e[t+f];for(f+=h,o=d&(1<<-l)-1,d>>=-l,l+=s;l>0;o=256*o+e[t+f],f+=h,l-=8);for(a=o&(1<<-l)-1,o>>=-l,l+=n;l>0;a=256*a+e[t+f],f+=h,l-=8);if(0===o)o=1-c;else{if(o===u)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),o-=c}return(d?-1:1)*a*Math.pow(2,o-n)},t.write=function(e,t,r,n,i,o){var a,s,u,c=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:o-1,p=n?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=l):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),(t+=a+f>=1?h/u:h*Math.pow(2,1-f))*u>=2&&(a++,u/=2),a+f>=l?(s=0,a=l):a+f>=1?(s=(t*u-1)*Math.pow(2,i),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),a=0));i>=8;e[r+d]=255&s,d+=p,s/=256,i-=8);for(a=a<0;e[r+d]=255&a,d+=p,a/=256,c-=8);e[r+d-p]|=128*m}},1736:e=>{"use strict";"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},9446:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1191)(),o=r(593)("Object.prototype.toString"),a=function(e){return!(i&&e&&"object"===(0,n.default)(e)&&Symbol.toStringTag in e)&&"[object Arguments]"===o(e)},s=function(e){return!!a(e)||null!==e&&"object"===(0,n.default)(e)&&"number"==typeof e.length&&e.length>=0&&"[object Array]"!==o(e)&&"[object Function]"===o(e.callee)},u=function(){return a(arguments)}();a.isLegacyArguments=s,e.exports=u?a:s},1493:(e,t,r)=>{"use strict";var n,i,o=r(8847)(r(3355)),a=Function.prototype.toString,s="object"===("undefined"==typeof Reflect?"undefined":(0,o.default)(Reflect))&&null!==Reflect&&Reflect.apply;if("function"==typeof s&&"function"==typeof Object.defineProperty)try{n=Object.defineProperty({},"length",{get:function(){throw i}}),i={},s((function(){throw 42}),null,n)}catch(e){e!==i&&(s=null)}else s=null;var u=/^\s*class\b/,c=function(e){try{var t=a.call(e);return u.test(t)}catch(e){return!1}},l=function(e){try{return!c(e)&&(a.call(e),!0)}catch(e){return!1}},f=Object.prototype.toString,h="function"==typeof Symbol&&!!Symbol.toStringTag,d=!(0 in[,]),p=function(){return!1};if("object"===("undefined"==typeof document?"undefined":(0,o.default)(document))){var m=document.all;f.call(m)===f.call(document.all)&&(p=function(e){if((d||!e)&&(void 0===e||"object"===(0,o.default)(e)))try{var t=f.call(e);return("[object HTMLAllCollection]"===t||"[object HTML document.all class]"===t||"[object HTMLCollection]"===t||"[object Object]"===t)&&null==e("")}catch(e){}return!1})}e.exports=s?function(e){if(p(e))return!0;if(!e)return!1;if("function"!=typeof e&&"object"!==(0,o.default)(e))return!1;try{s(e,null,n)}catch(e){if(e!==i)return!1}return!c(e)&&l(e)}:function(e){if(p(e))return!0;if(!e)return!1;if("function"!=typeof e&&"object"!==(0,o.default)(e))return!1;if(h)return l(e);if(c(e))return!1;var t=f.call(e);return!("[object Function]"!==t&&"[object GeneratorFunction]"!==t&&!/^\[object HTML/.test(t))&&l(e)}},4339:e=>{"use strict";e.exports=function(e){if(!e)return!1;var r=t.call(e);return"[object Function]"===r||"function"==typeof e&&"[object RegExp]"!==r||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)};var t=Object.prototype.toString},4477:(e,t,r)=>{"use strict";var n,i=Object.prototype.toString,o=Function.prototype.toString,a=/^\s*(?:function)?\*/,s=r(1191)(),u=Object.getPrototypeOf;e.exports=function(e){if("function"!=typeof e)return!1;if(a.test(o.call(e)))return!0;if(!s)return"[object GeneratorFunction]"===i.call(e);if(!u)return!1;if(void 0===n){var t=function(){if(!s)return!1;try{return Function("return function*() {}")()}catch(e){}}();n=!!t&&u(t)}return u(e)===n}},8619:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(e){if("string"!=typeof e)throw new Error("[is-hex-prefixed] value must be type 'string', is currently type "+(0,n.default)(e)+", while checking isHexPrefixed.");return"0x"===e.slice(0,2)}},8915:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(8184),o=r(3604),a=r(593),s=a("Object.prototype.toString"),u=r(1191)(),c=r(3820),l="undefined"==typeof globalThis?r.g:globalThis,f=o(),h=a("Array.prototype.indexOf",!0)||function(e,t){for(var r=0;r-1}return!!c&&function(e){var t=!1;return i(p,(function(r,n){if(!t)try{t=r.call(e)===n}catch(e){}})),t}(e)}},9484:e=>{"use strict";var t={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==t.call(e)}},4858:(e,t,r)=>{"use strict";e=r.nmd(e);var n=r(9142),i=r(8847)(r(3355));!function(){var t="object"===("undefined"==typeof window?"undefined":(0,i.default)(window))?window:{};!t.JS_SHA3_NO_NODE_JS&&"object"===(void 0===n?"undefined":(0,i.default)(n))&&n.versions&&n.versions.node&&(t=r.g);for(var o=!t.JS_SHA3_NO_COMMON_JS&&"object"===(0,i.default)(e)&&e.exports,a="0123456789abcdef".split(""),s=[0,8,16,24],u=[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],c=[224,256,384,512],l=["hex","buffer","arrayBuffer","array"],f=function(e,t,r){return function(n){return new S(e,t,e).update(n)[r]()}},h=function(e,t,r){return function(n,i){return new S(e,t,i).update(n)[r]()}},d=function(e,t){var r=f(e,t,"hex");r.create=function(){return new S(e,t,e)},r.update=function(e){return r.create().update(e)};for(var n=0;n>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}S.prototype.update=function(e){var t="string"!=typeof e;t&&e.constructor===ArrayBuffer&&(e=new Uint8Array(e));for(var r,n,i=e.length,o=this.blocks,a=this.byteCount,u=this.blockCount,c=0,l=this.s;c>2]|=e[c]<>2]|=n<>2]|=(192|n>>6)<>2]|=(128|63&n)<=57344?(o[r>>2]|=(224|n>>12)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<>2]|=(240|n>>18)<>2]|=(128|n>>12&63)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<=a){for(this.start=r-a,this.block=o[u],r=0;r>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+a[15&e]+a[e>>12&15]+a[e>>8&15]+a[e>>20&15]+a[e>>16&15]+a[e>>28&15]+a[e>>24&15];s%t==0&&(k(r),o=0)}return i&&(e=r[o],i>0&&(u+=a[e>>4&15]+a[15&e]),i>1&&(u+=a[e>>12&15]+a[e>>8&15]),i>2&&(u+=a[e>>20&15]+a[e>>16&15])),u},S.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&k(n)}return o&&(e=s<<2,t=n[a],o>0&&(u[e]=255&t),o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u};var k=function(e){var t,r,n,i,o,a,s,c,l,f,h,d,p,m,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],c=e[4]^e[14]^e[24]^e[34]^e[44],l=e[5]^e[15]^e[25]^e[35]^e[45],f=e[6]^e[16]^e[26]^e[36]^e[46],h=e[7]^e[17]^e[27]^e[37]^e[47],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(p=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(c<<1|l>>>31),r=o^(l<<1|c>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(f<<1|h>>>31),r=s^(h<<1|f>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=c^(d<<1|p>>>31),r=l^(p<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=f^(i<<1|o>>>31),r=h^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=m^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&m,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~m&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=u[n],e[1]^=u[n+1]};if(o)e.exports=m;else for(g=0;g{"use strict";e.exports=r(2109)(r(801))},2109:(e,t,r)=>{"use strict";var n=r(6543),i=r(274);e.exports=function(e){var t=n(e),r=i(e);return function(e,n){switch("string"==typeof e?e.toLowerCase():e){case"keccak224":return new t(1152,448,null,224,n);case"keccak256":return new t(1088,512,null,256,n);case"keccak384":return new t(832,768,null,384,n);case"keccak512":return new t(576,1024,null,512,n);case"sha3-224":return new t(1152,448,6,224,n);case"sha3-256":return new t(1088,512,6,256,n);case"sha3-384":return new t(832,768,6,384,n);case"sha3-512":return new t(576,1024,6,512,n);case"shake128":return new r(1344,256,31,n);case"shake256":return new r(1088,512,31,n);default:throw new Error("Invald algorithm: "+e)}}}},6543:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(9721)),a=i(r(8985)),s=i(r(5163)),u=i(r(4650)),c=i(r(1949)),l=r(6505).Transform;e.exports=function(e){return function(t){(0,s.default)(f,t);var r,i,l=(r=f,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=(0,c.default)(r);if(i){var n=(0,c.default)(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return(0,u.default)(this,e)});function f(t,r,n,i,a){var s;return(0,o.default)(this,f),(s=l.call(this,a))._rate=t,s._capacity=r,s._delimitedSuffix=n,s._hashBitLength=i,s._options=a,s._state=new e,s._state.initialize(t,r),s._finalized=!1,s}return(0,a.default)(f,[{key:"_transform",value:function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)}},{key:"_flush",value:function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)}},{key:"update",value:function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Digest already called");return n.isBuffer(e)||(e=n.from(e,t)),this._state.absorb(e),this}},{key:"digest",value:function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0,this._delimitedSuffix&&this._state.absorbLastFewBits(this._delimitedSuffix);var t=this._state.squeeze(this._hashBitLength/8);return void 0!==e&&(t=t.toString(e)),this._resetState(),t}},{key:"_resetState",value:function(){return this._state.initialize(this._rate,this._capacity),this}},{key:"_clone",value:function(){var e=new f(this._rate,this._capacity,this._delimitedSuffix,this._hashBitLength,this._options);return this._state.copy(e._state),e._finalized=this._finalized,e}}]),f}(l)}},274:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(9721)),a=i(r(8985)),s=i(r(5163)),u=i(r(4650)),c=i(r(1949)),l=r(6505).Transform;e.exports=function(e){return function(t){(0,s.default)(f,t);var r,i,l=(r=f,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=(0,c.default)(r);if(i){var n=(0,c.default)(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return(0,u.default)(this,e)});function f(t,r,n,i){var a;return(0,o.default)(this,f),(a=l.call(this,i))._rate=t,a._capacity=r,a._delimitedSuffix=n,a._options=i,a._state=new e,a._state.initialize(t,r),a._finalized=!1,a}return(0,a.default)(f,[{key:"_transform",value:function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)}},{key:"_flush",value:function(){}},{key:"_read",value:function(e){this.push(this.squeeze(e))}},{key:"update",value:function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Squeeze already called");return n.isBuffer(e)||(e=n.from(e,t)),this._state.absorb(e),this}},{key:"squeeze",value:function(e,t){this._finalized||(this._finalized=!0,this._state.absorbLastFewBits(this._delimitedSuffix));var r=this._state.squeeze(e);return void 0!==t&&(r=r.toString(t)),r}},{key:"_resetState",value:function(){return this._state.initialize(this._rate,this._capacity),this}},{key:"_clone",value:function(){var e=new f(this._rate,this._capacity,this._delimitedSuffix,this._options);return this._state.copy(e._state),e._finalized=this._finalized,e}}]),f}(l)}},5612:(e,t)=>{"use strict";var r=[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];t.p1600=function(e){for(var t=0;t<24;++t){var n=e[0]^e[10]^e[20]^e[30]^e[40],i=e[1]^e[11]^e[21]^e[31]^e[41],o=e[2]^e[12]^e[22]^e[32]^e[42],a=e[3]^e[13]^e[23]^e[33]^e[43],s=e[4]^e[14]^e[24]^e[34]^e[44],u=e[5]^e[15]^e[25]^e[35]^e[45],c=e[6]^e[16]^e[26]^e[36]^e[46],l=e[7]^e[17]^e[27]^e[37]^e[47],f=e[8]^e[18]^e[28]^e[38]^e[48],h=e[9]^e[19]^e[29]^e[39]^e[49],d=f^(o<<1|a>>>31),p=h^(a<<1|o>>>31),m=e[0]^d,y=e[1]^p,g=e[10]^d,b=e[11]^p,v=e[20]^d,w=e[21]^p,A=e[30]^d,S=e[31]^p,k=e[40]^d,E=e[41]^p;d=n^(s<<1|u>>>31),p=i^(u<<1|s>>>31);var _=e[2]^d,M=e[3]^p,T=e[12]^d,x=e[13]^p,P=e[22]^d,I=e[23]^p,O=e[32]^d,R=e[33]^p,C=e[42]^d,B=e[43]^p;d=o^(c<<1|l>>>31),p=a^(l<<1|c>>>31);var N=e[4]^d,L=e[5]^p,U=e[14]^d,F=e[15]^p,D=e[24]^d,j=e[25]^p,H=e[34]^d,J=e[35]^p,z=e[44]^d,G=e[45]^p;d=s^(f<<1|h>>>31),p=u^(h<<1|f>>>31);var q=e[6]^d,K=e[7]^p,V=e[16]^d,X=e[17]^p,Q=e[26]^d,W=e[27]^p,Z=e[36]^d,Y=e[37]^p,$=e[46]^d,ee=e[47]^p;d=c^(n<<1|i>>>31),p=l^(i<<1|n>>>31);var te=e[8]^d,re=e[9]^p,ne=e[18]^d,ie=e[19]^p,oe=e[28]^d,ae=e[29]^p,se=e[38]^d,ue=e[39]^p,ce=e[48]^d,le=e[49]^p,fe=m,he=y,de=b<<4|g>>>28,pe=g<<4|b>>>28,me=v<<3|w>>>29,ye=w<<3|v>>>29,ge=S<<9|A>>>23,be=A<<9|S>>>23,ve=k<<18|E>>>14,we=E<<18|k>>>14,Ae=_<<1|M>>>31,Se=M<<1|_>>>31,ke=x<<12|T>>>20,Ee=T<<12|x>>>20,_e=P<<10|I>>>22,Me=I<<10|P>>>22,Te=R<<13|O>>>19,xe=O<<13|R>>>19,Pe=C<<2|B>>>30,Ie=B<<2|C>>>30,Oe=L<<30|N>>>2,Re=N<<30|L>>>2,Ce=U<<6|F>>>26,Be=F<<6|U>>>26,Ne=j<<11|D>>>21,Le=D<<11|j>>>21,Ue=H<<15|J>>>17,Fe=J<<15|H>>>17,De=G<<29|z>>>3,je=z<<29|G>>>3,He=q<<28|K>>>4,Je=K<<28|q>>>4,ze=X<<23|V>>>9,Ge=V<<23|X>>>9,qe=Q<<25|W>>>7,Ke=W<<25|Q>>>7,Ve=Z<<21|Y>>>11,Xe=Y<<21|Z>>>11,Qe=ee<<24|$>>>8,We=$<<24|ee>>>8,Ze=te<<27|re>>>5,Ye=re<<27|te>>>5,$e=ne<<20|ie>>>12,et=ie<<20|ne>>>12,tt=ae<<7|oe>>>25,rt=oe<<7|ae>>>25,nt=se<<8|ue>>>24,it=ue<<8|se>>>24,ot=ce<<14|le>>>18,at=le<<14|ce>>>18;e[0]=fe^~ke&Ne,e[1]=he^~Ee&Le,e[10]=He^~$e&me,e[11]=Je^~et&ye,e[20]=Ae^~Ce&qe,e[21]=Se^~Be&Ke,e[30]=Ze^~de&_e,e[31]=Ye^~pe&Me,e[40]=Oe^~ze&tt,e[41]=Re^~Ge&rt,e[2]=ke^~Ne&Ve,e[3]=Ee^~Le&Xe,e[12]=$e^~me&Te,e[13]=et^~ye&xe,e[22]=Ce^~qe&nt,e[23]=Be^~Ke&it,e[32]=de^~_e&Ue,e[33]=pe^~Me&Fe,e[42]=ze^~tt&ge,e[43]=Ge^~rt&be,e[4]=Ne^~Ve&ot,e[5]=Le^~Xe&at,e[14]=me^~Te&De,e[15]=ye^~xe&je,e[24]=qe^~nt&ve,e[25]=Ke^~it&we,e[34]=_e^~Ue&Qe,e[35]=Me^~Fe&We,e[44]=tt^~ge&Pe,e[45]=rt^~be&Ie,e[6]=Ve^~ot&fe,e[7]=Xe^~at&he,e[16]=Te^~De&He,e[17]=xe^~je&Je,e[26]=nt^~ve&Ae,e[27]=it^~we&Se,e[36]=Ue^~Qe&Ze,e[37]=Fe^~We&Ye,e[46]=ge^~Pe&Oe,e[47]=be^~Ie&Re,e[8]=ot^~fe&ke,e[9]=at^~he&Ee,e[18]=De^~He&$e,e[19]=je^~Je&et,e[28]=ve^~Ae&Ce,e[29]=we^~Se&Be,e[38]=Qe^~Ze&de,e[39]=We^~Ye&pe,e[48]=Pe^~Oe&ze,e[49]=Ie^~Re&Ge,e[0]^=r[2*t],e[1]^=r[2*t+1]}}},801:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(5612);function o(){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}o.prototype.initialize=function(e,t){for(var r=0;r<50;++r)this.state[r]=0;this.blockSize=e/8,this.count=0,this.squeezing=!1},o.prototype.absorb=function(e){for(var t=0;t>>this.count%4*8&255,this.count+=1,this.count===this.blockSize&&(i.p1600(this.state),this.count=0);return t},o.prototype.copy=function(e){for(var t=0;t<50;++t)e.state[t]=this.state[t];e.blockSize=this.blockSize,e.count=this.count,e.squeezing=this.squeezing},e.exports=o},807:(e,t,r)=>{"use strict";var n=r(1736),i=r(2353),o=r(8850).Buffer,a=new Array(16);function s(){i.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function u(e,t){return e<>>32-t}function c(e,t,r,n,i,o,a){return u(e+(t&r|~t&n)+i+o|0,a)+t|0}function l(e,t,r,n,i,o,a){return u(e+(t&n|r&~n)+i+o|0,a)+t|0}function f(e,t,r,n,i,o,a){return u(e+(t^r^n)+i+o|0,a)+t|0}function h(e,t,r,n,i,o,a){return u(e+(r^(t|~n))+i+o|0,a)+t|0}n(s,i),s.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,o=this._d;r=c(r,n,i,o,e[0],3614090360,7),o=c(o,r,n,i,e[1],3905402710,12),i=c(i,o,r,n,e[2],606105819,17),n=c(n,i,o,r,e[3],3250441966,22),r=c(r,n,i,o,e[4],4118548399,7),o=c(o,r,n,i,e[5],1200080426,12),i=c(i,o,r,n,e[6],2821735955,17),n=c(n,i,o,r,e[7],4249261313,22),r=c(r,n,i,o,e[8],1770035416,7),o=c(o,r,n,i,e[9],2336552879,12),i=c(i,o,r,n,e[10],4294925233,17),n=c(n,i,o,r,e[11],2304563134,22),r=c(r,n,i,o,e[12],1804603682,7),o=c(o,r,n,i,e[13],4254626195,12),i=c(i,o,r,n,e[14],2792965006,17),r=l(r,n=c(n,i,o,r,e[15],1236535329,22),i,o,e[1],4129170786,5),o=l(o,r,n,i,e[6],3225465664,9),i=l(i,o,r,n,e[11],643717713,14),n=l(n,i,o,r,e[0],3921069994,20),r=l(r,n,i,o,e[5],3593408605,5),o=l(o,r,n,i,e[10],38016083,9),i=l(i,o,r,n,e[15],3634488961,14),n=l(n,i,o,r,e[4],3889429448,20),r=l(r,n,i,o,e[9],568446438,5),o=l(o,r,n,i,e[14],3275163606,9),i=l(i,o,r,n,e[3],4107603335,14),n=l(n,i,o,r,e[8],1163531501,20),r=l(r,n,i,o,e[13],2850285829,5),o=l(o,r,n,i,e[2],4243563512,9),i=l(i,o,r,n,e[7],1735328473,14),r=f(r,n=l(n,i,o,r,e[12],2368359562,20),i,o,e[5],4294588738,4),o=f(o,r,n,i,e[8],2272392833,11),i=f(i,o,r,n,e[11],1839030562,16),n=f(n,i,o,r,e[14],4259657740,23),r=f(r,n,i,o,e[1],2763975236,4),o=f(o,r,n,i,e[4],1272893353,11),i=f(i,o,r,n,e[7],4139469664,16),n=f(n,i,o,r,e[10],3200236656,23),r=f(r,n,i,o,e[13],681279174,4),o=f(o,r,n,i,e[0],3936430074,11),i=f(i,o,r,n,e[3],3572445317,16),n=f(n,i,o,r,e[6],76029189,23),r=f(r,n,i,o,e[9],3654602809,4),o=f(o,r,n,i,e[12],3873151461,11),i=f(i,o,r,n,e[15],530742520,16),r=h(r,n=f(n,i,o,r,e[2],3299628645,23),i,o,e[0],4096336452,6),o=h(o,r,n,i,e[7],1126891415,10),i=h(i,o,r,n,e[14],2878612391,15),n=h(n,i,o,r,e[5],4237533241,21),r=h(r,n,i,o,e[12],1700485571,6),o=h(o,r,n,i,e[3],2399980690,10),i=h(i,o,r,n,e[10],4293915773,15),n=h(n,i,o,r,e[1],2240044497,21),r=h(r,n,i,o,e[8],1873313359,6),o=h(o,r,n,i,e[15],4264355552,10),i=h(i,o,r,n,e[6],2734768916,15),n=h(n,i,o,r,e[13],1309151649,21),r=h(r,n,i,o,e[4],4149444226,6),o=h(o,r,n,i,e[11],3174756917,10),i=h(i,o,r,n,e[2],718787259,15),n=h(n,i,o,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+o|0},s.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 e=o.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=s},137:(e,t,r)=>{"use strict";var n=r(1734),i=r(2202);function o(e){this.rand=e||new i.Rand}e.exports=o,o.create=function(e){return new o(e)},o.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var i=new n(this.rand.generate(r))}while(i.cmp(e)>=0);return i},o.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},o.prototype.test=function(e,t,r){var i=e.bitLength(),o=n.mont(e),a=new n(1).toRed(o);t||(t=Math.max(1,i/48|0));for(var s=e.subn(1),u=0;!s.testn(u);u++);for(var c=e.shrn(u),l=s.toRed(o);t>0;t--){var f=this._randrange(new n(2),s);r&&r(f);var h=f.toRed(o).redPow(c);if(0!==h.cmp(a)&&0!==h.cmp(l)){for(var d=1;d0;t--){var l=this._randrange(new n(2),a),f=e.gcd(l);if(0!==f.cmpn(1))return f;var h=l.toRed(i).redPow(u);if(0!==h.cmp(o)&&0!==h.cmp(c)){for(var d=1;d{"use strict";function t(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=t,t.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},6580:(e,t)=>{"use strict";var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}},6565:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=function(){function e(t,r,n,o){(0,i.default)(this,e),this.name=t,this.code=r,this.alphabet=o,n&&o&&(this.engine=n(o))}return(0,o.default)(e,[{key:"encode",value:function(e){return this.engine.encode(e)}},{key:"decode",value:function(e){return this.engine.decode(e)}},{key:"isImplemented",value:function(){return this.engine}}]),e}();e.exports=a},2642:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base16 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"hex")}}}},6494:e=>{"use strict";function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=5;)s+=t[a>>>o-5&31],o-=5;if(o>0&&(s+=t[a<<5-o&31]),i)for(;s.length%8!=0;)s+="=";return s}("string"==typeof t?Uint8Array.from(t):t,e)},decode:function(r){var n,i=function(e,r){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,r){if(e){if("string"==typeof e)return t(e,r);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?t(e,r):void 0}}(e))){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(r);try{for(i.s();!(n=i.n()).done;){var o=n.value;if(e.indexOf(o)<0)throw new Error("invalid base32 character")}}catch(e){i.e(e)}finally{i.f()}return function(e,t){for(var r=(e=e.replace(new RegExp("=","g"),"")).length,n=0,i=0,o=0,a=new Uint8Array(5*r/8|0),s=0;s=8&&(a[o++]=i>>>n-8&255,n-=8);return a.buffer}(r,e)}}}},6627:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r-1,r=e.indexOf("-")>-1&&e.indexOf("_")>-1;return{encode:function(e){var n="";n="string"==typeof e?i.from(e).toString("base64"):e.toString("base64"),r&&(n=n.replace(/\+/g,"-").replace(/\//g,"_"));var o=n.indexOf("=");return o>0&&!t&&(n=n.substring(0,o)),n},decode:function(t){var r,o=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}(e))){r&&(e=r);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base64 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"base64")}}}},7905:(e,t,r)=>{"use strict";var n=r(6565),i=r(7548),o=r(2642),a=r(6494),s=r(6627),u=[["base1","1","","1"],["base2","0",i,"01"],["base8","7",i,"01234567"],["base10","9",i,"0123456789"],["base16","f",o,"0123456789abcdef"],["base32","b",a,"abcdefghijklmnopqrstuvwxyz234567"],["base32pad","c",a,"abcdefghijklmnopqrstuvwxyz234567="],["base32hex","v",a,"0123456789abcdefghijklmnopqrstuv"],["base32hexpad","t",a,"0123456789abcdefghijklmnopqrstuv="],["base32z","h",a,"ybndrfg8ejkmcpqxot1uwisza345h769"],["base58flickr","Z",i,"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"],["base58btc","z",i,"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"],["base64","m",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],["base64pad","M",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],["base64url","u",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],["base64urlpad","U",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_="]],c=u.reduce((function(e,t){return e[t[0]]=new n(t[0],t[1],t[2],t[3]),e}),{}),l=u.reduce((function(e,t){return e[t[1]]=c[t[0]],e}),{});e.exports={names:c,codes:l}},6086:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(7905);(t=e.exports=a).encode=function(e,t){var r=s(e);return a(r.name,n.from(r.encode(t)))},t.decode=function(e){n.isBuffer(e)&&(e=e.toString());var t=e.substring(0,1);"string"==typeof(e=e.substring(1,e.length))&&(e=n.from(e));var r=s(t);return n.from(r.decode(e.toString()))},t.isEncoded=function(e){if(n.isBuffer(e)&&(e=e.toString()),"[object String]"!==Object.prototype.toString.call(e))return!1;var t=e.substring(0,1);try{return s(t).name}catch(e){return!1}},t.names=Object.freeze(Object.keys(i.names)),t.codes=Object.freeze(Object.keys(i.codes));var o=new Error("Unsupported encoding");function a(e,t){if(!t)throw new Error("requires an encoded buffer");var r=s(e),i=n.from(r.code);return function(e,t){s(e).decode(t.toString())}(r.name,t),n.concat([i,t])}function s(e){var t;if(i.names[e])t=i.names[e];else{if(!i.codes[e])throw o;t=i.codes[e]}if(!t.isImplemented())throw new Error("Base "+e+" is not implemented yet");return t}},4093:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(4070),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(9033).Buffer,i=r(6657),o=r(7054),a=r(6002),s=r(5576);(t=e.exports).addPrefix=function(e,t){var r;if(n.isBuffer(e))r=s.varintBufferEncode(e);else{if(!a[e])throw new Error("multicodec not recognized");r=a[e]}return n.concat([r,t])},t.rmPrefix=function(e){return i.decode(e),e.slice(i.decode.bytes)},t.getCodec=function(e){var t=i.decode(e),r=o.get(t);if(void 0===r)throw new Error("Code ".concat(t," not found"));return r},t.getName=function(e){return o.get(e)},t.getNumber=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return s.varintBufferDecode(t)[0]},t.getCode=function(e){return i.decode(e)},t.getCodeVarint=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return t},t.getVarint=function(e){return i.encode(e)};var u=r(4093);Object.assign(t,u),t.print=r(1032)},7054:(e,t,r)=>{"use strict";var n=r(4070),i=new Map;for(var o in n){var a=n[o];i.set(a,o)}e.exports=Object.freeze(i)},1032:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(4070),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(9033).Buffer,i=r(6657);function o(e){return parseInt(e.toString("hex"),16)}function a(e){var t=e.toString(16);return t.length%2==1&&(t="0"+t),n.from(t,"hex")}e.exports={numberToBuffer:a,bufferToNumber:o,varintBufferEncode:function(e){return n.from(i.encode(o(e)))},varintBufferDecode:function(e){return a(i.decode(e))},varintEncode:function(e){return n.from(i.encode(e))}}},6002:(e,t,r)=>{"use strict";var n=r(4070),i=r(5576).varintEncode,o={};for(var a in n){var s=n[a];o[a]=i(s)}e.exports=Object.freeze(o)},1786:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=function(){function e(t,r,n,o){(0,i.default)(this,e),this.name=t,this.code=r,this.alphabet=o,n&&o&&(this.engine=n(o))}return(0,o.default)(e,[{key:"encode",value:function(e){return this.engine.encode(e)}},{key:"decode",value:function(e){return this.engine.decode(e)}},{key:"isImplemented",value:function(){return this.engine}}]),e}();e.exports=a},7739:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base16 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"hex")}}}},976:e=>{"use strict";function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=5;)s+=t[a>>>o-5&31],o-=5;if(o>0&&(s+=t[a<<5-o&31]),i)for(;s.length%8!=0;)s+="=";return s}("string"==typeof t?Uint8Array.from(t):t,e)},decode:function(r){var n,i=function(e,r){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,r){if(e){if("string"==typeof e)return t(e,r);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?t(e,r):void 0}}(e))){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(r);try{for(i.s();!(n=i.n()).done;){var o=n.value;if(e.indexOf(o)<0)throw new Error("invalid base32 character")}}catch(e){i.e(e)}finally{i.f()}return function(e,t){for(var r=(e=e.replace(new RegExp("=","g"),"")).length,n=0,i=0,o=0,a=new Uint8Array(5*r/8|0),s=0;s=8&&(a[o++]=i>>>n-8&255,n-=8);return a.buffer}(r,e)}}}},8504:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r-1,r=e.indexOf("-")>-1&&e.indexOf("_")>-1;return{encode:function(e){var n="";n="string"==typeof e?i.from(e).toString("base64"):e.toString("base64"),r&&(n=n.replace(/\+/g,"-").replace(/\//g,"_"));var o=n.indexOf("=");return o>0&&!t&&(n=n.substring(0,o)),n},decode:function(t){var r,o=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}(e))){r&&(e=r);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base64 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"base64")}}}},2263:(e,t,r)=>{"use strict";var n=r(1786),i=r(7548),o=r(7739),a=r(976),s=r(8504),u=[["base1","1","","1"],["base2","0",i,"01"],["base8","7",i,"01234567"],["base10","9",i,"0123456789"],["base16","f",o,"0123456789abcdef"],["base32","b",a,"abcdefghijklmnopqrstuvwxyz234567"],["base32pad","c",a,"abcdefghijklmnopqrstuvwxyz234567="],["base32hex","v",a,"0123456789abcdefghijklmnopqrstuv"],["base32hexpad","t",a,"0123456789abcdefghijklmnopqrstuv="],["base32z","h",a,"ybndrfg8ejkmcpqxot1uwisza345h769"],["base58flickr","Z",i,"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"],["base58btc","z",i,"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"],["base64","m",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],["base64pad","M",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],["base64url","u",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],["base64urlpad","U",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_="]],c=u.reduce((function(e,t){return e[t[0]]=new n(t[0],t[1],t[2],t[3]),e}),{}),l=u.reduce((function(e,t){return e[t[1]]=c[t[0]],e}),{});e.exports={names:c,codes:l}},2592:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(2263);function o(e,t){if(!t)throw new Error("requires an encoded buffer");var r=a(e),i=n.from(r.code);return function(e,t){a(e).decode(t.toString())}(r.name,t),n.concat([i,t])}function a(e){var t;if(i.names[e])t=i.names[e];else{if(!i.codes[e])throw new Error("Unsupported encoding");t=i.codes[e]}if(!t.isImplemented())throw new Error("Base "+e+" is not implemented yet");return t}(t=e.exports=o).encode=function(e,t){var r=a(e);return o(r.name,n.from(r.encode(t)))},t.decode=function(e){n.isBuffer(e)&&(e=e.toString());var t=e.substring(0,1);"string"==typeof(e=e.substring(1,e.length))&&(e=n.from(e));var r=a(t);return n.from(r.decode(e.toString()))},t.isEncoded=function(e){if(n.isBuffer(e)&&(e=e.toString()),"[object String]"!==Object.prototype.toString.call(e))return!1;var t=e.substring(0,1);try{return a(t).name}catch(e){return!1}},t.names=Object.freeze(Object.keys(i.names)),t.codes=Object.freeze(Object.keys(i.codes))},1269:(e,t)=>{"use strict";t.names=Object.freeze({identity:0,sha1:17,"sha2-256":18,"sha2-512":19,"dbl-sha2-256":86,"sha3-224":23,"sha3-256":22,"sha3-384":21,"sha3-512":20,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"murmur3-128":34,"murmur3-32":35,md4:212,md5:213,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"Skein256-8":45825,"Skein256-16":45826,"Skein256-24":45827,"Skein256-32":45828,"Skein256-40":45829,"Skein256-48":45830,"Skein256-56":45831,"Skein256-64":45832,"Skein256-72":45833,"Skein256-80":45834,"Skein256-88":45835,"Skein256-96":45836,"Skein256-104":45837,"Skein256-112":45838,"Skein256-120":45839,"Skein256-128":45840,"Skein256-136":45841,"Skein256-144":45842,"Skein256-152":45843,"Skein256-160":45844,"Skein256-168":45845,"Skein256-176":45846,"Skein256-184":45847,"Skein256-192":45848,"Skein256-200":45849,"Skein256-208":45850,"Skein256-216":45851,"Skein256-224":45852,"Skein256-232":45853,"Skein256-240":45854,"Skein256-248":45855,"Skein256-256":45856,"Skein512-8":45857,"Skein512-16":45858,"Skein512-24":45859,"Skein512-32":45860,"Skein512-40":45861,"Skein512-48":45862,"Skein512-56":45863,"Skein512-64":45864,"Skein512-72":45865,"Skein512-80":45866,"Skein512-88":45867,"Skein512-96":45868,"Skein512-104":45869,"Skein512-112":45870,"Skein512-120":45871,"Skein512-128":45872,"Skein512-136":45873,"Skein512-144":45874,"Skein512-152":45875,"Skein512-160":45876,"Skein512-168":45877,"Skein512-176":45878,"Skein512-184":45879,"Skein512-192":45880,"Skein512-200":45881,"Skein512-208":45882,"Skein512-216":45883,"Skein512-224":45884,"Skein512-232":45885,"Skein512-240":45886,"Skein512-248":45887,"Skein512-256":45888,"Skein512-264":45889,"Skein512-272":45890,"Skein512-280":45891,"Skein512-288":45892,"Skein512-296":45893,"Skein512-304":45894,"Skein512-312":45895,"Skein512-320":45896,"Skein512-328":45897,"Skein512-336":45898,"Skein512-344":45899,"Skein512-352":45900,"Skein512-360":45901,"Skein512-368":45902,"Skein512-376":45903,"Skein512-384":45904,"Skein512-392":45905,"Skein512-400":45906,"Skein512-408":45907,"Skein512-416":45908,"Skein512-424":45909,"Skein512-432":45910,"Skein512-440":45911,"Skein512-448":45912,"Skein512-456":45913,"Skein512-464":45914,"Skein512-472":45915,"Skein512-480":45916,"Skein512-488":45917,"Skein512-496":45918,"Skein512-504":45919,"Skein512-512":45920,"Skein1024-8":45921,"Skein1024-16":45922,"Skein1024-24":45923,"Skein1024-32":45924,"Skein1024-40":45925,"Skein1024-48":45926,"Skein1024-56":45927,"Skein1024-64":45928,"Skein1024-72":45929,"Skein1024-80":45930,"Skein1024-88":45931,"Skein1024-96":45932,"Skein1024-104":45933,"Skein1024-112":45934,"Skein1024-120":45935,"Skein1024-128":45936,"Skein1024-136":45937,"Skein1024-144":45938,"Skein1024-152":45939,"Skein1024-160":45940,"Skein1024-168":45941,"Skein1024-176":45942,"Skein1024-184":45943,"Skein1024-192":45944,"Skein1024-200":45945,"Skein1024-208":45946,"Skein1024-216":45947,"Skein1024-224":45948,"Skein1024-232":45949,"Skein1024-240":45950,"Skein1024-248":45951,"Skein1024-256":45952,"Skein1024-264":45953,"Skein1024-272":45954,"Skein1024-280":45955,"Skein1024-288":45956,"Skein1024-296":45957,"Skein1024-304":45958,"Skein1024-312":45959,"Skein1024-320":45960,"Skein1024-328":45961,"Skein1024-336":45962,"Skein1024-344":45963,"Skein1024-352":45964,"Skein1024-360":45965,"Skein1024-368":45966,"Skein1024-376":45967,"Skein1024-384":45968,"Skein1024-392":45969,"Skein1024-400":45970,"Skein1024-408":45971,"Skein1024-416":45972,"Skein1024-424":45973,"Skein1024-432":45974,"Skein1024-440":45975,"Skein1024-448":45976,"Skein1024-456":45977,"Skein1024-464":45978,"Skein1024-472":45979,"Skein1024-480":45980,"Skein1024-488":45981,"Skein1024-496":45982,"Skein1024-504":45983,"Skein1024-512":45984,"Skein1024-520":45985,"Skein1024-528":45986,"Skein1024-536":45987,"Skein1024-544":45988,"Skein1024-552":45989,"Skein1024-560":45990,"Skein1024-568":45991,"Skein1024-576":45992,"Skein1024-584":45993,"Skein1024-592":45994,"Skein1024-600":45995,"Skein1024-608":45996,"Skein1024-616":45997,"Skein1024-624":45998,"Skein1024-632":45999,"Skein1024-640":46e3,"Skein1024-648":46001,"Skein1024-656":46002,"Skein1024-664":46003,"Skein1024-672":46004,"Skein1024-680":46005,"Skein1024-688":46006,"Skein1024-696":46007,"Skein1024-704":46008,"Skein1024-712":46009,"Skein1024-720":46010,"Skein1024-728":46011,"Skein1024-736":46012,"Skein1024-744":46013,"Skein1024-752":46014,"Skein1024-760":46015,"Skein1024-768":46016,"Skein1024-776":46017,"Skein1024-784":46018,"Skein1024-792":46019,"Skein1024-800":46020,"Skein1024-808":46021,"Skein1024-816":46022,"Skein1024-824":46023,"Skein1024-832":46024,"Skein1024-840":46025,"Skein1024-848":46026,"Skein1024-856":46027,"Skein1024-864":46028,"Skein1024-872":46029,"Skein1024-880":46030,"Skein1024-888":46031,"Skein1024-896":46032,"Skein1024-904":46033,"Skein1024-912":46034,"Skein1024-920":46035,"Skein1024-928":46036,"Skein1024-936":46037,"Skein1024-944":46038,"Skein1024-952":46039,"Skein1024-960":46040,"Skein1024-968":46041,"Skein1024-976":46042,"Skein1024-984":46043,"Skein1024-992":46044,"Skein1024-1000":46045,"Skein1024-1008":46046,"Skein1024-1016":46047,"Skein1024-1024":46048}),t.codes=Object.freeze({0:"identity",17:"sha1",18:"sha2-256",19:"sha2-512",86:"dbl-sha2-256",23:"sha3-224",22:"sha3-256",21:"sha3-384",20:"sha3-512",24:"shake-128",25:"shake-256",26:"keccak-224",27:"keccak-256",28:"keccak-384",29:"keccak-512",34:"murmur3-128",35:"murmur3-32",212:"md4",213:"md5",45569:"blake2b-8",45570:"blake2b-16",45571:"blake2b-24",45572:"blake2b-32",45573:"blake2b-40",45574:"blake2b-48",45575:"blake2b-56",45576:"blake2b-64",45577:"blake2b-72",45578:"blake2b-80",45579:"blake2b-88",45580:"blake2b-96",45581:"blake2b-104",45582:"blake2b-112",45583:"blake2b-120",45584:"blake2b-128",45585:"blake2b-136",45586:"blake2b-144",45587:"blake2b-152",45588:"blake2b-160",45589:"blake2b-168",45590:"blake2b-176",45591:"blake2b-184",45592:"blake2b-192",45593:"blake2b-200",45594:"blake2b-208",45595:"blake2b-216",45596:"blake2b-224",45597:"blake2b-232",45598:"blake2b-240",45599:"blake2b-248",45600:"blake2b-256",45601:"blake2b-264",45602:"blake2b-272",45603:"blake2b-280",45604:"blake2b-288",45605:"blake2b-296",45606:"blake2b-304",45607:"blake2b-312",45608:"blake2b-320",45609:"blake2b-328",45610:"blake2b-336",45611:"blake2b-344",45612:"blake2b-352",45613:"blake2b-360",45614:"blake2b-368",45615:"blake2b-376",45616:"blake2b-384",45617:"blake2b-392",45618:"blake2b-400",45619:"blake2b-408",45620:"blake2b-416",45621:"blake2b-424",45622:"blake2b-432",45623:"blake2b-440",45624:"blake2b-448",45625:"blake2b-456",45626:"blake2b-464",45627:"blake2b-472",45628:"blake2b-480",45629:"blake2b-488",45630:"blake2b-496",45631:"blake2b-504",45632:"blake2b-512",45633:"blake2s-8",45634:"blake2s-16",45635:"blake2s-24",45636:"blake2s-32",45637:"blake2s-40",45638:"blake2s-48",45639:"blake2s-56",45640:"blake2s-64",45641:"blake2s-72",45642:"blake2s-80",45643:"blake2s-88",45644:"blake2s-96",45645:"blake2s-104",45646:"blake2s-112",45647:"blake2s-120",45648:"blake2s-128",45649:"blake2s-136",45650:"blake2s-144",45651:"blake2s-152",45652:"blake2s-160",45653:"blake2s-168",45654:"blake2s-176",45655:"blake2s-184",45656:"blake2s-192",45657:"blake2s-200",45658:"blake2s-208",45659:"blake2s-216",45660:"blake2s-224",45661:"blake2s-232",45662:"blake2s-240",45663:"blake2s-248",45664:"blake2s-256",45825:"Skein256-8",45826:"Skein256-16",45827:"Skein256-24",45828:"Skein256-32",45829:"Skein256-40",45830:"Skein256-48",45831:"Skein256-56",45832:"Skein256-64",45833:"Skein256-72",45834:"Skein256-80",45835:"Skein256-88",45836:"Skein256-96",45837:"Skein256-104",45838:"Skein256-112",45839:"Skein256-120",45840:"Skein256-128",45841:"Skein256-136",45842:"Skein256-144",45843:"Skein256-152",45844:"Skein256-160",45845:"Skein256-168",45846:"Skein256-176",45847:"Skein256-184",45848:"Skein256-192",45849:"Skein256-200",45850:"Skein256-208",45851:"Skein256-216",45852:"Skein256-224",45853:"Skein256-232",45854:"Skein256-240",45855:"Skein256-248",45856:"Skein256-256",45857:"Skein512-8",45858:"Skein512-16",45859:"Skein512-24",45860:"Skein512-32",45861:"Skein512-40",45862:"Skein512-48",45863:"Skein512-56",45864:"Skein512-64",45865:"Skein512-72",45866:"Skein512-80",45867:"Skein512-88",45868:"Skein512-96",45869:"Skein512-104",45870:"Skein512-112",45871:"Skein512-120",45872:"Skein512-128",45873:"Skein512-136",45874:"Skein512-144",45875:"Skein512-152",45876:"Skein512-160",45877:"Skein512-168",45878:"Skein512-176",45879:"Skein512-184",45880:"Skein512-192",45881:"Skein512-200",45882:"Skein512-208",45883:"Skein512-216",45884:"Skein512-224",45885:"Skein512-232",45886:"Skein512-240",45887:"Skein512-248",45888:"Skein512-256",45889:"Skein512-264",45890:"Skein512-272",45891:"Skein512-280",45892:"Skein512-288",45893:"Skein512-296",45894:"Skein512-304",45895:"Skein512-312",45896:"Skein512-320",45897:"Skein512-328",45898:"Skein512-336",45899:"Skein512-344",45900:"Skein512-352",45901:"Skein512-360",45902:"Skein512-368",45903:"Skein512-376",45904:"Skein512-384",45905:"Skein512-392",45906:"Skein512-400",45907:"Skein512-408",45908:"Skein512-416",45909:"Skein512-424",45910:"Skein512-432",45911:"Skein512-440",45912:"Skein512-448",45913:"Skein512-456",45914:"Skein512-464",45915:"Skein512-472",45916:"Skein512-480",45917:"Skein512-488",45918:"Skein512-496",45919:"Skein512-504",45920:"Skein512-512",45921:"Skein1024-8",45922:"Skein1024-16",45923:"Skein1024-24",45924:"Skein1024-32",45925:"Skein1024-40",45926:"Skein1024-48",45927:"Skein1024-56",45928:"Skein1024-64",45929:"Skein1024-72",45930:"Skein1024-80",45931:"Skein1024-88",45932:"Skein1024-96",45933:"Skein1024-104",45934:"Skein1024-112",45935:"Skein1024-120",45936:"Skein1024-128",45937:"Skein1024-136",45938:"Skein1024-144",45939:"Skein1024-152",45940:"Skein1024-160",45941:"Skein1024-168",45942:"Skein1024-176",45943:"Skein1024-184",45944:"Skein1024-192",45945:"Skein1024-200",45946:"Skein1024-208",45947:"Skein1024-216",45948:"Skein1024-224",45949:"Skein1024-232",45950:"Skein1024-240",45951:"Skein1024-248",45952:"Skein1024-256",45953:"Skein1024-264",45954:"Skein1024-272",45955:"Skein1024-280",45956:"Skein1024-288",45957:"Skein1024-296",45958:"Skein1024-304",45959:"Skein1024-312",45960:"Skein1024-320",45961:"Skein1024-328",45962:"Skein1024-336",45963:"Skein1024-344",45964:"Skein1024-352",45965:"Skein1024-360",45966:"Skein1024-368",45967:"Skein1024-376",45968:"Skein1024-384",45969:"Skein1024-392",45970:"Skein1024-400",45971:"Skein1024-408",45972:"Skein1024-416",45973:"Skein1024-424",45974:"Skein1024-432",45975:"Skein1024-440",45976:"Skein1024-448",45977:"Skein1024-456",45978:"Skein1024-464",45979:"Skein1024-472",45980:"Skein1024-480",45981:"Skein1024-488",45982:"Skein1024-496",45983:"Skein1024-504",45984:"Skein1024-512",45985:"Skein1024-520",45986:"Skein1024-528",45987:"Skein1024-536",45988:"Skein1024-544",45989:"Skein1024-552",45990:"Skein1024-560",45991:"Skein1024-568",45992:"Skein1024-576",45993:"Skein1024-584",45994:"Skein1024-592",45995:"Skein1024-600",45996:"Skein1024-608",45997:"Skein1024-616",45998:"Skein1024-624",45999:"Skein1024-632",46e3:"Skein1024-640",46001:"Skein1024-648",46002:"Skein1024-656",46003:"Skein1024-664",46004:"Skein1024-672",46005:"Skein1024-680",46006:"Skein1024-688",46007:"Skein1024-696",46008:"Skein1024-704",46009:"Skein1024-712",46010:"Skein1024-720",46011:"Skein1024-728",46012:"Skein1024-736",46013:"Skein1024-744",46014:"Skein1024-752",46015:"Skein1024-760",46016:"Skein1024-768",46017:"Skein1024-776",46018:"Skein1024-784",46019:"Skein1024-792",46020:"Skein1024-800",46021:"Skein1024-808",46022:"Skein1024-816",46023:"Skein1024-824",46024:"Skein1024-832",46025:"Skein1024-840",46026:"Skein1024-848",46027:"Skein1024-856",46028:"Skein1024-864",46029:"Skein1024-872",46030:"Skein1024-880",46031:"Skein1024-888",46032:"Skein1024-896",46033:"Skein1024-904",46034:"Skein1024-912",46035:"Skein1024-920",46036:"Skein1024-928",46037:"Skein1024-936",46038:"Skein1024-944",46039:"Skein1024-952",46040:"Skein1024-960",46041:"Skein1024-968",46042:"Skein1024-976",46043:"Skein1024-984",46044:"Skein1024-992",46045:"Skein1024-1000",46046:"Skein1024-1008",46047:"Skein1024-1016",46048:"Skein1024-1024"}),t.defaultLengths=Object.freeze({17:20,18:32,19:64,86:32,23:28,22:32,21:48,20:64,24:32,25:64,26:28,27:32,28:48,29:64,34:32,45569:1,45570:2,45571:3,45572:4,45573:5,45574:6,45575:7,45576:8,45577:9,45578:10,45579:11,45580:12,45581:13,45582:14,45583:15,45584:16,45585:17,45586:18,45587:19,45588:20,45589:21,45590:22,45591:23,45592:24,45593:25,45594:26,45595:27,45596:28,45597:29,45598:30,45599:31,45600:32,45601:33,45602:34,45603:35,45604:36,45605:37,45606:38,45607:39,45608:40,45609:41,45610:42,45611:43,45612:44,45613:45,45614:46,45615:47,45616:48,45617:49,45618:50,45619:51,45620:52,45621:53,45622:54,45623:55,45624:56,45625:57,45626:58,45627:59,45628:60,45629:61,45630:62,45631:63,45632:64,45633:1,45634:2,45635:3,45636:4,45637:5,45638:6,45639:7,45640:8,45641:9,45642:10,45643:11,45644:12,45645:13,45646:14,45647:15,45648:16,45649:17,45650:18,45651:19,45652:20,45653:21,45654:22,45655:23,45656:24,45657:25,45658:26,45659:27,45660:28,45661:29,45662:30,45663:31,45664:32,45825:1,45826:2,45827:3,45828:4,45829:5,45830:6,45831:7,45832:8,45833:9,45834:10,45835:11,45836:12,45837:13,45838:14,45839:15,45840:16,45841:17,45842:18,45843:19,45844:20,45845:21,45846:22,45847:23,45848:24,45849:25,45850:26,45851:27,45852:28,45853:29,45854:30,45855:31,45856:32,45857:1,45858:2,45859:3,45860:4,45861:5,45862:6,45863:7,45864:8,45865:9,45866:10,45867:11,45868:12,45869:13,45870:14,45871:15,45872:16,45873:17,45874:18,45875:19,45876:20,45877:21,45878:22,45879:23,45880:24,45881:25,45882:26,45883:27,45884:28,45885:29,45886:30,45887:31,45888:32,45889:33,45890:34,45891:35,45892:36,45893:37,45894:38,45895:39,45896:40,45897:41,45898:42,45899:43,45900:44,45901:45,45902:46,45903:47,45904:48,45905:49,45906:50,45907:51,45908:52,45909:53,45910:54,45911:55,45912:56,45913:57,45914:58,45915:59,45916:60,45917:61,45918:62,45919:63,45920:64,45921:1,45922:2,45923:3,45924:4,45925:5,45926:6,45927:7,45928:8,45929:9,45930:10,45931:11,45932:12,45933:13,45934:14,45935:15,45936:16,45937:17,45938:18,45939:19,45940:20,45941:21,45942:22,45943:23,45944:24,45945:25,45946:26,45947:27,45948:28,45949:29,45950:30,45951:31,45952:32,45953:33,45954:34,45955:35,45956:36,45957:37,45958:38,45959:39,45960:40,45961:41,45962:42,45963:43,45964:44,45965:45,45966:46,45967:47,45968:48,45969:49,45970:50,45971:51,45972:52,45973:53,45974:54,45975:55,45976:56,45977:57,45978:58,45979:59,45980:60,45981:61,45982:62,45983:63,45984:64,45985:65,45986:66,45987:67,45988:68,45989:69,45990:70,45991:71,45992:72,45993:73,45994:74,45995:75,45996:76,45997:77,45998:78,45999:79,46e3:80,46001:81,46002:82,46003:83,46004:84,46005:85,46006:86,46007:87,46008:88,46009:89,46010:90,46011:91,46012:92,46013:93,46014:94,46015:95,46016:96,46017:97,46018:98,46019:99,46020:100,46021:101,46022:102,46023:103,46024:104,46025:105,46026:106,46027:107,46028:108,46029:109,46030:110,46031:111,46032:112,46033:113,46034:114,46035:115,46036:116,46037:117,46038:118,46039:119,46040:120,46041:121,46042:122,46043:123,46044:124,46045:125,46046:126,46047:127,46048:128})},7748:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(2592),o=r(6657),a=r(1269);function s(e){t.decode(e)}t.names=a.names,t.codes=a.codes,t.defaultLengths=a.defaultLengths,t.toHexString=function(e){if(!n.isBuffer(e))throw new Error("must be passed a buffer");return e.toString("hex")},t.fromHexString=function(e){return n.from(e,"hex")},t.toB58String=function(e){if(!n.isBuffer(e))throw new Error("must be passed a buffer");return i.encode("base58btc",e).toString().slice(1)},t.fromB58String=function(e){var t=e;return n.isBuffer(e)&&(t=e.toString()),i.decode("z"+t)},t.decode=function(e){if(!n.isBuffer(e))throw new Error("multihash must be a Buffer");if(e.length<2)throw new Error("multihash too short. must be > 2 bytes.");var r=o.decode(e);if(!t.isValidCode(r))throw new Error("multihash unknown function code: 0x".concat(r.toString(16)));e=e.slice(o.decode.bytes);var i=o.decode(e);if(i<0)throw new Error("multihash invalid length: ".concat(i));if((e=e.slice(o.decode.bytes)).length!==i)throw new Error("multihash length inconsistent: 0x".concat(e.toString("hex")));return{code:r,name:a.codes[r],length:i,digest:e}},t.encode=function(e,r,i){if(!e||void 0===r)throw new Error("multihash encode requires at least two args: digest, code");var a=t.coerceCode(r);if(!n.isBuffer(e))throw new Error("digest should be a Buffer");if(null==i&&(i=e.length),i&&e.length!==i)throw new Error("digest length should be equal to specified length.");return n.concat([n.from(o.encode(a)),n.from(o.encode(i)),e])},t.coerceCode=function(e){var r=e;if("string"==typeof e){if(void 0===a.names[e])throw new Error("Unrecognized hash function named: ".concat(e));r=a.names[e]}if("number"!=typeof r)throw new Error("Hash function code should be a number. Got: ".concat(r));if(void 0===a.codes[r]&&!t.isAppCode(r))throw new Error("Unrecognized function code: ".concat(r));return r},t.isAppCode=function(e){return e>0&&e<16},t.isValidCode=function(e){return!!t.isAppCode(e)||!!a.codes[e]},t.validate=s,t.prefix=function(e){return s(e),e.slice(0,2)}},7277:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(6931);e.exports=function(e){if("string"==typeof e||"number"==typeof e){var t=new i(1),r=String(e).toLowerCase().trim(),a="0x"===r.substr(0,2)||"-0x"===r.substr(0,3),s=o(r);if("-"===s.substr(0,1)&&(s=o(s.slice(1)),t=new i(-1,10)),!(s=""===s?"0":s).match(/^-?[0-9]+$/)&&s.match(/^[0-9A-Fa-f]+$/)||s.match(/^[a-fA-F]+$/)||!0===a&&s.match(/^[0-9A-Fa-f]+$/))return new i(s,16).mul(t);if((s.match(/^-?[0-9]+$/)||""===s)&&!1===a)return new i(s,10).mul(t)}else if("object"===(0,n.default)(e)&&e.toString&&!e.pop&&!e.push&&e.toString(10).match(/^-?[0-9]+$/)&&(e.mul||e.dividedToIntegerBy))return new i(e.toString(10),10);throw new Error("[number-to-bn] while converting number "+JSON.stringify(e)+" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.")}},3103:e=>{"use strict";var t=Object.getOwnPropertySymbols,r=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function i(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,o){for(var a,s,u=i(e),c=1;c{"use strict";var n,i,o;e=r.nmd(e);var a,s=r(8847)(r(3355));"undefined"!=typeof self&&self,a=function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=7)}([function(e,t,r){r.d(t,"j",(function(){return i})),r.d(t,"d",(function(){return o})),r.d(t,"c",(function(){return a})),r.d(t,"h",(function(){return s})),r.d(t,"b",(function(){return u})),r.d(t,"k",(function(){return c})),r.d(t,"e",(function(){return l})),r.d(t,"g",(function(){return f})),r.d(t,"i",(function(){return h})),r.d(t,"a",(function(){return d})),r.d(t,"f",(function(){return p}));var n=r(1),i=c((function(e,t){var r=t.length;return c((function(n){for(var i=0;i0&&(i=r),r=e[c++]);)switch(J++,"\n"===r?(G++,z=0):z++,U){case d:if("{"===r)U=m;else if("["===r)U=g;else if(!K(r))return q("Non-whitespace before {[.");continue;case w:case m:if(K(r))continue;if(U===w)F.push(A);else{if("}"===r){s({}),u(),U=F.pop()||p;continue}F.push(y)}if('"'!==r)return q('Malformed object key should start with " ');U=v;continue;case A:case y:if(K(r))continue;if(":"===r)U===y?(F.push(y),void 0!==o&&(s({}),a(o),o=void 0),H++):void 0!==o&&(a(o),o=void 0),U=p;else if("}"===r)void 0!==o&&(s(o),u(),o=void 0),u(),H--,U=F.pop()||p;else{if(","!==r)return q("Bad object");U===y&&F.push(y),void 0!==o&&(s(o),u(),o=void 0),U=w}continue;case g:case p:if(K(r))continue;if(U===g){if(s([]),H++,U=p,"]"===r){u(),H--,U=F.pop()||p;continue}F.push(b)}if('"'===r)U=v;else if("{"===r)U=m;else if("["===r)U=g;else if("t"===r)U=S;else if("f"===r)U=_;else if("n"===r)U=P;else if("-"===r)B+=r;else if("0"===r)B+=r,U=20;else{if(-1==="123456789".indexOf(r))return q("Bad value");B+=r,U=20}continue;case b:if(","===r)F.push(b),void 0!==o&&(s(o),u(),o=void 0),U=p;else{if("]"!==r){if(K(r))continue;return q("Bad array")}void 0!==o&&(s(o),u(),o=void 0),u(),H--,U=F.pop()||p}continue;case v:void 0===o&&(o="");var h=c-1;e:for(;;){for(;j>0;)if(D+=r,r=e.charAt(c++),4===j?(o+=String.fromCharCode(parseInt(D,16)),j=0,h=c-1):j++,!r)break e;if('"'===r&&!N){U=F.pop()||p,o+=e.substring(h,c-1);break}if(!("\\"!==r||N||(N=!0,o+=e.substring(h,c-1),r=e.charAt(c++))))break;if(N){if(N=!1,"n"===r?o+="\n":"r"===r?o+="\r":"t"===r?o+="\t":"f"===r?o+="\f":"b"===r?o+="\b":"u"===r?(j=1,D=""):o+=r,r=e.charAt(c++),h=c-1,r)continue;break}f.lastIndex=c;var V=f.exec(e);if(!V){c=e.length+1,o+=e.substring(h,c-1);break}if(c=V.index+1,!(r=e.charAt(V.index))){o+=e.substring(h,c-1);break}}continue;case S:if(!r)continue;if("r"!==r)return q("Invalid true started with t"+r);U=k;continue;case k:if(!r)continue;if("u"!==r)return q("Invalid true started with tr"+r);U=E;continue;case E:if(!r)continue;if("e"!==r)return q("Invalid true started with tru"+r);s(!0),u(),U=F.pop()||p;continue;case _:if(!r)continue;if("a"!==r)return q("Invalid false started with f"+r);U=M;continue;case M:if(!r)continue;if("l"!==r)return q("Invalid false started with fa"+r);U=T;continue;case T:if(!r)continue;if("s"!==r)return q("Invalid false started with fal"+r);U=x;continue;case x:if(!r)continue;if("e"!==r)return q("Invalid false started with fals"+r);s(!1),u(),U=F.pop()||p;continue;case P:if(!r)continue;if("u"!==r)return q("Invalid null started with n"+r);U=I;continue;case I:if(!r)continue;if("l"!==r)return q("Invalid null started with nu"+r);U=O;continue;case O:if(!r)continue;if("l"!==r)return q("Invalid null started with nul"+r);s(null),u(),U=F.pop()||p;continue;case R:if("."!==r)return q("Leading zero not followed by .");B+=r,U=20;continue;case 20:if(-1!=="0123456789".indexOf(r))B+=r;else if("."===r){if(-1!==B.indexOf("."))return q("Invalid number has two dots");B+=r}else if("e"===r||"E"===r){if(-1!==B.indexOf("e")||-1!==B.indexOf("E"))return q("Invalid number has two exponential");B+=r}else if("+"===r||"-"===r){if("e"!==i&&"E"!==i)return q("Invalid symbol in number");B+=r}else B&&(s(parseFloat(B)),u(),B=""),c--,U=F.pop()||p;continue;default:return q("Unknown state: "+U)}J>=C&&(n=0,void 0!==o&&o.length>l&&(q("Max buffer length exceeded: textNode"),n=Math.max(n,o.length)),B.length>l&&(q("Max buffer length exceeded: numberNode"),n=Math.max(n,B.length)),C=l-n+J)}})),e(n.n).on((function(){if(U===d)return s({}),u(),void(L=!0);U===p&&0===H||q("Unexpected end"),void 0!==o&&(s(o),u(),o=void 0),L=!0}))}},function(e,t,r){r.d(t,"a",(function(){return u})),r.d(t,"b",(function(){return c}));var n=r(19),i=r(3),o=r(2),a=r(20),s=r(0);function u(){return new XMLHttpRequest}function c(e,t,r,u,c,l,f){var h=e(i.m).emit,d=e(i.b).emit,p=0,m=!0;function y(){if("2"===String(t.status)[0]){var e=t.responseText,r=(" "+e.substr(p)).substr(1);r&&h(r),p=Object(o.e)(e)}}function g(t){try{m&&e(i.c).emit(t.status,Object(a.a)(t.getAllResponseHeaders())),m=!1}catch(e){}}e(i.a).on((function(){t.onreadystatechange=null,t.abort()})),"onprogress"in t&&(t.onprogress=y),t.onreadystatechange=function(){switch(t.readyState){case 2:case 3:return g(t);case 4:g(t),"2"===String(t.status)[0]?(y(),e(i.n).emit()):d(Object(i.o)(t.status,t.responseText))}};try{for(var b in t.open(r,u,!0),l)t.setRequestHeader(b,l[b]);Object(n.a)(window.location,Object(n.b)(u))||t.setRequestHeader("X-Requested-With","XMLHttpRequest"),t.withCredentials=f,t.send(c)}catch(e){window.setTimeout(Object(s.j)(d,Object(i.o)(void 0,void 0,e)),0)}}},function(e,t,r){function n(e,t){function r(t){return String(t.port||{"http:":80,"https:":443}[t.protocol||e.protocol])}return!!(t.protocol&&t.protocol!==e.protocol||t.host&&t.host!==e.host||t.host&&r(t)!==r(e))}function i(e){var t=/(\w+:)?(?:\/\/)([\w.-]+)?(?::(\d+))?\/?/.exec(e)||[];return{protocol:t[1]||"",host:t[2]||"",port:t[3]||""}}r.d(t,"a",(function(){return n})),r.d(t,"b",(function(){return i}))},function(e,t,r){function n(e){var t={};return e&&e.split("\r\n").forEach((function(e){var r=e.indexOf(": ");t[e.substring(0,r)]=e.substring(r+2)})),t}r.d(t,"a",(function(){return n}))}]).default},"object"===(0,s.default)(t)&&"object"===(0,s.default)(e)?e.exports=a():(i=[],void 0===(o="function"==typeof(n=a)?n.apply(t,i):n)||(e.exports=o))},1823:(e,t,r)=>{"use strict";var n=r(8357);t.certificate=r(1320);var i=n.define("RSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())}));t.RSAPrivateKey=i;var o=n.define("RSAPublicKey",(function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())}));t.RSAPublicKey=o;var a=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())}));t.PublicKey=a;var s=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())})),u=n.define("PrivateKeyInfo",(function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(s),this.key("subjectPrivateKey").octstr())}));t.PrivateKey=u;var c=n.define("EncryptedPrivateKeyInfo",(function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())}));t.EncryptedPrivateKey=c;var l=n.define("DSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())}));t.DSAPrivateKey=l,t.DSAparam=n.define("DSAparam",(function(){this.int()}));var f=n.define("ECPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(h),this.key("publicKey").optional().explicit(1).bitstr())}));t.ECPrivateKey=f;var h=n.define("ECParameters",(function(){this.choice({namedCurve:this.objid()})}));t.signature=n.define("signature",(function(){this.seq().obj(this.key("r").int(),this.key("s").int())}))},1320:(e,t,r)=>{"use strict";var n=r(8357),i=n.define("Time",(function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})})),o=n.define("AttributeTypeValue",(function(){this.seq().obj(this.key("type").objid(),this.key("value").any())})),a=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())})),s=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(a),this.key("subjectPublicKey").bitstr())})),u=n.define("RelativeDistinguishedName",(function(){this.setof(o)})),c=n.define("RDNSequence",(function(){this.seqof(u)})),l=n.define("Name",(function(){this.choice({rdnSequence:this.use(c)})})),f=n.define("Validity",(function(){this.seq().obj(this.key("notBefore").use(i),this.key("notAfter").use(i))})),h=n.define("Extension",(function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())})),d=n.define("TBSCertificate",(function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(a),this.key("issuer").use(l),this.key("validity").use(f),this.key("subject").use(l),this.key("subjectPublicKeyInfo").use(s),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(h).optional())})),p=n.define("X509Certificate",(function(){this.seq().obj(this.key("tbsCertificate").use(d),this.key("signatureAlgorithm").use(a),this.key("signatureValue").bitstr())}));e.exports=p},4988:(e,t,r)=>{"use strict";var n=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,i=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,o=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,a=r(7085),s=r(8073),u=r(8850).Buffer;e.exports=function(e,t){var r,c=e.toString(),l=c.match(n);if(l){var f="aes"+l[1],h=u.from(l[2],"hex"),d=u.from(l[3].replace(/[\r\n]/g,""),"base64"),p=a(t,h.slice(0,8),parseInt(l[1],10)).key,m=[],y=s.createDecipheriv(f,p,h);m.push(y.update(d)),m.push(y.final()),r=u.concat(m)}else{var g=c.match(o);r=u.from(g[2].replace(/[\r\n]/g,""),"base64")}return{tag:c.match(i)[1],data:r}}},7552:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1823),o=r(2562),a=r(4988),s=r(8073),u=r(4192),c=r(8850).Buffer;function l(e){var t;"object"!==(0,n.default)(e)||c.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=c.from(e));var r,l,f=a(e,t),h=f.tag,d=f.data;switch(h){case"CERTIFICATE":l=i.certificate.decode(d,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(l||(l=i.PublicKey.decode(d,"der")),r=l.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return i.RSAPublicKey.decode(l.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return l.subjectPrivateKey=l.subjectPublicKey,{type:"ec",data:l};case"1.2.840.10040.4.1":return l.algorithm.params.pub_key=i.DSAparam.decode(l.subjectPublicKey.data,"der"),{type:"dsa",data:l.algorithm.params};default:throw new Error("unknown key id "+r)}case"ENCRYPTED PRIVATE KEY":d=function(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,n=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),i=o[e.algorithm.decrypt.cipher.algo.join(".")],a=e.algorithm.decrypt.cipher.iv,l=e.subjectPrivateKey,f=parseInt(i.split("-")[1],10)/8,h=u.pbkdf2Sync(t,r,n,f,"sha1"),d=s.createDecipheriv(i,h,a),p=[];return p.push(d.update(l)),p.push(d.final()),c.concat(p)}(d=i.EncryptedPrivateKey.decode(d,"der"),t);case"PRIVATE KEY":switch(r=(l=i.PrivateKey.decode(d,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return i.RSAPrivateKey.decode(l.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:l.algorithm.curve,privateKey:i.ECPrivateKey.decode(l.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return l.algorithm.params.priv_key=i.DSAparam.decode(l.subjectPrivateKey,"der"),{type:"dsa",params:l.algorithm.params};default:throw new Error("unknown key id "+r)}case"RSA PUBLIC KEY":return i.RSAPublicKey.decode(d,"der");case"RSA PRIVATE KEY":return i.RSAPrivateKey.decode(d,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:i.DSAPrivateKey.decode(d,"der")};case"EC PRIVATE KEY":return{curve:(d=i.ECPrivateKey.decode(d,"der")).parameters.value,privateKey:d.privateKey};default:throw new Error("unknown key type "+h)}}e.exports=l,l.signature=i.signature},8209:e=>{"use strict";var t=function(e){return e.replace(/^\s+|\s+$/g,"")};e.exports=function(e){if(!e)return{};for(var r,n={},i=t(e).split("\n"),o=0;o{"use strict";t.pbkdf2=r(1882),t.pbkdf2Sync=r(1658)},1882:(e,t,r)=>{"use strict";var n,i,o=r(8850).Buffer,a=r(3127),s=r(7401),u=r(1658),c=r(8398),l=r.g.crypto&&r.g.crypto.subtle,f={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},h=[];function d(){return i||(i=r.g.process&&r.g.process.nextTick?r.g.process.nextTick:r.g.queueMicrotask?r.g.queueMicrotask:r.g.setImmediate?r.g.setImmediate:r.g.setTimeout)}function p(e,t,r,n,i){return l.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then((function(e){return l.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},e,n<<3)})).then((function(e){return o.from(e)}))}e.exports=function(e,t,i,m,y,g){"function"==typeof y&&(g=y,y=void 0);var b=f[(y=y||"sha1").toLowerCase()];if(b&&"function"==typeof r.g.Promise){if(a(i,m),e=c(e,s,"Password"),t=c(t,s,"Salt"),"function"!=typeof g)throw new Error("No callback provided to pbkdf2");!function(e,t){e.then((function(e){d()((function(){t(null,e)}))}),(function(e){d()((function(){t(e)}))}))}(function(e){if(r.g.process&&!r.g.process.browser)return Promise.resolve(!1);if(!l||!l.importKey||!l.deriveBits)return Promise.resolve(!1);if(void 0!==h[e])return h[e];var t=p(n=n||o.alloc(8),n,10,128,e).then((function(){return!0})).catch((function(){return!1}));return h[e]=t,t}(b).then((function(r){return r?p(e,t,i,m,b):u(e,t,i,m,y)})),g)}else d()((function(){var r;try{r=u(e,t,i,m,y)}catch(e){return g(e)}g(null,r)}))}},7401:(e,t,r)=>{"use strict";var n,i=r(9142);n=r.g.process&&r.g.process.browser?"utf-8":r.g.process&&r.g.process.version?parseInt(i.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary":"utf-8",e.exports=n},3127:e=>{"use strict";var t=Math.pow(2,30)-1;e.exports=function(e,r){if("number"!=typeof e)throw new TypeError("Iterations not a number");if(e<0)throw new TypeError("Bad iterations");if("number"!=typeof r)throw new TypeError("Key length not a number");if(r<0||r>t||r!=r)throw new TypeError("Bad key length")}},1658:(e,t,r)=>{"use strict";var n=r(5349),i=r(6707),o=r(1708),a=r(8850).Buffer,s=r(3127),u=r(7401),c=r(8398),l=a.alloc(128),f={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function h(e,t,r){var s=function(e){return"rmd160"===e||"ripemd160"===e?function(e){return(new i).update(e).digest()}:"md5"===e?n:function(t){return o(e).update(t).digest()}}(e),u="sha512"===e||"sha384"===e?128:64;t.length>u?t=s(t):t.length{"use strict";var n=r(8850).Buffer;e.exports=function(e,t,r){if(n.isBuffer(e))return e;if("string"==typeof e)return n.from(e,t);if(ArrayBuffer.isView(e))return n.from(e.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")}},9142:e=>{"use strict";var t,r,n=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===i||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:i}catch(e){t=i}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(e){r=o}}();var s,u=[],c=!1,l=-1;function f(){c&&s&&(c=!1,s.length?u=s.concat(u):l=-1,u.length&&h())}function h(){if(!c){var e=a(f);c=!0;for(var t=u.length;t;){for(s=u,u=[];++l1)for(var r=1;r{"use strict";t.publicEncrypt=r(2466),t.privateDecrypt=r(3144),t.privateEncrypt=function(e,r){return t.publicEncrypt(e,r,!0)},t.publicDecrypt=function(e,r){return t.privateDecrypt(e,r,!0)}},6873:(e,t,r)=>{"use strict";var n=r(5866),i=r(8850).Buffer;function o(e){var t=i.allocUnsafe(4);return t.writeUInt32BE(e,0),t}e.exports=function(e,t){for(var r,a=i.alloc(0),s=0;a.length{"use strict";var n=r(7552),i=r(6873),o=r(817),a=r(1734),s=r(9782),u=r(5866),c=r(2561),l=r(8850).Buffer;e.exports=function(e,t,r){var f;f=e.padding?e.padding:r?1:4;var h,d=n(e),p=d.modulus.byteLength();if(t.length>p||new a(t).cmp(d.modulus)>=0)throw new Error("decryption error");h=r?c(new a(t),d):s(t,d);var m=l.alloc(p-h.length);if(h=l.concat([m,h],p),4===f)return function(e,t){var r=e.modulus.byteLength(),n=u("sha1").update(l.alloc(0)).digest(),a=n.length;if(0!==t[0])throw new Error("decryption error");var s=t.slice(1,a+1),c=t.slice(a+1),f=o(s,i(c,a)),h=o(c,i(f,r-a-1));if(function(e,t){e=l.from(e),t=l.from(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));for(var i=-1;++i=t.length){o++;break}var a=t.slice(2,i-1);if(("0002"!==n.toString("hex")&&!r||"0001"!==n.toString("hex")&&r)&&o++,a.length<8&&o++,o)throw new Error("decryption error");return t.slice(i)}(0,h,r);if(3===f)return h;throw new Error("unknown padding")}},2466:(e,t,r)=>{"use strict";var n=r(7552),i=r(5010),o=r(5866),a=r(6873),s=r(817),u=r(1734),c=r(2561),l=r(9782),f=r(8850).Buffer;e.exports=function(e,t,r){var h;h=e.padding?e.padding:r?1:4;var d,p=n(e);if(4===h)d=function(e,t){var r=e.modulus.byteLength(),n=t.length,c=o("sha1").update(f.alloc(0)).digest(),l=c.length,h=2*l;if(n>r-h-2)throw new Error("message too long");var d=f.alloc(r-n-h-2),p=r-l-1,m=i(l),y=s(f.concat([c,d,f.alloc(1,1),t],p),a(m,p)),g=s(m,a(y,l));return new u(f.concat([f.alloc(1),g,y],r))}(p,t);else if(1===h)d=function(e,t,r){var n,o=t.length,a=e.modulus.byteLength();if(o>a-11)throw new Error("message too long");return n=r?f.alloc(a-o-3,255):function(e){for(var t,r=f.allocUnsafe(e),n=0,o=i(2*e),a=0;n=0)throw new Error("data too long for modulus")}return r?l(d,p):c(d,p)}},2561:(e,t,r)=>{"use strict";var n=r(1734),i=r(8850).Buffer;e.exports=function(e,t){return i.from(e.toRed(n.mont(t.modulus)).redPow(new n(t.publicExponent)).fromRed().toArray())}},817:e=>{"use strict";e.exports=function(e,t){for(var r=e.length,n=-1;++n{"use strict";var n=r(9142),i=65536,o=r(8850).Buffer,a=r.g.crypto||r.g.msCrypto;a&&a.getRandomValues?e.exports=function(e,t){if(e>4294967295)throw new RangeError("requested too many random bytes");var r=o.allocUnsafe(e);if(e>0)if(e>i)for(var s=0;s{"use strict";var n=r(9142);function i(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var o=r(8850),a=r(5010),s=o.Buffer,u=o.kMaxLength,c=r.g.crypto||r.g.msCrypto,l=Math.pow(2,32)-1;function f(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(e>l||e<0)throw new TypeError("offset must be a uint32");if(e>u||e>t)throw new RangeError("offset out of range")}function h(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(e>l||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>u)throw new RangeError("buffer too small")}function d(e,t,r,i){if(n.browser){var o=e.buffer,s=new Uint8Array(o,t,r);return c.getRandomValues(s),i?void n.nextTick((function(){i(null,e)})):e}if(!i)return a(r).copy(e,t),e;a(r,(function(r,n){if(r)return i(r);n.copy(e,t),i(null,e)}))}c&&c.getRandomValues||!n.browser?(t.randomFill=function(e,t,n,i){if(!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof t)i=t,t=0,n=e.length;else if("function"==typeof n)i=n,n=e.length-t;else if("function"!=typeof i)throw new TypeError('"cb" argument must be a function');return f(t,e.length),h(n,t,e.length),d(e,t,n,i)},t.randomFillSync=function(e,t,n){if(void 0===t&&(t=0),!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return f(t,e.length),void 0===n&&(n=e.length-t),h(n,t,e.length),d(e,t,n)}):(t.randomFill=i,t.randomFillSync=i)},9024:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i={};function o(e,t,r){r||(r=Error);var n=function(e){var r,n;function i(r,n,i){return e.call(this,function(e,r,n){return"string"==typeof t?t:t(e,r,n)}(r,n,i))||this}return n=e,(r=i).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,i}(r);n.prototype.name=r.name,n.prototype.code=e,i[e]=n}function a(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map((function(e){return String(e)})),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}o("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),o("ERR_INVALID_ARG_TYPE",(function(e,t,r){var i,o,s,u,c;if("string"==typeof t&&(o="not ",t.substr(0,o.length)===o)?(i="must not be",t=t.replace(/^not /,"")):i="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))s="The ".concat(e," ").concat(i," ").concat(a(t,"type"));else{var l=("number"!=typeof c&&(c=0),c+".".length>(u=e).length||-1===u.indexOf(".",c)?"argument":"property");s='The "'.concat(e,'" ').concat(l," ").concat(i," ").concat(a(t,"type"))}return s+". Received type ".concat((0,n.default)(r))}),TypeError),o("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),o("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),o("ERR_STREAM_PREMATURE_CLOSE","Premature close"),o("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),o("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),o("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),o("ERR_STREAM_WRITE_AFTER_END","write after end"),o("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),o("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),o("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.q=i},6884:(e,t,r)=>{"use strict";var n=r(9142),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=l;var o=r(6297),a=r(1471);r(1736)(l,o);for(var s=i(a.prototype),u=0;u{"use strict";e.exports=i;var n=r(9154);function i(e){if(!(this instanceof i))return new i(e);n.call(this,e)}r(1736)(i,n),i.prototype._transform=function(e,t,r){r(null,e)}},6297:(e,t,r)=>{"use strict";var n,i=r(9142);e.exports=_,_.ReadableState=E,r(8291).EventEmitter;var o,a=function(e,t){return e.listeners(t).length},s=r(7144),u=r(9033).Buffer,c=r.g.Uint8Array||function(){},l=r(4616);o=l&&l.debuglog?l.debuglog("stream"):function(){};var f,h,d,p=r(5392),m=r(7572),y=r(6756).getHighWaterMark,g=r(9024).q,b=g.ERR_INVALID_ARG_TYPE,v=g.ERR_STREAM_PUSH_AFTER_EOF,w=g.ERR_METHOD_NOT_IMPLEMENTED,A=g.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(1736)(_,s);var S=m.errorOrDestroy,k=["error","close","destroy","pause","resume"];function E(e,t,i){n=n||r(6884),e=e||{},"boolean"!=typeof i&&(i=t instanceof n),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",i),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(f||(f=r(3462).s),this.decoder=new f(e.encoding),this.encoding=e.encoding)}function _(e){if(n=n||r(6884),!(this instanceof _))return new _(e);var t=this instanceof n;this._readableState=new E(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),s.call(this)}function M(e,t,r,n,i){o("readableAddChunk",t);var a,s=e._readableState;if(null===t)s.reading=!1,function(e,t){if(o("onEofChunk"),!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?I(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,O(e)))}}(e,s);else if(i||(a=function(e,t){var r,n;return n=t,u.isBuffer(n)||n instanceof c||"string"==typeof t||void 0===t||e.objectMode||(r=new b("chunk",["string","Buffer","Uint8Array"],t)),r}(s,t)),a)S(e,a);else if(s.objectMode||t&&t.length>0)if("string"==typeof t||s.objectMode||Object.getPrototypeOf(t)===u.prototype||(t=function(e){return u.from(e)}(t)),n)s.endEmitted?S(e,new A):T(e,s,t,!0);else if(s.ended)S(e,new v);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(t=s.decoder.write(t),s.objectMode||0!==t.length?T(e,s,t,!1):R(e,s)):T(e,s,t,!1)}else n||(s.reading=!1,R(e,s));return!s.ended&&(s.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=x?e=x:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function I(e){var t=e._readableState;o("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(o("emitReadable",t.flowing),t.emittedReadable=!0,i.nextTick(O,e))}function O(e){var t=e._readableState;o("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,U(e)}function R(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(C,e,t))}function C(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function N(e){o("readable nexttick read 0"),e.read(0)}function L(e,t){o("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(o("flow",t.flowing);t.flowing&&null!==e.read(););}function F(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function D(e){var t=e._readableState;o("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,i.nextTick(j,t,e))}function j(e,t){if(o("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function H(e,t){for(var r=0,n=e.length;r=t.highWaterMark:t.length>0)||t.ended))return o("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?D(this):I(this),null;if(0===(e=P(e,t))&&t.ended)return 0===t.length&&D(this),null;var n,i=t.needReadable;return o("need readable",i),(0===t.length||t.length-e0?F(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&D(this)),null!==n&&this.emit("data",n),n},_.prototype._read=function(e){S(this,new w("_read()"))},_.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e)}n.pipesCount+=1,o("pipe count=%d opts=%j",n.pipesCount,t);var s=t&&!1===t.end||e===i.stdout||e===i.stderr?m:u;function u(){o("onend"),e.end()}n.endEmitted?i.nextTick(s):r.once("end",s),e.on("unpipe",(function t(i,a){o("onunpipe"),i===r&&a&&!1===a.hasUnpiped&&(a.hasUnpiped=!0,o("cleanup"),e.removeListener("close",d),e.removeListener("finish",p),e.removeListener("drain",c),e.removeListener("error",h),e.removeListener("unpipe",t),r.removeListener("end",u),r.removeListener("end",m),r.removeListener("data",f),l=!0,!n.awaitDrain||e._writableState&&!e._writableState.needDrain||c())}));var c=function(e){return function(){var t=e._readableState;o("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&a(e,"data")&&(t.flowing=!0,U(e))}}(r);e.on("drain",c);var l=!1;function f(t){o("ondata");var i=e.write(t);o("dest.write",i),!1===i&&((1===n.pipesCount&&n.pipes===e||n.pipesCount>1&&-1!==H(n.pipes,e))&&!l&&(o("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function h(t){o("onerror",t),m(),e.removeListener("error",h),0===a(e,"error")&&S(e,t)}function d(){e.removeListener("finish",p),m()}function p(){o("onfinish"),e.removeListener("close",d),m()}function m(){o("unpipe"),r.unpipe(e)}return r.on("data",f),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",h),e.once("close",d),e.once("finish",p),e.emit("pipe",r),n.flowing||(o("pipe resume"),r.resume()),e},_.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0,!1!==n.flowing&&this.resume()):"readable"===e&&(n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,o("on readable",n.length,n.reading),n.length?I(this):n.reading||i.nextTick(N,this))),r},_.prototype.addListener=_.prototype.on,_.prototype.removeListener=function(e,t){var r=s.prototype.removeListener.call(this,e,t);return"readable"===e&&i.nextTick(B,this),r},_.prototype.removeAllListeners=function(e){var t=s.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||i.nextTick(B,this),t},_.prototype.resume=function(){var e=this._readableState;return e.flowing||(o("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}(this,e)),e.paused=!1,this},_.prototype.pause=function(){return o("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(o("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},_.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",(function(){if(o("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(i){o("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i||(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))})),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var a=0;a{"use strict";e.exports=l;var n=r(9024).q,i=n.ERR_METHOD_NOT_IMPLEMENTED,o=n.ERR_MULTIPLE_CALLBACK,a=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=n.ERR_TRANSFORM_WITH_LENGTH_0,u=r(6884);function c(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length{"use strict";var n,i=r(9142);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(void 0),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}e.exports=_,_.WritableState=E;var a,s={deprecate:r(6219)},u=r(7144),c=r(9033).Buffer,l=r.g.Uint8Array||function(){},f=r(7572),h=r(6756).getHighWaterMark,d=r(9024).q,p=d.ERR_INVALID_ARG_TYPE,m=d.ERR_METHOD_NOT_IMPLEMENTED,y=d.ERR_MULTIPLE_CALLBACK,g=d.ERR_STREAM_CANNOT_PIPE,b=d.ERR_STREAM_DESTROYED,v=d.ERR_STREAM_NULL_VALUES,w=d.ERR_STREAM_WRITE_AFTER_END,A=d.ERR_UNKNOWN_ENCODING,S=f.errorOrDestroy;function k(){}function E(e,t,a){n=n||r(6884),e=e||{},"boolean"!=typeof a&&(a=t instanceof n),this.objectMode=!!e.objectMode,a&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=h(this,e,"writableHighWaterMark",a),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var s=!1===e.decodeStrings;this.decodeStrings=!s,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if("function"!=typeof o)throw new y;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,n,o){--t.pendingcb,r?(i.nextTick(o,n),i.nextTick(O,e,t),e._writableState.errorEmitted=!0,S(e,n)):(o(n),e._writableState.errorEmitted=!0,S(e,n),O(e,t))}(e,r,n,t,o);else{var a=P(r)||e.destroyed;a||r.corked||r.bufferProcessing||!r.bufferedRequest||x(e,r),n?i.nextTick(T,e,r,a,o):T(e,r,a,o)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function _(e){var t=this instanceof(n=n||r(6884));if(!t&&!a.call(_,this))return new _(e);this._writableState=new E(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),u.call(this)}function M(e,t,r,n,i,o,a){t.writelen=n,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new b("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function T(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),O(e,t)}function x(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),a=t.corkedRequestsFree;a.entry=r;for(var s=0,u=!0;r;)i[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;i.allBuffers=u,M(e,t,!0,t.length,i,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,l=r.encoding,f=r.callback;if(M(e,t,!1,t.objectMode?1:c.length,c,l,f),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function P(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function I(e,t){e._final((function(r){t.pendingcb--,r&&S(e,r),t.prefinished=!0,e.emit("prefinish"),O(e,t)}))}function O(e,t){var r=P(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,i.nextTick(I,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}r(1736)(_,u),E.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(E.prototype,"buffer",{get:s.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(a=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!a.call(this,e)||this===_&&e&&e._writableState instanceof E}})):a=function(e){return e instanceof this},_.prototype.pipe=function(){S(this,new g)},_.prototype.write=function(e,t,r){var n,o=this._writableState,a=!1,s=!o.objectMode&&(n=e,c.isBuffer(n)||n instanceof l);return s&&!c.isBuffer(e)&&(e=function(e){return c.from(e)}(e)),"function"==typeof t&&(r=t,t=null),s?t="buffer":t||(t=o.defaultEncoding),"function"!=typeof r&&(r=k),o.ending?function(e,t){var r=new w;S(e,r),i.nextTick(t,r)}(this,r):(s||function(e,t,r,n){var o;return null===r?o=new v:"string"==typeof r||t.objectMode||(o=new p("chunk",["string","Buffer"],r)),!o||(S(e,o),i.nextTick(n,o),!1)}(this,o,e,r))&&(o.pendingcb++,a=function(e,t,r,n,i,o){if(!r){var a=function(e,t,r){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=c.from(t,r)),t}(t,n,i);n!==a&&(r=!0,i="buffer",n=a)}var s=t.objectMode?1:n.length;t.length+=s;var u=t.length-1))throw new A(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(_.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,r){r(new m("_write()"))},_.prototype._writev=null,_.prototype.end=function(e,t,r){var n=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||function(e,t,r){t.ending=!0,O(e,t),r&&(t.finished?i.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}(this,n,r),this},Object.defineProperty(_.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(_.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=f.destroy,_.prototype._undestroy=f.undestroy,_.prototype._destroy=function(e,t){t(e)}},2317:(e,t,r)=>{"use strict";var n,i=r(9142);function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var a=r(5831),s=Symbol("lastResolve"),u=Symbol("lastReject"),c=Symbol("error"),l=Symbol("ended"),f=Symbol("lastPromise"),h=Symbol("handlePromise"),d=Symbol("stream");function p(e,t){return{value:e,done:t}}function m(e){var t=e[s];if(null!==t){var r=e[d].read();null!==r&&(e[f]=null,e[s]=null,e[u]=null,t(p(r,!1)))}}function y(e){i.nextTick(m,e)}var g=Object.getPrototypeOf((function(){})),b=Object.setPrototypeOf((o(n={get stream(){return this[d]},next:function(){var e=this,t=this[c];if(null!==t)return Promise.reject(t);if(this[l])return Promise.resolve(p(void 0,!0));if(this[d].destroyed)return new Promise((function(t,r){i.nextTick((function(){e[c]?r(e[c]):t(p(void 0,!0))}))}));var r,n=this[f];if(n)r=new Promise(function(e,t){return function(r,n){e.then((function(){t[l]?r(p(void 0,!0)):t[h](r,n)}),n)}}(n,this));else{var o=this[d].read();if(null!==o)return Promise.resolve(p(o,!1));r=new Promise(this[h])}return this[f]=r,r}},Symbol.asyncIterator,(function(){return this})),o(n,"return",(function(){var e=this;return new Promise((function(t,r){e[d].destroy(null,(function(e){e?r(e):t(p(void 0,!0))}))}))})),n),g);e.exports=function(e){var t,r=Object.create(b,(o(t={},d,{value:e,writable:!0}),o(t,s,{value:null,writable:!0}),o(t,u,{value:null,writable:!0}),o(t,c,{value:null,writable:!0}),o(t,l,{value:e._readableState.endEmitted,writable:!0}),o(t,h,{value:function(e,t){var n=r[d].read();n?(r[f]=null,r[s]=null,r[u]=null,e(p(n,!1))):(r[s]=e,r[u]=t)},writable:!0}),t));return r[f]=null,a(e,(function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[u];return null!==t&&(r[f]=null,r[s]=null,r[u]=null,t(e)),void(r[c]=e)}var n=r[s];null!==n&&(r[f]=null,r[s]=null,r[u]=null,n(p(void 0,!0))),r[l]=!0})),e.on("readable",y.bind(null,r)),r}},5392:(e,t,r)=>{"use strict";function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var o=r(9033).Buffer,a=r(2361).inspect,s=a&&a.custom||"inspect";e.exports=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.head=null,this.tail=null,this.length=0}var t;return t=[{key:"push",value:function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return o.alloc(0);for(var t,r,n,i=o.allocUnsafe(e>>>0),a=this.head,s=0;a;)t=a.data,r=i,n=s,o.prototype.copy.call(t,r,n),s+=a.data.length,a=a.next;return i}},{key:"consume",value:function(e,t){var r;return ei.length?i.length:e;if(o===i.length?n+=i:n+=i.slice(0,e),0==(e-=o)){o===i.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(e){var t=o.allocUnsafe(e),r=this.head,n=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var i=r.data,a=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,a),0==(e-=a)){a===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(a));break}++n}return this.length-=n,t}},{key:s,value:function(e,t){return a(this,function(e){for(var t=1;t{"use strict";var n=r(9142);function i(e,t){a(e,t),o(e)}function o(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function a(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,s=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return s||u?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,n.nextTick(a,this,e)):n.nextTick(a,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!t&&e?r._writableState?r._writableState.errorEmitted?n.nextTick(o,r):(r._writableState.errorEmitted=!0,n.nextTick(i,r,e)):n.nextTick(i,r,e):t?(n.nextTick(o,r),t(e)):n.nextTick(o,r)})),this)},undestroy:function(){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)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}},5831:(e,t,r)=>{"use strict";var n=r(9024).q.ERR_STREAM_PREMATURE_CLOSE;function i(){}e.exports=function e(t,r,o){if("function"==typeof r)return e(t,null,r);r||(r={}),o=function(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i{"use strict";e.exports=function(){throw new Error("Readable.from is not available in the browser")}},384:(e,t,r)=>{"use strict";var n,i=r(9024).q,o=i.ERR_MISSING_ARGS,a=i.ERR_STREAM_DESTROYED;function s(e){if(e)throw e}function u(e,t,i,o){o=function(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}(o);var s=!1;e.on("close",(function(){s=!0})),void 0===n&&(n=r(5831)),n(e,{readable:t,writable:i},(function(e){if(e)return o(e);s=!0,o()}));var u=!1;return function(t){if(!s&&!u)return u=!0,function(e){return e.setHeader&&"function"==typeof e.abort}(e)?e.abort():"function"==typeof e.destroy?e.destroy():void o(t||new a("pipe"))}}function c(e){e()}function l(e,t){return e.pipe(t)}function f(e){return e.length?"function"!=typeof e[e.length-1]?s:e.pop():s}e.exports=function(){for(var e=arguments.length,t=new Array(e),r=0;r0,(function(e){n||(n=e),e&&a.forEach(c),o||(a.forEach(c),i(n))}))}));return t.reduce(l)}},6756:(e,t,r)=>{"use strict";var n=r(9024).q.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,i){var o=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,i,r);if(null!=o){if(!isFinite(o)||Math.floor(o)!==o||o<0)throw new n(i?r:"highWaterMark",o);return Math.floor(o)}return e.objectMode?16:16384}}},7144:(e,t,r)=>{"use strict";e.exports=r(8291).EventEmitter},6505:(e,t,r)=>{"use strict";(t=e.exports=r(6297)).Stream=t,t.Readable=t,t.Writable=r(1471),t.Duplex=r(6884),t.Transform=r(9154),t.PassThrough=r(3582),t.finished=r(5831),t.pipeline=r(384)},6707:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(1736),o=r(2353),a=new Array(16),s=[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],u=[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],c=[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],l=[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],f=[0,1518500249,1859775393,2400959708,2840853838],h=[1352829926,1548603684,1836072691,2053994217,0];function d(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(e,t){return e<>>32-t}function m(e,t,r,n,i,o,a,s){return p(e+(t^r^n)+o+a|0,s)+i|0}function y(e,t,r,n,i,o,a,s){return p(e+(t&r|~t&n)+o+a|0,s)+i|0}function g(e,t,r,n,i,o,a,s){return p(e+((t|~r)^n)+o+a|0,s)+i|0}function b(e,t,r,n,i,o,a,s){return p(e+(t&n|r&~n)+o+a|0,s)+i|0}function v(e,t,r,n,i,o,a,s){return p(e+(t^(r|~n))+o+a|0,s)+i|0}i(d,o),d.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,A=0|this._b,S=0|this._c,k=0|this._d,E=0|this._e,_=0;_<80;_+=1){var M,T;_<16?(M=m(r,n,i,o,d,e[s[_]],f[0],c[_]),T=v(w,A,S,k,E,e[u[_]],h[0],l[_])):_<32?(M=y(r,n,i,o,d,e[s[_]],f[1],c[_]),T=b(w,A,S,k,E,e[u[_]],h[1],l[_])):_<48?(M=g(r,n,i,o,d,e[s[_]],f[2],c[_]),T=g(w,A,S,k,E,e[u[_]],h[2],l[_])):_<64?(M=b(r,n,i,o,d,e[s[_]],f[3],c[_]),T=y(w,A,S,k,E,e[u[_]],h[3],l[_])):(M=v(r,n,i,o,d,e[s[_]],f[4],c[_]),T=m(w,A,S,k,E,e[u[_]],h[4],l[_])),r=d,d=o,o=p(i,10),i=n,n=M,w=E,E=k,k=p(S,10),S=A,A=T}var x=this._b+i+k|0;this._b=this._c+o+E|0,this._c=this._d+d+w|0,this._d=this._e+r+A|0,this._e=this._a+n+S|0,this._a=x},d.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 e=n.alloc?n.alloc(20):new n(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=d},6905:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.getLength=t.decode=t.encode=void 0;var i,o=(i=r(1734))&&i.__esModule?i:{default:i};function a(e,t){if("0"===e[0]&&"0"===e[1])throw new Error("invalid RLP: extra zeros");return parseInt(e,t)}function s(e,t){if(e<56)return n.from([e+t]);var r=l(e),i=l(t+55+r.length/2);return n.from(i+r,"hex")}function u(e){var t,r,i,o,s,c=[],l=e[0];if(l<=127)return{data:e.slice(0,1),remainder:e.slice(1)};if(l<=183){if(t=l-127,i=128===l?n.from([]):e.slice(1,t),2===t&&i[0]<128)throw new Error("invalid rlp encoding: byte must be less 0x80");return{data:i,remainder:e.slice(t)}}if(l<=191){if(r=l-182,e.length-1e.length)throw new Error("invalid rlp: total length is larger than the data");if(0===(o=e.slice(r,f)).length)throw new Error("invalid rlp, List has a invalid length");for(;o.length;)s=u(o),c.push(s.data),o=s.remainder;return{data:c,remainder:e.slice(f)}}function c(e){return"0x"===e.slice(0,2)}function l(e){if(e<0)throw new Error("Invalid integer as argument, must be unsigned!");var t=e.toString(16);return t.length%2?"0"+t:t}function f(e){if(!n.isBuffer(e)){if("string"==typeof e)return c(e)?n.from((r="string"!=typeof(i=e)?i:c(i)?i.slice(2):i).length%2?"0"+r:r,"hex"):n.from(e);if("number"==typeof e||"bigint"==typeof e)return e?(t=l(e),n.from(t,"hex")):n.from([]);if(null==e)return n.from([]);if(e instanceof Uint8Array)return n.from(e);if(o.default.isBN(e))return n.from(e.toArray());throw new Error("invalid type")}var t,r,i;return e}t.encode=function e(t){if(Array.isArray(t)){for(var r=[],i=0;i{"use strict";var n=r(9033),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=a),a.prototype=Object.create(i.prototype),o(i,a),a.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},1755:(e,t,r)=>{"use strict";var n,i=r(9142),o=r(8847)(r(3355)),a=r(9033),s=a.Buffer,u={};for(n in a)a.hasOwnProperty(n)&&"SlowBuffer"!==n&&"Buffer"!==n&&(u[n]=a[n]);var c=u.Buffer={};for(n in s)s.hasOwnProperty(n)&&"allocUnsafe"!==n&&"allocUnsafeSlow"!==n&&(c[n]=s[n]);if(u.Buffer.prototype=s.prototype,c.from&&c.from!==Uint8Array.from||(c.from=function(e,t,r){if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type '+(0,o.default)(e));if(e&&void 0===e.length)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+(0,o.default)(e));return s(e,t,r)}),c.alloc||(c.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError('The "size" argument must be of type number. Received type '+(0,o.default)(e));if(e<0||e>=2*(1<<30))throw new RangeError('The value "'+e+'" is invalid for option "size"');var n=s(e);return t&&0!==t.length?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n}),!u.kStringMaxLength)try{u.kStringMaxLength=i.binding("buffer").kStringMaxLength}catch(e){}u.constants||(u.constants={MAX_LENGTH:u.kMaxLength},u.kStringMaxLength&&(u.constants.MAX_STRING_LENGTH=u.kStringMaxLength)),e.exports=u},7799:e=>{"use strict";!function(t){var r=2147483647;function n(e){var t=new Uint32Array([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]),r=1779033703,n=3144134277,i=1013904242,o=2773480762,a=1359893119,s=2600822924,u=528734635,c=1541459225,l=new Uint32Array(64);function f(e){for(var f=0,h=e.length;h>=64;){var d=r,p=n,m=i,y=o,g=a,b=s,v=u,w=c,A=void 0,S=void 0,k=void 0,E=void 0,_=void 0;for(S=0;S<16;S++)k=f+4*S,l[S]=(255&e[k])<<24|(255&e[k+1])<<16|(255&e[k+2])<<8|255&e[k+3];for(S=16;S<64;S++)E=((A=l[S-2])>>>17|A<<15)^(A>>>19|A<<13)^A>>>10,_=((A=l[S-15])>>>7|A<<25)^(A>>>18|A<<14)^A>>>3,l[S]=(E+l[S-7]|0)+(_+l[S-16]|0)|0;for(S=0;S<64;S++)E=(((g>>>6|g<<26)^(g>>>11|g<<21)^(g>>>25|g<<7))+(g&b^~g&v)|0)+(w+(t[S]+l[S]|0)|0)|0,_=((d>>>2|d<<30)^(d>>>13|d<<19)^(d>>>22|d<<10))+(d&p^d&m^p&m)|0,w=v,v=b,b=g,g=y+E|0,y=m,m=p,p=d,d=E+_|0;r=r+d|0,n=n+p|0,i=i+m|0,o=o+y|0,a=a+g|0,s=s+b|0,u=u+v|0,c=c+w|0,f+=64,h-=64}}f(e);var h,d=e.length%64,p=e.length/536870912|0,m=e.length<<3,y=d<56?56:120,g=e.slice(e.length-d,e.length);for(g.push(128),h=d+1;h>>24&255),g.push(p>>>16&255),g.push(p>>>8&255),g.push(p>>>0&255),g.push(m>>>24&255),g.push(m>>>16&255),g.push(m>>>8&255),g.push(m>>>0&255),f(g),[r>>>24&255,r>>>16&255,r>>>8&255,r>>>0&255,n>>>24&255,n>>>16&255,n>>>8&255,n>>>0&255,i>>>24&255,i>>>16&255,i>>>8&255,i>>>0&255,o>>>24&255,o>>>16&255,o>>>8&255,o>>>0&255,a>>>24&255,a>>>16&255,a>>>8&255,a>>>0&255,s>>>24&255,s>>>16&255,s>>>8&255,s>>>0&255,u>>>24&255,u>>>16&255,u>>>8&255,u>>>0&255,c>>>24&255,c>>>16&255,c>>>8&255,c>>>0&255]}function i(e,t,r){e=e.length<=64?e:n(e);var i,o=64+t.length+4,a=new Array(o),s=new Array(64),u=[];for(i=0;i<64;i++)a[i]=54;for(i=0;i=o-4;e--){if(a[e]++,a[e]<=255)return;a[e]=0}}for(;r>=32;)c(),u=u.concat(n(s.concat(n(a)))),r-=32;return r>0&&(c(),u=u.concat(n(s.concat(n(a))).slice(0,r))),u}function o(e,t,r,n,i){var o;for(c(e,16*(2*r-1),i,0,16),o=0;o<2*r;o++)u(e,16*o,i,16),s(i,n),c(i,0,e,t+16*o,16);for(o=0;o>>32-t}function s(e,t){c(e,0,t,0,16);for(var r=8;r>0;r-=2)t[4]^=a(t[0]+t[12],7),t[8]^=a(t[4]+t[0],9),t[12]^=a(t[8]+t[4],13),t[0]^=a(t[12]+t[8],18),t[9]^=a(t[5]+t[1],7),t[13]^=a(t[9]+t[5],9),t[1]^=a(t[13]+t[9],13),t[5]^=a(t[1]+t[13],18),t[14]^=a(t[10]+t[6],7),t[2]^=a(t[14]+t[10],9),t[6]^=a(t[2]+t[14],13),t[10]^=a(t[6]+t[2],18),t[3]^=a(t[15]+t[11],7),t[7]^=a(t[3]+t[15],9),t[11]^=a(t[7]+t[3],13),t[15]^=a(t[11]+t[7],18),t[1]^=a(t[0]+t[3],7),t[2]^=a(t[1]+t[0],9),t[3]^=a(t[2]+t[1],13),t[0]^=a(t[3]+t[2],18),t[6]^=a(t[5]+t[4],7),t[7]^=a(t[6]+t[5],9),t[4]^=a(t[7]+t[6],13),t[5]^=a(t[4]+t[7],18),t[11]^=a(t[10]+t[9],7),t[8]^=a(t[11]+t[10],9),t[9]^=a(t[8]+t[11],13),t[10]^=a(t[9]+t[8],18),t[12]^=a(t[15]+t[14],7),t[13]^=a(t[12]+t[15],9),t[14]^=a(t[13]+t[12],13),t[15]^=a(t[14]+t[13],18);for(var n=0;n<16;++n)e[n]+=t[n]}function u(e,t,r,n){for(var i=0;i=256)return!1}return!0}function f(e,t){if("number"!=typeof e||e%1)throw new Error("invalid "+t);return e}function h(e,t,n,a,s,h,d){if(n=f(n,"N"),a=f(a,"r"),s=f(s,"p"),h=f(h,"dkLen"),0===n||0!=(n&n-1))throw new Error("N must be power of 2");if(n>r/128/a)throw new Error("N too large");if(a>r/128/s)throw new Error("r too large");if(!l(e))throw new Error("password must be an array or buffer");if(e=Array.prototype.slice.call(e),!l(t))throw new Error("salt must be an array or buffer");t=Array.prototype.slice.call(t);for(var p=i(e,t,128*s*a),m=new Uint32Array(32*s*a),y=0;yO&&(r=O);for(var l=0;lO&&(r=O);for(var y=0;y>0&255),p.push(m[B]>>8&255),p.push(m[B]>>16&255),p.push(m[B]>>24&255);var N=i(e,p,h);return d&&d(null,1,N),N}d&&R(t)};if(!d)for(;;){var B=C();if(null!=B)return B}C()}var d={scrypt:function(e,t,r,n,i,o,a){return new Promise((function(s,u){var c=0;a&&a(0),h(e,t,r,n,i,o,(function(e,t,r){if(e)u(e);else if(r)a&&1!==c&&a(1),s(new Uint8Array(r));else if(a&&t!==c)return c=t,a(t)}))}))},syncScrypt:function(e,t,r,n,i,o){return new Uint8Array(h(e,t,r,n,i,o))}};e.exports=d}()},7902:(e,t,r)=>{"use strict";e.exports=r(6922)(r(8123))},8123:(e,t,r)=>{"use strict";var n=new(0,r(6597).ec)("secp256k1"),i=n.curve,o=i.n.constructor;function a(e){var t=e[0];switch(t){case 2:case 3:return 33!==e.length?null:function(e,t){var r=new o(t);if(r.cmp(i.p)>=0)return null;var a=(r=r.toRed(i.red)).redSqr().redIMul(r).redIAdd(i.b).redSqrt();return 3===e!==a.isOdd()&&(a=a.redNeg()),n.keyPair({pub:{x:r,y:a}})}(t,e.subarray(1,33));case 4:case 6:case 7:return 65!==e.length?null:function(e,t,r){var a=new o(t),s=new o(r);if(a.cmp(i.p)>=0||s.cmp(i.p)>=0)return null;if(a=a.toRed(i.red),s=s.toRed(i.red),(6===e||7===e)&&s.isOdd()!==(7===e))return null;var u=a.redSqr().redIMul(a);return s.redSqr().redISub(u.redIAdd(i.b)).isZero()?n.keyPair({pub:{x:a,y:s}}):null}(t,e.subarray(1,33),e.subarray(33,65));default:return null}}function s(e,t){for(var r=t.encode(null,33===e.length),n=0;n=0)return 1;if(r.iadd(new o(e)),r.cmp(i.n)>=0&&r.isub(i.n),r.isZero())return 1;var n=r.toArrayLike(Uint8Array,"be",32);return e.set(n),0},privateKeyTweakMul:function(e,t){var r=new o(t);if(r.cmp(i.n)>=0||r.isZero())return 1;r.imul(new o(e)),r.cmp(i.n)>=0&&(r=r.umod(i.n));var n=r.toArrayLike(Uint8Array,"be",32);return e.set(n),0},publicKeyVerify:function(e){return null===a(e)?1:0},publicKeyCreate:function(e,t){var r=new o(t);return r.cmp(i.n)>=0||r.isZero()?1:(s(e,n.keyFromPrivate(t).getPublic()),0)},publicKeyConvert:function(e,t){var r=a(t);return null===r?1:(s(e,r.getPublic()),0)},publicKeyNegate:function(e,t){var r=a(t);if(null===r)return 1;var n=r.getPublic();return n.y=n.y.redNeg(),s(e,n),0},publicKeyCombine:function(e,t){for(var r=new Array(t.length),n=0;n=0)return 2;var u=n.getPublic().add(i.g.mul(r));return u.isInfinity()?2:(s(e,u),0)},publicKeyTweakMul:function(e,t,r){var n=a(t);return null===n?1:(r=new o(r)).cmp(i.n)>=0||r.isZero()?2:(s(e,n.getPublic().mul(r)),0)},signatureNormalize:function(e){var t=new o(e.subarray(0,32)),r=new o(e.subarray(32,64));return t.cmp(i.n)>=0||r.cmp(i.n)>=0?1:(1===r.cmp(n.nh)&&e.set(i.n.sub(r).toArrayLike(Uint8Array,"be",32),32),0)},signatureExport:function(e,t){var r=t.subarray(0,32),n=t.subarray(32,64);if(new o(r).cmp(i.n)>=0)return 1;if(new o(n).cmp(i.n)>=0)return 1;var a=e.output,s=a.subarray(4,37);s[0]=0,s.set(r,1);for(var u=33,c=0;u>1&&0===s[c]&&!(128&s[c+1]);--u,++c);if(128&(s=s.subarray(c))[0])return 1;if(u>1&&0===s[0]&&!(128&s[1]))return 1;var l=a.subarray(39,72);l[0]=0,l.set(n,1);for(var f=33,h=0;f>1&&0===l[h]&&!(128&l[h+1]);--f,++h);return 128&(l=l.subarray(h))[0]||f>1&&0===l[0]&&!(128&l[1])?1:(e.outputlen=6+u+f,a[0]=48,a[1]=e.outputlen-2,a[2]=2,a[3]=s.length,a.set(s,4),a[4+u]=2,a[5+u]=l.length,a.set(l,6+u),0)},signatureImport:function(e,t){if(t.length<8)return 1;if(t.length>72)return 1;if(48!==t[0])return 1;if(t[1]!==t.length-2)return 1;if(2!==t[2])return 1;var r=t[3];if(0===r)return 1;if(5+r>=t.length)return 1;if(2!==t[4+r])return 1;var n=t[5+r];if(0===n)return 1;if(6+r+n!==t.length)return 1;if(128&t[4])return 1;if(r>1&&0===t[4]&&!(128&t[5]))return 1;if(128&t[r+6])return 1;if(n>1&&0===t[r+6]&&!(128&t[r+7]))return 1;var a=t.subarray(4,4+r);if(33===a.length&&0===a[0]&&(a=a.subarray(1)),a.length>32)return 1;var s=t.subarray(6+r);if(33===s.length&&0===s[0]&&(s=s.slice(1)),s.length>32)throw new Error("S length is too long");var u=new o(a);u.cmp(i.n)>=0&&(u=new o(0));var c=new o(t.subarray(6+r));return c.cmp(i.n)>=0&&(c=new o(0)),e.set(u.toArrayLike(Uint8Array,"be",32),0),e.set(c.toArrayLike(Uint8Array,"be",32),32),0},ecdsaSign:function(e,t,r,a,s){if(s){var u=s;s=function(e){var n=u(t,r,null,a,e);if(!(n instanceof Uint8Array&&32===n.length))throw new Error("This is the way");return new o(n)}}var c,l=new o(r);if(l.cmp(i.n)>=0||l.isZero())return 1;try{c=n.sign(t,r,{canonical:!0,k:s,pers:a})}catch(e){return 1}return e.signature.set(c.r.toArrayLike(Uint8Array,"be",32),0),e.signature.set(c.s.toArrayLike(Uint8Array,"be",32),32),e.recid=c.recoveryParam,0},ecdsaVerify:function(e,t,r){var s={r:e.subarray(0,32),s:e.subarray(32,64)},u=new o(s.r),c=new o(s.s);if(u.cmp(i.n)>=0||c.cmp(i.n)>=0)return 1;if(1===c.cmp(n.nh)||u.isZero()||c.isZero())return 3;var l=a(r);if(null===l)return 2;var f=l.getPublic();return n.verify(t,s,f)?0:3},ecdsaRecover:function(e,t,r,a){var u,c={r:t.slice(0,32),s:t.slice(32,64)},l=new o(c.r),f=new o(c.s);if(l.cmp(i.n)>=0||f.cmp(i.n)>=0)return 1;if(l.isZero()||f.isZero())return 2;try{u=n.recoverPubKey(a,c,r)}catch(e){return 2}return s(e,u),0},ecdh:function(e,t,r,s,u,c,l){var f=a(t);if(null===f)return 1;var h=new o(r);if(h.cmp(i.n)>=0||h.isZero())return 2;var d=f.getPublic().mul(h);if(void 0===u)for(var p=d.encode(null,!0),m=n.hash().update(p).digest(),y=0;y<32;++y)e[y]=m[y];else{c||(c=new Uint8Array(32));for(var g=d.getX().toArray("be",32),b=0;b<32;++b)c[b]=g[b];l||(l=new Uint8Array(32));for(var v=d.getY().toArray("be",32),w=0;w<32;++w)l[w]=v[w];var A=u(c,l,s);if(!(A instanceof Uint8Array&&A.length===e.length))return 2;e.set(A)}return 0}}},6922:e=>{"use strict";function t(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&void 0!==arguments[0]?arguments[0]:function(e){return new Uint8Array(e)},t=arguments.length>1?arguments[1]:void 0;return"function"==typeof e&&(e=e(t)),m("output",e,t),e}function b(e){return Object.prototype.toString.call(e).slice(8,-1)}e.exports=function(e){return{contextRandomize:function(t){if(p(null===t||t instanceof Uint8Array,"Expected seed to be an Uint8Array or null"),null!==t&&m("seed",t,32),1===e.contextRandomize(t))throw new Error("Unknow error on context randomization")},privateKeyVerify:function(t){return m("private key",t,32),0===e.privateKeyVerify(t)},privateKeyNegate:function(t){switch(m("private key",t,32),e.privateKeyNegate(t)){case 0:return t;case 1:throw new Error(n)}},privateKeyTweakAdd:function(t,r){switch(m("private key",t,32),m("tweak",r,32),e.privateKeyTweakAdd(t,r)){case 0:return t;case 1:throw new Error(i)}},privateKeyTweakMul:function(t,r){switch(m("private key",t,32),m("tweak",r,32),e.privateKeyTweakMul(t,r)){case 0:return t;case 1:throw new Error(o)}},publicKeyVerify:function(t){return m("public key",t,[33,65]),0===e.publicKeyVerify(t)},publicKeyCreate:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2?arguments[2]:void 0;switch(m("private key",t,32),y(r),n=g(n,r?33:65),e.publicKeyCreate(n,t)){case 0:return n;case 1:throw new Error(a);case 2:throw new Error(u)}},publicKeyConvert:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2?arguments[2]:void 0;switch(m("public key",t,[33,65]),y(r),n=g(n,r?33:65),e.publicKeyConvert(n,t)){case 0:return n;case 1:throw new Error(s);case 2:throw new Error(u)}},publicKeyNegate:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0;switch(m("public key",t,[33,65]),y(r),i=g(i,r?33:65),e.publicKeyNegate(i,t)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(n);case 3:throw new Error(u)}},publicKeyCombine:function(r){var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0;p(Array.isArray(r),"Expected public keys to be an Array"),p(r.length>0,"Expected public keys array will have more than zero items");var o,a=t(r);try{for(a.s();!(o=a.n()).done;){var l=o.value;m("public key",l,[33,65])}}catch(e){a.e(e)}finally{a.f()}switch(y(n),i=g(i,n?33:65),e.publicKeyCombine(i,r)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(c);case 3:throw new Error(u)}},publicKeyTweakAdd:function(t,r){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],o=arguments.length>3?arguments[3]:void 0;switch(m("public key",t,[33,65]),m("tweak",r,32),y(n),o=g(o,n?33:65),e.publicKeyTweakAdd(o,t,r)){case 0:return o;case 1:throw new Error(s);case 2:throw new Error(i)}},publicKeyTweakMul:function(t,r){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3?arguments[3]:void 0;switch(m("public key",t,[33,65]),m("tweak",r,32),y(n),i=g(i,n?33:65),e.publicKeyTweakMul(i,t,r)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(o)}},signatureNormalize:function(t){switch(m("signature",t,64),e.signatureNormalize(t)){case 0:return t;case 1:throw new Error(l)}},signatureExport:function(t,r){m("signature",t,64);var i={output:r=g(r,72),outputlen:72};switch(e.signatureExport(i,t)){case 0:return r.slice(0,i.outputlen);case 1:throw new Error(l);case 2:throw new Error(n)}},signatureImport:function(t,r){switch(m("signature",t),r=g(r,64),e.signatureImport(r,t)){case 0:return r;case 1:throw new Error(l);case 2:throw new Error(n)}},ecdsaSign:function(t,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=arguments.length>3?arguments[3]:void 0;m("message",t,32),m("private key",r,32),p("Object"===b(i),"Expected options to be an Object"),void 0!==i.data&&m("options.data",i.data),void 0!==i.noncefn&&p("Function"===b(i.noncefn),"Expected options.noncefn to be a Function");var a={signature:o=g(o,64),recid:null};switch(e.ecdsaSign(a,t,r,i.data,i.noncefn)){case 0:return a;case 1:throw new Error(f);case 2:throw new Error(n)}},ecdsaVerify:function(t,r,n){switch(m("signature",t,64),m("message",r,32),m("public key",n,[33,65]),e.ecdsaVerify(t,r,n)){case 0:return!0;case 3:return!1;case 1:throw new Error(l);case 2:throw new Error(s)}},ecdsaRecover:function(t,r,i){var o=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=arguments.length>4?arguments[4]:void 0;switch(m("signature",t,64),p("Number"===b(r)&&r>=0&&r<=3,"Expected recovery id to be a Number within interval [0, 3]"),m("message",i,32),y(o),a=g(a,o?33:65),e.ecdsaRecover(a,t,r,i)){case 0:return a;case 1:throw new Error(l);case 2:throw new Error(h);case 3:throw new Error(n)}},ecdh:function(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3?arguments[3]:void 0;switch(m("public key",t,[33,65]),m("private key",r,32),p("Object"===b(n),"Expected options to be an Object"),void 0!==n.data&&m("options.data",n.data),void 0!==n.hashfn?(p("Function"===b(n.hashfn),"Expected options.hashfn to be a Function"),void 0!==n.xbuf&&m("options.xbuf",n.xbuf,32),void 0!==n.ybuf&&m("options.ybuf",n.ybuf,32),m("output",i)):i=g(i,32),e.ecdh(i,t,r,n.data,n.hashfn,n.xbuf,n.ybuf)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(d)}}}}},6003:(e,t,r)=>{"use strict";var n=r(8850).Buffer;function i(e,t){this._block=n.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}i.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=n.from(e,t));for(var r=this._block,i=this._blockSize,o=e.length,a=this._len,s=0;s=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},1708:(e,t,r)=>{"use strict";var n=e.exports=function(e){e=e.toLowerCase();var t=n[e];if(!t)throw new Error(e+" is not supported (we accept pull requests)");return new t};n.sha=r(8210),n.sha1=r(544),n.sha224=r(6288),n.sha256=r(4571),n.sha384=r(6959),n.sha512=r(4515)},8210:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<30|e>>>2}function l(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,f=0;f<16;++f)r[f]=e.readInt32BE(4*f);for(;f<80;++f)r[f]=r[f-3]^r[f-8]^r[f-14]^r[f-16];for(var h=0;h<80;++h){var d=~~(h/20),p=0|((t=n)<<5|t>>>27)+l(d,i,o,s)+u+r[h]+a[d];u=s,s=o,o=c(i),i=n,n=p}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},544:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<5|e>>>27}function l(e){return e<<30|e>>>2}function f(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,h=0;h<16;++h)r[h]=e.readInt32BE(4*h);for(;h<80;++h)r[h]=(t=r[h-3]^r[h-8]^r[h-14]^r[h-16])<<1|t>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=c(n)+f(p,i,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=l(i),i=n,n=m}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},6288:(e,t,r)=>{"use strict";var n=r(1736),i=r(4571),o=r(6003),a=r(8850).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}n(u,i),u.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=u},4571:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[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],s=new Array(64);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function h(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function d(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}n(u,i),u.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,y=0|this._h,g=0;g<16;++g)r[g]=e.readInt32BE(4*g);for(;g<64;++g)r[g]=0|(((t=r[g-2])>>>17|t<<15)^(t>>>19|t<<13)^t>>>10)+r[g-7]+d(r[g-15])+r[g-16];for(var b=0;b<64;++b){var v=y+h(u)+c(u,p,m)+a[b]+r[b]|0,w=f(n)+l(n,i,o)|0;y=m,m=p,p=u,u=s+v|0,s=o,o=i,i=n,n=v+w|0}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=y+this._h|0},u.prototype._hash=function(){var e=o.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=u},6959:(e,t,r)=>{"use strict";var n=r(1736),i=r(4515),o=r(6003),a=r(8850).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}n(u,i),u.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(48);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e},e.exports=u},4515:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],s=new Array(160);function u(){this.init(),this._w=s,i.call(this,128,112)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function h(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function d(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function p(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function y(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function g(e,t){return e>>>0>>0?1:0}n(u,i),u.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},u.prototype._update=function(e){for(var t=this._w,r=0|this._ah,n=0|this._bh,i=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,b=0|this._gh,v=0|this._hh,w=0|this._al,A=0|this._bl,S=0|this._cl,k=0|this._dl,E=0|this._el,_=0|this._fl,M=0|this._gl,T=0|this._hl,x=0;x<32;x+=2)t[x]=e.readInt32BE(4*x),t[x+1]=e.readInt32BE(4*x+4);for(;x<160;x+=2){var P=t[x-30],I=t[x-30+1],O=d(P,I),R=p(I,P),C=m(P=t[x-4],I=t[x-4+1]),B=y(I,P),N=t[x-14],L=t[x-14+1],U=t[x-32],F=t[x-32+1],D=R+L|0,j=O+N+g(D,R)|0;j=(j=j+C+g(D=D+B|0,B)|0)+U+g(D=D+F|0,F)|0,t[x]=j,t[x+1]=D}for(var H=0;H<160;H+=2){j=t[H],D=t[H+1];var J=l(r,n,i),z=l(w,A,S),G=f(r,w),q=f(w,r),K=h(s,E),V=h(E,s),X=a[H],Q=a[H+1],W=c(s,u,b),Z=c(E,_,M),Y=T+V|0,$=v+K+g(Y,T)|0;$=($=($=$+W+g(Y=Y+Z|0,Z)|0)+X+g(Y=Y+Q|0,Q)|0)+j+g(Y=Y+D|0,D)|0;var ee=q+z|0,te=G+J+g(ee,q)|0;v=b,T=M,b=u,M=_,u=s,_=E,s=o+$+g(E=k+Y|0,k)|0,o=i,k=S,i=n,S=A,n=r,A=w,r=$+te+g(w=Y+ee|0,Y)|0}this._al=this._al+w|0,this._bl=this._bl+A|0,this._cl=this._cl+S|0,this._dl=this._dl+k|0,this._el=this._el+E|0,this._fl=this._fl+_|0,this._gl=this._gl+M|0,this._hl=this._hl+T|0,this._ah=this._ah+r+g(this._al,w)|0,this._bh=this._bh+n+g(this._bl,A)|0,this._ch=this._ch+i+g(this._cl,S)|0,this._dh=this._dh+o+g(this._dl,k)|0,this._eh=this._eh+s+g(this._el,E)|0,this._fh=this._fh+u+g(this._fl,_)|0,this._gh=this._gh+b+g(this._gl,M)|0,this._hh=this._hh+v+g(this._hl,T)|0},u.prototype._hash=function(){var e=o.allocUnsafe(64);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=u},7245:(e,t,r)=>{"use strict";e.exports=i;var n=r(8291).EventEmitter;function i(){n.call(this)}r(1736)(i,n),i.Readable=r(6297),i.Writable=r(1471),i.Duplex=r(6884),i.Transform=r(9154),i.PassThrough=r(3582),i.finished=r(5831),i.pipeline=r(384),i.Stream=i,i.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",i),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",s),r.on("close",u));var a=!1;function s(){a||(a=!0,e.end())}function u(){a||(a=!0,"function"==typeof e.destroy&&e.destroy())}function c(e){if(l(),0===n.listenerCount(this,"error"))throw e}function l(){r.removeListener("data",i),e.removeListener("drain",o),r.removeListener("end",s),r.removeListener("close",u),r.removeListener("error",c),e.removeListener("error",c),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return r.on("error",c),e.on("error",c),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e}},9519:(e,t,r)=>{"use strict";var n=r(8844),i=r(3319),o=r(7705),a=r(3675),s=r(1143),u=t;u.request=function(e,t){e="string"==typeof e?s.parse(e):o(e);var i=-1===r.g.location.protocol.search(/^https?:$/)?"http:":"",a=e.protocol||i,u=e.hostname||e.host,c=e.port,l=e.path||"/";u&&-1!==u.indexOf(":")&&(u="["+u+"]"),e.url=(u?a+"//"+u:"")+(c?":"+c:"")+l,e.method=(e.method||"GET").toUpperCase(),e.headers=e.headers||{};var f=new n(e);return t&&f.on("response",t),f},u.get=function(e,t){var r=u.request(e,t);return r.end(),r},u.ClientRequest=n,u.IncomingMessage=i.IncomingMessage,u.Agent=function(){},u.Agent.defaultMaxSockets=4,u.globalAgent=new u.Agent,u.STATUS_CODES=a,u.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]},3928:(e,t,r)=>{"use strict";var n;function i(){if(void 0!==n)return n;if(r.g.XMLHttpRequest){n=new r.g.XMLHttpRequest;try{n.open("GET",r.g.XDomainRequest?"/":"https://example.com")}catch(e){n=null}}else n=null;return n}function o(e){var t=i();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}function a(e){return"function"==typeof e}t.fetch=a(r.g.fetch)&&a(r.g.ReadableStream),t.writableStream=a(r.g.WritableStream),t.abortController=a(r.g.AbortController),t.arraybuffer=t.fetch||o("arraybuffer"),t.msstream=!t.fetch&&o("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&o("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!i()&&a(i().overrideMimeType),n=null},8844:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(9142),o=r(3928),a=r(1736),s=r(3319),u=r(6505),c=s.IncomingMessage,l=s.readyStates,f=e.exports=function(e){var t,r=this;u.Writable.call(r),r._opts=e,r._body=[],r._headers={},e.auth&&r.setHeader("Authorization","Basic "+n.from(e.auth).toString("base64")),Object.keys(e.headers).forEach((function(t){r.setHeader(t,e.headers[t])}));var i=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!o.abortController)i=!1,t=!0;else if("prefer-streaming"===e.mode)t=!1;else if("allow-wrong-content-type"===e.mode)t=!o.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");t=!0}r._mode=function(e,t){return o.fetch&&t?"fetch":o.mozchunkedarraybuffer?"moz-chunked-arraybuffer":o.msstream?"ms-stream":o.arraybuffer&&e?"arraybuffer":"text"}(t,i),r._fetchTimer=null,r._socketTimeout=null,r._socketTimer=null,r.on("finish",(function(){r._onFinish()}))};a(f,u.Writable),f.prototype.setHeader=function(e,t){var r=e.toLowerCase();-1===h.indexOf(r)&&(this._headers[r]={name:e,value:t})},f.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},f.prototype.removeHeader=function(e){delete this._headers[e.toLowerCase()]},f.prototype._onFinish=function(){var e=this;if(!e._destroyed){var t=e._opts;"timeout"in t&&0!==t.timeout&&e.setTimeout(t.timeout);var n=e._headers,a=null;"GET"!==t.method&&"HEAD"!==t.method&&(a=new Blob(e._body,{type:(n["content-type"]||{}).value||""}));var s=[];if(Object.keys(n).forEach((function(e){var t=n[e].name,r=n[e].value;Array.isArray(r)?r.forEach((function(e){s.push([t,e])})):s.push([t,r])})),"fetch"===e._mode){var u=null;if(o.abortController){var c=new AbortController;u=c.signal,e._fetchAbortController=c,"requestTimeout"in t&&0!==t.requestTimeout&&(e._fetchTimer=r.g.setTimeout((function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()}),t.requestTimeout))}r.g.fetch(e._opts.url,{method:e._opts.method,headers:s,body:a||void 0,mode:"cors",credentials:t.withCredentials?"include":"same-origin",signal:u}).then((function(t){e._fetchResponse=t,e._resetTimers(!1),e._connect()}),(function(t){e._resetTimers(!0),e._destroyed||e.emit("error",t)}))}else{var f=e._xhr=new r.g.XMLHttpRequest;try{f.open(e._opts.method,e._opts.url,!0)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}"responseType"in f&&(f.responseType=e._mode),"withCredentials"in f&&(f.withCredentials=!!t.withCredentials),"text"===e._mode&&"overrideMimeType"in f&&f.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in t&&(f.timeout=t.requestTimeout,f.ontimeout=function(){e.emit("requestTimeout")}),s.forEach((function(e){f.setRequestHeader(e[0],e[1])})),e._response=null,f.onreadystatechange=function(){switch(f.readyState){case l.LOADING:case l.DONE:e._onXHRProgress()}},"moz-chunked-arraybuffer"===e._mode&&(f.onprogress=function(){e._onXHRProgress()}),f.onerror=function(){e._destroyed||(e._resetTimers(!0),e.emit("error",new Error("XHR error")))};try{f.send(a)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}}}},f.prototype._onXHRProgress=function(){var e=this;e._resetTimers(!1),function(e){try{var t=e.status;return null!==t&&0!==t}catch(e){return!1}}(e._xhr)&&!e._destroyed&&(e._response||e._connect(),e._response._onXHRProgress(e._resetTimers.bind(e)))},f.prototype._connect=function(){var e=this;e._destroyed||(e._response=new c(e._xhr,e._fetchResponse,e._mode,e._resetTimers.bind(e)),e._response.on("error",(function(t){e.emit("error",t)})),e.emit("response",e._response))},f.prototype._write=function(e,t,r){this._body.push(e),r()},f.prototype._resetTimers=function(e){var t=this;r.g.clearTimeout(t._socketTimer),t._socketTimer=null,e?(r.g.clearTimeout(t._fetchTimer),t._fetchTimer=null):t._socketTimeout&&(t._socketTimer=r.g.setTimeout((function(){t.emit("timeout")}),t._socketTimeout))},f.prototype.abort=f.prototype.destroy=function(e){var t=this;t._destroyed=!0,t._resetTimers(!0),t._response&&(t._response._destroyed=!0),t._xhr?t._xhr.abort():t._fetchAbortController&&t._fetchAbortController.abort(),e&&t.emit("error",e)},f.prototype.end=function(e,t,r){"function"==typeof e&&(r=e,e=void 0),u.Writable.prototype.end.call(this,e,t,r)},f.prototype.setTimeout=function(e,t){var r=this;t&&r.once("timeout",t),r._socketTimeout=e,r._resetTimers(!1)},f.prototype.flushHeaders=function(){},f.prototype.setNoDelay=function(){},f.prototype.setSocketKeepAlive=function(){};var h=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]},3319:(e,t,r)=>{"use strict";var n=r(9142),i=r(9033).Buffer,o=r(3928),a=r(1736),s=r(6505),u=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},c=t.IncomingMessage=function(e,t,r,a){var u=this;if(s.Readable.call(u),u._mode=r,u.headers={},u.rawHeaders=[],u.trailers={},u.rawTrailers=[],u.on("end",(function(){n.nextTick((function(){u.emit("close")}))})),"fetch"===r){if(u._fetchResponse=t,u.url=t.url,u.statusCode=t.status,u.statusMessage=t.statusText,t.headers.forEach((function(e,t){u.headers[t.toLowerCase()]=e,u.rawHeaders.push(t,e)})),o.writableStream){var c=new WritableStream({write:function(e){return a(!1),new Promise((function(t,r){u._destroyed?r():u.push(i.from(e))?t():u._resumeFetch=t}))},close:function(){a(!0),u._destroyed||u.push(null)},abort:function(e){a(!0),u._destroyed||u.emit("error",e)}});try{return void t.body.pipeTo(c).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}catch(e){}}var l=t.body.getReader();!function e(){l.read().then((function(t){u._destroyed||(a(t.done),t.done?u.push(null):(u.push(i.from(t.value)),e()))})).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}()}else if(u._xhr=e,u._pos=0,u.url=e.responseURL,u.statusCode=e.status,u.statusMessage=e.statusText,e.getAllResponseHeaders().split(/\r?\n/).forEach((function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var r=t[1].toLowerCase();"set-cookie"===r?(void 0===u.headers[r]&&(u.headers[r]=[]),u.headers[r].push(t[2])):void 0!==u.headers[r]?u.headers[r]+=", "+t[2]:u.headers[r]=t[2],u.rawHeaders.push(t[1],t[2])}})),u._charset="x-user-defined",!o.overrideMimeType){var f=u.rawHeaders["mime-type"];if(f){var h=f.match(/;\s*charset=([^;])(;|$)/);h&&(u._charset=h[1].toLowerCase())}u._charset||(u._charset="utf-8")}};a(c,s.Readable),c.prototype._read=function(){var e=this._resumeFetch;e&&(this._resumeFetch=null,e())},c.prototype._onXHRProgress=function(e){var t=this,n=t._xhr,o=null;switch(t._mode){case"text":if((o=n.responseText).length>t._pos){var a=o.substr(t._pos);if("x-user-defined"===t._charset){for(var s=i.alloc(a.length),c=0;ct._pos&&(t.push(i.from(new Uint8Array(l.result.slice(t._pos)))),t._pos=l.result.byteLength)},l.onload=function(){e(!0),t.push(null)},l.readAsArrayBuffer(o)}t._xhr.readyState===u.DONE&&"ms-stream"!==t._mode&&(e(!0),t.push(null))}},3462:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.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 o(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){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 e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=u,this.end=c,t=4;break;case"utf8":this.fillLast=s,t=4;break;case"base64":this.text=l,this.end=f,t=3;break;default:return this.write=h,void(this.end=d)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function a(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function u(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function c(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function l(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function h(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}t.s=o,o.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0?(i>0&&(e.lastNeed=i-1),i):--n=0?(i>0&&(e.lastNeed=i-2),i):--n=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},o.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},6931:(e,t,r)=>{"use strict";var n=r(8619);e.exports=function(e){return"string"!=typeof e?e:n(e)?e.slice(2):e}},6427:(e,t,r)=>{"use strict";var n=function(){throw"This swarm.js function isn't available on the browser."},i={readFile:n},o={download:n,safeDownloadArchived:n,directoryTree:n},a={platform:n,arch:n},s={join:n,slice:n},u={spawn:n},c={lookup:n},l=r(1357),f=r(631),h=r(2733),d=r(2510),p=r(3094);e.exports=p({fs:i,files:o,os:a,path:s,child_process:u,defaultArchives:{},mimetype:c,request:l,downloadUrl:null,bytes:f,hash:h,pick:d})},2510:e=>{"use strict";var t=function(e){return function(){return new Promise((function(t,r){var n,i=function(r){var n={},i=r.target.files.length,o=0;[].map.call(r.target.files,(function(r){var a=new FileReader;a.onload=function(a){var s=new Uint8Array(a.target.result);if("directory"===e){var u=r.webkitRelativePath;n[u.slice(u.indexOf("/")+1)]={type:"text/plain",data:s},++o===i&&t(n)}else if("file"===e){var c=r.webkitRelativePath;t({type:mimetype.lookup(c),data:s})}else t(s)},a.readAsArrayBuffer(r)}))};"directory"===e?((n=document.createElement("input")).addEventListener("change",i),n.type="file",n.webkitdirectory=!0,n.mozdirectory=!0,n.msdirectory=!0,n.odirectory=!0,n.directory=!0):((n=document.createElement("input")).addEventListener("change",i),n.type="file");var o=document.createEvent("MouseEvents");o.initEvent("click",!0,!1),n.dispatchEvent(o)}))}};e.exports={data:t("data"),file:t("file"),directory:t("directory")}},2733:(e,t,r)=>{"use strict";var n=r(9574).keccak256,i=r(631),o=function(e,t){var r=i.reverse(i.pad(6,i.fromNumber(e))),o=i.flatten([r,"0x0000",t]);return n(o).slice(2)};e.exports=function e(t){"string"==typeof t&&"0x"!==t.slice(0,2)?t=i.fromString(t):"string"!=typeof t&&void 0!==t.length&&(t=i.fromUint8Array(t));var r=i.length(t);if(r<=4096)return o(r,t);for(var n=4096;128*n{"use strict";e.exports=function(e){var t=e.fs,r=e.files,n=e.os,i=e.path,o=e.child_process,a=e.mimetype,s=e.defaultArchives,u=e.request,c=e.downloadUrl,l=e.bytes,f=e.hash,h=e.pick,d=function(e){return function(t){for(var r={},n=0,i=e.length;n=400?n(new Error("Error ".concat(i.statusCode,"."))):r(new Uint8Array(t))}))}))}},y=function(e){return function(t){return function t(r){return function(n){return function(i){var o=function(e){return void 0===e.path?Promise.resolve():"application/bzz-manifest+json"===e.contentType?t(e.hash)(n+e.path)(i):Promise.resolve((r=n+e.path,function(e){return function(t){return t[r]=e,t}})(function(e){return{type:e.contentType,hash:e.hash}}(e))(i));var r};return m(e)(r).then((function(e){return JSON.parse(L(e)).entries})).then((function(e){return Promise.all(e.map(o))})).then((function(){return i}))}}}(t)("")({})}},g=function(e){return function(t){return y(e)(t).then((function(e){return d(Object.keys(e))(Object.keys(e).map((function(t){return e[t].hash})))}))}},b=function(e){return function(t){return y(e)(t).then((function(t){var r=Object.keys(t),n=r.map((function(e){return t[e].hash})),i=r.map((function(e){return t[e].type})),o=n.map(m(e));return Promise.all(o).then((function(e){return d(r)(function(e){return e.map((function(e,t){return{type:i[t],data:e}}))}(e))}))}))}},v=function(e){return function(t){return function(n){return r.download(p(e)(t))(n)}}},w=function(e){return function(t){return function(r){return g(e)(t).then((function(t){var n=[];for(var o in t)if(o.length>0){var a=i.join(r,o);n.push(v(e)(t[o])(a))}return Promise.all(n).then((function(){return r}))}))}}},A=function(e){return function(t){return new Promise((function(r,n){var i={body:"string"==typeof t?U(t):t,method:"POST"};u("".concat(e,"/bzz-raw:/"),i,(function(e,t){return e?n(e):r(t)}))}))}},S=function(e){return function(t){return function(r){return function(n){return function i(o){var a="/"===r[0]?r:"/"+r,s="".concat(e,"/bzz:/").concat(t).concat(a),c={method:"PUT",headers:{"Content-Type":n.type},body:n.data};return new Promise((function(e,t){u(s,c,(function(r,n){return r?t(r):-1!==n.indexOf("error")?t(n):e(n)}))})).catch((function(e){return o>0&&i(o-1)}))}(3)}}}},k=function(e){return function(t){return _(e)({"":t})}},E=function(e){return function(r){return t.readFile(r).then((function(t){return k(e)({type:a.lookup(r),data:t})}))}},_=function(e){return function(t){return A(e)("{}").then((function(r){return Object.keys(t).reduce((function(r,n){return r.then(function(r){return function(n){return S(e)(n)(r)(t[r])}}(n))}),Promise.resolve(r))}))}},M=function(e){return function(r){return t.readFile(r).then(A(e))}},T=function(e){return function(n){return function(i){return r.directoryTree(i).then((function(e){return Promise.all(e.map((function(e){return t.readFile(e)}))).then((function(t){var r=e.map((function(e){return e.slice(i.length)})),n=e.map((function(e){return a.lookup(e)||"text/plain"}));return d(r)(t.map((function(e,t){return{type:n[t],data:e}})))}))})).then((function(e){return(t=n?{"":e[n]}:{},function(e){var r={};for(var n in t)r[n]=t[n];for(var i in e)r[i]=e[i];return r})(e);var t})).then(_(e))}}},x=function(e){return function(t){if("data"===t.pick)return h.data().then(A(e));if("file"===t.pick)return h.file().then(k(e));if("directory"===t.pick)return h.directory().then(_(e));if(t.path)switch(t.kind){case"data":return M(e)(t.path);case"file":return E(e)(t.path);case"directory":return T(e)(t.defaultFile)(t.path)}else{if(t.length||"string"==typeof t)return A(e)(t);if(t instanceof Object)return _(e)(t)}return Promise.reject(new Error("Bad arguments"))}},P=function(e){return function(t){return function(r){return B(e)(t).then((function(n){return n?r?w(e)(t)(r):b(e)(t):r?v(e)(t)(r):m(e)(t)}))}}},I=function(e,t){var i=n.platform().replace("win32","windows")+"-"+("x64"===n.arch()?"amd64":"386"),o=(t||s)[i],a=c+o.archive+".tar.gz",u=o.archiveMD5,l=o.binaryMD5;return r.safeDownloadArchived(a)(u)(l)(e)},O=function(e){return new Promise((function(t,r){var n=o.spawn,i=function(e){return function(t){return-1!==(""+t).indexOf(e)}},a=e.account,s=e.password,u=e.dataDir,c=e.ensApi,l=e.privateKey,f=0,h=n(e.binPath,["--bzzaccount",a||l,"--datadir",u,"--ens-api",c]),d=function(e){0===f&&i("Passphrase")(e)?setTimeout((function(){f=1,h.stdin.write(s+"\n")}),500):i("Swarm http proxy started")(e)&&(f=2,clearTimeout(p),t(h))};h.stdout.on("data",d),h.stderr.on("data",d);var p=setTimeout((function(){return r(new Error("Couldn't start swarm process."))}),2e4)}))},R=function(e){return new Promise((function(t,r){e.stderr.removeAllListeners("data"),e.stdout.removeAllListeners("data"),e.stdin.removeAllListeners("error"),e.removeAllListeners("error"),e.removeAllListeners("exit"),e.kill("SIGINT");var n=setTimeout((function(){return e.kill("SIGKILL")}),8e3);e.once("close",(function(){clearTimeout(n),t()}))}))},C=function(e){return A(e)("test").then((function(e){return"c9a99c7d326dcc6316f32fe2625b311f6dc49a175e6877681ded93137d3569e7"===e})).catch((function(){return!1}))},B=function(e){return function(t){return m(e)(t).then((function(e){try{return!!JSON.parse(L(e)).entries}catch(e){return!1}}))}},N=function(e){return function(t,r,n,i,o){var a;return void 0!==t&&(a=e(t)),void 0!==r&&(a=e(r)),void 0!==n&&(a=e(n)),void 0!==i&&(a=e(i)),void 0!==o&&(a=e(o)),a}},L=function(e){return l.toString(l.fromUint8Array(e))},U=function(e){return l.toUint8Array(l.fromString(e))},F=function(e){return{download:function(t,r){return P(e)(t)(r)},downloadData:N(m(e)),downloadDataToDisk:N(v(e)),downloadDirectory:N(b(e)),downloadDirectoryToDisk:N(w(e)),downloadEntries:N(y(e)),downloadRoutes:N(g(e)),isAvailable:function(){return C(e)},upload:function(t){return x(e)(t)},uploadData:N(A(e)),uploadFile:N(k(e)),uploadFileFromDisk:N(k(e)),uploadDataFromDisk:N(M(e)),uploadDirectory:N(_(e)),uploadDirectoryFromDisk:N(T(e)),uploadToManifest:N(S(e)),pick:h,hash:f,fromString:U,toString:L}};return{at:F,local:function(e){return function(t){return C("http://localhost:8500").then((function(r){return r?t(F("http://localhost:8500")).then((function(){})):I(e.binPath,e.archives).onData((function(t){return(e.onProgress||function(){})(t.length)})).then((function(){return O(e)})).then((function(e){return t(F("http://localhost:8500")).then((function(){return e}))})).then(R)}))}},download:P,downloadBinary:I,downloadData:m,downloadDataToDisk:v,downloadDirectory:b,downloadDirectoryToDisk:w,downloadEntries:y,downloadRoutes:g,isAvailable:C,startProcess:O,stopProcess:R,upload:x,uploadData:A,uploadDataFromDisk:M,uploadFile:k,uploadFileFromDisk:E,uploadDirectory:_,uploadDirectoryFromDisk:T,uploadToManifest:S,pick:h,hash:f,fromString:U,toString:L}}},7380:e=>{"use strict";var t=function(e,t){for(var r=[],n=0;n{"use strict";r(7380);var n=function(e,t){return parseInt(e.slice(2*t+2,2*t+4),16)},i=function(e){return(e.length-2)/2},o=function(e){for(var t=[],r=2,n=e.length;r>6|192);else{if(i>55295&&i<56320){if(++n==e.length)return null;var o=e.charCodeAt(n);if(o<56320||o>57343)return null;r+=t((i=65536+((1023&i)<<10)+(1023&o))>>18|240),r+=t(i>>12&63|128)}else r+=t(i>>12|224);r+=t(i>>6&63|128)}r+=t(63&i|128)}}return r},toString:function(e){for(var t="",r=0,o=i(e);r127){if(a>191&&a<224){if(r>=o)return null;a=(31&a)<<6|63&n(e,r)}else if(a>223&&a<240){if(r+1>=o)return null;a=(15&a)<<12|(63&n(e,r))<<6|63&n(e,++r)}else{if(!(a>239&&a<248))return null;if(r+2>=o)return null;a=(7&a)<<18|(63&n(e,r))<<12|(63&n(e,++r))<<6|63&n(e,++r)}++r}if(a<=65535)t+=String.fromCharCode(a);else{if(!(a<=1114111))return null;a-=65536,t+=String.fromCharCode(a>>10|55296),t+=String.fromCharCode(1023&a|56320)}}return t},fromNumber:function(e){var t=e.toString(16);return t.length%2==0?"0x"+t:"0x0"+t},toNumber:function(e){return parseInt(e.slice(2),16)},fromNat:function(e){return"0x0"===e?"0x":e.length%2==0?e:"0x0"+e.slice(2)},toNat:function(e){return"0"===e[2]?"0x"+e.slice(3):e},fromArray:a,toArray:o,fromUint8Array:function(e){return a([].slice.call(e,0))},toUint8Array:function(e){return new Uint8Array(o(e))}}},9574:e=>{"use strict";var t="0123456789abcdef".split(""),r=[1,256,65536,16777216],n=[0,8,16,24],i=[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],o=function(e){var t,r,n,o,a,s,u,c,l,f,h,d,p,m,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)o=e[0]^e[10]^e[20]^e[30]^e[40],a=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],u=e[3]^e[13]^e[23]^e[33]^e[43],c=e[4]^e[14]^e[24]^e[34]^e[44],l=e[5]^e[15]^e[25]^e[35]^e[45],f=e[6]^e[16]^e[26]^e[36]^e[46],h=e[7]^e[17]^e[27]^e[37]^e[47],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(s<<1|u>>>31),r=(p=e[9]^e[19]^e[29]^e[39]^e[49])^(u<<1|s>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=o^(c<<1|l>>>31),r=a^(l<<1|c>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=s^(f<<1|h>>>31),r=u^(h<<1|f>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=c^(d<<1|p>>>31),r=l^(p<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=f^(o<<1|a>>>31),r=h^(a<<1|o>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=m^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&m,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~m&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=i[n],e[1]^=i[n+1]},a=function(e){return function(i){var a;if("0x"===i.slice(0,2)){a=[];for(var s=2,u=i.length;s>2]|=i[d]<>2]|=a<>2]|=(192|a>>6)<>2]|=(128|63&a)<=57344?(u[y>>2]|=(224|a>>12)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<>2]|=(240|a>>18)<>2]|=(128|a>>12&63)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<=c){for(e.start=y-c,e.block=u[l],y=0;y>2]|=r[3&y],e.lastByteIndex===c)for(u[0]=u[l],y=1;y>4&15]+t[15&p]+t[p>>12&15]+t[p>>8&15]+t[p>>20&15]+t[p>>16&15]+t[p>>28&15]+t[p>>24&15];g%l==0&&(o(h),y=0)}return"0x"+m}(function(e){return{blocks:[],reset:!0,block:0,start:0,blockCount:1600-(e<<1)>>5,outputBlocks:e>>5,s:(t=[0,0,0,0,0,0,0,0,0,0],[].concat(t,t,t,t,t))};var t}(e),a)}};e.exports={keccak256:a(256),keccak512:a(512),keccak256s:a(256),keccak512s:a(512)}},8419:e=>{"use strict";e.exports=function(e,t){if(t){t=(t=t.trim().replace(/^(\?|#|&)/,""))?"?"+t:t;var r=e.split(/[\?\#]/)[0];t&&/\:\/\/[^\/]*$/.test(r)&&(r+="/");var n=e.match(/(\#.*)$/);e=r+t,n&&(e+=n[0])}return e}},8677:(e,t,r)=>{"use strict";var n;e=r.nmd(e);var i=r(8847)(r(3355));!function(o){var a="object"==(0,i.default)(t)&&t&&!t.nodeType&&t,s="object"==(0,i.default)(e)&&e&&!e.nodeType&&e,u="object"==(void 0===r.g?"undefined":(0,i.default)(r.g))&&r.g;u.global!==u&&u.window!==u&&u.self!==u||(o=u);var c,l,f=2147483647,h=36,d=/^xn--/,p=/[^\x20-\x7E]/,m=/[\x2E\u3002\uFF0E\uFF61]/g,y={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},g=Math.floor,b=String.fromCharCode;function v(e){throw RangeError(y[e])}function w(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function A(e,t){var r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+w((e=e.replace(m,".")).split("."),t).join(".")}function S(e){for(var t,r,n=[],i=0,o=e.length;i=55296&&t<=56319&&i65535&&(t+=b((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+b(e)})).join("")}function E(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function _(e,t,r){var n=0;for(e=r?g(e/700):e>>1,e+=g(e/t);e>455;n+=h)e=g(e/35);return g(n+36*e/(e+38))}function M(e){var t,r,n,i,o,a,s,u,c,l,d,p=[],m=e.length,y=0,b=128,w=72;for((r=e.lastIndexOf("-"))<0&&(r=0),n=0;n=128&&v("not-basic"),p.push(e.charCodeAt(n));for(i=r>0?r+1:0;i=m&&v("invalid-input"),((u=(d=e.charCodeAt(i++))-48<10?d-22:d-65<26?d-65:d-97<26?d-97:h)>=h||u>g((f-y)/a))&&v("overflow"),y+=u*a,!(u<(c=s<=w?1:s>=w+26?26:s-w));s+=h)a>g(f/(l=h-c))&&v("overflow"),a*=l;w=_(y-o,t=p.length+1,0==o),g(y/t)>f-b&&v("overflow"),b+=g(y/t),y%=t,p.splice(y++,0,b)}return k(p)}function T(e){var t,r,n,i,o,a,s,u,c,l,d,p,m,y,w,A=[];for(p=(e=S(e)).length,t=128,r=0,o=72,a=0;a=t&&dg((f-r)/(m=n+1))&&v("overflow"),r+=(s-t)*m,t=s,a=0;af&&v("overflow"),d==t){for(u=r,c=h;!(u<(l=c<=o?1:c>=o+26?26:c-o));c+=h)w=u-l,y=h-l,A.push(b(E(l+w%y,0))),u=g(w/y);A.push(b(E(u,0))),o=_(r,m,n==i),r=0,++n}++r,++t}return A.join("")}if(c={version:"1.3.2",ucs2:{decode:S,encode:k},decode:M,encode:T,toASCII:function(e){return A(e,(function(e){return p.test(e)?"xn--"+T(e):e}))},toUnicode:function(e){return A(e,(function(e){return d.test(e)?M(e.slice(4).toLowerCase()):e}))}},"object"==(0,i.default)(r.amdO)&&r.amdO)void 0===(n=function(){return c}.call(t,r,t,e))||(e.exports=n);else if(a&&s)if(e.exports==a)s.exports=c;else for(l in c)c.hasOwnProperty(l)&&(a[l]=c[l]);else o.punycode=c}(void 0)},8983:e=>{"use strict";function t(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,r,n,i){r=r||"&",n=n||"=";var o={};if("string"!=typeof e||0===e.length)return o;var a=/\+/g;e=e.split(r);var s=1e3;i&&"number"==typeof i.maxKeys&&(s=i.maxKeys);var u=e.length;s>0&&u>s&&(u=s);for(var c=0;c=0?(l=p.substr(0,m),f=p.substr(m+1)):(l=p,f=""),h=decodeURIComponent(l),d=decodeURIComponent(f),t(o,h)?Array.isArray(o[h])?o[h].push(d):o[h]=[o[h],d]:o[h]=d}return o}},4031:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=function(e){switch((0,n.default)(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,t,r,o){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===(0,n.default)(e)?Object.keys(e).map((function(n){var o=encodeURIComponent(i(n))+r;return Array.isArray(e[n])?e[n].map((function(e){return o+encodeURIComponent(i(e))})).join(t):o+encodeURIComponent(i(e[n]))})).join(t):o?encodeURIComponent(i(o))+r+encodeURIComponent(i(e)):""}},845:(e,t,r)=>{"use strict";t.decode=t.parse=r(8983),t.encode=t.stringify=r(4031)},1143:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(8677),o=r(5751);function a(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}t.parse=w,t.resolve=function(e,t){return w(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?w(e,!1,!0).resolveObject(t):t},t.format=function(e){return o.isString(e)&&(e=w(e)),e instanceof a?e.format():a.prototype.format.call(e)},t.Url=a;var s=/^([a-z0-9.+-]+:)/i,u=/:[0-9]*$/,c=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,l=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),f=["'"].concat(l),h=["%","/","?",";","#"].concat(f),d=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,m=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,y={javascript:!0,"javascript:":!0},g={javascript:!0,"javascript:":!0},b={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},v=r(845);function w(e,t,r){if(e&&o.isObject(e)&&e instanceof a)return e;var n=new a;return n.parse(e,t,r),n}a.prototype.parse=function(e,t,r){if(!o.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+(0,n.default)(e));var a=e.indexOf("?"),u=-1!==a&&a127?B+="x":B+=C[N];if(!B.match(p)){var U=O.slice(0,x),F=O.slice(x+1),D=C.match(m);D&&(U.push(D[1]),F.unshift(D[2])),F.length&&(w="/"+F.join(".")+w),this.hostname=U.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),I||(this.hostname=i.toASCII(this.hostname));var j=this.port?":"+this.port:"",H=this.hostname||"";this.host=H+j,this.href+=this.host,I&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==w[0]&&(w="/"+w))}if(!y[k])for(x=0,R=f.length;x0)&&r.host.split("@"))&&(r.auth=P.shift(),r.host=r.hostname=P.shift())),r.search=e.search,r.query=e.query,o.isNull(r.pathname)&&o.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r;if(!k.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var _=k.slice(-1)[0],M=(r.host||e.host||k.length>1)&&("."===_||".."===_)||""===_,T=0,x=k.length;x>=0;x--)"."===(_=k[x])?k.splice(x,1):".."===_?(k.splice(x,1),T++):T&&(k.splice(x,1),T--);if(!A&&!S)for(;T--;T)k.unshift("..");!A||""===k[0]||k[0]&&"/"===k[0].charAt(0)||k.unshift(""),M&&"/"!==k.join("/").substr(-1)&&k.push("");var P,I=""===k[0]||k[0]&&"/"===k[0].charAt(0);return E&&(r.hostname=r.host=I?"":k.length?k.shift():"",(P=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=P.shift(),r.host=r.hostname=P.shift())),(A=A||r.host&&k.length)&&!I&&k.unshift(""),k.length?r.pathname=k.join("/"):(r.pathname=null,r.path=null),o.isNull(r.pathname)&&o.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},a.prototype.parseHost=function(){var e=this.host,t=u.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},5751:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"===(0,n.default)(e)&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},8632:(e,t)=>{"use strict";!function(e){var t,r,n,i=String.fromCharCode;function o(e){for(var t,r,n=[],i=0,o=e.length;i=55296&&t<=56319&&i=55296&&e<=57343)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value")}function s(e,t){return i(e>>t&63|128)}function u(e){if(0==(4294967168&e))return i(e);var t="";return 0==(4294965248&e)?t=i(e>>6&31|192):0==(4294901760&e)?(a(e),t=i(e>>12&15|224),t+=s(e,6)):0==(4292870144&e)&&(t=i(e>>18&7|240),t+=s(e,12),t+=s(e,6)),t+i(63&e|128)}function c(){if(n>=r)throw Error("Invalid byte index");var e=255&t[n];if(n++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function l(){var e,i;if(n>r)throw Error("Invalid byte index");if(n==r)return!1;if(e=255&t[n],n++,0==(128&e))return e;if(192==(224&e)){if((i=(31&e)<<6|c())>=128)return i;throw Error("Invalid continuation byte")}if(224==(240&e)){if((i=(15&e)<<12|c()<<6|c())>=2048)return a(i),i;throw Error("Invalid continuation byte")}if(240==(248&e)&&(i=(7&e)<<18|c()<<12|c()<<6|c())>=65536&&i<=1114111)return i;throw Error("Invalid UTF-8 detected")}e.version="3.0.0",e.encode=function(e){for(var t=o(e),r=t.length,n=-1,i="";++n65535&&(o+=i((t-=65536)>>>10&1023|55296),t=56320|1023&t),o+=i(t);return o}(s)}}(t)},6219:(e,t,r)=>{"use strict";function n(e){try{if(!r.g.localStorage)return!1}catch(e){return!1}var t=r.g.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=function(e,t){if(n("noDeprecation"))return e;var r=!1;return function(){if(!r){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}},6248:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(e){return e&&"object"===(0,n.default)(e)&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},7092:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(9446),o=r(4477),a=r(2337),s=r(8915);function u(e){return e.call.bind(e)}var c="undefined"!=typeof BigInt,l="undefined"!=typeof Symbol,f=u(Object.prototype.toString),h=u(Number.prototype.valueOf),d=u(String.prototype.valueOf),p=u(Boolean.prototype.valueOf);if(c)var m=u(BigInt.prototype.valueOf);if(l)var y=u(Symbol.prototype.valueOf);function g(e,t){if("object"!==(0,n.default)(e))return!1;try{return t(e),!0}catch(e){return!1}}function b(e){return"[object Map]"===f(e)}function v(e){return"[object Set]"===f(e)}function w(e){return"[object WeakMap]"===f(e)}function A(e){return"[object WeakSet]"===f(e)}function S(e){return"[object ArrayBuffer]"===f(e)}function k(e){return"undefined"!=typeof ArrayBuffer&&(S.working?S(e):e instanceof ArrayBuffer)}function E(e){return"[object DataView]"===f(e)}function _(e){return"undefined"!=typeof DataView&&(E.working?E(e):e instanceof DataView)}t.isArgumentsObject=i,t.isGeneratorFunction=o,t.isTypedArray=s,t.isPromise=function(e){return"undefined"!=typeof Promise&&e instanceof Promise||null!==e&&"object"===(0,n.default)(e)&&"function"==typeof e.then&&"function"==typeof e.catch},t.isArrayBufferView=function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):s(e)||_(e)},t.isUint8Array=function(e){return"Uint8Array"===a(e)},t.isUint8ClampedArray=function(e){return"Uint8ClampedArray"===a(e)},t.isUint16Array=function(e){return"Uint16Array"===a(e)},t.isUint32Array=function(e){return"Uint32Array"===a(e)},t.isInt8Array=function(e){return"Int8Array"===a(e)},t.isInt16Array=function(e){return"Int16Array"===a(e)},t.isInt32Array=function(e){return"Int32Array"===a(e)},t.isFloat32Array=function(e){return"Float32Array"===a(e)},t.isFloat64Array=function(e){return"Float64Array"===a(e)},t.isBigInt64Array=function(e){return"BigInt64Array"===a(e)},t.isBigUint64Array=function(e){return"BigUint64Array"===a(e)},b.working="undefined"!=typeof Map&&b(new Map),t.isMap=function(e){return"undefined"!=typeof Map&&(b.working?b(e):e instanceof Map)},v.working="undefined"!=typeof Set&&v(new Set),t.isSet=function(e){return"undefined"!=typeof Set&&(v.working?v(e):e instanceof Set)},w.working="undefined"!=typeof WeakMap&&w(new WeakMap),t.isWeakMap=function(e){return"undefined"!=typeof WeakMap&&(w.working?w(e):e instanceof WeakMap)},A.working="undefined"!=typeof WeakSet&&A(new WeakSet),t.isWeakSet=function(e){return A(e)},S.working="undefined"!=typeof ArrayBuffer&&S(new ArrayBuffer),t.isArrayBuffer=k,E.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&E(new DataView(new ArrayBuffer(1),0,1)),t.isDataView=_;var M="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function T(e){return"[object SharedArrayBuffer]"===f(e)}function x(e){return void 0!==M&&(void 0===T.working&&(T.working=T(new M)),T.working?T(e):e instanceof M)}function P(e){return g(e,h)}function I(e){return g(e,d)}function O(e){return g(e,p)}function R(e){return c&&g(e,m)}function C(e){return l&&g(e,y)}t.isSharedArrayBuffer=x,t.isAsyncFunction=function(e){return"[object AsyncFunction]"===f(e)},t.isMapIterator=function(e){return"[object Map Iterator]"===f(e)},t.isSetIterator=function(e){return"[object Set Iterator]"===f(e)},t.isGeneratorObject=function(e){return"[object Generator]"===f(e)},t.isWebAssemblyCompiledModule=function(e){return"[object WebAssembly.Module]"===f(e)},t.isNumberObject=P,t.isStringObject=I,t.isBooleanObject=O,t.isBigIntObject=R,t.isSymbolObject=C,t.isBoxedPrimitive=function(e){return P(e)||I(e)||O(e)||R(e)||C(e)},t.isAnyArrayBuffer=function(e){return"undefined"!=typeof Uint8Array&&(k(e)||x(e))},["isProxy","isExternal","isModuleNamespaceObject"].forEach((function(e){Object.defineProperty(t,e,{enumerable:!1,value:function(){throw new Error(e+" is not supported in userland")}})}))},5058:(e,t,r)=>{"use strict";var n=r(9142),i=r(8847)(r(3355)),o=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}})),s=n[r];r=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),g(r)?n.showHidden=r:r&&t._extend(n,r),A(n.showHidden)&&(n.showHidden=!1),A(n.depth)&&(n.depth=2),A(n.colors)&&(n.colors=!1),A(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=f),d(n,e,n.depth)}function f(e,t){var r=l.styles[t];return r?"["+l.colors[r][0]+"m"+e+"["+l.colors[r][1]+"m":e}function h(e,t){return e}function d(e,r,n){if(e.customInspect&&r&&M(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var i=r.inspect(n,e);return w(i)||(i=d(e,i,n)),i}var o=function(e,t){if(A(t))return e.stylize("undefined","undefined");if(w(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return v(t)?e.stylize(""+t,"number"):g(t)?e.stylize(""+t,"boolean"):b(t)?e.stylize("null","null"):void 0}(e,r);if(o)return o;var a=Object.keys(r),s=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),_(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return p(r);if(0===a.length){if(M(r)){var u=r.name?": "+r.name:"";return e.stylize("[Function"+u+"]","special")}if(S(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(E(r))return e.stylize(Date.prototype.toString.call(r),"date");if(_(r))return p(r)}var c,l="",f=!1,h=["{","}"];return y(r)&&(f=!0,h=["[","]"]),M(r)&&(l=" [Function"+(r.name?": "+r.name:"")+"]"),S(r)&&(l=" "+RegExp.prototype.toString.call(r)),E(r)&&(l=" "+Date.prototype.toUTCString.call(r)),_(r)&&(l=" "+p(r)),0!==a.length||f&&0!=r.length?n<0?S(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),c=f?function(e,t,r,n,i){for(var o=[],a=0,s=t.length;a60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}(c,l,h)):h[0]+l+h[1]}function p(e){return"["+Error.prototype.toString.call(e)+"]"}function m(e,t,r,n,i,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?s=u.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):u.set&&(s=e.stylize("[Setter]","special")),O(n,i)||(a="["+i+"]"),s||(e.seen.indexOf(u.value)<0?(s=b(r)?d(e,u.value,null):d(e,u.value,r-1)).indexOf("\n")>-1&&(s=o?s.split("\n").map((function(e){return" "+e})).join("\n").slice(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),A(a)){if(o&&i.match(/^\d+$/))return s;(a=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.slice(1,-1),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function y(e){return Array.isArray(e)}function g(e){return"boolean"==typeof e}function b(e){return null===e}function v(e){return"number"==typeof e}function w(e){return"string"==typeof e}function A(e){return void 0===e}function S(e){return k(e)&&"[object RegExp]"===T(e)}function k(e){return"object"===(0,i.default)(e)&&null!==e}function E(e){return k(e)&&"[object Date]"===T(e)}function _(e){return k(e)&&("[object Error]"===T(e)||e instanceof Error)}function M(e){return"function"==typeof e}function T(e){return Object.prototype.toString.call(e)}function x(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(e=e.toUpperCase(),!s[e])if(u.test(e)){var r=n.pid;s[e]=function(){var n=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,n)}}else s[e]=function(){};return s[e]},t.inspect=l,l.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},l.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.types=r(7092),t.isArray=y,t.isBoolean=g,t.isNull=b,t.isNullOrUndefined=function(e){return null==e},t.isNumber=v,t.isString=w,t.isSymbol=function(e){return"symbol"===(0,i.default)(e)},t.isUndefined=A,t.isRegExp=S,t.types.isRegExp=S,t.isObject=k,t.isDate=E,t.types.isDate=E,t.isError=_,t.types.isNativeError=_,t.isFunction=M,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"===(0,i.default)(e)||void 0===e},t.isBuffer=r(6248);var P=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function I(){var e=new Date,t=[x(e.getHours()),x(e.getMinutes()),x(e.getSeconds())].join(":");return[e.getDate(),P[e.getMonth()],t].join(" ")}function O(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",I(),t.format.apply(t,arguments))},t.inherits=r(1736),t._extend=function(e,t){if(!t||!k(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var R="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function C(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(R&&e[R]){var t;if("function"!=typeof(t=e[R]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,R,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise((function(e,n){t=e,r=n})),i=[],o=0;o{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"NIL",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"v1",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"v3",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"v4",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"v5",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"validate",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return u.default}});var n=h(r(5999)),i=h(r(8231)),o=h(r(8647)),a=h(r(5025)),s=h(r(5996)),u=h(r(8928)),c=h(r(6163)),l=h(r(2982)),f=h(r(1729));function h(e){return e&&e.__esModule?e:{default:e}}},6792:(e,t)=>{"use strict";function r(e){return 14+(e+64>>>9<<4)+1}function n(e,t){var r=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(r>>16)<<16|65535&r}function i(e,t,r,i,o,a){return n((s=n(n(t,e),n(i,a)))<<(u=o)|s>>>32-u,r);var s,u}function o(e,t,r,n,o,a,s){return i(t&r|~t&n,e,t,o,a,s)}function a(e,t,r,n,o,a,s){return i(t&n|r&~n,e,t,o,a,s)}function s(e,t,r,n,o,a,s){return i(t^r^n,e,t,o,a,s)}function u(e,t,r,n,o,a,s){return i(r^(t|~n),e,t,o,a,s)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default=function(e){if("string"==typeof e){var t=unescape(encodeURIComponent(e));e=new Uint8Array(t.length);for(var i=0;i>5]>>>i%32&255,a=parseInt(n.charAt(o>>>4&15)+n.charAt(15&o),16);t.push(a)}return t}(function(e,t){e[t>>5]|=128<>5]|=(255&e[i/8])<{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};t.default=r},5996:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default="00000000-0000-0000-0000-000000000000"},1729:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=(n=r(6163))&&n.__esModule?n:{default:n};t.default=function(e){if(!(0,i.default)(e))throw TypeError("Invalid UUID");var t,r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=255&t,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=255&t,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=255&t,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=255&t,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=255&t,r}},7300:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default=/^(?:[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},4402:(e,t)=>{"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){if(!r&&!(r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return r(n)};var n=new Uint8Array(16)},2702:(e,t)=>{"use strict";function r(e,t,r,n){switch(e){case 0:return t&r^~t&n;case 1:case 3:return t^r^n;case 2:return t&r^t&n^r&n}}function n(e,t){return e<>>32-t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default=function(e){var t=[1518500249,1859775393,2400959708,3395469782],i=[1732584193,4023233417,2562383102,271733878,3285377520];if("string"==typeof e){var o=unescape(encodeURIComponent(e));e=[];for(var a=0;a>>0;A=w,w=v,v=n(b,30)>>>0,b=g,g=E}i[0]=i[0]+g>>>0,i[1]=i[1]+b>>>0,i[2]=i[2]+v>>>0,i[3]=i[3]+w>>>0,i[4]=i[4]+A>>>0}return[i[0]>>24&255,i[0]>>16&255,i[0]>>8&255,255&i[0],i[1]>>24&255,i[1]>>16&255,i[1]>>8&255,255&i[1],i[2]>>24&255,i[2]>>16&255,i[2]>>8&255,255&i[2],i[3]>>24&255,i[3]>>16&255,i[3]>>8&255,255&i[3],i[4]>>24&255,i[4]>>16&255,i[4]>>8&255,255&i[4]]}},2982:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.unsafeStringify=s;for(var n,i=(n=r(6163))&&n.__esModule?n:{default:n},o=[],a=0;a<256;++a)o.push((a+256).toString(16).slice(1));function s(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(o[e[t+0]]+o[e[t+1]]+o[e[t+2]]+o[e[t+3]]+"-"+o[e[t+4]]+o[e[t+5]]+"-"+o[e[t+6]]+o[e[t+7]]+"-"+o[e[t+8]]+o[e[t+9]]+"-"+o[e[t+10]]+o[e[t+11]]+o[e[t+12]]+o[e[t+13]]+o[e[t+14]]+o[e[t+15]]).toLowerCase()}t.default=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=s(e,t);if(!(0,i.default)(r))throw TypeError("Stringified UUID is invalid");return r}},5999:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i,o,a=(n=r(4402))&&n.__esModule?n:{default:n},s=r(2982),u=0,c=0;t.default=function(e,t,r){var n=t&&r||0,l=t||new Array(16),f=(e=e||{}).node||i,h=void 0!==e.clockseq?e.clockseq:o;if(null==f||null==h){var d=e.random||(e.rng||a.default)();null==f&&(f=i=[1|d[0],d[1],d[2],d[3],d[4],d[5]]),null==h&&(h=o=16383&(d[6]<<8|d[7]))}var p=void 0!==e.msecs?e.msecs:Date.now(),m=void 0!==e.nsecs?e.nsecs:c+1,y=p-u+(m-c)/1e4;if(y<0&&void 0===e.clockseq&&(h=h+1&16383),(y<0||p>u)&&void 0===e.nsecs&&(m=0),m>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");u=p,c=m,o=h;var g=(1e4*(268435455&(p+=122192928e5))+m)%4294967296;l[n++]=g>>>24&255,l[n++]=g>>>16&255,l[n++]=g>>>8&255,l[n++]=255&g;var b=p/4294967296*1e4&268435455;l[n++]=b>>>8&255,l[n++]=255&b,l[n++]=b>>>24&15|16,l[n++]=b>>>16&255,l[n++]=h>>>8|128,l[n++]=255&h;for(var v=0;v<6;++v)l[n+v]=f[v];return t||(0,s.unsafeStringify)(l)}},8231:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=o(r(6125)),i=o(r(6792));function o(e){return e&&e.__esModule?e:{default:e}}var a=(0,n.default)("v3",48,i.default);t.default=a},6125:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.URL=t.DNS=void 0,t.default=function(e,t,r){function n(e,n,a,s){var u;if("string"==typeof e&&(e=function(e){e=unescape(encodeURIComponent(e));for(var t=[],r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=a(r(1788)),i=a(r(4402)),o=r(2982);function a(e){return e&&e.__esModule?e:{default:e}}t.default=function(e,t,r){if(n.default.randomUUID&&!t&&!e)return n.default.randomUUID();var a=(e=e||{}).random||(e.rng||i.default)();if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,t){r=r||0;for(var s=0;s<16;++s)t[r+s]=a[s];return t}return(0,o.unsafeStringify)(a)}},5025:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=o(r(6125)),i=o(r(2702));function o(e){return e&&e.__esModule?e:{default:e}}var a=(0,n.default)("v5",80,i.default);t.default=a},6163:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=(n=r(7300))&&n.__esModule?n:{default:n};t.default=function(e){return"string"==typeof e&&i.default.test(e)}},8928:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=(n=r(6163))&&n.__esModule?n:{default:n};t.default=function(e){if(!(0,i.default)(e))throw TypeError("Invalid UUID");return parseInt(e.slice(14,15),16)}},8325:e=>{"use strict";e.exports=function e(t,r){var n,i=0,o=0,a=r=r||0,s=t.length;do{if(a>=s)throw e.bytes=0,new RangeError("Could not decode varint");n=t[a++],i+=o<28?(127&n)<=128);return e.bytes=a-r,i}},2699:e=>{"use strict";e.exports=function e(r,n,i){n=n||[];for(var o=i=i||0;r>=t;)n[i++]=255&r|128,r/=128;for(;-128&r;)n[i++]=255&r|128,r>>>=7;return n[i]=0|r,e.bytes=i-o+1,n};var t=Math.pow(2,31)},6657:(e,t,r)=>{"use strict";e.exports={encode:r(2699),decode:r(8325),encodingLength:r(7490)}},7490:e=>{"use strict";var t=Math.pow(2,7),r=Math.pow(2,14),n=Math.pow(2,21),i=Math.pow(2,28),o=Math.pow(2,35),a=Math.pow(2,42),s=Math.pow(2,49),u=Math.pow(2,56),c=Math.pow(2,63);e.exports=function(e){return e{"use strict";var n,i=r(8847)(r(3355));if("object"===("undefined"==typeof globalThis?"undefined":(0,i.default)(globalThis)))n=globalThis;else try{n=r(6464)}catch(e){}finally{if(n||"undefined"==typeof window||(n=window),!n)throw new Error("Could not determine global this")}var o=n.WebSocket||n.MozWebSocket,a=r(5735);function s(e,t){return t?new o(e,t):new o(e)}o&&["CONNECTING","OPEN","CLOSING","CLOSED"].forEach((function(e){Object.defineProperty(s,e,{get:function(){return o[e]}})})),e.exports={w3cwebsocket:o?s:null,version:a}},5735:(e,t,r)=>{"use strict";e.exports=r(9794).version},2337:(e,t,r)=>{"use strict";var n=r(8184),i=r(3604),o=r(593),a=r(3820),s=o("Object.prototype.toString"),u=r(1191)(),c="undefined"==typeof globalThis?r.g:globalThis,l=i(),f=o("String.prototype.slice"),h={},d=Object.getPrototypeOf;u&&a&&d&&n(l,(function(e){if("function"==typeof c[e]){var t=new c[e];if(Symbol.toStringTag in t){var r=d(t),n=a(r,Symbol.toStringTag);if(!n){var i=d(r);n=a(i,Symbol.toStringTag)}h[e]=n.get}}}));var p=r(8915);e.exports=function(e){return!!p(e)&&(u&&Symbol.toStringTag in e?function(e){var t=!1;return n(h,(function(r,n){if(!t)try{var i=r.call(e);i===n&&(t=i)}catch(e){}})),t}(e):f(s(e),8,-1))}},1357:(e,t,r)=>{"use strict";var n=r(8992),i=r(8419),o=r(3103),a=r(9122),s=r(7321),u="application/json",c=function(){};e.exports=function(e,t,r){if(!e||"string"!=typeof e)throw new TypeError("must specify a URL");if("function"==typeof t&&(r=t,t={}),r&&"function"!=typeof r)throw new TypeError("expected cb to be undefined or a function");r=r||c;var l=(t=t||{}).json?"json":"text",f=(t=o({responseType:l},t)).headers||{},h=(t.method||"GET").toUpperCase(),d=t.query;return d&&("string"!=typeof d&&(d=n.stringify(d)),e=i(e,d)),"json"===t.responseType&&a(f,"Accept",u),t.json&&"GET"!==h&&"HEAD"!==h&&(a(f,"Content-Type",u),t.body=JSON.stringify(t.body)),t.method=h,t.url=e,t.headers=f,delete t.query,delete t.json,s(t,r)}},9122:e=>{"use strict";e.exports=function(e,t,r){var n=t.toLowerCase();e[t]||e[n]||(e[t]=r)}},9800:e=>{"use strict";e.exports=function(e,t){return t?{statusCode:t.statusCode,headers:t.headers,method:e.method,url:e.url,rawRequest:t.rawRequest?t.rawRequest:t}:null}},7321:(e,t,r)=>{"use strict";var n=r(346),i=r(9800),o=function(){};e.exports=function(e,t){delete e.uri;var r=!1;"json"===e.responseType&&(e.responseType="text",r=!0);var a=n(e,(function(n,a,s){if(r&&!n)try{var u=a.rawRequest.responseText;s=JSON.parse(u)}catch(e){n=e}a=i(e,a),t(n,n?null:s,a),t=o})),s=a.onabort;return a.onabort=function(){var e=s.apply(a,Array.prototype.slice.call(arguments));return t(new Error("XHR Aborted")),t=o,e},a}},8992:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(3621),o=r(3103),a=r(34);function s(e,t){return t.encode?t.strict?i(e):encodeURIComponent(e):e}function u(e){return Array.isArray(e)?e.sort():"object"===(0,n.default)(e)?u(Object.keys(e)).sort((function(e,t){return Number(e)-Number(t)})).map((function(t){return e[t]})):e}function c(e){var t=e.indexOf("?");return-1===t?"":e.slice(t+1)}function l(e,t){var r=function(e){var t;switch(e.arrayFormat){case"index":return function(e,r,n){t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),t?(void 0===n[e]&&(n[e]={}),n[e][t[1]]=r):n[e]=r};case"bracket":return function(e,r,n){t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),t?void 0!==n[e]?n[e]=[].concat(n[e],r):n[e]=[r]:n[e]=r};default:return function(e,t,r){void 0!==r[e]?r[e]=[].concat(r[e],t):r[e]=t}}}(t=o({arrayFormat:"none"},t)),i=Object.create(null);return"string"!=typeof e?i:(e=e.trim().replace(/^[?#&]/,""))?(e.split("&").forEach((function(e){var t=e.replace(/\+/g," ").split("="),n=t.shift(),o=t.length>0?t.join("="):void 0;o=void 0===o?null:a(o),r(a(n),o,i)})),Object.keys(i).sort().reduce((function(e,t){var r=i[t];return Boolean(r)&&"object"===(0,n.default)(r)&&!Array.isArray(r)?e[t]=u(r):e[t]=r,e}),Object.create(null))):i}t.extract=c,t.parse=l,t.stringify=function(e,t){!1===(t=o({encode:!0,strict:!0,arrayFormat:"none"},t)).sort&&(t.sort=function(){});var r=function(e){switch(e.arrayFormat){case"index":return function(t,r,n){return null===r?[s(t,e),"[",n,"]"].join(""):[s(t,e),"[",s(n,e),"]=",s(r,e)].join("")};case"bracket":return function(t,r){return null===r?s(t,e):[s(t,e),"[]=",s(r,e)].join("")};default:return function(t,r){return null===r?s(t,e):[s(t,e),"=",s(r,e)].join("")}}}(t);return e?Object.keys(e).sort(t.sort).map((function(n){var i=e[n];if(void 0===i)return"";if(null===i)return s(n,t);if(Array.isArray(i)){var o=[];return i.slice().forEach((function(e){void 0!==e&&o.push(r(n,e,o.length))})),o.join("&")}return s(n,t)+"="+s(i,t)})).filter((function(e){return e.length>0})).join("&"):""},t.parseUrl=function(e,t){return{url:e.split("?")[0]||"",query:l(c(e),t)}}},3621:e=>{"use strict";e.exports=function(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}},346:(e,t,r)=>{"use strict";var n=r(2948),i=r(4339),o=r(8209),a=r(7705);function s(e,t,r){var n=e;return i(t)?(r=t,"string"==typeof e&&(n={uri:e})):n=a(t,{uri:e}),n.callback=r,n}function u(e,t,r){return c(t=s(e,t,r))}function c(e){if(void 0===e.callback)throw new Error("callback argument missing");var t=!1,r=function(r,n,i){t||(t=!0,e.callback(r,n,i))};function n(){var e=void 0;if(e=l.response?l.response:l.responseText||function(e){try{if("document"===e.responseType)return e.responseXML;var t=e.responseXML&&"parsererror"===e.responseXML.documentElement.nodeName;if(""===e.responseType&&!t)return e.responseXML}catch(e){}return null}(l),g)try{e=JSON.parse(e)}catch(e){}return e}function i(e){return clearTimeout(f),e instanceof Error||(e=new Error(""+(e||"Unknown XMLHttpRequest Error"))),e.statusCode=0,r(e,b)}function a(){if(!c){var t;clearTimeout(f),t=e.useXDR&&void 0===l.status?200:1223===l.status?204:l.status;var i=b,a=null;return 0!==t?(i={body:n(),statusCode:t,method:d,headers:{},url:h,rawRequest:l},l.getAllResponseHeaders&&(i.headers=o(l.getAllResponseHeaders()))):a=new Error("Internal XMLHttpRequest Error"),r(a,i,i.body)}}var s,c,l=e.xhr||null;l||(l=e.cors||e.useXDR?new u.XDomainRequest:new u.XMLHttpRequest);var f,h=l.url=e.uri||e.url,d=l.method=e.method||"GET",p=e.body||e.data,m=l.headers=e.headers||{},y=!!e.sync,g=!1,b={body:void 0,headers:{},statusCode:0,method:d,url:h,rawRequest:l};if("json"in e&&!1!==e.json&&(g=!0,m.accept||m.Accept||(m.Accept="application/json"),"GET"!==d&&"HEAD"!==d&&(m["content-type"]||m["Content-Type"]||(m["Content-Type"]="application/json"),p=JSON.stringify(!0===e.json?p:e.json))),l.onreadystatechange=function(){4===l.readyState&&setTimeout(a,0)},l.onload=a,l.onerror=i,l.onprogress=function(){},l.onabort=function(){c=!0},l.ontimeout=i,l.open(d,h,!y,e.username,e.password),y||(l.withCredentials=!!e.withCredentials),!y&&e.timeout>0&&(f=setTimeout((function(){if(!c){c=!0,l.abort("timeout");var e=new Error("XMLHttpRequest timeout");e.code="ETIMEDOUT",i(e)}}),e.timeout)),l.setRequestHeader)for(s in m)m.hasOwnProperty(s)&&l.setRequestHeader(s,m[s]);else if(e.headers&&!function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}(e.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in e&&(l.responseType=e.responseType),"beforeSend"in e&&"function"==typeof e.beforeSend&&e.beforeSend(l),l.send(p||null),l}e.exports=u,e.exports.default=u,u.XMLHttpRequest=n.XMLHttpRequest||function(){},u.XDomainRequest="withCredentials"in new u.XMLHttpRequest?u.XMLHttpRequest:n.XDomainRequest,function(e,t){for(var r=0;r{"use strict";e.exports=function(){for(var e={},r=0;r{"use strict";var n=r(8847)(r(3355)),i=r(6427),o=function e(t){this.givenProvider=e.givenProvider,t&&t._requestManager&&(t=t.currentProvider),"undefined"!=typeof document&&(this.pick=i.pick),this.setProvider(t)};o.givenProvider=null,"undefined"!=typeof ethereum&ðereum.bzz&&(o.givenProvider=ethereum.bzz),o.prototype.setProvider=function(e){if(e&&"object"===(0,n.default)(e)&&"string"==typeof e.bzz&&(e=e.bzz),"string"!=typeof e){this.currentProvider=null;var t=new Error("No provider set, please set one using bzz.setProvider().");return this.download=this.upload=this.isAvailable=function(){throw t},!1}return this.currentProvider=e,this.download=i.at(e).download,this.upload=i.at(e).upload,this.isAvailable=i.at(e).isAvailable,!0},e.exports=o},4246:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports={ErrorResponse:function(e){var t=e&&e.error&&e.error.message?e.error.message:JSON.stringify(e),r=e.error&&e.error.data?e.error.data:null,n=new Error("Returned error: "+t);return n.data=r,n},InvalidNumberOfParams:function(e,t,r){return new Error('Invalid number of parameters for "'+r+'". Got '+e+" expected "+t+"!")},InvalidConnection:function(e,t){return this.ConnectionError("CONNECTION ERROR: Couldn't connect to node "+e+".",t)},InvalidProvider:function(){return new Error("Provider not set or invalid")},InvalidResponse:function(e){var t=e&&e.error&&e.error.message?e.error.message:"Invalid JSON RPC response: "+JSON.stringify(e);return new Error(t)},ConnectionTimeout:function(e){return new Error("CONNECTION TIMEOUT: timeout of "+e+" ms achived")},ConnectionNotOpenError:function(e){return this.ConnectionError("connection not open on send()",e)},ConnectionCloseError:function(e){return"object"===(0,n.default)(e)&&e.code&&e.reason?this.ConnectionError("CONNECTION ERROR: The connection got closed with the close code `"+e.code+"` and the following reason string `"+e.reason+"`",e):new Error("CONNECTION ERROR: The connection closed unexpectedly")},MaxAttemptsReachedOnReconnectingError:function(){return new Error("Maximum number of reconnect attempts reached!")},PendingRequestsOnReconnectingError:function(){return new Error("CONNECTION ERROR: Provider started to reconnect before the response got received!")},ConnectionError:function(e,t){var r=new Error(e);return t&&(r.code=t.code,r.reason=t.reason),r},RevertInstructionError:function(e,t){var r=new Error("Your request got reverted with the following reason string: "+e);return r.reason=e,r.signature=t,r},TransactionRevertInstructionError:function(e,t,r){var n=new Error("Transaction has been reverted by the EVM:\n"+JSON.stringify(r,null,2));return n.reason=e,n.signature=t,n.receipt=r,n},TransactionError:function(e,t){var r=new Error(e);return r.receipt=t,r},NoContractAddressFoundError:function(e){return this.TransactionError("The transaction receipt didn't contain a contract address.",e)},ContractCodeNotStoredError:function(e){return this.TransactionError("The contract code couldn't be stored, please check your gas limit.",e)},TransactionRevertedWithoutReasonError:function(e){return this.TransactionError("Transaction has been reverted by the EVM:\n"+JSON.stringify(e,null,2),e)},TransactionOutOfGasError:function(e){return this.TransactionError("Transaction ran out of gas. Please provide more gas:\n"+JSON.stringify(e,null,2),e)},ResolverMethodMissingError:function(e,t){return new Error("The resolver at "+e+'does not implement requested method: "'+t+'".')},ContractMissingABIError:function(){return new Error("You must provide the json interface of the contract when instantiating a contract object.")},ContractOnceRequiresCallbackError:function(){return new Error("Once requires a callback as the second parameter.")},ContractEventDoesNotExistError:function(e){return new Error('Event "'+e+"\" doesn't exist in this contract.")},ContractReservedEventError:function(e){return new Error('The event "'+e+"\" is a reserved event name, you can't use it.")},ContractMissingDeployDataError:function(){return new Error('No "data" specified in neither the given options, nor the default options.')},ContractNoAddressDefinedError:function(){return new Error("This contract object doesn't have address set yet, please set an address first.")},ContractNoFromAddressDefinedError:function(){return new Error('No "from" address specified in neither the given options, nor the default options.')}}},2084:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(775)),o=n(r(3355));function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t{"use strict";var n=r(4246),i=r(2084);e.exports={errors:n,formatters:i}},3349:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(2247)),o=n(r(4519)),a=n(r(775)),s=n(r(5698)),u=n(r(3355));function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function l(e){for(var t=1;t1?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},g.prototype.getCall=function(e){return"function"==typeof this.call?this.call(e):this.call},g.prototype.extractCallback=function(e){if("function"==typeof e[e.length-1])return e.pop()},g.prototype.validateArgs=function(e){if(e.length!==this.params)throw f.InvalidNumberOfParams(e.length,this.params,this.name)},g.prototype.formatInput=function(e){var t=this;return this.inputFormatter?this.inputFormatter.map((function(r,n){return r?r.call(t,e[n]):e[n]})):e},g.prototype.formatOutput=function(e){var t=this;return Array.isArray(e)?e.map((function(e){return t.outputFormatter&&e?t.outputFormatter(e):e})):this.outputFormatter&&e?this.outputFormatter(e):e},g.prototype.toPayload=function(e){var t=this.getCall(e),r=this.extractCallback(e),n=this.formatInput(e);this.validateArgs(n);var i={method:t,params:n,callback:r};return this.transformPayload&&(i=this.transformPayload(i)),i},g.prototype._confirmTransaction=function(e,t,r){var n=this,o=!1,a=!0,c=0,l=0,b=null,v=null,w=null,A=r.params[0]&&"object"===(0,u.default)(r.params[0])&&r.params[0].gas?r.params[0].gas:null,S=!!r.params[0]&&"object"===(0,u.default)(r.params[0])&&r.params[0].data&&r.params[0].from&&!r.params[0].to,k=S&&r.params[0].data.length>2,E=[new g({name:"getBlockByNumber",call:"eth_getBlockByNumber",params:2,inputFormatter:[h.inputBlockNumberFormatter,function(e){return!!e}],outputFormatter:h.outputBlockFormatter}),new g({name:"getTransactionReceipt",call:"eth_getTransactionReceipt",params:1,inputFormatter:[null],outputFormatter:h.outputTransactionReceiptFormatter}),new g({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[h.inputAddressFormatter,h.inputDefaultBlockNumberFormatter]}),new g({name:"getTransactionByHash",call:"eth_getTransactionByHash",params:1,inputFormatter:[null],outputFormatter:h.outputTransactionFormatter}),new m({name:"subscribe",type:"eth",subscriptions:{newBlockHeaders:{subscriptionName:"newHeads",params:0,outputFormatter:h.outputBlockFormatter}}})],_={};E.forEach((function(e){e.attachToObject(_),e.requestManager=n.requestManager}));var M=function(u,m,g,E,M){if(!g)return M||(M={unsubscribe:function(){clearInterval(b),clearTimeout(v)}}),(u?p.resolve(u):_.getTransactionReceipt(t)).catch((function(t){M.unsubscribe(),o=!0,d._fireError({message:"Failed to check for transaction receipt:",data:t},e.eventEmitter,e.reject)})).then(function(){var t=(0,s.default)(i.default.mark((function t(r){var o,s,c;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r&&r.blockHash){t.next=2;break}throw new Error("Receipt missing or blockHash null");case 2:if(n.extraFormatters&&n.extraFormatters.receiptFormatter&&(r=n.extraFormatters.receiptFormatter(r)),!(e.eventEmitter.listeners("confirmation").length>0)){t.next=28;break}if(void 0!==u&&0===l){t.next=25;break}return t.next=7,_.getBlockByNumber("latest");case 7:if(s=t.sent,c=s?s.hash:null,!m){t.next=24;break}if(!w){t.next=17;break}return t.next=13,_.getBlockByNumber(w.number+1);case 13:(o=t.sent)&&(w=o,e.eventEmitter.emit("confirmation",l,r,c)),t.next=22;break;case 17:return t.next=19,_.getBlockByNumber(r.blockNumber);case 19:o=t.sent,w=o,e.eventEmitter.emit("confirmation",l,r,c);case 22:t.next=25;break;case 24:e.eventEmitter.emit("confirmation",l,r,c);case 25:(m&&o||!m)&&l++,a=!1,l===n.transactionConfirmationBlocks+1&&(M.unsubscribe(),e.eventEmitter.removeAllListeners());case 28:return t.abrupt("return",r);case 29:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).then(function(){var t=(0,s.default)(i.default.mark((function t(r){var s;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!S||o){t.next=19;break}if(r.contractAddress){t.next=5;break}return a&&(M.unsubscribe(),o=!0),d._fireError(f.NoContractAddressFoundError(r),e.eventEmitter,e.reject,null,r),t.abrupt("return");case 5:return t.prev=5,t.next=8,_.getCode(r.contractAddress);case 8:s=t.sent,t.next=13;break;case 11:t.prev=11,t.t0=t.catch(5);case 13:if(s){t.next=15;break}return t.abrupt("return");case 15:!0===r.status&&k||s.length>2?(e.eventEmitter.emit("receipt",r),n.extraFormatters&&n.extraFormatters.contractDeployFormatter?e.resolve(n.extraFormatters.contractDeployFormatter(r)):e.resolve(r),a&&e.eventEmitter.removeAllListeners()):d._fireError(f.ContractCodeNotStoredError(r),e.eventEmitter,e.reject,null,r),a&&M.unsubscribe(),o=!0;case 19:return t.abrupt("return",r);case 20:case"end":return t.stop()}}),t,null,[[5,11]])})));return function(e){return t.apply(this,arguments)}}()).then(function(){var t=(0,s.default)(i.default.mark((function t(s){var u,c,l,p;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(S||o){t.next=35;break}if(s.outOfGas||A&&A===s.gasUsed||!0!==s.status&&"0x1"!==s.status&&void 0!==s.status){t.next=7;break}e.eventEmitter.emit("receipt",s),e.resolve(s),a&&e.eventEmitter.removeAllListeners(),t.next=33;break;case 7:if(JSON.stringify(s,null,2),!1!==s.status&&"0x0"!==s.status){t.next=32;break}if(t.prev=9,u=null,!n.handleRevert||"eth_sendTransaction"!==n.call&&"eth_sendRawTransaction"!==n.call){t.next=24;break}return c=r.params[0],"eth_sendRawTransaction"===n.call&&(l=r.params[0],p=y.parse(l),c=h.inputTransactionFormatter({data:p.data,to:p.to,from:p.from,gas:p.gasLimit.toHexString(),gasPrice:p.gasPrice?p.gasPrice.toHexString():void 0,value:p.value.toHexString()})),t.next=16,n.getRevertReason(c,s.blockNumber);case 16:if(!(u=t.sent)){t.next=21;break}d._fireError(f.TransactionRevertInstructionError(u.reason,u.signature,s),e.eventEmitter,e.reject,null,s),t.next=22;break;case 21:throw!1;case 22:t.next=25;break;case 24:throw!1;case 25:t.next=30;break;case 27:t.prev=27,t.t0=t.catch(9),d._fireError(f.TransactionRevertedWithoutReasonError(s),e.eventEmitter,e.reject,null,s);case 30:t.next=33;break;case 32:d._fireError(f.TransactionOutOfGasError(s),e.eventEmitter,e.reject,null,s);case 33:a&&M.unsubscribe(),o=!0;case 35:case"end":return t.stop()}}),t,null,[[9,27]])})));return function(e){return t.apply(this,arguments)}}()).catch((function(){c++,m?c-1>=n.transactionPollingTimeout&&(M.unsubscribe(),o=!0,d._fireError(f.TransactionError("Transaction was not mined within "+n.transactionPollingTimeout+" seconds, please make sure your transaction was properly sent. Be aware that it might still be mined!"),e.eventEmitter,e.reject)):c-1>=n.transactionBlockTimeout&&(M.unsubscribe(),o=!0,d._fireError(f.TransactionError("Transaction was not mined within "+n.transactionBlockTimeout+" blocks, please make sure your transaction was properly sent. Be aware that it might still be mined!"),e.eventEmitter,e.reject))}));M.unsubscribe(),o=!0,d._fireError({message:"Failed to subscribe to new newBlockHeaders to confirm the transaction receipts.",data:g},e.eventEmitter,e.reject)},T=function(e){var t=!1,r=function(){b=setInterval(M.bind(null,e,!0),n.transactionPollingInterval)};if(!this.requestManager.provider.on)return r();_.subscribe("newBlockHeaders",(function(n,i,o){if(t=!0,n||!i)return r();M(e,!1,n,0,o)})),v=setTimeout((function(){t||r()}),1e3*this.blockHeaderTimeout)}.bind(this);_.getTransactionReceipt(t).then((function(t){t&&t.blockHash?(e.eventEmitter.listeners("confirmation").length>0&&T(t),M(t,!1)):o||T()})).catch((function(){o||T()}))};var b=function(e,t){return"number"==typeof e?t.wallet[e]:e&&"object"===(0,u.default)(e)&&e.address&&e.privateKey?e:t.wallet[e.toLowerCase()]};function v(e,t){return new Promise((function(r,n){try{var i=new g({name:"getBlockByNumber",call:"eth_getBlockByNumber",params:2,inputFormatter:[function(e){return e?d.toHex(e):"latest"},function(){return!1}]}).createFunction(e.requestManager),a=new g({name:"getGasPrice",call:"eth_gasPrice",params:0}).createFunction(e.requestManager);Promise.all([i(),a()]).then((function(e){var n=(0,o.default)(e,2),i=n[0],a=n[1];if(("0x2"===t.type||void 0===t.type)&&i&&i.baseFeePerGas){var s,u;t.gasPrice?(s=t.gasPrice,u=t.gasPrice,delete t.gasPrice):(s=t.maxPriorityFeePerGas||"0x9502F900",u=t.maxFeePerGas||d.toHex(d.toBN(i.baseFeePerGas).mul(d.toBN(2)).add(d.toBN(s)))),r({maxFeePerGas:u,maxPriorityFeePerGas:s})}else{if(t.maxPriorityFeePerGas||t.maxFeePerGas)throw Error("Network doesn't support eip-1559");r({gasPrice:a})}}))}catch(e){n(e)}}))}g.prototype.buildCall=function(){var e=this,t="eth_sendTransaction"===e.call||"eth_sendRawTransaction"===e.call,r="eth_call"===e.call,n=function(){var n=Array.prototype.slice.call(arguments),i=p(!t),o=e.toPayload(n);e.hexFormat=!1,"eth_getTransactionReceipt"===e.call&&(e.hexFormat=o.params.length{"use strict";var n=r(8008),i=function(e){var t,r,i=new Promise((function(){t=arguments[0],r=arguments[1]}));if(e)return{resolve:t,reject:r,eventEmitter:i};var o=new n;return i._events=o._events,i.emit=o.emit,i.on=o.on,i.once=o.once,i.off=o.off,i.listeners=o.listeners,i.addListener=o.addListener,i.removeListener=o.removeListener,i.removeAllListeners=o.removeAllListeners,{resolve:t,reject:r,eventEmitter:i}};i.resolve=function(e){var t=i(!0);return t.resolve(e),t.eventEmitter},e.exports=i},5229:(e,t,r)=>{"use strict";var n=r(8155),i=r(1314).errors,o=function(e){this.requestManager=e,this.requests=[]};o.prototype.add=function(e){this.requests.push(e)},o.prototype.execute=function(){var e=this.requests,t=this._sortResponses.bind(this);this.requestManager.sendBatch(e,(function(r,o){o=t(o),e.map((function(e,t){return o[t]||{}})).forEach((function(t,r){if(e[r].callback){if(t&&t.error)return e[r].callback(i.ErrorResponse(t));if(!n.isValidResponse(t))return e[r].callback(i.InvalidResponse(t));try{e[r].callback(null,e[r].format?e[r].format(t.result):t.result)}catch(t){e[r].callback(t)}}}))}))},o.prototype._sortResponses=function(e){return(e||[]).sort((function(e,t){return e.id-t.id}))},e.exports=o},9764:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=null,o="object"===("undefined"==typeof globalThis?"undefined":(0,n.default)(globalThis))?globalThis:void 0;if(!o)try{o=Function("return this")()}catch(e){o=self}void 0!==o.ethereum?i=o.ethereum:void 0!==o.web3&&o.web3.currentProvider&&(o.web3.currentProvider.sendAsync&&(o.web3.currentProvider.send=o.web3.currentProvider.sendAsync,delete o.web3.currentProvider.sendAsync),!o.web3.currentProvider.on&&o.web3.currentProvider.connection&&"ipcProviderWrapper"===o.web3.currentProvider.connection.constructor.name&&(o.web3.currentProvider.on=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");"data"===e?this.connection.on("data",(function(e){var r="";e=e.toString();try{r=JSON.parse(e)}catch(r){return t(new Error("Couldn't parse response data"+e))}r.id||-1===r.method.indexOf("_subscription")||t(null,r)})):this.connection.on(e,t)}),i=o.web3.currentProvider),e.exports=i},2033:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(5058).callbackify,o=r(1314).errors,a=r(8155),s=r(5229),u=r(9764),c=function e(t,r){this.provider=null,this.providers=e.providers,this.setProvider(t,r),this.subscriptions=new Map};c.givenProvider=u,c.providers={WebsocketProvider:r(7651),HttpProvider:r(4565),IpcProvider:r(2683)},c.prototype.setProvider=function(e,t){var r=this;if(e&&"string"==typeof e&&this.providers)if(/^http(s)?:\/\//i.test(e))e=new this.providers.HttpProvider(e);else if(/^ws(s)?:\/\//i.test(e))e=new this.providers.WebsocketProvider(e);else if(e&&"object"===(0,n.default)(t)&&"function"==typeof t.connect)e=new this.providers.IpcProvider(e,t);else if(e)throw new Error("Can't autodetect provider for \""+e+'"');this.provider&&this.provider.connected&&this.clearSubscriptions(),this.provider=e||null,this.provider&&this.provider.on&&("function"==typeof e.request?this.provider.on("message",(function(e){if(e&&"eth_subscription"===e.type&&e.data){var t=e.data;t.subscription&&r.subscriptions.has(t.subscription)&&r.subscriptions.get(t.subscription).callback(null,t.result)}})):this.provider.on("data",(function(e,t){(e=e||t).method&&e.params&&e.params.subscription&&r.subscriptions.has(e.params.subscription)&&r.subscriptions.get(e.params.subscription).callback(null,e.params.result)})),this.provider.on("connect",(function(){r.subscriptions.forEach((function(e){e.subscription.resubscribe()}))})),this.provider.on("error",(function(e){r.subscriptions.forEach((function(t){t.callback(e)}))})),this.provider.on("disconnect",(function(e){r._isCleanCloseEvent(e)&&!r._isIpcCloseError(e)||(r.subscriptions.forEach((function(t){t.callback(o.ConnectionCloseError(e)),r.subscriptions.delete(t.subscription.id)})),r.provider&&r.provider.emit&&r.provider.emit("error",o.ConnectionCloseError(e))),r.provider&&r.provider.emit&&r.provider.emit("end",e)})))},c.prototype.send=function(e,t){if(t=t||function(){},!this.provider)return t(o.InvalidProvider());var r=e.method,n=e.params,s=a.toPayload(r,n),u=this._jsonrpcResultCallback(t,s);if(this.provider.request)i(this.provider.request.bind(this.provider))({method:r,params:n},t);else if(this.provider.sendAsync)this.provider.sendAsync(s,u);else{if(!this.provider.send)throw new Error("Provider does not have a request or send method to use.");this.provider.send(s,u)}},c.prototype.sendBatch=function(e,t){if(!this.provider)return t(o.InvalidProvider());var r=a.toBatchPayload(e);this.provider[this.provider.sendAsync?"sendAsync":"send"](r,(function(e,r){return e?t(e):Array.isArray(r)?void t(null,r):t(o.InvalidResponse(r))}))},c.prototype.addSubscription=function(e,t){if(!this.provider.on)throw new Error("The provider doesn't support subscriptions: "+this.provider.constructor.name);this.subscriptions.set(e.id,{callback:t,subscription:e})},c.prototype.removeSubscription=function(e,t){if(this.subscriptions.has(e)){var r=this.subscriptions.get(e).subscription.options.type;return this.subscriptions.delete(e),void this.send({method:r+"_unsubscribe",params:[e]},t)}"function"==typeof t&&t(null)},c.prototype.clearSubscriptions=function(e){try{var t=this;return this.subscriptions.size>0&&this.subscriptions.forEach((function(r,n){e&&"syncing"===r.name||t.removeSubscription(n)})),this.provider.reset&&this.provider.reset(),!0}catch(e){throw new Error("Error while clearing subscriptions: ".concat(e))}},c.prototype._isCleanCloseEvent=function(e){return"object"===(0,n.default)(e)&&([1e3].includes(e.code)||!0===e.wasClean)},c.prototype._isIpcCloseError=function(e){return"boolean"==typeof e&&e},c.prototype._jsonrpcResultCallback=function(e,t){return function(r,n){return n&&n.id&&t.id!==n.id?e(new Error("Wrong response id ".concat(n.id," (expected: ").concat(t.id,") in ").concat(JSON.stringify(t)))):r?e(r):n&&n.error?e(o.ErrorResponse(n)):a.isValidResponse(n)?void e(null,n.result):e(o.InvalidResponse(n))}},e.exports={Manager:c,BatchManager:s}},8155:e=>{"use strict";var t={messageId:Math.floor(Math.random()*Number.MAX_SAFE_INTEGER),toPayload:function(e,r){if(!e)throw new Error('JSONRPC method should be specified for params: "'+JSON.stringify(r)+'"!');return t.messageId===Number.MAX_SAFE_INTEGER?t.messageId=Math.floor(Math.random()*Number.MAX_SAFE_INTEGER):t.messageId++,{jsonrpc:"2.0",id:t.messageId,method:e,params:r||[]}},isValidResponse:function(e){return Array.isArray(e)?e.every(t):t(e);function t(e){return!(!e||e.error||"2.0"!==e.jsonrpc||"number"!=typeof e.id&&"string"!=typeof e.id||void 0===e.result)}},toBatchPayload:function(e){return e.map((function(e){return t.toPayload(e.method,e.params)}))}};e.exports=t},4178:(e,t,r)=>{"use strict";var n=r(2929),i=function(e){this.name=e.name,this.type=e.type,this.subscriptions=e.subscriptions||{},this.requestManager=null};i.prototype.setRequestManager=function(e){this.requestManager=e},i.prototype.attachToObject=function(e){var t=this.buildCall(),r=this.name.split(".");r.length>1?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},i.prototype.buildCall=function(){var e=this;return function(){e.subscriptions[arguments[0]]||console.warn("Subscription "+JSON.stringify(arguments[0])+" doesn't exist. Subscribing anyway.");var t=new n({subscription:e.subscriptions[arguments[0]]||{},requestManager:e.requestManager,type:e.type});return t.subscribe.apply(t,arguments)}},e.exports={subscriptions:i,subscription:n}},2929:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1314).errors,o=r(8008),a=r(1314).formatters;function s(e){return e}function u(e){o.call(this),this.id=null,this.callback=s,this.arguments=null,this.lastBlock=null,this.options={subscription:e.subscription,type:e.type,requestManager:e.requestManager}}u.prototype=Object.create(o.prototype),u.prototype.constructor=u,u.prototype._extractCallback=function(e){if("function"==typeof e[e.length-1])return e.pop()},u.prototype._validateArgs=function(e){var t=this.options.subscription;if(t||(t={}),t.params||(t.params=0),e.length!==t.params)throw i.InvalidNumberOfParams(e.length,t.params,t.subscriptionName)},u.prototype._formatInput=function(e){var t=this.options.subscription;return t&&t.inputFormatter?t.inputFormatter.map((function(t,r){return t?t(e[r]):e[r]})):e},u.prototype._formatOutput=function(e){var t=this.options.subscription;return t&&t.outputFormatter&&e?t.outputFormatter(e):e},u.prototype._toPayload=function(e){var t=[];if(this.callback=this._extractCallback(e)||s,this.subscriptionMethod||(this.subscriptionMethod=e.shift(),this.options.subscription.subscriptionName&&(this.subscriptionMethod=this.options.subscription.subscriptionName)),this.arguments||(this.arguments=this._formatInput(e),this._validateArgs(this.arguments),e=[]),t.push(this.subscriptionMethod),t=t.concat(this.arguments),e.length)throw new Error("Only a callback is allowed as parameter on an already instantiated subscription.");return{method:this.options.type+"_subscribe",params:t}},u.prototype.unsubscribe=function(e){this.options.requestManager.removeSubscription(this.id,e),this.id=null,this.lastBlock=null,this.removeAllListeners()},u.prototype.subscribe=function(){var e=this,t=Array.prototype.slice.call(arguments),r=this._toPayload(t);if(!r)return this;if(!this.options.requestManager.provider)return setTimeout((function(){var t=new Error("No provider set.");e.callback(t,null,e),e.emit("error",t)}),0),this;if(!this.options.requestManager.provider.on)return setTimeout((function(){var t=new Error("The current provider doesn't support subscriptions: "+e.options.requestManager.provider.constructor.name);e.callback(t,null,e),e.emit("error",t)}),0),this;if(this.lastBlock&&this.options.params&&"object"===(0,n.default)(this.options.params)&&(r.params[1]=this.options.params,r.params[1].fromBlock=a.inputBlockNumberFormatter(this.lastBlock+1)),this.id&&this.unsubscribe(),this.options.params=r.params[1],"logs"===r.params[0]&&r.params[1]&&"object"===(0,n.default)(r.params[1])&&r.params[1].hasOwnProperty("fromBlock")&&isFinite(r.params[1].fromBlock)){var i=Object.assign({},r.params[1]);this.options.requestManager.send({method:"eth_getLogs",params:[i]},(function(t,r){t?setTimeout((function(){e.callback(t,null,e),e.emit("error",t)}),0):r.forEach((function(t){var r=e._formatOutput(t);e.callback(null,r,e),e.emit("data",r)}))}))}return"object"===(0,n.default)(r.params[1])&&delete r.params[1].fromBlock,this.options.requestManager.send(r,(function(t,i){!t&&i?(e.id=i,e.method=r.params[0],e.options.requestManager.addSubscription(e,(function(t,r){t?(e.callback(t,!1,e),e.emit("error",t)):(Array.isArray(r)||(r=[r]),r.forEach((function(t){var r=e._formatOutput(t);if(e.lastBlock=r&&"object"===(0,n.default)(r)?r.blockNumber:null,"function"==typeof e.options.subscription.subscriptionHandler)return e.options.subscription.subscriptionHandler.call(e,r);e.emit("data",r),e.callback(null,r,e)})))})),e.emit("connected",i)):setTimeout((function(){e.callback(t,!1,e),e.emit("error",t)}),0)})),this},u.prototype.resubscribe=function(){this.options.requestManager.removeSubscription(this.id),this.id=null,this.subscribe(this.callback)},e.exports=u},9907:(e,t,r)=>{"use strict";var n=r(1314).formatters,i=r(3349),o=r(8161);e.exports=function(e){var t=function(t){var r;return t.property?(e[t.property]||(e[t.property]={}),r=e[t.property]):r=e,t.methods&&t.methods.forEach((function(t){t instanceof i||(t=new i(t)),t.attachToObject(r),t.setRequestManager(e._requestManager)})),e};return t.formatters=n,t.utils=o,t.Method=i,t}},606:(e,t,r)=>{"use strict";var n=r(2033),i=r(9907);e.exports={packageInit:function(e,t){if(t=Array.prototype.slice.call(t),!e)throw new Error('You need to instantiate using the "new" keyword.');Object.defineProperty(e,"currentProvider",{get:function(){return e._provider},set:function(t){return e.setProvider(t)},enumerable:!0,configurable:!0}),t[0]&&t[0]._requestManager?e._requestManager=t[0]._requestManager:e._requestManager=new n.Manager(t[0],t[1]),e.givenProvider=n.Manager.givenProvider,e.providers=n.Manager.providers,e._provider=e._requestManager.provider,e.setProvider||(e.setProvider=function(t,r){return e._requestManager.setProvider(t,r),e._provider=e._requestManager.provider,!0}),e.setRequestManager=function(t){e._requestManager=t,e._provider=t.provider},e.BatchRequest=n.BatchManager.bind(null,e._requestManager),e.extend=i(e)},addProviders:function(e){e.givenProvider=n.Manager.givenProvider,e.providers=n.Manager.providers}}},9901:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(9033).Buffer,o=r(8161),a=r(2914).RQ,s=r(2914)._R,u=new a((function(e,t){return!e.match(/^u?int/)||Array.isArray(t)||t&&"object"===(0,n.default)(t)&&"BN"===t.constructor.name?t:t.toString()}));function c(){}var l=function(){};l.prototype.encodeFunctionSignature=function(e){return("function"==typeof e||"object"===(0,n.default)(e)&&e)&&(e=o._jsonInterfaceMethodToString(e)),o.sha3(e).slice(0,10)},l.prototype.encodeEventSignature=function(e){return("function"==typeof e||"object"===(0,n.default)(e)&&e)&&(e=o._jsonInterfaceMethodToString(e)),o.sha3(e)},l.prototype.encodeParameter=function(e,t){return this.encodeParameters([e],[t])},l.prototype.encodeParameters=function(e,t){var r=this;return e=r.mapTypes(e),t=t.map((function(t,i){var o=e[i];return"object"===(0,n.default)(o)&&o.type&&(o=o.type),t=r.formatParam(o,t),"string"==typeof o&&o.includes("tuple")&&function e(t,n){if("array"===t.name){if(!t.type.match(/\[(\d+)\]/))return n.map((function(r){return e(u._getCoder(s.from(t.type.replace("[]",""))),r)}));var i=parseInt(t.type.match(/\[(\d+)\]/)[1]);if(n.length!==i)throw new Error("Array length does not matches with the given input");return n.map((function(r){return e(u._getCoder(s.from(t.type.replace(/\[\d+\]/,""))),r)}))}t.coders.forEach((function(t,i){"tuple"===t.name?e(t,n[i]):n[i]=r.formatParam(t.name,n[i])}))}(u._getCoder(s.from(o)),t),t})),u.encode(e,t)},l.prototype.mapTypes=function(e){var t=this,r=[];return e.forEach((function(e){if("object"===(0,n.default)(e)&&"function"===e.type&&(e=Object.assign({},e,{type:"bytes24"})),t.isSimplifiedStructFormat(e)){var i=Object.keys(e)[0];r.push(Object.assign(t.mapStructNameAndType(i),{components:t.mapStructToCoderFormat(e[i])}))}else r.push(e)})),r},l.prototype.isSimplifiedStructFormat=function(e){return"object"===(0,n.default)(e)&&void 0===e.components&&void 0===e.name},l.prototype.mapStructNameAndType=function(e){var t="tuple";return e.indexOf("[]")>-1&&(t="tuple[]",e=e.slice(0,-2)),{type:t,name:e}},l.prototype.mapStructToCoderFormat=function(e){var t=this,r=[];return Object.keys(e).forEach((function(i){"object"!==(0,n.default)(e[i])?r.push({name:i,type:e[i]}):r.push(Object.assign(t.mapStructNameAndType(i),{components:t.mapStructToCoderFormat(e[i])}))})),r},l.prototype.formatParam=function(e,t){var r=this,n=new RegExp(/^bytes([0-9]*)$/),a=new RegExp(/^bytes([0-9]*)\[\]$/),s=new RegExp(/^(u?int)([0-9]*)$/),u=new RegExp(/^(u?int)([0-9]*)\[\]$/);if(o.isBN(t)||o.isBigNumber(t))return t.toString(10);if(e.match(a)||e.match(u))return t.map((function(t){return r.formatParam(e.replace("[]",""),t)}));var c=e.match(s);if(c){var l=parseInt(c[2]||"256");l/80&&(!t||"0x"===t||"0X"===t))throw new Error("Returned values aren't valid, did it run Out of Gas? You might also see this error if you are not using the correct ABI for the contract you are retrieving data from, requesting data from a block number that does not exist, or querying a node which is not fully synced.");var i=u.decode(this.mapTypes(e),"0x"+t.replace(/0x/i,""),r),o=new c;return o.__length__=0,e.forEach((function(e,t){var r=i[o.__length__],a="object"===(0,n.default)(e)&&e.type&&"string"===e.type;r="0x"!==r||a||"string"==typeof e&&"string"===e?r:null,o[t]=r,("function"==typeof e||e&&"object"===(0,n.default)(e))&&e.name&&(o[e.name]=r),o.__length__++})),o},l.prototype.decodeLog=function(e,t,r){var n=this;r=Array.isArray(r)?r:[r],t=t||"";var i=[],o=[],a=0;e.forEach((function(e,t){e.indexed?(o[t]=["bool","int","uint","address","fixed","ufixed"].find((function(t){return-1!==e.type.indexOf(t)}))?n.decodeParameter(e.type,r[a]):r[a],a++):i[t]=e}));var s=t,u=s?this.decodeParametersWith(i,s,!0):[],l=new c;return l.__length__=0,e.forEach((function(e,t){l[t]="string"===e.type?"":null,void 0!==u[t]&&(l[t]=u[t]),void 0!==o[t]&&(l[t]=o[t]),e.name&&(l[e.name]=l[t]),l.__length__++})),l};var f=new l;e.exports=f},9819:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(3106)),a=i(r(3355)),s=i(r(775)),u=i(r(4519));function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function l(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r0){var l,h="Signer Error: ",d=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return f(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?f(e,t):void 0}}(e))){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}(c);try{for(d.s();!(l=d.n()).done;){var p=l.value;h+="".concat(h," ").concat(p,".")}}catch(e){d.e(e)}finally{d.f()}throw new Error(h)}var m="0x"+u.serialize().toString("hex"),y=b.keccak256(m),g={messageHash:"0x"+n.from(u.getMessageToSign(!0)).toString("hex"),v:"0x"+u.v.toString("hex"),r:"0x"+u.r.toString("hex"),s:"0x"+u.s.toString("hex"),rawTransaction:m,transactionHash:y};return r(null,g),g}catch(e){return r(e),Promise.reject(e)}}return e.type=function(e){var t,r=void 0!==e.maxFeePerGas||void 0!==e.maxPriorityFeePerGas;if(void 0!==e.type?t=b.toHex(e.type):void 0===e.type&&r&&(t="0x2"),void 0!==e.gasPrice&&("0x2"===t||r))throw Error("eip-1559 transactions don't support gasPrice");if(("0x1"===t||"0x0"===t)&&r)throw Error("pre-eip-1559 transaction don't support maxFeePerGas/maxPriorityFeePerGas");return r||e.common&&e.common.hardfork&&e.common.hardfork.toLowerCase()===S.London||e.hardfork&&e.hardfork.toLowerCase()===S.London?t="0x2":(e.accessList||e.common&&e.common.hardfork&&e.common.hardfork.toLowerCase()===S.Berlin||e.hardfork&&e.hardfork.toLowerCase()===S.Berlin)&&(t="0x1"),t}(e),void 0!==e.nonce&&void 0!==e.chainId&&(void 0!==e.gasPrice||void 0!==e.maxFeePerGas&&void 0!==e.maxPriorityFeePerGas)&&s?Promise.resolve(c(e)):Promise.all([E(e.common)||E(e.common.customChain.chainId)?E(e.chainId)?i._ethereumCall.getChainId():e.chainId:void 0,E(e.nonce)?i._ethereumCall.getTransactionCount(i.privateKeyToAccount(t).address):e.nonce,E(s)?i._ethereumCall.getNetworkId():1,T(i,e)]).then((function(t){var r=(0,u.default)(t,4),n=r[0],i=r[1],o=r[2],a=r[3];if(E(n)&&E(e.common)&&E(e.common.customChain.chainId)||E(i)||E(o)||E(a))throw new Error('One of the values "chainId", "networkId", "gasPrice", or "nonce" couldn\'t be fetched: '+JSON.stringify(t));return c(l(l(l({},e),E(e.common)||E(e.common.customChain.chainId)?{chainId:n}:{}),{},{nonce:i,networkId:o},a))}))},M.prototype.recoverTransaction=function(e){var t=n.from(e.slice(2),"hex"),r=w.fromSerializedData(t);return b.toChecksumAddress(r.getSenderAddress().toString("hex"))},M.prototype.hashMessage=function(e){var t=b.isHexStrict(e)?e:b.utf8ToHex(e),r=b.hexToBytes(t),i=n.from(r),o="Ethereum Signed Message:\n"+r.length,a=n.from(o),s=n.concat([a,i]);return k.bufferToHex(k.keccak256(s))},M.prototype.sign=function(e,t){if(t.startsWith("0x")||(t="0x"+t),66!==t.length)throw new Error("Private key must be 32 bytes long");var r=this.hashMessage(e),n=p.sign(r,t),i=p.decodeSignature(n);return{message:e,messageHash:r,v:i[0],r:i[1],s:i[2],signature:n}},M.prototype.recover=function(e,t,r){var n=[].slice.apply(arguments);return e&&"object"===(0,a.default)(e)?this.recover(e.messageHash,p.encodeSignature([e.v,e.r,e.s]),!0):(r||(e=this.hashMessage(e)),n.length>=4?(r="boolean"==typeof(r=n.slice(-1)[0])&&!!r,this.recover(e,p.encodeSignature(n.slice(1,4)),r)):p.recover(e,t))},M.prototype.decrypt=function(e,t,r){if("string"!=typeof t)throw new Error("No password given.");var i,s,u=e&&"object"===(0,a.default)(e)?e:JSON.parse(r?e.toLowerCase():e);if(3!==u.version)throw new Error("Not a valid V3 wallet");if("scrypt"===u.crypto.kdf)s=u.crypto.kdfparams,i=y.syncScrypt(n.from(t),n.from(s.salt,"hex"),s.n,s.r,s.p,s.dklen);else{if("pbkdf2"!==u.crypto.kdf)throw new Error("Unsupported key derivation scheme");if("hmac-sha256"!==(s=u.crypto.kdfparams).prf)throw new Error("Unsupported parameters to PBKDF2");i=m.pbkdf2Sync(n.from(t),n.from(s.salt,"hex"),s.c,s.dklen,"sha256")}var c=n.from(u.crypto.ciphertext,"hex");if(b.sha3(n.from([].concat((0,o.default)(i.slice(16,32)),(0,o.default)(c)))).replace("0x","")!==u.crypto.mac)throw new Error("Key derivation failed - possibly wrong password");var l=m.createDecipheriv(u.crypto.cipher,i.slice(0,16),n.from(u.crypto.cipherparams.iv,"hex")),f="0x"+n.from([].concat((0,o.default)(l.update(c)),(0,o.default)(l.final()))).toString("hex");return this.privateKeyToAccount(f,!0)},M.prototype.encrypt=function(e,t,r){var i,a=this.privateKeyToAccount(e,!0),s=(r=r||{}).salt||m.randomBytes(32),u=r.iv||m.randomBytes(16),c=r.kdf||"scrypt",l={dklen:r.dklen||32,salt:s.toString("hex")};if("pbkdf2"===c)l.c=r.c||262144,l.prf="hmac-sha256",i=m.pbkdf2Sync(n.from(t),n.from(l.salt,"hex"),l.c,l.dklen,"sha256");else{if("scrypt"!==c)throw new Error("Unsupported kdf");l.n=r.n||8192,l.r=r.r||8,l.p=r.p||1,i=y.syncScrypt(n.from(t),n.from(l.salt,"hex"),l.n,l.r,l.p,l.dklen)}var f=m.createCipheriv(r.cipher||"aes-128-ctr",i.slice(0,16),u);if(!f)throw new Error("Unsupported cipher");var h=n.from([].concat((0,o.default)(f.update(n.from(a.privateKey.replace("0x",""),"hex"))),(0,o.default)(f.final()))),d=b.sha3(n.from([].concat((0,o.default)(i.slice(16,32)),(0,o.default)(h)))).replace("0x","");return{version:3,id:g.v4({random:r.uuid||m.randomBytes(16)}),address:a.address.toLowerCase().replace("0x",""),crypto:{ciphertext:h.toString("hex"),cipherparams:{iv:u.toString("hex")},cipher:r.cipher||"aes-128-ctr",kdf:c,kdfparams:l,mac:d.toString("hex")}}},x.prototype._findSafeIndex=function(e){return e=e||0,this.hasOwnProperty(e)?this._findSafeIndex(e+1):e},x.prototype._currentIndexes=function(){return Object.keys(this).map((function(e){return parseInt(e)})).filter((function(e){return e<9e20}))},x.prototype.create=function(e,t){for(var r=0;r{"use strict";var n=r(8847),i=n(r(775)),o=n(r(3355));function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t0&&e.topics.length!==n+1&&(t={anonymous:!0,inputs:[]})}var i=t.anonymous?e.topics:e.topics.slice(1);return r.returnValues=m.decodeLog(t.inputs,e.data,i),delete r.returnValues.__length__,r.event=t.name,r.signature=t.anonymous||!e.topics[0]?null:e.topics[0],r.raw={data:r.data,topics:r.topics},delete r.data,delete r.topics,r},y.prototype._encodeMethodABI=function(){var e=this._method.signature,t=this.arguments||[],r=!1,n=this._parent.options.jsonInterface.filter((function(t){return"constructor"===e&&t.type===e||(t.signature===e||t.signature===e.replace("0x","")||t.name===e)&&"function"===t.type})).map((function(e){var n=Array.isArray(e.inputs)?e.inputs.length:0;if(n!==t.length)throw new Error("The number of arguments is not matching the methods required number. You need to pass "+n+" arguments.");return"function"===e.type&&(r=e.signature),Array.isArray(e.inputs)?e.inputs:[]})).map((function(e){return m.encodeParameters(e,t).replace("0x","")}))[0]||"";if("constructor"===e){if(!this._deployData)throw new Error("The contract has no contract data option set. This is necessary to append the constructor parameters.");return this._deployData.startsWith("0x")||(this._deployData="0x"+this._deployData),this._deployData+n}var i=r?r+n:n;if(!i)throw new Error("Couldn't find a matching contract method named \""+this._method.name+'".');return i},y.prototype._decodeMethodReturn=function(e,t){if(!t)return null;t=t.length>=2?t.slice(2):t;var r=m.decodeParameters(e,t);return 1===r.__length__?r[0]:(delete r.__length__,r)},y.prototype.deploy=function(e,t){if((e=e||{}).arguments=e.arguments||[],!(e=this._getOrSetDefaultOptions(e)).data){if("function"==typeof t)return t(d.ContractMissingDeployDataError());throw d.ContractMissingDeployDataError()}var r=this.options.jsonInterface.find((function(e){return"constructor"===e.type}))||{};return r.signature="constructor",this._createTxObject.apply({method:r,parent:this,deployData:e.data,_ethAccounts:this.constructor._ethAccounts},e.arguments)},y.prototype._generateEventOptions=function(){var e=Array.prototype.slice.call(arguments),t=this._getCallback(e),r="object"===(!!e[e.length-1]&&(0,o.default)(e[e.length-1]))?e.pop():{},n="string"==typeof e[0]?e[0]:"allevents",i="allevents"===n.toLowerCase()?{name:"ALLEVENTS",jsonInterface:this.options.jsonInterface}:this.options.jsonInterface.find((function(e){return"event"===e.type&&(e.name===n||e.signature==="0x"+n.replace("0x",""))}));if(!i)throw d.ContractEventDoesNotExistError(n);if(!l.isAddress(this.options.address))throw d.ContractNoAddressDefinedError();return{params:this._encodeEventABI(i,r),event:i,callback:t}},y.prototype.clone=function(){return new this.constructor(this.options.jsonInterface,this.options.address,this.options)},y.prototype.once=function(e,t,r){var n=Array.prototype.slice.call(arguments);if(!(r=this._getCallback(n)))throw d.ContractOnceRequiresCallbackError();t&&delete t.fromBlock,this._on(e,t,(function(e,t,n){n.unsubscribe(),"function"==typeof r&&r(e,t,n)}))},y.prototype._on=function(){var e=this._generateEventOptions.apply(this,arguments);e.params&&e.params.toBlock&&(delete e.params.toBlock,console.warn("Invalid option: toBlock. Use getPastEvents for specific range.")),this._checkListener("newListener",e.event.name),this._checkListener("removeListener",e.event.name);var t=new f({subscription:{params:1,inputFormatter:[h.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event),subscriptionHandler:function(e){e.removed?this.emit("changed",e):this.emit("data",e),"function"==typeof this.callback&&this.callback(null,e,this)}},type:"eth",requestManager:this._requestManager});return t.subscribe("logs",e.params,e.callback||function(){}),t},y.prototype.getPastEvents=function(){var e=this._generateEventOptions.apply(this,arguments),t=new c({name:"getPastLogs",call:"eth_getLogs",params:1,inputFormatter:[h.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event)});t.setRequestManager(this._requestManager);var r=t.buildCall();return t=null,r(e.params,e.callback)},y.prototype._createTxObject=function(){var e=Array.prototype.slice.call(arguments),t={};if("function"===this.method.type&&(t.call=this.parent._executeMethod.bind(t,"call"),t.call.request=this.parent._executeMethod.bind(t,"call",!0)),t.send=this.parent._executeMethod.bind(t,"send"),t.send.request=this.parent._executeMethod.bind(t,"send",!0),t.encodeABI=this.parent._encodeMethodABI.bind(t),t.estimateGas=this.parent._executeMethod.bind(t,"estimate"),t.createAccessList=this.parent._executeMethod.bind(t,"createAccessList"),e&&this.method.inputs&&e.length!==this.method.inputs.length){if(this.nextMethod)return this.nextMethod.apply(null,e);throw d.InvalidNumberOfParams(e.length,this.method.inputs.length,this.method.name)}return t.arguments=e||[],t._method=this.method,t._parent=this.parent,t._ethAccounts=this.parent.constructor._ethAccounts||this._ethAccounts,this.deployData&&(t._deployData=this.deployData),t},y.prototype._processExecuteArguments=function(e,t){var r={};if(r.type=e.shift(),r.callback=this._parent._getCallback(e),"call"!==r.type||!0===e[e.length-1]||"string"!=typeof e[e.length-1]&&!isFinite(e[e.length-1])||(r.defaultBlock=e.pop()),r.options="object"===(!!e[e.length-1]&&(0,o.default)(e[e.length-1]))?e.pop():{},r.generateRequest=!0===e[e.length-1]&&e.pop(),r.options=this._parent._getOrSetDefaultOptions(r.options),r.options.data=this.encodeABI(),!this._deployData&&!l.isAddress(this._parent.options.address))throw d.ContractNoAddressDefinedError();return this._deployData||(r.options.to=this._parent.options.address),r.options.data?r:l._fireError(new Error("Couldn't find a matching contract method, or the number of parameters is wrong."),t.eventEmitter,t.reject,r.callback)},y.prototype._executeMethod=function(){var e=this,t=this._parent._processExecuteArguments.call(this,Array.prototype.slice.call(arguments),r),r=p("send"!==t.type),n=e.constructor._ethAccounts||e._ethAccounts;if(t.generateRequest){var i={params:[h.inputCallFormatter.call(this._parent,t.options)],callback:t.callback};return"call"===t.type?(i.params.push(h.inputDefaultBlockNumberFormatter.call(this._parent,t.defaultBlock)),i.method="eth_call",i.format=this._parent._decodeMethodReturn.bind(null,this._method.outputs)):i.method="eth_sendTransaction",i}switch(t.type){case"createAccessList":if(!l.isAddress(t.options.from))return l._fireError(d.ContractNoFromAddressDefinedError(),r.eventEmitter,r.reject,t.callback);var o=new c({name:"createAccessList",call:"eth_createAccessList",params:2,inputFormatter:[h.inputTransactionFormatter,h.inputDefaultBlockNumberFormatter],requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock}).createFunction();return o(t.options,t.callback);case"estimate":var a=new c({name:"estimateGas",call:"eth_estimateGas",params:1,inputFormatter:[h.inputCallFormatter],outputFormatter:l.hexToNumber,requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock}).createFunction();return a(t.options,t.callback);case"call":var s=new c({name:"call",call:"eth_call",params:2,inputFormatter:[h.inputCallFormatter,h.inputDefaultBlockNumberFormatter],outputFormatter:function(t){return e._parent._decodeMethodReturn(e._method.outputs,t)},requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock,handleRevert:e._parent.handleRevert,abiCoder:m}).createFunction();return s(t.options,t.defaultBlock,t.callback);case"send":if(!l.isAddress(t.options.from))return l._fireError(d.ContractNoFromAddressDefinedError(),r.eventEmitter,r.reject,t.callback);if("boolean"==typeof this._method.payable&&!this._method.payable&&t.options.value&&t.options.value>0)return l._fireError(new Error("Can not send value to non-payable contract method or constructor"),r.eventEmitter,r.reject,t.callback);var u={receiptFormatter:function(t){if(Array.isArray(t.logs)){var r=t.logs.map((function(t){return e._parent._decodeEventABI.call({name:"ALLEVENTS",jsonInterface:e._parent.options.jsonInterface},t)}));t.events={};var n=0;r.forEach((function(e){e.event?t.events[e.event]?Array.isArray(t.events[e.event])?t.events[e.event].push(e):t.events[e.event]=[t.events[e.event],e]:t.events[e.event]=e:(t.events[n]=e,n++)})),delete t.logs}return t},contractDeployFormatter:function(t){var r=e._parent.clone();return r.options.address=t.contractAddress,r}},f=new c({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[h.inputTransactionFormatter],requestManager:e._parent._requestManager,accounts:e.constructor._ethAccounts||e._ethAccounts,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock,transactionBlockTimeout:e._parent.transactionBlockTimeout,transactionConfirmationBlocks:e._parent.transactionConfirmationBlocks,transactionPollingTimeout:e._parent.transactionPollingTimeout,transactionPollingInterval:e._parent.transactionPollingInterval,defaultCommon:e._parent.defaultCommon,defaultChain:e._parent.defaultChain,defaultHardfork:e._parent.defaultHardfork,handleRevert:e._parent.handleRevert,extraFormatters:u,abiCoder:m}).createFunction();return f(t.options,t.callback);default:throw new Error('Method "'+t.type+'" not implemented.')}},e.exports=y},6764:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(2247)),o=n(r(5698)),a=r(5160),s=r(1314).formatters,u=r(8161),c=r(1841),l=r(2867),f=r(2689);function h(e){this.eth=e;var t=null;this._detectedAddress=null,this._lastSyncCheck=null,Object.defineProperty(this,"registry",{get:function(){return new c(this)},enumerable:!0}),Object.defineProperty(this,"resolverMethodHandler",{get:function(){return new l(this.registry)},enumerable:!0}),Object.defineProperty(this,"registryAddress",{get:function(){return t},set:function(e){t=null!==e?s.inputAddressFormatter(e):e},enumerable:!0})}h.prototype.supportsInterface=function(e,t,r){return this.getResolver(e).then((function(e){return u.isHexStrict(t)||(t=u.sha3(t).slice(0,10)),e.methods.supportsInterface(t).call(r)})).catch((function(e){if("function"!=typeof r)throw e;r(e,null)}))},h.prototype.resolver=function(e,t){return this.registry.resolver(e,t)},h.prototype.getResolver=function(e,t){return this.registry.getResolver(e,t)},h.prototype.setResolver=function(e,t,r,n){return this.registry.setResolver(e,t,r,n)},h.prototype.setRecord=function(e,t,r,n,i,o){return this.registry.setRecord(e,t,r,n,i,o)},h.prototype.setSubnodeRecord=function(e,t,r,n,i,o,a){return this.registry.setSubnodeRecord(e,t,r,n,i,o,a)},h.prototype.setApprovalForAll=function(e,t,r,n){return this.registry.setApprovalForAll(e,t,r,n)},h.prototype.isApprovedForAll=function(e,t,r){return this.registry.isApprovedForAll(e,t,r)},h.prototype.recordExists=function(e,t){return this.registry.recordExists(e,t)},h.prototype.setSubnodeOwner=function(e,t,r,n,i){return this.registry.setSubnodeOwner(e,t,r,n,i)},h.prototype.getTTL=function(e,t){return this.registry.getTTL(e,t)},h.prototype.setTTL=function(e,t,r,n){return this.registry.setTTL(e,t,r,n)},h.prototype.getOwner=function(e,t){return this.registry.getOwner(e,t)},h.prototype.setOwner=function(e,t,r,n){return this.registry.setOwner(e,t,r,n)},h.prototype.getAddress=function(e,t){return this.resolverMethodHandler.method(e,"addr",[]).call(t)},h.prototype.setAddress=function(e,t,r,n){return this.resolverMethodHandler.method(e,"setAddr",[t]).send(r,n)},h.prototype.getPubkey=function(e,t){return this.resolverMethodHandler.method(e,"pubkey",[],null,t).call(t)},h.prototype.setPubkey=function(e,t,r,n,i){return this.resolverMethodHandler.method(e,"setPubkey",[t,r]).send(n,i)},h.prototype.getContent=function(e,t){return this.resolverMethodHandler.method(e,"content",[]).call(t)},h.prototype.setContent=function(e,t,r,n){return this.resolverMethodHandler.method(e,"setContent",[t]).send(r,n)},h.prototype.getContenthash=function(e,t){return this.resolverMethodHandler.method(e,"contenthash",[],f.decode).call(t)},h.prototype.setContenthash=function(e,t,r,n){var i;try{i=f.encode(t)}catch(e){var o=new Error("Could not encode "+t+". See docs for supported hash protocols.");if("function"==typeof n)return void n(o,null);throw o}return this.resolverMethodHandler.method(e,"setContenthash",[i]).send(r,n)},h.prototype.getMultihash=function(e,t){return this.resolverMethodHandler.method(e,"multihash",[]).call(t)},h.prototype.setMultihash=function(e,t,r,n){return this.resolverMethodHandler.method(e,"multihash",[t]).send(r,n)},h.prototype.checkNetwork=(0,o.default)(i.default.mark((function e(){var t,r,n,o,s;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=new Date/1e3,this._lastSyncCheck&&!(t-this._lastSyncCheck>3600)){e.next=9;break}return e.next=4,this.eth.getBlock("latest");case 4:if(r=e.sent,!((n=t-r.timestamp)>3600)){e.next=8;break}throw new Error("Network not synced; last block was "+n+" seconds ago");case 8:this._lastSyncCheck=t;case 9:if(!this.registryAddress){e.next=11;break}return e.abrupt("return",this.registryAddress);case 11:if(this._detectedAddress){e.next=20;break}return e.next=14,this.eth.net.getNetworkType();case 14:if(o=e.sent,void 0!==(s=a.addresses[o])){e.next=18;break}throw new Error("ENS is not supported on network "+o);case 18:return this._detectedAddress=s,e.abrupt("return",this._detectedAddress);case 20:return e.abrupt("return",this._detectedAddress);case 21:case"end":return e.stop()}}),e,this)}))),e.exports=h},5160:e=>{"use strict";e.exports={addresses:{main:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",ropsten:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",rinkeby:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",goerli:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},interfaceIds:{addr:"0x3b3b57de",setAddr:"0x3b3b57de",pubkey:"0xc8690233",setPubkey:"0xc8690233",contenthash:"0xbc1c58d1",setContenthash:"0xbc1c58d1",content:"0xd8389dc5",setContent:"0xd8389dc5"}}},1841:(e,t,r)=>{"use strict";var n=r(8164),i=r(1006),o=r(282),a=r(1314).formatters,s=r(8161),u=r(3205),c=r(8384);function l(e){var t=this;this.ens=e,this.contract=e.checkNetwork().then((function(e){var r=new n(u,e);return r.setProvider(t.ens.eth.currentProvider),r}))}l.prototype.owner=function(e,t){return console.warn('Deprecated: Please use the "getOwner" method instead of "owner".'),this.getOwner(e,t)},l.prototype.getOwner=function(e,t){var r=new o(!0);return this.contract.then((function(t){return t.methods.owner(i.hash(e)).call()})).then((function(e){"function"!=typeof t?r.resolve(e):t(e,e)})).catch((function(e){"function"!=typeof t?r.reject(e):t(e,null)})),r.eventEmitter},l.prototype.setOwner=function(e,t,r,n){var s=new o(!0);return this.contract.then((function(n){return n.methods.setOwner(i.hash(e),a.inputAddressFormatter(t)).send(r)})).then((function(e){"function"!=typeof n?s.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?s.reject(e):n(e,null)})),s.eventEmitter},l.prototype.getTTL=function(e,t){var r=new o(!0);return this.contract.then((function(t){return t.methods.ttl(i.hash(e)).call()})).then((function(e){"function"!=typeof t?r.resolve(e):t(e,e)})).catch((function(e){"function"!=typeof t?r.reject(e):t(e,null)})),r.eventEmitter},l.prototype.setTTL=function(e,t,r,n){var a=new o(!0);return this.contract.then((function(n){return n.methods.setTTL(i.hash(e),t).send(r)})).then((function(e){"function"!=typeof n?a.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?a.reject(e):n(e,null)})),a.eventEmitter},l.prototype.setSubnodeOwner=function(e,t,r,n,u){var c=new o(!0);return s.isHexStrict(t)||(t=s.sha3(t)),this.contract.then((function(o){return o.methods.setSubnodeOwner(i.hash(e),t,a.inputAddressFormatter(r)).send(n)})).then((function(e){"function"!=typeof u?c.resolve(e):u(e,e)})).catch((function(e){"function"!=typeof u?c.reject(e):u(e,null)})),c.eventEmitter},l.prototype.setRecord=function(e,t,r,n,s,u){var c=new o(!0);return this.contract.then((function(o){return o.methods.setRecord(i.hash(e),a.inputAddressFormatter(t),a.inputAddressFormatter(r),n).send(s)})).then((function(e){"function"!=typeof u?c.resolve(e):u(e,e)})).catch((function(e){"function"!=typeof u?c.reject(e):u(e,null)})),c.eventEmitter},l.prototype.setSubnodeRecord=function(e,t,r,n,u,c,l){var f=new o(!0);return s.isHexStrict(t)||(t=s.sha3(t)),this.contract.then((function(o){return o.methods.setSubnodeRecord(i.hash(e),t,a.inputAddressFormatter(r),a.inputAddressFormatter(n),u).send(c)})).then((function(e){"function"!=typeof l?f.resolve(e):l(e,e)})).catch((function(e){"function"!=typeof l?f.reject(e):l(e,null)})),f.eventEmitter},l.prototype.setApprovalForAll=function(e,t,r,n){var i=new o(!0);return this.contract.then((function(n){return n.methods.setApprovalForAll(a.inputAddressFormatter(e),t).send(r)})).then((function(e){"function"!=typeof n?i.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?i.reject(e):n(e,null)})),i.eventEmitter},l.prototype.isApprovedForAll=function(e,t,r){var n=new o(!0);return this.contract.then((function(r){return r.methods.isApprovedForAll(a.inputAddressFormatter(e),a.inputAddressFormatter(t)).call()})).then((function(e){"function"!=typeof r?n.resolve(e):r(e,e)})).catch((function(e){"function"!=typeof r?n.reject(e):r(e,null)})),n.eventEmitter},l.prototype.recordExists=function(e,t){var r=new o(!0);return this.contract.then((function(t){return t.methods.recordExists(i.hash(e)).call()})).then((function(e){"function"!=typeof t?r.resolve(e):t(e,e)})).catch((function(e){"function"!=typeof t?r.reject(e):t(e,null)})),r.eventEmitter},l.prototype.resolver=function(e,t){return console.warn('Deprecated: Please use the "getResolver" method instead of "resolver".'),this.getResolver(e,t)},l.prototype.getResolver=function(e,t){var r=this;return this.contract.then((function(t){return t.methods.resolver(i.hash(e)).call()})).then((function(e){var i=new n(c,e);if(i.setProvider(r.ens.eth.currentProvider),"function"!=typeof t)return i;t(i,i)})).catch((function(e){if("function"!=typeof t)throw e;t(e,null)}))},l.prototype.setResolver=function(e,t,r,n){var s=new o(!0);return this.contract.then((function(n){return n.methods.setResolver(i.hash(e),a.inputAddressFormatter(t)).send(r)})).then((function(e){"function"!=typeof n?s.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?s.reject(e):n(e,null)})),s.eventEmitter},e.exports=l},715:(e,t,r)=>{"use strict";var n=r(6764);e.exports=n},2867:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(2247)),o=n(r(5698)),a=r(282),s=r(1006),u=r(1314).errors,c=r(5160).interfaceIds;function l(e){this.registry=e}l.prototype.method=function(e,t,r,n,i){return{call:this.call.bind({ensName:e,methodName:t,methodArguments:r,callback:i,parent:this,outputFormatter:n}),send:this.send.bind({ensName:e,methodName:t,methodArguments:r,callback:i,parent:this})}},l.prototype.call=function(e){var t=this,r=new a,n=this.parent.prepareArguments(this.ensName,this.methodArguments),s=this.outputFormatter||null;return this.parent.registry.getResolver(this.ensName).then(function(){var a=(0,o.default)(i.default.mark((function o(a){return i.default.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,t.parent.checkInterfaceSupport(a,t.methodName);case 2:t.parent.handleCall(r,a.methods[t.methodName],n,s,e);case 3:case"end":return i.stop()}}),o)})));return function(e){return a.apply(this,arguments)}}()).catch((function(t){"function"!=typeof e?r.reject(t):e(t,null)})),r.eventEmitter},l.prototype.send=function(e,t){var r=this,n=new a,s=this.parent.prepareArguments(this.ensName,this.methodArguments);return this.parent.registry.getResolver(this.ensName).then(function(){var a=(0,o.default)(i.default.mark((function o(a){return i.default.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,r.parent.checkInterfaceSupport(a,r.methodName);case 2:r.parent.handleSend(n,a.methods[r.methodName],s,e,t);case 3:case"end":return i.stop()}}),o)})));return function(e){return a.apply(this,arguments)}}()).catch((function(e){"function"!=typeof t?n.reject(e):t(e,null)})),n.eventEmitter},l.prototype.handleCall=function(e,t,r,n,i){return t.apply(this,r).call().then((function(t){n&&(t=n(t)),"function"!=typeof i?e.resolve(t):i(t,t)})).catch((function(t){"function"!=typeof i?e.reject(t):i(t,null)})),e},l.prototype.handleSend=function(e,t,r,n,i){return t.apply(this,r).send(n).on("sending",(function(){e.eventEmitter.emit("sending")})).on("sent",(function(){e.eventEmitter.emit("sent")})).on("transactionHash",(function(t){e.eventEmitter.emit("transactionHash",t)})).on("confirmation",(function(t,r){e.eventEmitter.emit("confirmation",t,r)})).on("receipt",(function(t){e.eventEmitter.emit("receipt",t),e.resolve(t),"function"==typeof i&&i(t,t)})).on("error",(function(t){e.eventEmitter.emit("error",t),"function"!=typeof i?e.reject(t):i(t,null)})),e},l.prototype.prepareArguments=function(e,t){var r=s.hash(e);return t.length>0?(t.unshift(r),t):[r]},l.prototype.checkInterfaceSupport=function(){var e=(0,o.default)(i.default.mark((function e(t,r){var n;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(c[r]){e.next=2;break}return e.abrupt("return");case 2:return n=!1,e.prev=3,e.next=6,t.methods.supportsInterface(c[r]).call();case 6:n=e.sent,e.next=12;break;case 9:e.prev=9,e.t0=e.catch(3),console.warn('Could not verify interface of resolver contract at "'+t.options.address+'". ');case 12:if(n){e.next=14;break}throw u.ResolverMethodMissingError(t.options.address,r);case 14:case"end":return e.stop()}}),e,null,[[3,9]])})));return function(t,r){return e.apply(this,arguments)}}(),e.exports=l},2689:(e,t,r)=>{"use strict";var n=r(4308);e.exports={decode:function(e){var t=null,r=null,i=null;if(e&&e.error)return{protocolType:null,decoded:e.error};if(e)try{t=n.decode(e);var o=n.getCodec(e);"ipfs-ns"===o?r="ipfs":"swarm-ns"===o?r="bzz":"onion"===o?r="onion":"onion3"===o?r="onion3":t=e}catch(e){i=e.message}return{protocolType:r,decoded:t,error:i}},encode:function(e){var t,r,i=!1;if(e){var o=e.match(/^(ipfs|bzz|onion|onion3):\/\/(.*)/)||e.match(/\/(ipfs)\/(.*)/);o&&(r=o[1],t=o[2]);try{if("ipfs"===r)t.length>=4&&(i="0x"+n.fromIpfs(t));else if("bzz"===r)t.length>=4&&(i="0x"+n.fromSwarm(t));else if("onion"===r)16===t.length&&(i="0x"+n.encode("onion",t));else{if("onion3"!==r)throw new Error("Could not encode content hash: unsupported content type");56===t.length&&(i="0x"+n.encode("onion3",t))}}catch(e){throw e}}return i}}},3205:e=>{"use strict";e.exports=[{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"resolver",outputs:[{name:"",type:"address"}],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"owner",outputs:[{name:"",type:"address"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"label",type:"bytes32"},{name:"owner",type:"address"}],name:"setSubnodeOwner",outputs:[],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"ttl",type:"uint64"}],name:"setTTL",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"ttl",outputs:[{name:"",type:"uint64"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"resolver",type:"address"}],name:"setResolver",outputs:[],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"owner",type:"address"}],name:"setOwner",outputs:[],payable:!1,type:"function"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"owner",type:"address"}],name:"Transfer",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!0,name:"label",type:"bytes32"},{indexed:!1,name:"owner",type:"address"}],name:"NewOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"resolver",type:"address"}],name:"NewResolver",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"ttl",type:"uint64"}],name:"NewTTL",type:"event"},{constant:!1,inputs:[{internalType:"bytes32",name:"node",type:"bytes32"},{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"resolver",type:"address"},{internalType:"uint64",name:"ttl",type:"uint64"}],name:"setRecord",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!1,inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{constant:!0,inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{internalType:"bytes32",name:"node",type:"bytes32"}],name:"recordExists",outputs:[{internalType:"bool",name:"",type:"bool"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{internalType:"bytes32",name:"node",type:"bytes32"},{internalType:"bytes32",name:"label",type:"bytes32"},{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"resolver",type:"address"},{internalType:"uint64",name:"ttl",type:"uint64"}],name:"setSubnodeRecord",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"}]},8384:e=>{"use strict";e.exports=[{constant:!0,inputs:[{name:"interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{name:"",type:"bool"}],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"},{name:"contentTypes",type:"uint256"}],name:"ABI",outputs:[{name:"contentType",type:"uint256"},{name:"data",type:"bytes"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"hash",type:"bytes"}],name:"setMultihash",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"multihash",outputs:[{name:"",type:"bytes"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"x",type:"bytes32"},{name:"y",type:"bytes32"}],name:"setPubkey",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"content",outputs:[{name:"ret",type:"bytes32"}],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"addr",outputs:[{name:"ret",type:"address"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"contentType",type:"uint256"},{name:"data",type:"bytes"}],name:"setABI",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"name",outputs:[{name:"ret",type:"string"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"name",type:"string"}],name:"setName",outputs:[],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"hash",type:"bytes32"}],name:"setContent",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"pubkey",outputs:[{name:"x",type:"bytes32"},{name:"y",type:"bytes32"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"addr",type:"address"}],name:"setAddr",outputs:[],payable:!1,type:"function"},{inputs:[{name:"ensAddr",type:"address"}],payable:!1,type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"a",type:"address"}],name:"AddrChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"hash",type:"bytes32"}],name:"ContentChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"name",type:"string"}],name:"NameChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!0,name:"contentType",type:"uint256"}],name:"ABIChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"x",type:"bytes32"},{indexed:!1,name:"y",type:"bytes32"}],name:"PubkeyChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"hash",type:"bytes"}],name:"ContenthashChanged",type:"event"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"contenthash",outputs:[{name:"",type:"bytes"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"hash",type:"bytes"}],name:"setContenthash",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"}]},6:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=r(8161),s=r(1734),u=function(e){var t="A".charCodeAt(0),r="Z".charCodeAt(0);return(e=(e=e.toUpperCase()).slice(4)+e.slice(0,4)).split("").map((function(e){var n=e.charCodeAt(0);return n>=t&&n<=r?n-t+10:e})).join("")},c=function(e){for(var t,r=e;r.length>2;)t=r.slice(0,9),r=parseInt(t,10)%97+r.slice(t.length);return parseInt(r,10)%97},l=function(){function e(t){(0,i.default)(this,e),this._iban=t}return(0,o.default)(e,[{key:"isValid",value:function(){return/^XE[0-9]{2}(ETH[0-9A-Z]{13}|[0-9A-Z]{30,31})$/.test(this._iban)&&1===c(u(this._iban))}},{key:"isDirect",value:function(){return 34===this._iban.length||35===this._iban.length}},{key:"isIndirect",value:function(){return 20===this._iban.length}},{key:"checksum",value:function(){return this._iban.slice(2,4)}},{key:"institution",value:function(){return this.isIndirect()?this._iban.slice(7,11):""}},{key:"client",value:function(){return this.isIndirect()?this._iban.slice(11):""}},{key:"toAddress",value:function(){if(this.isDirect()){var e=this._iban.slice(4),t=new s(e,36);return a.toChecksumAddress(t.toString(16,20))}return""}},{key:"toString",value:function(){return this._iban}}],[{key:"toAddress",value:function(t){if(!(t=new e(t)).isDirect())throw new Error("IBAN is indirect and can't be converted");return t.toAddress()}},{key:"toIban",value:function(t){return e.fromAddress(t).toString()}},{key:"fromAddress",value:function(t){if(!a.isAddress(t))throw new Error("Provided address is not a valid address: "+t);t=t.replace("0x","").replace("0X","");var r=function(e,t){for(var r=e;r.length<30;)r="0"+r;return r}(new s(t,16).toString(36));return e.fromBban(r.toUpperCase())}},{key:"fromBban",value:function(t){return new e("XE"+("0"+(98-c(u("XE00"+t)))).slice(-2)+t)}},{key:"createIndirect",value:function(t){return e.fromBban("ETH"+t.institution+t.identifier)}},{key:"isValid",value:function(t){return new e(t).isValid()}}]),e}();e.exports=l},6306:(e,t,r)=>{"use strict";var n=r(606),i=r(3349),o=r(8161),a=r(473),s=r(1314).formatters,u=function(){var e=this;n.packageInit(this,arguments),this.net=new a(this);var t=null,r="latest";Object.defineProperty(this,"defaultAccount",{get:function(){return t},set:function(e){return e&&(t=o.toChecksumAddress(s.inputAddressFormatter(e))),u.forEach((function(e){e.defaultAccount=t})),e},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return r},set:function(e){return r=e,u.forEach((function(e){e.defaultBlock=r})),e},enumerable:!0});var u=[new i({name:"getAccounts",call:"personal_listAccounts",params:0,outputFormatter:o.toChecksumAddress}),new i({name:"newAccount",call:"personal_newAccount",params:1,inputFormatter:[null],outputFormatter:o.toChecksumAddress}),new i({name:"unlockAccount",call:"personal_unlockAccount",params:3,inputFormatter:[s.inputAddressFormatter,null,null]}),new i({name:"lockAccount",call:"personal_lockAccount",params:1,inputFormatter:[s.inputAddressFormatter]}),new i({name:"importRawKey",call:"personal_importRawKey",params:2}),new i({name:"sendTransaction",call:"personal_sendTransaction",params:2,inputFormatter:[s.inputTransactionFormatter,null]}),new i({name:"signTransaction",call:"personal_signTransaction",params:2,inputFormatter:[s.inputTransactionFormatter,null]}),new i({name:"sign",call:"personal_sign",params:3,inputFormatter:[s.inputSignFormatter,s.inputAddressFormatter,null]}),new i({name:"ecRecover",call:"personal_ecRecover",params:2,inputFormatter:[s.inputSignFormatter,null]})];u.forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager),t.defaultBlock=e.defaultBlock,t.defaultAccount=e.defaultAccount}))};n.addProviders(u),e.exports=u},8130:e=>{"use strict";e.exports=function(e){var t,r=this;return this.net.getId().then((function(e){return t=e,r.getBlock(0)})).then((function(r){var n="private";return"0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3"===r.hash&&1===t&&(n="main"),"0x41941023680923e0fe4d74a34bdac8141f2540e3ae90623718e47d66d1ca4a2d"===r.hash&&3===t&&(n="ropsten"),"0x6341fd3daf94b748c72ced5a5b26028f2474f5f00d824504e4fa37a75767e177"===r.hash&&4===t&&(n="rinkeby"),"0xbf7e331f7f7c1dd2e05159666b3bf8bc7a8a3a9eb1d518969eab529dd9b88c1a"===r.hash&&5===t&&(n="goerli"),"0xa3c565fc15c7478862d50ccd6561e3c06b24cc509bf388941c25ea985ce32cb9"===r.hash&&42===t&&(n="kovan"),"function"==typeof e&&e(null,n),n})).catch((function(t){if("function"!=typeof e)throw t;e(t)}))}},6748:(e,t,r)=>{"use strict";var n=r(606),i=r(1314),o=r(4178).subscriptions,a=r(3349),s=r(8161),u=r(473),c=r(715),l=r(6306),f=r(8164),h=r(6),d=r(9819),p=r(9901),m=r(8130),y=i.formatters,g=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getBlockByHash":"eth_getBlockByNumber"},b=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getTransactionByBlockHashAndIndex":"eth_getTransactionByBlockNumberAndIndex"},v=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getUncleByBlockHashAndIndex":"eth_getUncleByBlockNumberAndIndex"},w=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getBlockTransactionCountByHash":"eth_getBlockTransactionCountByNumber"},A=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getUncleCountByBlockHash":"eth_getUncleCountByBlockNumber"},S=function(){var e=this;n.packageInit(this,arguments);var t=this.setRequestManager;this.setRequestManager=function(r){return t(r),e.net.setRequestManager(r),e.personal.setRequestManager(r),e.accounts.setRequestManager(r),e.Contract._requestManager=e._requestManager,e.Contract.currentProvider=e._provider,!0};var r=this.setProvider;this.setProvider=function(){r.apply(e,arguments),e.setRequestManager(e._requestManager),e.ens._detectedAddress=null,e.ens._lastSyncCheck=null};var i,S,k,E=!1,_=null,M="latest",T=50,x=24,P=750,I=1e3,O=10,R=100;Object.defineProperty(this,"handleRevert",{get:function(){return E},set:function(t){E=t,e.Contract.handleRevert=E,N.forEach((function(e){e.handleRevert=E}))},enumerable:!0}),Object.defineProperty(this,"defaultCommon",{get:function(){return k},set:function(t){k=t,e.Contract.defaultCommon=k,N.forEach((function(e){e.defaultCommon=k}))},enumerable:!0}),Object.defineProperty(this,"defaultHardfork",{get:function(){return S},set:function(t){S=t,e.Contract.defaultHardfork=S,N.forEach((function(e){e.defaultHardfork=S}))},enumerable:!0}),Object.defineProperty(this,"defaultChain",{get:function(){return i},set:function(t){i=t,e.Contract.defaultChain=i,N.forEach((function(e){e.defaultChain=i}))},enumerable:!0}),Object.defineProperty(this,"transactionPollingTimeout",{get:function(){return P},set:function(t){P=t,e.Contract.transactionPollingTimeout=P,N.forEach((function(e){e.transactionPollingTimeout=P}))},enumerable:!0}),Object.defineProperty(this,"transactionPollingInterval",{get:function(){return I},set:function(t){I=t,e.Contract.transactionPollingInterval=I,N.forEach((function(e){e.transactionPollingInterval=I}))},enumerable:!0}),Object.defineProperty(this,"transactionConfirmationBlocks",{get:function(){return x},set:function(t){x=t,e.Contract.transactionConfirmationBlocks=x,N.forEach((function(e){e.transactionConfirmationBlocks=x}))},enumerable:!0}),Object.defineProperty(this,"transactionBlockTimeout",{get:function(){return T},set:function(t){T=t,e.Contract.transactionBlockTimeout=T,N.forEach((function(e){e.transactionBlockTimeout=T}))},enumerable:!0}),Object.defineProperty(this,"blockHeaderTimeout",{get:function(){return O},set:function(t){O=t,e.Contract.blockHeaderTimeout=O,N.forEach((function(e){e.blockHeaderTimeout=O}))},enumerable:!0}),Object.defineProperty(this,"defaultAccount",{get:function(){return _},set:function(t){return t&&(_=s.toChecksumAddress(y.inputAddressFormatter(t))),e.Contract.defaultAccount=_,e.personal.defaultAccount=_,N.forEach((function(e){e.defaultAccount=_})),t},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return M},set:function(t){return M=t,e.Contract.defaultBlock=M,e.personal.defaultBlock=M,N.forEach((function(e){e.defaultBlock=M})),t},enumerable:!0}),Object.defineProperty(this,"maxListenersWarningThreshold",{get:function(){return R},set:function(t){e.currentProvider&&e.currentProvider.setMaxListeners&&(R=t,e.currentProvider.setMaxListeners(t))},enumerable:!0}),this.clearSubscriptions=e._requestManager.clearSubscriptions.bind(e._requestManager),this.removeSubscriptionById=e._requestManager.removeSubscription.bind(e._requestManager),this.net=new u(this),this.net.getNetworkType=m.bind(this),this.accounts=new d(this),this.personal=new l(this),this.personal.defaultAccount=this.defaultAccount,this.maxListenersWarningThreshold=R;var C=this,B=function(){f.apply(this,arguments);var e=this,t=C.setProvider;C.setProvider=function(){t.apply(C,arguments),n.packageInit(e,[C])}};B.setProvider=function(){f.setProvider.apply(this,arguments)},B.prototype=Object.create(f.prototype),B.prototype.constructor=B,this.Contract=B,this.Contract.defaultAccount=this.defaultAccount,this.Contract.defaultBlock=this.defaultBlock,this.Contract.transactionBlockTimeout=this.transactionBlockTimeout,this.Contract.transactionConfirmationBlocks=this.transactionConfirmationBlocks,this.Contract.transactionPollingTimeout=this.transactionPollingTimeout,this.Contract.transactionPollingInterval=this.transactionPollingInterval,this.Contract.blockHeaderTimeout=this.blockHeaderTimeout,this.Contract.handleRevert=this.handleRevert,this.Contract._requestManager=this._requestManager,this.Contract._ethAccounts=this.accounts,this.Contract.currentProvider=this._requestManager.provider,this.Iban=h,this.abi=p,this.ens=new c(this);var N=[new a({name:"getNodeInfo",call:"web3_clientVersion"}),new a({name:"getProtocolVersion",call:"eth_protocolVersion",params:0}),new a({name:"getCoinbase",call:"eth_coinbase",params:0}),new a({name:"isMining",call:"eth_mining",params:0}),new a({name:"getHashrate",call:"eth_hashrate",params:0,outputFormatter:s.hexToNumber}),new a({name:"isSyncing",call:"eth_syncing",params:0,outputFormatter:y.outputSyncingFormatter}),new a({name:"getGasPrice",call:"eth_gasPrice",params:0,outputFormatter:y.outputBigNumberFormatter}),new a({name:"getFeeHistory",call:"eth_feeHistory",params:3,inputFormatter:[s.numberToHex,y.inputBlockNumberFormatter,null]}),new a({name:"getAccounts",call:"eth_accounts",params:0,outputFormatter:s.toChecksumAddress}),new a({name:"getBlockNumber",call:"eth_blockNumber",params:0,outputFormatter:s.hexToNumber}),new a({name:"getBalance",call:"eth_getBalance",params:2,inputFormatter:[y.inputAddressFormatter,y.inputDefaultBlockNumberFormatter],outputFormatter:y.outputBigNumberFormatter}),new a({name:"getStorageAt",call:"eth_getStorageAt",params:3,inputFormatter:[y.inputAddressFormatter,s.numberToHex,y.inputDefaultBlockNumberFormatter]}),new a({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[y.inputAddressFormatter,y.inputDefaultBlockNumberFormatter]}),new a({name:"getBlock",call:g,params:2,inputFormatter:[y.inputBlockNumberFormatter,function(e){return!!e}],outputFormatter:y.outputBlockFormatter}),new a({name:"getUncle",call:v,params:2,inputFormatter:[y.inputBlockNumberFormatter,s.numberToHex],outputFormatter:y.outputBlockFormatter}),new a({name:"getBlockTransactionCount",call:w,params:1,inputFormatter:[y.inputBlockNumberFormatter],outputFormatter:s.hexToNumber}),new a({name:"getBlockUncleCount",call:A,params:1,inputFormatter:[y.inputBlockNumberFormatter],outputFormatter:s.hexToNumber}),new a({name:"getTransaction",call:"eth_getTransactionByHash",params:1,inputFormatter:[null],outputFormatter:y.outputTransactionFormatter}),new a({name:"getTransactionFromBlock",call:b,params:2,inputFormatter:[y.inputBlockNumberFormatter,s.numberToHex],outputFormatter:y.outputTransactionFormatter}),new a({name:"getTransactionReceipt",call:"eth_getTransactionReceipt",params:1,inputFormatter:[null],outputFormatter:y.outputTransactionReceiptFormatter}),new a({name:"getTransactionCount",call:"eth_getTransactionCount",params:2,inputFormatter:[y.inputAddressFormatter,y.inputDefaultBlockNumberFormatter],outputFormatter:s.hexToNumber}),new a({name:"sendSignedTransaction",call:"eth_sendRawTransaction",params:1,inputFormatter:[null],abiCoder:p}),new a({name:"signTransaction",call:"eth_signTransaction",params:1,inputFormatter:[y.inputTransactionFormatter]}),new a({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[y.inputTransactionFormatter],abiCoder:p}),new a({name:"sign",call:"eth_sign",params:2,inputFormatter:[y.inputSignFormatter,y.inputAddressFormatter],transformPayload:function(e){return e.params.reverse(),e}}),new a({name:"call",call:"eth_call",params:2,inputFormatter:[y.inputCallFormatter,y.inputDefaultBlockNumberFormatter],abiCoder:p}),new a({name:"estimateGas",call:"eth_estimateGas",params:1,inputFormatter:[y.inputCallFormatter],outputFormatter:s.hexToNumber}),new a({name:"submitWork",call:"eth_submitWork",params:3}),new a({name:"getWork",call:"eth_getWork",params:0}),new a({name:"getPastLogs",call:"eth_getLogs",params:1,inputFormatter:[y.inputLogFormatter],outputFormatter:y.outputLogFormatter}),new a({name:"getChainId",call:"eth_chainId",params:0,outputFormatter:s.hexToNumber}),new a({name:"requestAccounts",call:"eth_requestAccounts",params:0,outputFormatter:s.toChecksumAddress}),new a({name:"getProof",call:"eth_getProof",params:3,inputFormatter:[y.inputAddressFormatter,y.inputStorageKeysFormatter,y.inputDefaultBlockNumberFormatter],outputFormatter:y.outputProofFormatter}),new a({name:"getPendingTransactions",call:"eth_pendingTransactions",params:0,outputFormatter:y.outputTransactionFormatter}),new a({name:"createAccessList",call:"eth_createAccessList",params:2,inputFormatter:[y.inputTransactionFormatter,y.inputDefaultBlockNumberFormatter]}),new o({name:"subscribe",type:"eth",subscriptions:{newBlockHeaders:{subscriptionName:"newHeads",params:0,outputFormatter:y.outputBlockFormatter},pendingTransactions:{subscriptionName:"newPendingTransactions",params:0},logs:{params:1,inputFormatter:[y.inputLogFormatter],outputFormatter:y.outputLogFormatter,subscriptionHandler:function(e){e.removed?this.emit("changed",e):this.emit("data",e),"function"==typeof this.callback&&this.callback(null,e,this)}},syncing:{params:0,outputFormatter:y.outputSyncingFormatter,subscriptionHandler:function(e){var t=this;!0!==this._isSyncing?(this._isSyncing=!0,this.emit("changed",t._isSyncing),"function"==typeof this.callback&&this.callback(null,t._isSyncing,this),setTimeout((function(){t.emit("data",e),"function"==typeof t.callback&&t.callback(null,e,t)}),0)):(this.emit("data",e),"function"==typeof t.callback&&this.callback(null,e,this),clearTimeout(this._isSyncingTimeout),this._isSyncingTimeout=setTimeout((function(){e.currentBlock>e.highestBlock-200&&(t._isSyncing=!1,t.emit("changed",t._isSyncing),"function"==typeof t.callback&&t.callback(null,t._isSyncing,t))}),500))}}}})];N.forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager,e.accounts),t.defaultBlock=e.defaultBlock,t.defaultAccount=e.defaultAccount,t.transactionBlockTimeout=e.transactionBlockTimeout,t.transactionConfirmationBlocks=e.transactionConfirmationBlocks,t.transactionPollingTimeout=e.transactionPollingTimeout,t.transactionPollingInterval=e.transactionPollingInterval,t.handleRevert=e.handleRevert}))};n.addProviders(S),e.exports=S},473:(e,t,r)=>{"use strict";var n=r(606),i=r(3349),o=r(8161),a=function(){var e=this;n.packageInit(this,arguments),[new i({name:"getId",call:"net_version",params:0,outputFormatter:parseInt}),new i({name:"isListening",call:"net_listening",params:0}),new i({name:"getPeerCount",call:"net_peerCount",params:0,outputFormatter:o.hexToNumber})].forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager)}))};n.addProviders(a),e.exports=a},4565:(e,t,r)=>{"use strict";var n=r(1314).errors,i=r(9519),o=r(912);r(2439),r(4258).polyfill(),void 0===r.g||r.g.AbortController||r(3368);var a=function(e,t){t=t||{},this.withCredentials=t.withCredentials,this.timeout=t.timeout||0,this.headers=t.headers,this.agent=t.agent,this.connected=!1;var r=!1!==t.keepAlive;this.host=e||"http://localhost:8545",this.agent||("https"===this.host.substring(0,5)?this.httpsAgent=new o.Agent({keepAlive:r}):this.httpAgent=new i.Agent({keepAlive:r}))};a.prototype.send=function(e,t){var r,i={method:"POST",body:JSON.stringify(e)},o={};if("undefined"!=typeof AbortController?r=new AbortController:"undefined"!=typeof window&&void 0!==window.AbortController&&(r=new window.AbortController),void 0!==r&&(i.signal=r.signal),"undefined"==typeof XMLHttpRequest){var a={httpsAgent:this.httpsAgent,httpAgent:this.httpAgent};this.agent&&(a.httpsAgent=this.agent.https,a.httpAgent=this.agent.http),"https"===this.host.substring(0,5)?i.agent=a.httpsAgent:i.agent=a.httpAgent}this.headers&&this.headers.forEach((function(e){o[e.name]=e.value})),o["Content-Type"]||(o["Content-Type"]="application/json"),this.withCredentials?i.credentials="include":i.credentials="omit",i.headers=o,this.timeout>0&&void 0!==r&&(this.timeoutId=setTimeout((function(){r.abort()}),this.timeout)),fetch(this.host,i).then(function(e){void 0!==this.timeoutId&&clearTimeout(this.timeoutId),e.json().then((function(e){t(null,e)})).catch((function(r){t(n.InvalidResponse(e))}))}.bind(this)).catch(function(e){void 0!==this.timeoutId&&clearTimeout(this.timeoutId),"AbortError"===e.name&&t(n.ConnectionTimeout(this.timeout)),t(n.InvalidConnection(this.host))}.bind(this))},a.prototype.disconnect=function(){},a.prototype.supportsSubscriptions=function(){return!1},e.exports=a},2683:(e,t,r)=>{"use strict";var n=r(1314).errors,i=r(3150),o=function(e,t){var r=this;this.responseCallbacks={},this.notificationCallbacks=[],this.path=e,this.connected=!1,this.connection=t.connect({path:this.path}),this.addDefaultEvents();var n=function(e){var t=null;Array.isArray(e)?e.forEach((function(e){r.responseCallbacks[e.id]&&(t=e.id)})):t=e.id,t||-1===e.method.indexOf("_subscription")?r.responseCallbacks[t]&&(r.responseCallbacks[t](null,e),delete r.responseCallbacks[t]):r.notificationCallbacks.forEach((function(t){"function"==typeof t&&t(e)}))};"Socket"===t.constructor.name?i(this.connection).done(n):this.connection.on("data",(function(e){r._parseResponse(e.toString()).forEach(n)}))};o.prototype.addDefaultEvents=function(){var e=this;this.connection.on("connect",(function(){e.connected=!0})),this.connection.on("close",(function(){e.connected=!1})),this.connection.on("error",(function(){e._timeout()})),this.connection.on("end",(function(){e._timeout()})),this.connection.on("timeout",(function(){e._timeout()}))},o.prototype._parseResponse=function(e){var t=this,r=[];return e.replace(/\}[\n\r]?\{/g,"}|--|{").replace(/\}\][\n\r]?\[\{/g,"}]|--|[{").replace(/\}[\n\r]?\[\{/g,"}|--|[{").replace(/\}\][\n\r]?\{/g,"}]|--|{").split("|--|").forEach((function(e){t.lastChunk&&(e=t.lastChunk+e);var i=null;try{i=JSON.parse(e)}catch(r){return t.lastChunk=e,clearTimeout(t.lastChunkTimeout),void(t.lastChunkTimeout=setTimeout((function(){throw t._timeout(),n.InvalidResponse(e)}),15e3))}clearTimeout(t.lastChunkTimeout),t.lastChunk=null,i&&r.push(i)})),r},o.prototype._addResponseCallback=function(e,t){var r=e.id||e[0].id,n=e.method||e[0].method;this.responseCallbacks[r]=t,this.responseCallbacks[r].method=n},o.prototype._timeout=function(){for(var e in this.responseCallbacks)this.responseCallbacks.hasOwnProperty(e)&&(this.responseCallbacks[e](n.InvalidConnection("on IPC")),delete this.responseCallbacks[e])},o.prototype.reconnect=function(){this.connection.connect({path:this.path})},o.prototype.send=function(e,t){this.connection.writable||this.connection.connect({path:this.path}),this.connection.write(JSON.stringify(e)),this._addResponseCallback(e,t)},o.prototype.on=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");"data"===e?this.notificationCallbacks.push(t):this.connection.on(e,t)},o.prototype.once=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");this.connection.once(e,t)},o.prototype.removeListener=function(e,t){var r=this;"data"===e?this.notificationCallbacks.forEach((function(e,n){e===t&&r.notificationCallbacks.splice(n,1)})):this.connection.removeListener(e,t)},o.prototype.removeAllListeners=function(e){"data"===e?this.notificationCallbacks=[]:this.connection.removeAllListeners(e)},o.prototype.reset=function(){this._timeout(),this.notificationCallbacks=[],this.connection.removeAllListeners("error"),this.connection.removeAllListeners("end"),this.connection.removeAllListeners("timeout"),this.addDefaultEvents()},o.prototype.supportsSubscriptions=function(){return!0},e.exports=o},360:(e,t,r)=>{"use strict";var n=r(9142),i=r(9033).Buffer,o=r(8847)(r(3355)),a="[object process]"===Object.prototype.toString.call(void 0!==n?n:0),s="undefined"!=typeof navigator&&"ReactNative"===navigator.product,u=null,c=null;if(a||s){u=function(e){return i.from(e).toString("base64")};var l=r(1143);if(l.URL){var f=l.URL;c=function(e){return new f(e)}}else c=r(1143).parse}else u=btoa.bind("object"===("undefined"==typeof globalThis?"undefined":(0,o.default)(globalThis))?globalThis:self),c=function(e){return new URL(e)};e.exports={parseURL:c,btoa:u}},7651:(e,t,r)=>{"use strict";var n=r(8008),i=r(360),o=r(1314).errors,a=r(1158).w3cwebsocket,s=function(e,t){n.call(this),t=t||{},this.url=e,this._customTimeout=t.timeout||15e3,this.headers=t.headers||{},this.protocol=t.protocol||void 0,this.reconnectOptions=Object.assign({auto:!1,delay:5e3,maxAttempts:!1,onTimeout:!1},t.reconnect),this.clientConfig=t.clientConfig||void 0,this.requestOptions=t.requestOptions||void 0,this.DATA="data",this.CLOSE="close",this.ERROR="error",this.CONNECT="connect",this.RECONNECT="reconnect",this.connection=null,this.requestQueue=new Map,this.responseQueue=new Map,this.reconnectAttempts=0,this.reconnecting=!1;var r=i.parseURL(e);r.username&&r.password&&(this.headers.authorization="Basic "+i.btoa(r.username+":"+r.password)),r.auth&&(this.headers.authorization="Basic "+i.btoa(r.auth)),Object.defineProperty(this,"connected",{get:function(){return this.connection&&this.connection.readyState===this.connection.OPEN},enumerable:!0}),this.connect()};(s.prototype=Object.create(n.prototype)).constructor=s,s.prototype.connect=function(){this.connection=new a(this.url,this.protocol,void 0,this.headers,this.requestOptions,this.clientConfig),this._addSocketListeners()},s.prototype._onMessage=function(e){var t=this;this._parseResponse("string"==typeof e.data?e.data:"").forEach((function(e){if(e.method&&-1!==e.method.indexOf("_subscription"))t.emit(t.DATA,e);else{var r=e.id;Array.isArray(e)&&(r=e[0].id),t.responseQueue.has(r)&&(void 0!==t.responseQueue.get(r).callback&&t.responseQueue.get(r).callback(!1,e),t.responseQueue.delete(r))}}))},s.prototype._onConnect=function(){if(this.emit(this.CONNECT),this.reconnectAttempts=0,this.reconnecting=!1,this.requestQueue.size>0){var e=this;this.requestQueue.forEach((function(t,r){e.send(t.payload,t.callback),e.requestQueue.delete(r)}))}},s.prototype._onClose=function(e){var t=this;!this.reconnectOptions.auto||[1e3,1001].includes(e.code)&&!1!==e.wasClean?(this.emit(this.CLOSE,e),this.requestQueue.size>0&&this.requestQueue.forEach((function(r,n){r.callback(o.ConnectionNotOpenError(e)),t.requestQueue.delete(n)})),this.responseQueue.size>0&&this.responseQueue.forEach((function(r,n){r.callback(o.InvalidConnection("on WS",e)),t.responseQueue.delete(n)})),this._removeSocketListeners(),this.removeAllListeners()):this.reconnect()},s.prototype._addSocketListeners=function(){this.connection.addEventListener("message",this._onMessage.bind(this)),this.connection.addEventListener("open",this._onConnect.bind(this)),this.connection.addEventListener("close",this._onClose.bind(this))},s.prototype._removeSocketListeners=function(){this.connection.removeEventListener("message",this._onMessage),this.connection.removeEventListener("open",this._onConnect),this.connection.removeEventListener("close",this._onClose)},s.prototype._parseResponse=function(e){var t=this,r=[];return e.replace(/\}[\n\r]?\{/g,"}|--|{").replace(/\}\][\n\r]?\[\{/g,"}]|--|[{").replace(/\}[\n\r]?\[\{/g,"}|--|[{").replace(/\}\][\n\r]?\{/g,"}]|--|{").split("|--|").forEach((function(e){t.lastChunk&&(e=t.lastChunk+e);var n=null;try{n=JSON.parse(e)}catch(r){return t.lastChunk=e,clearTimeout(t.lastChunkTimeout),void(t.lastChunkTimeout=setTimeout((function(){t.reconnectOptions.auto&&t.reconnectOptions.onTimeout?t.reconnect():(t.emit(t.ERROR,o.ConnectionTimeout(t._customTimeout)),t.requestQueue.size>0&&t.requestQueue.forEach((function(e,r){e.callback(o.ConnectionTimeout(t._customTimeout)),t.requestQueue.delete(r)})))}),t._customTimeout))}clearTimeout(t.lastChunkTimeout),t.lastChunk=null,n&&r.push(n)})),r},s.prototype.send=function(e,t){var r=e.id,n={payload:e,callback:t};if(Array.isArray(e)&&(r=e[0].id),this.connection.readyState===this.connection.CONNECTING||this.reconnecting)this.requestQueue.set(r,n);else{if(this.connection.readyState!==this.connection.OPEN)return this.requestQueue.delete(r),this.emit(this.ERROR,o.ConnectionNotOpenError()),void n.callback(o.ConnectionNotOpenError());this.responseQueue.set(r,n),this.requestQueue.delete(r);try{this.connection.send(JSON.stringify(n.payload))}catch(e){n.callback(e),this.responseQueue.delete(r)}}},s.prototype.reset=function(){this.responseQueue.clear(),this.requestQueue.clear(),this.removeAllListeners(),this._removeSocketListeners(),this._addSocketListeners()},s.prototype.disconnect=function(e,t){this._removeSocketListeners(),this.connection.close(e||1e3,t)},s.prototype.supportsSubscriptions=function(){return!0},s.prototype.reconnect=function(){var e=this;this.reconnecting=!0,this.responseQueue.size>0&&this.responseQueue.forEach((function(t,r){t.callback(o.PendingRequestsOnReconnectingError()),e.responseQueue.delete(r)})),!this.reconnectOptions.maxAttempts||this.reconnectAttempts0&&this.requestQueue.forEach((function(t,r){t.callback(o.MaxAttemptsReachedOnReconnectingError()),e.requestQueue.delete(r)})))},e.exports=s},2565:(e,t,r)=>{"use strict";var n=r(606),i=r(4178).subscriptions,o=r(3349),a=r(473),s=function(){var e=this;n.packageInit(this,arguments);var t=this.setRequestManager;this.setRequestManager=function(r){return t(r),e.net.setRequestManager(r),!0};var r=this.setProvider;this.setProvider=function(){r.apply(e,arguments),e.setRequestManager(e._requestManager)},this.net=new a(this),[new i({name:"subscribe",type:"shh",subscriptions:{messages:{params:1}}}),new o({name:"getVersion",call:"shh_version",params:0}),new o({name:"getInfo",call:"shh_info",params:0}),new o({name:"setMaxMessageSize",call:"shh_setMaxMessageSize",params:1}),new o({name:"setMinPoW",call:"shh_setMinPoW",params:1}),new o({name:"markTrustedPeer",call:"shh_markTrustedPeer",params:1}),new o({name:"newKeyPair",call:"shh_newKeyPair",params:0}),new o({name:"addPrivateKey",call:"shh_addPrivateKey",params:1}),new o({name:"deleteKeyPair",call:"shh_deleteKeyPair",params:1}),new o({name:"hasKeyPair",call:"shh_hasKeyPair",params:1}),new o({name:"getPublicKey",call:"shh_getPublicKey",params:1}),new o({name:"getPrivateKey",call:"shh_getPrivateKey",params:1}),new o({name:"newSymKey",call:"shh_newSymKey",params:0}),new o({name:"addSymKey",call:"shh_addSymKey",params:1}),new o({name:"generateSymKeyFromPassword",call:"shh_generateSymKeyFromPassword",params:1}),new o({name:"hasSymKey",call:"shh_hasSymKey",params:1}),new o({name:"getSymKey",call:"shh_getSymKey",params:1}),new o({name:"deleteSymKey",call:"shh_deleteSymKey",params:1}),new o({name:"newMessageFilter",call:"shh_newMessageFilter",params:1}),new o({name:"getFilterMessages",call:"shh_getFilterMessages",params:1}),new o({name:"deleteMessageFilter",call:"shh_deleteMessageFilter",params:1}),new o({name:"post",call:"shh_post",params:1,inputFormatter:[null]}),new o({name:"unsubscribe",call:"shh_unsubscribe",params:1})].forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager)}))};s.prototype.clearSubscriptions=function(){this._requestManager.clearSubscriptions()},n.addProviders(s),e.exports=s},8161:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(7130),o=r(323),a=r(747),s=r(5010),u=r(1734),c=function e(t,r){var i=[];return r.forEach((function(r){if("object"===(0,n.default)(r.components)){if("tuple"!==r.type.substring(0,5))throw new Error("components found but type is not tuple; report on GitHub");var o="",a=r.type.indexOf("[");a>=0&&(o=r.type.substring(a));var s=e(t,r.components);Array.isArray(s)&&t?i.push("tuple("+s.join(",")+")"+o):t?i.push("("+s+")"):i.push("("+s.join(",")+")"+o)}else i.push(r.type)})),i},l=function(e){if(!o.isHexStrict(e))throw new Error("The parameter must be a valid HEX string.");var t="",r=0,n=e.length;for("0x"===e.substring(0,2)&&(r=2);r7?r+=e[n].toUpperCase():r+=e[n];return r},toHex:o.toHex,toBN:o.toBN,bytesToHex:o.bytesToHex,hexToBytes:o.hexToBytes,hexToNumberString:o.hexToNumberString,hexToNumber:o.hexToNumber,toDecimal:o.hexToNumber,numberToHex:o.numberToHex,fromDecimal:o.numberToHex,hexToUtf8:o.hexToUtf8,hexToString:o.hexToUtf8,toUtf8:o.hexToUtf8,stripHexPrefix:o.stripHexPrefix,utf8ToHex:o.utf8ToHex,stringToHex:o.utf8ToHex,fromUtf8:o.utf8ToHex,hexToAscii:l,toAscii:l,asciiToHex:f,fromAscii:f,unitMap:i.unitMap,toWei:function(e,t){if(t=h(t),!o.isBN(e)&&"string"!=typeof e)throw new Error("Please pass numbers as strings or BN objects to avoid precision errors.");return o.isBN(e)?i.toWei(e,t):i.toWei(e,t).toString(10)},fromWei:function(e,t){if(t=h(t),!o.isBN(e)&&"string"!=typeof e)throw new Error("Please pass numbers as strings or BN objects to avoid precision errors.");return o.isBN(e)?i.fromWei(e,t):i.fromWei(e,t).toString(10)},padLeft:o.leftPad,leftPad:o.leftPad,padRight:o.rightPad,rightPad:o.rightPad,toTwosComplement:o.toTwosComplement,isBloom:o.isBloom,isUserEthereumAddressInBloom:o.isUserEthereumAddressInBloom,isContractAddressInBloom:o.isContractAddressInBloom,isTopic:o.isTopic,isTopicInBloom:o.isTopicInBloom,isInBloom:o.isInBloom,compareBlockNumbers:function(e,t){if(e===t)return 0;if("genesis"!==e&&"earliest"!==e&&0!==e||"genesis"!==t&&"earliest"!==t&&0!==t){if("genesis"===e||"earliest"===e||0===e)return-1;if("genesis"===t||"earliest"===t||0===t)return 1;if("latest"===e||"finalized"===e)return"pending"===t?-1:1;if("latest"===t||"finalized"===t)return"pending"===e?1:-1;if("pending"===e)return 1;if("pending"===t)return-1;if("safe"===e||"safe"===t)return;var r=new u(e),n=new u(t);return r.lt(n)?-1:r.eq(n)?0:1}return 0},toNumber:o.toNumber}},747:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(323),a=function(e){var t=(0,n.default)(e);if("string"===t)return o.isHexStrict(e)?new i(e.replace(/0x/i,""),16):new i(e,10);if("number"===t)return new i(e);if(o.isBigNumber(e))return new i(e.toString(10));if(o.isBN(e))return e;throw new Error(e+" is not a number")},s=function(e,t,r){var n,s;if("bytes"===(e=function(e){return e.startsWith("int[")?"int256"+e.slice(3):"int"===e?"int256":e.startsWith("uint[")?"uint256"+e.slice(4):"uint"===e?"uint256":e.startsWith("fixed[")?"fixed128x128"+e.slice(5):"fixed"===e?"fixed128x128":e.startsWith("ufixed[")?"ufixed128x128"+e.slice(6):"ufixed"===e?"ufixed128x128":e}(e))){if(t.replace(/^0x/i,"").length%2!=0)throw new Error("Invalid bytes characters "+t.length);return t}if("string"===e)return o.utf8ToHex(t);if("bool"===e)return t?"01":"00";if(e.startsWith("address")){if(n=r?64:40,!o.isAddress(t))throw new Error(t+" is not a valid address, or the checksum is invalid.");return o.leftPad(t.toLowerCase(),n)}if(n=function(e){var t=/^\D+(\d+).*$/.exec(e);return t?parseInt(t[1],10):null}(e),e.startsWith("bytes")){if(!n)throw new Error("bytes[] not yet supported in solidity");if(r&&(n=32),n<1||n>32||n256)throw new Error("Invalid uint"+n+" size");if((s=a(t)).bitLength()>n)throw new Error("Supplied uint exceeds width: "+n+" vs "+s.bitLength());if(s.lt(new i(0)))throw new Error("Supplied uint "+s.toString()+" is negative");return n?o.leftPad(s.toString("hex"),n/8*2):s}if(e.startsWith("int")){if(n%8||n<8||n>256)throw new Error("Invalid int"+n+" size");if((s=a(t)).bitLength()>n)throw new Error("Supplied int exceeds width: "+n+" vs "+s.bitLength());return s.lt(new i(0))?s.toTwos(n).toString("hex"):n?o.leftPad(s.toString("hex"),n/8*2):s}throw new Error("Unsupported or invalid type: "+e)},u=function(e){if(Array.isArray(e))throw new Error("Autodetection of array types is not supported.");var t,r,a="";if(e&&"object"===(0,n.default)(e)&&(e.hasOwnProperty("v")||e.hasOwnProperty("t")||e.hasOwnProperty("value")||e.hasOwnProperty("type"))?(t=e.hasOwnProperty("t")?e.t:e.type,a=e.hasOwnProperty("v")?e.v:e.value):(t=o.toHex(e,!0),a=o.toHex(e),t.startsWith("int")||t.startsWith("uint")||(t="bytes")),!t.startsWith("int")&&!t.startsWith("uint")||"string"!=typeof a||/^(-)?0x/i.test(a)||(a=new i(a)),Array.isArray(a)){if(r=function(e){var t=/^\D+\d*\[(\d+)\]$/.exec(e);return t?parseInt(t[1],10):null}(t),r&&a.length!==r)throw new Error(t+" is not matching the given array "+JSON.stringify(a));r=a.length}return Array.isArray(a)?a.map((function(e){return s(t,e,r).toString("hex").replace("0x","")})).join(""):s(t,a,r).toString("hex").replace("0x","")};e.exports={soliditySha3:function(){var e=Array.prototype.slice.call(arguments),t=e.map(u);return o.sha3("0x"+t.join(""))},soliditySha3Raw:function(){return o.sha3Raw("0x"+Array.prototype.slice.call(arguments).map(u).join(""))},encodePacked:function(){var e=Array.prototype.slice.call(arguments),t=e.map(u);return"0x"+t.join("").toLowerCase()}}},323:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(4519)),a=i(r(3355)),s=r(1734),u=r(7277),c=r(8632),l=r(3062),f=r(9313),h=function(e){return s.isBN(e)},d=function(e){return e&&e.constructor&&"BigNumber"===e.constructor.name},p=function(e){try{return u.apply(null,arguments)}catch(t){throw new Error(t+' Given value: "'+e+'"')}},m=function(e){return!!/^(0x)?[0-9a-f]{40}$/i.test(e)&&(!(!/^(0x|0X)?[0-9a-f]{40}$/.test(e)&&!/^(0x|0X)?[0-9A-F]{40}$/.test(e))||y(e))},y=function(e){e=e.replace(/^0x/i,"");for(var t=E(e.toLowerCase()).replace(/^0x/i,""),r=0;r<40;r++)if(parseInt(t[r],16)>7&&e[r].toUpperCase()!==e[r]||parseInt(t[r],16)<=7&&e[r].toLowerCase()!==e[r])return!1;return!0},g=function(e){var t="";e=(e=(e=(e=(e=c.encode(e)).replace(/^(?:\u0000)*/,"")).split("").reverse().join("")).replace(/^(?:\u0000)*/,"")).split("").reverse().join("");for(var r=0;r>>4).toString(16)),t.push((15&e[r]).toString(16));return"0x"+t.join("")},isHex:S,isHexStrict:A,stripHexPrefix:function(e){return 0!==e&&S(e)?e.replace(/^(-)?0x/i,"$1"):e},leftPad:function(e,t,r){var n=/^0x/i.test(e)||"number"==typeof e,i=t-(e=e.toString(16).replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(n?"0x":"")+new Array(i).join(r||"0")+e},rightPad:function(e,t,r){var n=/^0x/i.test(e)||"number"==typeof e,i=t-(e=e.toString(16).replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(n?"0x":"")+e+new Array(i).join(r||"0")},toTwosComplement:function(e){return"0x"+p(e).toTwos(256).toString(16,64)},sha3:E,sha3Raw:function(e){return null===(e=E(e))?k:e},toNumber:function(e){return"number"==typeof e?e:b(w(e))}}},7001:(e,t,r)=>{"use strict";var n=r(8920).i8,i=r(606),o=r(6748),a=r(473),s=r(6306),u=r(2565),c=r(2463),l=r(8161),f=function(){var e=this;i.packageInit(this,arguments),this.version=n,this.utils=l,this.eth=new o(this),this.shh=new u(this),this.bzz=new c(this);var t=this.setProvider;this.setProvider=function(r,n){return t.apply(e,arguments),e.eth.setRequestManager(e._requestManager),e.shh.setRequestManager(e._requestManager),e.bzz.setProvider(r),!0}};f.version=n,f.utils=l,f.modules={Eth:o,Net:a,Personal:s,Shh:u,Bzz:c},i.addProviders(f),e.exports=f},9214:()=>{},2361:()=>{},4616:()=>{},8768:e=>{"use strict";e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r{"use strict";e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},7907:(e,t,r)=>{"use strict";var n=r(8768);e.exports=function(e){if(Array.isArray(e))return n(e)},e.exports.__esModule=!0,e.exports.default=e.exports},8975:e=>{"use strict";e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},5698:e=>{"use strict";function t(e,t,r,n,i,o,a){try{var s=e[o](a),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}e.exports=function(e){return function(){var r=this,n=arguments;return new Promise((function(i,o){var a=e.apply(r,n);function s(e){t(a,i,o,s,u,"next",e)}function u(e){t(a,i,o,s,u,"throw",e)}s(void 0)}))}},e.exports.__esModule=!0,e.exports.default=e.exports},9721:e=>{"use strict";e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},4727:(e,t,r)=>{"use strict";var n=r(8746),i=r(6923);function o(t,r,a){return i()?(e.exports=o=Reflect.construct.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=o=function(e,t,r){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return r&&n(o,r.prototype),o},e.exports.__esModule=!0,e.exports.default=e.exports),o.apply(null,arguments)}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},8985:(e,t,r)=>{"use strict";var n=r(2310);function i(e,t){for(var r=0;r{"use strict";var n=r(2310);e.exports=function(e,t,r){return(t=n(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},e.exports.__esModule=!0,e.exports.default=e.exports},119:(e,t,r)=>{"use strict";var n=r(7460);function i(){return"undefined"!=typeof Reflect&&Reflect.get?(e.exports=i=Reflect.get.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=i=function(e,t,r){var i=n(e,t);if(i){var o=Object.getOwnPropertyDescriptor(i,t);return o.get?o.get.call(arguments.length<3?e:r):o.value}},e.exports.__esModule=!0,e.exports.default=e.exports),i.apply(this,arguments)}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports},1949:e=>{"use strict";function t(r){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},5163:(e,t,r)=>{"use strict";var n=r(8746);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&n(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},8847:e=>{"use strict";e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},6923:e=>{"use strict";e.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.__esModule=!0,e.exports.default=e.exports},1642:e=>{"use strict";e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports.default=e.exports},1436:e=>{"use strict";e.exports=function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,o,a,s=[],u=!0,c=!1;try{if(o=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=o.call(r)).done)&&(s.push(n.value),s.length!==t);u=!0);}catch(e){c=!0,i=e}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(c)throw i}}return s}},e.exports.__esModule=!0,e.exports.default=e.exports},2966:e=>{"use strict";e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},2344:e=>{"use strict";e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},4650:(e,t,r)=>{"use strict";var n=r(3355).default,i=r(8975);e.exports=function(e,t){if(t&&("object"===n(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return i(e)},e.exports.__esModule=!0,e.exports.default=e.exports},2028:(e,t,r)=>{"use strict";var n=r(3355).default;function i(){e.exports=i=function(){return t},e.exports.__esModule=!0,e.exports.default=e.exports;var t={},r=Object.prototype,o=r.hasOwnProperty,a=Object.defineProperty||function(e,t,r){e[t]=r.value},s="function"==typeof Symbol?Symbol:{},u=s.iterator||"@@iterator",c=s.asyncIterator||"@@asyncIterator",l=s.toStringTag||"@@toStringTag";function f(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{f({},"")}catch(e){f=function(e,t,r){return e[t]=r}}function h(e,t,r,n){var i=t&&t.prototype instanceof m?t:m,o=Object.create(i.prototype),s=new x(n||[]);return a(o,"_invoke",{value:E(e,r,s)}),o}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=h;var p={};function m(){}function y(){}function g(){}var b={};f(b,u,(function(){return this}));var v=Object.getPrototypeOf,w=v&&v(v(P([])));w&&w!==r&&o.call(w,u)&&(b=w);var A=g.prototype=m.prototype=Object.create(b);function S(e){["next","throw","return"].forEach((function(t){f(e,t,(function(e){return this._invoke(t,e)}))}))}function k(e,t){function r(i,a,s,u){var c=d(e[i],e,a);if("throw"!==c.type){var l=c.arg,f=l.value;return f&&"object"==n(f)&&o.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,s,u)}),(function(e){r("throw",e,s,u)})):t.resolve(f).then((function(e){l.value=e,s(l)}),(function(e){return r("throw",e,s,u)}))}u(c.arg)}var i;a(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,i){r(e,n,t,i)}))}return i=i?i.then(o,o):o()}})}function E(e,t,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return{value:void 0,done:!0}}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var s=_(a,r);if(s){if(s===p)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=d(e,t,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===p)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function _(e,t){var r=t.method,n=e.iterator[r];if(void 0===n)return t.delegate=null,"throw"===r&&e.iterator.return&&(t.method="return",t.arg=void 0,_(e,t),"throw"===t.method)||"return"!==r&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+r+"' method")),p;var i=d(n,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,p;var o=i.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,p):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,p)}function M(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function T(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function x(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(M,this),this.reset(!0)}function P(e){if(e){var t=e[u];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,n=function t(){for(;++r=0;--n){var i=this.tryEntries[n],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var s=o.call(i,"catchLoc"),u=o.call(i,"finallyLoc");if(s&&u){if(this.prev=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&o.call(n,"finallyLoc")&&this.prev=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),T(r),p}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var i=n.arg;T(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:P(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=void 0),p}},t}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports},8746:e=>{"use strict";function t(r,n){return e.exports=t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,t(r,n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},4519:(e,t,r)=>{"use strict";var n=r(2338),i=r(1436),o=r(6906),a=r(2966);e.exports=function(e,t){return n(e)||i(e,t)||o(e,t)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},7460:(e,t,r)=>{"use strict";var n=r(1949);e.exports=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=n(e)););return e},e.exports.__esModule=!0,e.exports.default=e.exports},3106:(e,t,r)=>{"use strict";var n=r(7907),i=r(1642),o=r(6906),a=r(2344);e.exports=function(e){return n(e)||i(e)||o(e)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},9662:(e,t,r)=>{"use strict";var n=r(3355).default;e.exports=function(e,t){if("object"!==n(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var i=r.call(e,t||"default");if("object"!==n(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},2310:(e,t,r)=>{"use strict";var n=r(3355).default,i=r(9662);e.exports=function(e){var t=i(e,"string");return"symbol"===n(t)?t:String(t)},e.exports.__esModule=!0,e.exports.default=e.exports},3355:e=>{"use strict";function t(r){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},6906:(e,t,r)=>{"use strict";var n=r(8768);e.exports=function(e,t){if(e){if("string"==typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},2247:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(2028)();e.exports=i;try{regeneratorRuntime=i}catch(e){"object"===("undefined"==typeof globalThis?"undefined":(0,n.default)(globalThis))?globalThis.regeneratorRuntime=i:Function("r","regeneratorRuntime = r")(i)}},3604:(e,t,r)=>{"use strict";var n=["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],i="undefined"==typeof globalThis?r.g:globalThis;e.exports=function(){for(var e=[],t=0;t{"use strict";e.exports=JSON.parse('{"name":"goerli","chainId":5,"networkId":5,"defaultHardfork":"istanbul","consensus":{"type":"poa","algorithm":"clique","clique":{"period":15,"epoch":30000}},"comment":"Cross-client PoA test network","url":"https://github.com/goerli/testnet","genesis":{"hash":"0xbf7e331f7f7c1dd2e05159666b3bf8bc7a8a3a9eb1d518969eab529dd9b88c1a","timestamp":"0x5c51a607","gasLimit":10485760,"difficulty":1,"nonce":"0x0000000000000000","extraData":"0x22466c6578692069732061207468696e6722202d204166726900000000000000e0a2bd4258d2768837baa26a28fe71dc079f84c70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","stateRoot":"0x5d6cded585e73c4e322c30c2f782a336316f17dd85a4863b9d838d2d4b8b3008"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0xa3f5ab08"},{"name":"homestead","block":0,"forkHash":"0xa3f5ab08"},{"name":"tangerineWhistle","block":0,"forkHash":"0xa3f5ab08"},{"name":"spuriousDragon","block":0,"forkHash":"0xa3f5ab08"},{"name":"byzantium","block":0,"forkHash":"0xa3f5ab08"},{"name":"constantinople","block":0,"forkHash":"0xa3f5ab08"},{"name":"petersburg","block":0,"forkHash":"0xa3f5ab08"},{"name":"istanbul","block":1561651,"forkHash":"0xc25efa5c"},{"name":"berlin","block":4460644,"forkHash":"0x757a1c47"},{"name":"london","block":5062605,"forkHash":"0xb8c6299d"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"51.141.78.53","port":30303,"id":"011f758e6552d105183b1761c5e2dea0111bc20fd5f6422bc7f91e0fabbec9a6595caf6239b37feb773dddd3f87240d99d859431891e4a642cf2a0a9e6cbb98a","location":"","comment":"Upstream bootnode 1"},{"ip":"13.93.54.137","port":30303,"id":"176b9417f511d05b6b2cf3e34b756cf0a7096b3094572a8f6ef4cdcb9d1f9d00683bf0f83347eebdf3b81c3521c2332086d9592802230bf528eaf606a1d9677b","location":"","comment":"Upstream bootnode 2"},{"ip":"94.237.54.114","port":30313,"id":"46add44b9f13965f7b9875ac6b85f016f341012d84f975377573800a863526f4da19ae2c620ec73d11591fa9510e992ecc03ad0751f53cc02f7c7ed6d55c7291","location":"","comment":"Upstream bootnode 3"},{"ip":"18.218.250.66","port":30313,"id":"b5948a2d3e9d486c4d75bf32713221c2bd6cf86463302339299bd227dc2e276cd5a1c7ca4f43a0e9122fe9af884efed563bd2a1fd28661f3b5f5ad7bf1de5949","location":"","comment":"Upstream bootnode 4"},{"ip":"3.11.147.67","port":30303,"id":"a61215641fb8714a373c80edbfa0ea8878243193f57c96eeb44d0bc019ef295abd4e044fd619bfc4c59731a73fb79afe84e9ab6da0c743ceb479cbb6d263fa91","location":"","comment":"Ethereum Foundation bootnode"},{"ip":"51.15.116.226","port":30303,"id":"a869b02cec167211fb4815a82941db2e7ed2936fd90e78619c53eb17753fcf0207463e3419c264e2a1dd8786de0df7e68cf99571ab8aeb7c4e51367ef186b1dd","location":"","comment":"Goerli Initiative bootnode"},{"ip":"51.15.119.157","port":30303,"id":"807b37ee4816ecf407e9112224494b74dd5933625f655962d892f2f0f02d7fbbb3e2a94cf87a96609526f30c998fd71e93e2f53015c558ffc8b03eceaf30ee33","location":"","comment":"Goerli Initiative bootnode"},{"ip":"51.15.119.157","port":40303,"id":"a59e33ccd2b3e52d578f1fbd70c6f9babda2650f0760d6ff3b37742fdcdfdb3defba5d56d315b40c46b70198c7621e63ffa3f987389c7118634b0fefbbdfa7fd","location":"","comment":"Goerli Initiative bootnode"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.goerli.ethdisco.net"]}')},7098:e=>{"use strict";e.exports=JSON.parse('{"name":"kovan","chainId":42,"networkId":42,"defaultHardfork":"istanbul","consensus":{"type":"poa","algorithm":"aura","aura":{}},"comment":"Parity PoA test network","url":"https://kovan-testnet.github.io/website/","genesis":{"hash":"0xa3c565fc15c7478862d50ccd6561e3c06b24cc509bf388941c25ea985ce32cb9","timestamp":null,"gasLimit":6000000,"difficulty":131072,"nonce":"0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","extraData":"0x","stateRoot":"0x2480155b48a1cea17d67dbfdfaafe821c1d19cdd478c5358e8ec56dec24502b2"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0x010ffe56"},{"name":"homestead","block":0,"forkHash":"0x010ffe56"},{"name":"tangerineWhistle","block":0,"forkHash":"0x010ffe56"},{"name":"spuriousDragon","block":0,"forkHash":"0x010ffe56"},{"name":"byzantium","block":5067000,"forkHash":"0x7f83c620"},{"name":"constantinople","block":9200000,"forkHash":"0xa94e3dc4"},{"name":"petersburg","block":10255201,"forkHash":"0x186874aa"},{"name":"istanbul","block":14111141,"forkHash":"0x7f6599a6"},{"name":"berlin","block":null,"forkHash":null},{"name":"london","block":null,"forkHash":null},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"116.203.116.241","port":30303,"id":"16898006ba2cd4fa8bf9a3dfe32684c178fa861df144bfc21fe800dc4838a03e342056951fa9fd533dcb0be1219e306106442ff2cf1f7e9f8faa5f2fc1a3aa45","location":"","comment":"1"},{"ip":"3.217.96.11","port":30303,"id":"2909846f78c37510cc0e306f185323b83bb2209e5ff4fdd279d93c60e3f365e3c6e62ad1d2133ff11f9fd6d23ad9c3dad73bb974d53a22f7d1ac5b7dea79d0b0","location":"","comment":"2"},{"ip":"108.61.170.124","port":30303,"id":"740e1c8ea64e71762c71a463a04e2046070a0c9394fcab5891d41301dc473c0cff00ebab5a9bc87fbcb610ab98ac18225ff897bc8b7b38def5975d5ceb0a7d7c","location":"","comment":"3"},{"ip":"157.230.31.163","port":30303,"id":"2909846f78c37510cc0e306f185323b83bb2209e5ff4fdd279d93c60e3f365e3c6e62ad1d2133ff11f9fd6d23ad9c3dad73bb974d53a22f7d1ac5b7dea79d0b0","location":"","comment":"4"}]}')},7295:e=>{"use strict";e.exports=JSON.parse('{"name":"mainnet","chainId":1,"networkId":1,"defaultHardfork":"istanbul","consensus":{"type":"pow","algorithm":"ethash","ethash":{}},"comment":"The Ethereum main chain","url":"https://ethstats.net/","genesis":{"hash":"0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3","timestamp":null,"gasLimit":5000,"difficulty":17179869184,"nonce":"0x0000000000000042","extraData":"0x11bbe8db4e347b4e8c937c1c8370e4b5ed33adb3db69cbdb7a38e1e50b1b82fa","stateRoot":"0xd7f8974fb5ac78d9ac099b9ad5018bedc2ce0a72dad1827a1709da30580f0544"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0xfc64ec04"},{"name":"homestead","block":1150000,"forkHash":"0x97c2c34c"},{"name":"dao","block":1920000,"forkHash":"0x91d1f948"},{"name":"tangerineWhistle","block":2463000,"forkHash":"0x7a64da13"},{"name":"spuriousDragon","block":2675000,"forkHash":"0x3edd5b10"},{"name":"byzantium","block":4370000,"forkHash":"0xa00bc324"},{"name":"constantinople","block":7280000,"forkHash":"0x668db0af"},{"name":"petersburg","block":7280000,"forkHash":"0x668db0af"},{"name":"istanbul","block":9069000,"forkHash":"0x879d6e30"},{"name":"muirGlacier","block":9200000,"forkHash":"0xe029e991"},{"name":"berlin","block":12244000,"forkHash":"0x0eb440f6"},{"name":"london","block":12965000,"forkHash":"0xb715077d"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"18.138.108.67","port":30303,"id":"d860a01f9722d78051619d1e2351aba3f43f943f6f00718d1b9baa4101932a1f5011f16bb2b1bb35db20d6fe28fa0bf09636d26a87d31de9ec6203eeedb1f666","location":"ap-southeast-1-001","comment":"bootnode-aws-ap-southeast-1-001"},{"ip":"3.209.45.79","port":30303,"id":"22a8232c3abc76a16ae9d6c3b164f98775fe226f0917b0ca871128a74a8e9630b458460865bab457221f1d448dd9791d24c4e5d88786180ac185df813a68d4de","location":"us-east-1-001","comment":"bootnode-aws-us-east-1-001"},{"ip":"34.255.23.113","port":30303,"id":"ca6de62fce278f96aea6ec5a2daadb877e51651247cb96ee310a318def462913b653963c155a0ef6c7d50048bba6e6cea881130857413d9f50a621546b590758","location":"eu-west-1-001","comment":"bootnode-aws-eu-west-1-001"},{"ip":"35.158.244.151","port":30303,"id":"279944d8dcd428dffaa7436f25ca0ca43ae19e7bcf94a8fb7d1641651f92d121e972ac2e8f381414b80cc8e5555811c2ec6e1a99bb009b3f53c4c69923e11bd8","location":"eu-central-1-001","comment":"bootnode-aws-eu-central-1-001"},{"ip":"52.187.207.27","port":30303,"id":"8499da03c47d637b20eee24eec3c356c9a2e6148d6fe25ca195c7949ab8ec2c03e3556126b0d7ed644675e78c4318b08691b7b57de10e5f0d40d05b09238fa0a","location":"australiaeast-001","comment":"bootnode-azure-australiaeast-001"},{"ip":"191.234.162.198","port":30303,"id":"103858bdb88756c71f15e9b5e09b56dc1be52f0a5021d46301dbbfb7e130029cc9d0d6f73f693bc29b665770fff7da4d34f3c6379fe12721b5d7a0bcb5ca1fc1","location":"brazilsouth-001","comment":"bootnode-azure-brazilsouth-001"},{"ip":"52.231.165.108","port":30303,"id":"715171f50508aba88aecd1250af392a45a330af91d7b90701c436b618c86aaa1589c9184561907bebbb56439b8f8787bc01f49a7c77276c58c1b09822d75e8e8","location":"koreasouth-001","comment":"bootnode-azure-koreasouth-001"},{"ip":"104.42.217.25","port":30303,"id":"5d6d7cd20d6da4bb83a1d28cadb5d409b64edf314c0335df658c1a54e32c7c4a7ab7823d57c39b6a757556e68ff1df17c748b698544a55cb488b52479a92b60f","location":"westus-001","comment":"bootnode-azure-westus-001"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.mainnet.ethdisco.net"]}')},439:e=>{"use strict";e.exports=JSON.parse('{"name":"rinkeby","chainId":4,"networkId":4,"defaultHardfork":"istanbul","consensus":{"type":"poa","algorithm":"clique","clique":{"period":15,"epoch":30000}},"comment":"PoA test network","url":"https://www.rinkeby.io","genesis":{"hash":"0x6341fd3daf94b748c72ced5a5b26028f2474f5f00d824504e4fa37a75767e177","timestamp":"0x58ee40ba","gasLimit":4700000,"difficulty":1,"nonce":"0x0000000000000000","extraData":"0x52657370656374206d7920617574686f7269746168207e452e436172746d616e42eb768f2244c8811c63729a21a3569731535f067ffc57839b00206d1ad20c69a1981b489f772031b279182d99e65703f0076e4812653aab85fca0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","stateRoot":"0x53580584816f617295ea26c0e17641e0120cab2f0a8ffb53a866fd53aa8e8c2d"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0x3b8e0691"},{"name":"homestead","block":1,"forkHash":"0x60949295"},{"name":"tangerineWhistle","block":2,"forkHash":"0x8bde40dd"},{"name":"spuriousDragon","block":3,"forkHash":"0xcb3a64bb"},{"name":"byzantium","block":1035301,"forkHash":"0x8d748b57"},{"name":"constantinople","block":3660663,"forkHash":"0xe49cab14"},{"name":"petersburg","block":4321234,"forkHash":"0xafec6b27"},{"name":"istanbul","block":5435345,"forkHash":"0xcbdb8838"},{"name":"berlin","block":8290928,"forkHash":"0x6910c8bd"},{"name":"london","block":8897988,"forkHash":"0x8e29f2f3"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"52.169.42.101","port":30303,"id":"a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf","location":"","comment":"IE"},{"ip":"52.3.158.184","port":30303,"id":"343149e4feefa15d882d9fe4ac7d88f885bd05ebb735e547f12e12080a9fa07c8014ca6fd7f373123488102fe5e34111f8509cf0b7de3f5b44339c9f25e87cb8","location":"","comment":"INFURA"},{"ip":"159.89.28.211","port":30303,"id":"b6b28890b006743680c52e64e0d16db57f28124885595fa03a562be1d2bf0f3a1da297d56b13da25fb992888fd556d4c1a27b1f39d531bde7de1921c90061cc6","location":"","comment":"AKASHA"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.rinkeby.ethdisco.net"]}')},1227:e=>{"use strict";e.exports=JSON.parse('{"name":"ropsten","chainId":3,"networkId":3,"defaultHardfork":"istanbul","consensus":{"type":"pow","algorithm":"ethash","ethash":{}},"comment":"PoW test network","url":"https://github.com/ethereum/ropsten","genesis":{"hash":"0x41941023680923e0fe4d74a34bdac8141f2540e3ae90623718e47d66d1ca4a2d","timestamp":null,"gasLimit":16777216,"difficulty":1048576,"nonce":"0x0000000000000042","extraData":"0x3535353535353535353535353535353535353535353535353535353535353535","stateRoot":"0x217b0bbcfb72e2d57e28f33cb361b9983513177755dc3f33ce3e7022ed62b77b"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0x30c7ddbc"},{"name":"homestead","block":0,"forkHash":"0x30c7ddbc"},{"name":"tangerineWhistle","block":0,"forkHash":"0x30c7ddbc"},{"name":"spuriousDragon","block":10,"forkHash":"0x63760190"},{"name":"byzantium","block":1700000,"forkHash":"0x3ea159c7"},{"name":"constantinople","block":4230000,"forkHash":"0x97b544f3"},{"name":"petersburg","block":4939394,"forkHash":"0xd6e2149b"},{"name":"istanbul","block":6485846,"forkHash":"0x4bc66396"},{"name":"muirGlacier","block":7117117,"forkHash":"0x6727ef90"},{"name":"berlin","block":9812189,"forkHash":"0xa157d377"},{"name":"london","block":10499401,"forkHash":"0x7119b6b3"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"52.176.7.10","port":30303,"id":"30b7ab30a01c124a6cceca36863ece12c4f5fa68e3ba9b0b51407ccc002eeed3b3102d20a88f1c1d3c3154e2449317b8ef95090e77b312d5cc39354f86d5d606","location":"","comment":"US-Azure geth"},{"ip":"52.176.100.77","port":30303,"id":"865a63255b3bb68023b6bffd5095118fcc13e79dcf014fe4e47e065c350c7cc72af2e53eff895f11ba1bbb6a2b33271c1116ee870f266618eadfc2e78aa7349c","location":"","comment":"US-Azure parity"},{"ip":"52.232.243.152","port":30303,"id":"6332792c4a00e3e4ee0926ed89e0d27ef985424d97b6a45bf0f23e51f0dcb5e66b875777506458aea7af6f9e4ffb69f43f3778ee73c81ed9d34c51c4b16b0b0f","location":"","comment":"Parity"},{"ip":"192.81.208.223","port":30303,"id":"94c15d1b9e2fe7ce56e458b9a3b672ef11894ddedd0c6f247e0f1d3487f52b66208fb4aeb8179fce6e3a749ea93ed147c37976d67af557508d199d9594c35f09","location":"","comment":"@gpip"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.ropsten.ethdisco.net"]}')},7523:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-1559","number":1559,"comment":"Fee market change for ETH 1.0 chain","url":"https://eips.ethereum.org/EIPS/eip-1559","status":"Review","minimumHardfork":"berlin","requiredEIPs":[2930],"gasConfig":{"baseFeeMaxChangeDenominator":{"v":8,"d":"Maximum base fee change denominator"},"elasticityMultiplier":{"v":2,"d":"Maximum block gas target elasticity"},"initialBaseFee":{"v":1000000000,"d":"Initial base fee on first EIP1559 block"}},"gasPrices":{},"vm":{},"pow":{}}')},3339:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2315","number":2315,"comment":"Simple subroutines for the EVM","url":"https://eips.ethereum.org/EIPS/eip-2315","status":"Draft","minimumHardfork":"istanbul","gasConfig":{},"gasPrices":{"beginsub":{"v":2,"d":"Base fee of the BEGINSUB opcode"},"returnsub":{"v":5,"d":"Base fee of the RETURNSUB opcode"},"jumpsub":{"v":10,"d":"Base fee of the JUMPSUB opcode"}},"vm":{},"pow":{}}')},6769:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2537","number":2537,"comment":"BLS12-381 precompiles","url":"https://eips.ethereum.org/EIPS/eip-2537","status":"Draft","minimumHardfork":"chainstart","gasConfig":{},"gasPrices":{"Bls12381G1AddGas":{"v":600,"d":"Gas cost of a single BLS12-381 G1 addition precompile-call"},"Bls12381G1MulGas":{"v":12000,"d":"Gas cost of a single BLS12-381 G1 multiplication precompile-call"},"Bls12381G2AddGas":{"v":4500,"d":"Gas cost of a single BLS12-381 G2 addition precompile-call"},"Bls12381G2MulGas":{"v":55000,"d":"Gas cost of a single BLS12-381 G2 multiplication precompile-call"},"Bls12381PairingBaseGas":{"v":115000,"d":"Base gas cost of BLS12-381 pairing check"},"Bls12381PairingPerPairGas":{"v":23000,"d":"Per-pair gas cost of BLS12-381 pairing check"},"Bls12381MapG1Gas":{"v":5500,"d":"Gas cost of BLS12-381 map field element to G1"},"Bls12381MapG2Gas":{"v":110000,"d":"Gas cost of BLS12-381 map field element to G2"},"Bls12381MultiExpGasDiscount":{"v":[[1,1200],[2,888],[3,764],[4,641],[5,594],[6,547],[7,500],[8,453],[9,438],[10,423],[11,408],[12,394],[13,379],[14,364],[15,349],[16,334],[17,330],[18,326],[19,322],[20,318],[21,314],[22,310],[23,306],[24,302],[25,298],[26,294],[27,289],[28,285],[29,281],[30,277],[31,273],[32,269],[33,268],[34,266],[35,265],[36,263],[37,262],[38,260],[39,259],[40,257],[41,256],[42,254],[43,253],[44,251],[45,250],[46,248],[47,247],[48,245],[49,244],[50,242],[51,241],[52,239],[53,238],[54,236],[55,235],[56,233],[57,232],[58,231],[59,229],[60,228],[61,226],[62,225],[63,223],[64,222],[65,221],[66,220],[67,219],[68,219],[69,218],[70,217],[71,216],[72,216],[73,215],[74,214],[75,213],[76,213],[77,212],[78,211],[79,211],[80,210],[81,209],[82,208],[83,208],[84,207],[85,206],[86,205],[87,205],[88,204],[89,203],[90,202],[91,202],[92,201],[93,200],[94,199],[95,199],[96,198],[97,197],[98,196],[99,196],[100,195],[101,194],[102,193],[103,193],[104,192],[105,191],[106,191],[107,190],[108,189],[109,188],[110,188],[111,187],[112,186],[113,185],[114,185],[115,184],[116,183],[117,182],[118,182],[119,181],[120,180],[121,179],[122,179],[123,178],[124,177],[125,176],[126,176],[127,175],[128,174]],"d":"Discount gas costs of calls to the MultiExp precompiles with `k` (point, scalar) pair"}},"vm":{},"pow":{}}')},7897:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2565","number":2565,"comment":"ModExp gas cost","url":"https://eips.ethereum.org/EIPS/eip-2565","status":"Last call","minimumHardfork":"byzantium","gasConfig":{},"gasPrices":{"modexpGquaddivisor":{"v":3,"d":"Gquaddivisor from modexp precompile for gas calculation"}},"vm":{},"pow":{}}')},2170:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2718","comment":"Typed Transaction Envelope","url":"https://eips.ethereum.org/EIPS/eip-2718","status":"Draft","minimumHardfork":"chainstart","gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},8436:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2929","comment":"Gas cost increases for state access opcodes","url":"https://eips.ethereum.org/EIPS/eip-2929","status":"Draft","minimumHardfork":"chainstart","gasConfig":{},"gasPrices":{"coldsload":{"v":2100,"d":"Gas cost of the first read of storage from a given location (per transaction)"},"coldaccountaccess":{"v":2600,"d":"Gas cost of the first read of a given address (per transaction)"},"warmstorageread":{"v":100,"d":"Gas cost of reading storage locations which have already loaded \'cold\'"},"sstoreCleanGasEIP2200":{"v":2900,"d":"Once per SSTORE operation from clean non-zero to something else"},"sstoreNoopGasEIP2200":{"v":100,"d":"Once per SSTORE operation if the value doesn\'t change"},"sstoreDirtyGasEIP2200":{"v":100,"d":"Once per SSTORE operation if a dirty value is changed"},"sstoreInitRefundEIP2200":{"v":19900,"d":"Once per SSTORE operation for resetting to the original zero value"},"sstoreCleanRefundEIP2200":{"v":4900,"d":"Once per SSTORE operation for resetting to the original non-zero value"},"call":{"v":0,"d":"Base fee of the CALL opcode"},"callcode":{"v":0,"d":"Base fee of the CALLCODE opcode"},"delegatecall":{"v":0,"d":"Base fee of the DELEGATECALL opcode"},"staticcall":{"v":0,"d":"Base fee of the STATICCALL opcode"},"balance":{"v":0,"d":"Base fee of the BALANCE opcode"},"extcodesize":{"v":0,"d":"Base fee of the EXTCODESIZE opcode"},"extcodecopy":{"v":0,"d":"Base fee of the EXTCODECOPY opcode"},"extcodehash":{"v":0,"d":"Base fee of the EXTCODEHASH opcode"},"sload":{"v":0,"d":"Base fee of the SLOAD opcode"},"sstore":{"v":0,"d":"Base fee of the SSTORE opcode"}},"vm":{},"pow":{}}')},6213:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2930","comment":"Optional access lists","url":"https://eips.ethereum.org/EIPS/eip-2930","status":"Draft","minimumHardfork":"istanbul","requiredEIPs":[2718,2929],"gasConfig":{},"gasPrices":{"accessListStorageKeyCost":{"v":1900,"d":"Gas cost per storage key in an Access List transaction"},"accessListAddressCost":{"v":2400,"d":"Gas cost per storage key in an Access List transaction"}},"vm":{},"pow":{}}')},5491:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3198","number":3198,"comment":"BASEFEE opcode","url":"https://eips.ethereum.org/EIPS/eip-3198","status":"Review","minimumHardfork":"london","gasConfig":{},"gasPrices":{"basefee":{"v":2,"d":"Gas cost of the BASEFEE opcode"}},"vm":{},"pow":{}}')},7852:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3529","comment":"Reduction in refunds","url":"https://eips.ethereum.org/EIPS/eip-3529","status":"Draft","minimumHardfork":"berlin","requiredEIPs":[2929],"gasConfig":{"maxRefundQuotient":{"v":5,"d":"Maximum refund quotient; max tx refund is min(tx.gasUsed/maxRefundQuotient, tx.gasRefund)"}},"gasPrices":{"selfdestructRefund":{"v":0,"d":"Refunded following a selfdestruct operation"},"sstoreClearRefundEIP2200":{"v":4800,"d":"Once per SSTORE operation for clearing an originally existing storage slot"}},"vm":{},"pow":{}}')},1871:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3541","comment":"Reject new contracts starting with the 0xEF byte","url":"https://eips.ethereum.org/EIPS/eip-3541","status":"Draft","minimumHardfork":"berlin","requiredEIPs":[],"gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},7225:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3554","comment":"Reduction in refunds","url":"Difficulty Bomb Delay to December 1st 2021","status":"Draft","minimumHardfork":"muirGlacier","requiredEIPs":[],"gasConfig":{},"gasPrices":{},"vm":{},"pow":{"difficultyBombDelay":{"v":9500000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},8571:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3675","number":3675,"comment":"Upgrade consensus to Proof-of-Stake","url":"https://eips.ethereum.org/EIPS/eip-3675","status":"Draft","minimumHardfork":"london","requiredEIPs":[],"gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},15:e=>{"use strict";e.exports=JSON.parse('{"name":"berlin","comment":"HF targeted for July 2020 following the Muir Glacier HF","url":"https://eips.ethereum.org/EIPS/eip-2070","status":"Draft","eips":[2565,2929,2718,2930]}')},6985:e=>{"use strict";e.exports=JSON.parse('{"name":"byzantium","comment":"Hardfork with new precompiles, instructions and other protocol changes","url":"https://eips.ethereum.org/EIPS/eip-609","status":"Final","gasConfig":{},"gasPrices":{"modexpGquaddivisor":{"v":20,"d":"Gquaddivisor from modexp precompile for gas calculation"},"ecAdd":{"v":500,"d":"Gas costs for curve addition precompile"},"ecMul":{"v":40000,"d":"Gas costs for curve multiplication precompile"},"ecPairing":{"v":100000,"d":"Base gas costs for curve pairing precompile"},"ecPairingWord":{"v":80000,"d":"Gas costs regarding curve pairing precompile input length"},"revert":{"v":0,"d":"Base fee of the REVERT opcode"},"staticcall":{"v":700,"d":"Base fee of the STATICCALL opcode"},"returndatasize":{"v":2,"d":"Base fee of the RETURNDATASIZE opcode"},"returndatacopy":{"v":3,"d":"Base fee of the RETURNDATACOPY opcode"}},"vm":{},"pow":{"minerReward":{"v":"3000000000000000000","d":"the amount a miner get rewarded for mining a block"},"difficultyBombDelay":{"v":3000000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},114:e=>{"use strict";e.exports=JSON.parse('{"name":"chainstart","comment":"Start of the Ethereum main chain","url":"","status":"","gasConfig":{"minGasLimit":{"v":5000,"d":"Minimum the gas limit may ever be"},"gasLimitBoundDivisor":{"v":1024,"d":"The bound divisor of the gas limit, used in update calculations"},"maxRefundQuotient":{"v":2,"d":"Maximum refund quotient; max tx refund is min(tx.gasUsed/maxRefundQuotient, tx.gasRefund)"}},"gasPrices":{"base":{"v":2,"d":"Gas base cost, used e.g. for ChainID opcode (Istanbul)"},"tierStep":{"v":[0,2,3,5,8,10,20],"d":"Once per operation, for a selection of them"},"exp":{"v":10,"d":"Base fee of the EXP opcode"},"expByte":{"v":10,"d":"Times ceil(log256(exponent)) for the EXP instruction"},"sha3":{"v":30,"d":"Base fee of the SHA3 opcode"},"sha3Word":{"v":6,"d":"Once per word of the SHA3 operation\'s data"},"sload":{"v":50,"d":"Base fee of the SLOAD opcode"},"sstoreSet":{"v":20000,"d":"Once per SSTORE operation if the zeroness changes from zero"},"sstoreReset":{"v":5000,"d":"Once per SSTORE operation if the zeroness does not change from zero"},"sstoreRefund":{"v":15000,"d":"Once per SSTORE operation if the zeroness changes to zero"},"jumpdest":{"v":1,"d":"Base fee of the JUMPDEST opcode"},"log":{"v":375,"d":"Base fee of the LOG opcode"},"logData":{"v":8,"d":"Per byte in a LOG* operation\'s data"},"logTopic":{"v":375,"d":"Multiplied by the * of the LOG*, per LOG transaction. e.g. LOG0 incurs 0 * c_txLogTopicGas, LOG4 incurs 4 * c_txLogTopicGas"},"create":{"v":32000,"d":"Base fee of the CREATE opcode"},"call":{"v":40,"d":"Base fee of the CALL opcode"},"callStipend":{"v":2300,"d":"Free gas given at beginning of call"},"callValueTransfer":{"v":9000,"d":"Paid for CALL when the value transfor is non-zero"},"callNewAccount":{"v":25000,"d":"Paid for CALL when the destination address didn\'t exist prior"},"selfdestructRefund":{"v":24000,"d":"Refunded following a selfdestruct operation"},"memory":{"v":3,"d":"Times the address of the (highest referenced byte in memory + 1). NOTE: referencing happens on read, write and in instructions such as RETURN and CALL"},"quadCoeffDiv":{"v":512,"d":"Divisor for the quadratic particle of the memory cost equation"},"createData":{"v":200,"d":""},"tx":{"v":21000,"d":"Per transaction. NOTE: Not payable on data of calls between transactions"},"txCreation":{"v":32000,"d":"The cost of creating a contract via tx"},"txDataZero":{"v":4,"d":"Per byte of data attached to a transaction that equals zero. NOTE: Not payable on data of calls between transactions"},"txDataNonZero":{"v":68,"d":"Per byte of data attached to a transaction that is not equal to zero. NOTE: Not payable on data of calls between transactions"},"copy":{"v":3,"d":"Multiplied by the number of 32-byte words that are copied (round up) for any *COPY operation and added"},"ecRecover":{"v":3000,"d":""},"sha256":{"v":60,"d":""},"sha256Word":{"v":12,"d":""},"ripemd160":{"v":600,"d":""},"ripemd160Word":{"v":120,"d":""},"identity":{"v":15,"d":""},"identityWord":{"v":3,"d":""},"stop":{"v":0,"d":"Base fee of the STOP opcode"},"add":{"v":3,"d":"Base fee of the ADD opcode"},"mul":{"v":5,"d":"Base fee of the MUL opcode"},"sub":{"v":3,"d":"Base fee of the SUB opcode"},"div":{"v":5,"d":"Base fee of the DIV opcode"},"sdiv":{"v":5,"d":"Base fee of the SDIV opcode"},"mod":{"v":5,"d":"Base fee of the MOD opcode"},"smod":{"v":5,"d":"Base fee of the SMOD opcode"},"addmod":{"v":8,"d":"Base fee of the ADDMOD opcode"},"mulmod":{"v":8,"d":"Base fee of the MULMOD opcode"},"signextend":{"v":5,"d":"Base fee of the SIGNEXTEND opcode"},"lt":{"v":3,"d":"Base fee of the LT opcode"},"gt":{"v":3,"d":"Base fee of the GT opcode"},"slt":{"v":3,"d":"Base fee of the SLT opcode"},"sgt":{"v":3,"d":"Base fee of the SGT opcode"},"eq":{"v":3,"d":"Base fee of the EQ opcode"},"iszero":{"v":3,"d":"Base fee of the ISZERO opcode"},"and":{"v":3,"d":"Base fee of the AND opcode"},"or":{"v":3,"d":"Base fee of the OR opcode"},"xor":{"v":3,"d":"Base fee of the XOR opcode"},"not":{"v":3,"d":"Base fee of the NOT opcode"},"byte":{"v":3,"d":"Base fee of the BYTE opcode"},"address":{"v":2,"d":"Base fee of the ADDRESS opcode"},"balance":{"v":20,"d":"Base fee of the BALANCE opcode"},"origin":{"v":2,"d":"Base fee of the ORIGIN opcode"},"caller":{"v":2,"d":"Base fee of the CALLER opcode"},"callvalue":{"v":2,"d":"Base fee of the CALLVALUE opcode"},"calldataload":{"v":3,"d":"Base fee of the CALLDATALOAD opcode"},"calldatasize":{"v":2,"d":"Base fee of the CALLDATASIZE opcode"},"calldatacopy":{"v":3,"d":"Base fee of the CALLDATACOPY opcode"},"codesize":{"v":2,"d":"Base fee of the CODESIZE opcode"},"codecopy":{"v":3,"d":"Base fee of the CODECOPY opcode"},"gasprice":{"v":2,"d":"Base fee of the GASPRICE opcode"},"extcodesize":{"v":20,"d":"Base fee of the EXTCODESIZE opcode"},"extcodecopy":{"v":20,"d":"Base fee of the EXTCODECOPY opcode"},"blockhash":{"v":20,"d":"Base fee of the BLOCKHASH opcode"},"coinbase":{"v":2,"d":"Base fee of the COINBASE opcode"},"timestamp":{"v":2,"d":"Base fee of the TIMESTAMP opcode"},"number":{"v":2,"d":"Base fee of the NUMBER opcode"},"difficulty":{"v":2,"d":"Base fee of the DIFFICULTY opcode"},"gaslimit":{"v":2,"d":"Base fee of the GASLIMIT opcode"},"pop":{"v":2,"d":"Base fee of the POP opcode"},"mload":{"v":3,"d":"Base fee of the MLOAD opcode"},"mstore":{"v":3,"d":"Base fee of the MSTORE opcode"},"mstore8":{"v":3,"d":"Base fee of the MSTORE8 opcode"},"sstore":{"v":0,"d":"Base fee of the SSTORE opcode"},"jump":{"v":8,"d":"Base fee of the JUMP opcode"},"jumpi":{"v":10,"d":"Base fee of the JUMPI opcode"},"pc":{"v":2,"d":"Base fee of the PC opcode"},"msize":{"v":2,"d":"Base fee of the MSIZE opcode"},"gas":{"v":2,"d":"Base fee of the GAS opcode"},"push":{"v":3,"d":"Base fee of the PUSH opcode"},"dup":{"v":3,"d":"Base fee of the DUP opcode"},"swap":{"v":3,"d":"Base fee of the SWAP opcode"},"callcode":{"v":40,"d":"Base fee of the CALLCODE opcode"},"return":{"v":0,"d":"Base fee of the RETURN opcode"},"invalid":{"v":0,"d":"Base fee of the INVALID opcode"},"selfdestruct":{"v":0,"d":"Base fee of the SELFDESTRUCT opcode"}},"vm":{"stackLimit":{"v":1024,"d":"Maximum size of VM stack allowed"},"callCreateDepth":{"v":1024,"d":"Maximum depth of call/create stack"},"maxExtraDataSize":{"v":32,"d":"Maximum size extra data may be after Genesis"}},"pow":{"minimumDifficulty":{"v":131072,"d":"The minimum that the difficulty may ever be"},"difficultyBoundDivisor":{"v":2048,"d":"The bound divisor of the difficulty, used in the update calculations"},"durationLimit":{"v":13,"d":"The decision boundary on the blocktime duration used to determine whether difficulty should go up or not"},"epochDuration":{"v":30000,"d":"Duration between proof-of-work epochs"},"timebombPeriod":{"v":100000,"d":"Exponential difficulty timebomb period"},"minerReward":{"v":"5000000000000000000","d":"the amount a miner get rewarded for mining a block"},"difficultyBombDelay":{"v":0,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},5993:e=>{"use strict";e.exports=JSON.parse('{"name":"constantinople","comment":"Postponed hardfork including EIP-1283 (SSTORE gas metering changes)","url":"https://eips.ethereum.org/EIPS/eip-1013","status":"Final","gasConfig":{},"gasPrices":{"netSstoreNoopGas":{"v":200,"d":"Once per SSTORE operation if the value doesn\'t change"},"netSstoreInitGas":{"v":20000,"d":"Once per SSTORE operation from clean zero"},"netSstoreCleanGas":{"v":5000,"d":"Once per SSTORE operation from clean non-zero"},"netSstoreDirtyGas":{"v":200,"d":"Once per SSTORE operation from dirty"},"netSstoreClearRefund":{"v":15000,"d":"Once per SSTORE operation for clearing an originally existing storage slot"},"netSstoreResetRefund":{"v":4800,"d":"Once per SSTORE operation for resetting to the original non-zero value"},"netSstoreResetClearRefund":{"v":19800,"d":"Once per SSTORE operation for resetting to the original zero value"},"shl":{"v":3,"d":"Base fee of the SHL opcode"},"shr":{"v":3,"d":"Base fee of the SHR opcode"},"sar":{"v":3,"d":"Base fee of the SAR opcode"},"extcodehash":{"v":400,"d":"Base fee of the EXTCODEHASH opcode"},"create2":{"v":32000,"d":"Base fee of the CREATE2 opcode"}},"vm":{},"pow":{"minerReward":{"v":"2000000000000000000","d":"The amount a miner gets rewarded for mining a block"},"difficultyBombDelay":{"v":5000000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},7197:e=>{"use strict";e.exports=JSON.parse('{"name":"dao","comment":"DAO rescue hardfork","url":"https://eips.ethereum.org/EIPS/eip-779","status":"Final","gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},2800:e=>{"use strict";e.exports=JSON.parse('{"name":"homestead","comment":"Homestead hardfork with protocol and network changes","url":"https://eips.ethereum.org/EIPS/eip-606","status":"Final","gasConfig":{},"gasPrices":{"delegatecall":{"v":40,"d":"Base fee of the DELEGATECALL opcode"}},"vm":{},"pow":{}}')},3166:e=>{"use strict";e.exports=JSON.parse('{"name":"istanbul","comment":"HF targeted for December 2019 following the Constantinople/Petersburg HF","url":"https://eips.ethereum.org/EIPS/eip-1679","status":"Draft","gasConfig":{},"gasPrices":{"blake2Round":{"v":1,"d":"Gas cost per round for the Blake2 F precompile"},"ecAdd":{"v":150,"d":"Gas costs for curve addition precompile"},"ecMul":{"v":6000,"d":"Gas costs for curve multiplication precompile"},"ecPairing":{"v":45000,"d":"Base gas costs for curve pairing precompile"},"ecPairingWord":{"v":34000,"d":"Gas costs regarding curve pairing precompile input length"},"txDataNonZero":{"v":16,"d":"Per byte of data attached to a transaction that is not equal to zero. NOTE: Not payable on data of calls between transactions"},"sstoreSentryGasEIP2200":{"v":2300,"d":"Minimum gas required to be present for an SSTORE call, not consumed"},"sstoreNoopGasEIP2200":{"v":800,"d":"Once per SSTORE operation if the value doesn\'t change"},"sstoreDirtyGasEIP2200":{"v":800,"d":"Once per SSTORE operation if a dirty value is changed"},"sstoreInitGasEIP2200":{"v":20000,"d":"Once per SSTORE operation from clean zero to non-zero"},"sstoreInitRefundEIP2200":{"v":19200,"d":"Once per SSTORE operation for resetting to the original zero value"},"sstoreCleanGasEIP2200":{"v":5000,"d":"Once per SSTORE operation from clean non-zero to something else"},"sstoreCleanRefundEIP2200":{"v":4200,"d":"Once per SSTORE operation for resetting to the original non-zero value"},"sstoreClearRefundEIP2200":{"v":15000,"d":"Once per SSTORE operation for clearing an originally existing storage slot"},"balance":{"v":700,"d":"Base fee of the BALANCE opcode"},"extcodehash":{"v":700,"d":"Base fee of the EXTCODEHASH opcode"},"chainid":{"v":2,"d":"Base fee of the CHAINID opcode"},"selfbalance":{"v":5,"d":"Base fee of the SELFBALANCE opcode"},"sload":{"v":800,"d":"Base fee of the SLOAD opcode"}},"vm":{},"pow":{}}')},1250:e=>{"use strict";e.exports=JSON.parse('{"name":"london","comment":"HF targeted for July 2021 following the Berlin fork","url":"https://github.com/ethereum/eth1.0-specs/blob/master/network-upgrades/mainnet-upgrades/london.md","status":"Draft","eips":[1559,3198,3529,3541]}')},8648:e=>{"use strict";e.exports=JSON.parse('{"name":"merge","comment":"Hardfork to upgrade the consensus mechanism to Proof-of-Stake","url":"https://github.com/ethereum/pm/issues/361","status":"pre-Draft","consensus":{"type":"pos","algorithm":"casper","casper":{}},"eips":[3675]}')},2946:e=>{"use strict";e.exports=JSON.parse('{"name":"muirGlacier","comment":"HF to delay the difficulty bomb","url":"https://eips.ethereum.org/EIPS/eip-2384","status":"Final","gasConfig":{},"gasPrices":{},"vm":{},"pow":{"difficultyBombDelay":{"v":9000000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},4064:e=>{"use strict";e.exports=JSON.parse('{"name":"petersburg","comment":"Aka constantinopleFix, removes EIP-1283, activate together with or after constantinople","url":"https://eips.ethereum.org/EIPS/eip-1716","status":"Draft","gasConfig":{},"gasPrices":{"netSstoreNoopGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreInitGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreCleanGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreDirtyGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreClearRefund":{"v":null,"d":"Removed along EIP-1283"},"netSstoreResetRefund":{"v":null,"d":"Removed along EIP-1283"},"netSstoreResetClearRefund":{"v":null,"d":"Removed along EIP-1283"}},"vm":{},"pow":{}}')},5553:e=>{"use strict";e.exports=JSON.parse('{"name":"shanghai","comment":"Next feature hardfork after the London HF","url":"https://github.com/ethereum/pm/issues/356","status":"Pre-Draft","eips":[]}')},716:e=>{"use strict";e.exports=JSON.parse('{"name":"spuriousDragon","comment":"HF with EIPs for simple replay attack protection, EXP cost increase, state trie clearing, contract code size limit","url":"https://eips.ethereum.org/EIPS/eip-607","status":"Final","gasConfig":{},"gasPrices":{"expByte":{"v":50,"d":"Times ceil(log256(exponent)) for the EXP instruction"}},"vm":{"maxCodeSize":{"v":24576,"d":"Maximum length of contract code"}},"pow":{}}')},2302:e=>{"use strict";e.exports=JSON.parse('{"name":"tangerineWhistle","comment":"Hardfork with gas cost changes for IO-heavy operations","url":"https://eips.ethereum.org/EIPS/eip-608","status":"Final","gasConfig":{},"gasPrices":{"sload":{"v":200,"d":"Once per SLOAD operation"},"call":{"v":700,"d":"Once per CALL operation & message call transaction"},"extcodesize":{"v":700,"d":"Base fee of the EXTCODESIZE opcode"},"extcodecopy":{"v":700,"d":"Base fee of the EXTCODECOPY opcode"},"balance":{"v":400,"d":"Base fee of the BALANCE opcode"},"delegatecall":{"v":700,"d":"Base fee of the DELEGATECALL opcode"},"callcode":{"v":700,"d":"Base fee of the CALLCODE opcode"},"selfdestruct":{"v":5000,"d":"Base fee of the SELFDESTRUCT opcode"}},"vm":{},"pow":{}}')},4946:e=>{"use strict";e.exports=JSON.parse('{"aes-128-ecb":{"cipher":"AES","key":128,"iv":0,"mode":"ECB","type":"block"},"aes-192-ecb":{"cipher":"AES","key":192,"iv":0,"mode":"ECB","type":"block"},"aes-256-ecb":{"cipher":"AES","key":256,"iv":0,"mode":"ECB","type":"block"},"aes-128-cbc":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes-192-cbc":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes-256-cbc":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes128":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes192":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes256":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes-128-cfb":{"cipher":"AES","key":128,"iv":16,"mode":"CFB","type":"stream"},"aes-192-cfb":{"cipher":"AES","key":192,"iv":16,"mode":"CFB","type":"stream"},"aes-256-cfb":{"cipher":"AES","key":256,"iv":16,"mode":"CFB","type":"stream"},"aes-128-cfb8":{"cipher":"AES","key":128,"iv":16,"mode":"CFB8","type":"stream"},"aes-192-cfb8":{"cipher":"AES","key":192,"iv":16,"mode":"CFB8","type":"stream"},"aes-256-cfb8":{"cipher":"AES","key":256,"iv":16,"mode":"CFB8","type":"stream"},"aes-128-cfb1":{"cipher":"AES","key":128,"iv":16,"mode":"CFB1","type":"stream"},"aes-192-cfb1":{"cipher":"AES","key":192,"iv":16,"mode":"CFB1","type":"stream"},"aes-256-cfb1":{"cipher":"AES","key":256,"iv":16,"mode":"CFB1","type":"stream"},"aes-128-ofb":{"cipher":"AES","key":128,"iv":16,"mode":"OFB","type":"stream"},"aes-192-ofb":{"cipher":"AES","key":192,"iv":16,"mode":"OFB","type":"stream"},"aes-256-ofb":{"cipher":"AES","key":256,"iv":16,"mode":"OFB","type":"stream"},"aes-128-ctr":{"cipher":"AES","key":128,"iv":16,"mode":"CTR","type":"stream"},"aes-192-ctr":{"cipher":"AES","key":192,"iv":16,"mode":"CTR","type":"stream"},"aes-256-ctr":{"cipher":"AES","key":256,"iv":16,"mode":"CTR","type":"stream"},"aes-128-gcm":{"cipher":"AES","key":128,"iv":12,"mode":"GCM","type":"auth"},"aes-192-gcm":{"cipher":"AES","key":192,"iv":12,"mode":"GCM","type":"auth"},"aes-256-gcm":{"cipher":"AES","key":256,"iv":12,"mode":"GCM","type":"auth"}}')},5207:e=>{"use strict";e.exports=JSON.parse('{"sha224WithRSAEncryption":{"sign":"rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"RSA-SHA224":{"sign":"ecdsa/rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"sha256WithRSAEncryption":{"sign":"rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"RSA-SHA256":{"sign":"ecdsa/rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"sha384WithRSAEncryption":{"sign":"rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"RSA-SHA384":{"sign":"ecdsa/rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"sha512WithRSAEncryption":{"sign":"rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA512":{"sign":"ecdsa/rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA1":{"sign":"rsa","hash":"sha1","id":"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{"sign":"ecdsa","hash":"sha1","id":""},"sha256":{"sign":"ecdsa","hash":"sha256","id":""},"sha224":{"sign":"ecdsa","hash":"sha224","id":""},"sha384":{"sign":"ecdsa","hash":"sha384","id":""},"sha512":{"sign":"ecdsa","hash":"sha512","id":""},"DSA-SHA":{"sign":"dsa","hash":"sha1","id":""},"DSA-SHA1":{"sign":"dsa","hash":"sha1","id":""},"DSA":{"sign":"dsa","hash":"sha1","id":""},"DSA-WITH-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-WITH-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-WITH-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-WITH-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-RIPEMD160":{"sign":"dsa","hash":"rmd160","id":""},"ripemd160WithRSA":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"RSA-RIPEMD160":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"md5WithRSAEncryption":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"},"RSA-MD5":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"}}')},1308:e=>{"use strict";e.exports=JSON.parse('{"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}')},3630:e=>{"use strict";e.exports=JSON.parse('{"identity":0,"ip4":4,"tcp":6,"sha1":17,"sha2-256":18,"sha2-512":19,"sha3-512":20,"sha3-384":21,"sha3-256":22,"sha3-224":23,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"blake3":30,"dccp":33,"murmur3-128":34,"murmur3-32":35,"ip6":41,"ip6zone":42,"path":47,"multicodec":48,"multihash":49,"multiaddr":50,"multibase":51,"dns":53,"dns4":54,"dns6":55,"dnsaddr":56,"protobuf":80,"cbor":81,"raw":85,"dbl-sha2-256":86,"rlp":96,"bencode":99,"dag-pb":112,"dag-cbor":113,"libp2p-key":114,"git-raw":120,"torrent-info":123,"torrent-file":124,"leofcoin-block":129,"leofcoin-tx":130,"leofcoin-pr":131,"sctp":132,"dag-jose":133,"dag-cose":134,"eth-block":144,"eth-block-list":145,"eth-tx-trie":146,"eth-tx":147,"eth-tx-receipt-trie":148,"eth-tx-receipt":149,"eth-state-trie":150,"eth-account-snapshot":151,"eth-storage-trie":152,"bitcoin-block":176,"bitcoin-tx":177,"bitcoin-witness-commitment":178,"zcash-block":192,"zcash-tx":193,"stellar-block":208,"stellar-tx":209,"md4":212,"md5":213,"bmt":214,"decred-block":224,"decred-tx":225,"ipld-ns":226,"ipfs-ns":227,"swarm-ns":228,"ipns-ns":229,"zeronet":230,"secp256k1-pub":231,"bls12_381-g1-pub":234,"bls12_381-g2-pub":235,"x25519-pub":236,"ed25519-pub":237,"dash-block":240,"dash-tx":241,"swarm-manifest":250,"swarm-feed":251,"udp":273,"p2p-webrtc-star":275,"p2p-webrtc-direct":276,"p2p-stardust":277,"p2p-circuit":290,"dag-json":297,"udt":301,"utp":302,"unix":400,"p2p":421,"ipfs":421,"https":443,"onion":444,"onion3":445,"garlic64":446,"garlic32":447,"tls":448,"quic":460,"ws":477,"wss":478,"p2p-websocket-star":479,"http":480,"json":512,"messagepack":513,"libp2p-peer-record":769,"sha2-256-trunc254-padded":4114,"ripemd-128":4178,"ripemd-160":4179,"ripemd-256":4180,"ripemd-320":4181,"x11":4352,"sm3-256":21325,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"skein256-8":45825,"skein256-16":45826,"skein256-24":45827,"skein256-32":45828,"skein256-40":45829,"skein256-48":45830,"skein256-56":45831,"skein256-64":45832,"skein256-72":45833,"skein256-80":45834,"skein256-88":45835,"skein256-96":45836,"skein256-104":45837,"skein256-112":45838,"skein256-120":45839,"skein256-128":45840,"skein256-136":45841,"skein256-144":45842,"skein256-152":45843,"skein256-160":45844,"skein256-168":45845,"skein256-176":45846,"skein256-184":45847,"skein256-192":45848,"skein256-200":45849,"skein256-208":45850,"skein256-216":45851,"skein256-224":45852,"skein256-232":45853,"skein256-240":45854,"skein256-248":45855,"skein256-256":45856,"skein512-8":45857,"skein512-16":45858,"skein512-24":45859,"skein512-32":45860,"skein512-40":45861,"skein512-48":45862,"skein512-56":45863,"skein512-64":45864,"skein512-72":45865,"skein512-80":45866,"skein512-88":45867,"skein512-96":45868,"skein512-104":45869,"skein512-112":45870,"skein512-120":45871,"skein512-128":45872,"skein512-136":45873,"skein512-144":45874,"skein512-152":45875,"skein512-160":45876,"skein512-168":45877,"skein512-176":45878,"skein512-184":45879,"skein512-192":45880,"skein512-200":45881,"skein512-208":45882,"skein512-216":45883,"skein512-224":45884,"skein512-232":45885,"skein512-240":45886,"skein512-248":45887,"skein512-256":45888,"skein512-264":45889,"skein512-272":45890,"skein512-280":45891,"skein512-288":45892,"skein512-296":45893,"skein512-304":45894,"skein512-312":45895,"skein512-320":45896,"skein512-328":45897,"skein512-336":45898,"skein512-344":45899,"skein512-352":45900,"skein512-360":45901,"skein512-368":45902,"skein512-376":45903,"skein512-384":45904,"skein512-392":45905,"skein512-400":45906,"skein512-408":45907,"skein512-416":45908,"skein512-424":45909,"skein512-432":45910,"skein512-440":45911,"skein512-448":45912,"skein512-456":45913,"skein512-464":45914,"skein512-472":45915,"skein512-480":45916,"skein512-488":45917,"skein512-496":45918,"skein512-504":45919,"skein512-512":45920,"skein1024-8":45921,"skein1024-16":45922,"skein1024-24":45923,"skein1024-32":45924,"skein1024-40":45925,"skein1024-48":45926,"skein1024-56":45927,"skein1024-64":45928,"skein1024-72":45929,"skein1024-80":45930,"skein1024-88":45931,"skein1024-96":45932,"skein1024-104":45933,"skein1024-112":45934,"skein1024-120":45935,"skein1024-128":45936,"skein1024-136":45937,"skein1024-144":45938,"skein1024-152":45939,"skein1024-160":45940,"skein1024-168":45941,"skein1024-176":45942,"skein1024-184":45943,"skein1024-192":45944,"skein1024-200":45945,"skein1024-208":45946,"skein1024-216":45947,"skein1024-224":45948,"skein1024-232":45949,"skein1024-240":45950,"skein1024-248":45951,"skein1024-256":45952,"skein1024-264":45953,"skein1024-272":45954,"skein1024-280":45955,"skein1024-288":45956,"skein1024-296":45957,"skein1024-304":45958,"skein1024-312":45959,"skein1024-320":45960,"skein1024-328":45961,"skein1024-336":45962,"skein1024-344":45963,"skein1024-352":45964,"skein1024-360":45965,"skein1024-368":45966,"skein1024-376":45967,"skein1024-384":45968,"skein1024-392":45969,"skein1024-400":45970,"skein1024-408":45971,"skein1024-416":45972,"skein1024-424":45973,"skein1024-432":45974,"skein1024-440":45975,"skein1024-448":45976,"skein1024-456":45977,"skein1024-464":45978,"skein1024-472":45979,"skein1024-480":45980,"skein1024-488":45981,"skein1024-496":45982,"skein1024-504":45983,"skein1024-512":45984,"skein1024-520":45985,"skein1024-528":45986,"skein1024-536":45987,"skein1024-544":45988,"skein1024-552":45989,"skein1024-560":45990,"skein1024-568":45991,"skein1024-576":45992,"skein1024-584":45993,"skein1024-592":45994,"skein1024-600":45995,"skein1024-608":45996,"skein1024-616":45997,"skein1024-624":45998,"skein1024-632":45999,"skein1024-640":46000,"skein1024-648":46001,"skein1024-656":46002,"skein1024-664":46003,"skein1024-672":46004,"skein1024-680":46005,"skein1024-688":46006,"skein1024-696":46007,"skein1024-704":46008,"skein1024-712":46009,"skein1024-720":46010,"skein1024-728":46011,"skein1024-736":46012,"skein1024-744":46013,"skein1024-752":46014,"skein1024-760":46015,"skein1024-768":46016,"skein1024-776":46017,"skein1024-784":46018,"skein1024-792":46019,"skein1024-800":46020,"skein1024-808":46021,"skein1024-816":46022,"skein1024-824":46023,"skein1024-832":46024,"skein1024-840":46025,"skein1024-848":46026,"skein1024-856":46027,"skein1024-864":46028,"skein1024-872":46029,"skein1024-880":46030,"skein1024-888":46031,"skein1024-896":46032,"skein1024-904":46033,"skein1024-912":46034,"skein1024-920":46035,"skein1024-928":46036,"skein1024-936":46037,"skein1024-944":46038,"skein1024-952":46039,"skein1024-960":46040,"skein1024-968":46041,"skein1024-976":46042,"skein1024-984":46043,"skein1024-992":46044,"skein1024-1000":46045,"skein1024-1008":46046,"skein1024-1016":46047,"skein1024-1024":46048,"poseidon-bls12_381-a2-fc1":46081,"poseidon-bls12_381-a2-fc1-sc":46082,"zeroxcert-imprint-256":52753,"fil-commitment-unsealed":61697,"fil-commitment-sealed":61698,"holochain-adr-v0":8417572,"holochain-adr-v1":8483108,"holochain-key-v0":9728292,"holochain-key-v1":9793828,"holochain-sig-v0":10645796,"holochain-sig-v1":10711332}')},9799:e=>{"use strict";e.exports=JSON.parse('{"modp1":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},"modp2":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},"modp5":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},"modp14":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},"modp15":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},"modp16":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},"modp17":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},"modp18":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}')},8597:e=>{"use strict";e.exports={i8:"6.5.4"}},4070:e=>{"use strict";e.exports=JSON.parse('{"identity":0,"ip4":4,"tcp":6,"sha1":17,"sha2-256":18,"sha2-512":19,"sha3-512":20,"sha3-384":21,"sha3-256":22,"sha3-224":23,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"dccp":33,"murmur3-128":34,"murmur3-32":35,"ip6":41,"ip6zone":42,"path":47,"multicodec":48,"multihash":49,"multiaddr":50,"multibase":51,"dns":53,"dns4":54,"dns6":55,"dnsaddr":56,"protobuf":80,"cbor":81,"raw":85,"dbl-sha2-256":86,"rlp":96,"bencode":99,"dag-pb":112,"dag-cbor":113,"libp2p-key":114,"git-raw":120,"torrent-info":123,"torrent-file":124,"leofcoin-block":129,"leofcoin-tx":130,"leofcoin-pr":131,"sctp":132,"eth-block":144,"eth-block-list":145,"eth-tx-trie":146,"eth-tx":147,"eth-tx-receipt-trie":148,"eth-tx-receipt":149,"eth-state-trie":150,"eth-account-snapshot":151,"eth-storage-trie":152,"bitcoin-block":176,"bitcoin-tx":177,"zcash-block":192,"zcash-tx":193,"stellar-block":208,"stellar-tx":209,"md4":212,"md5":213,"bmt":214,"decred-block":224,"decred-tx":225,"ipld-ns":226,"ipfs-ns":227,"swarm-ns":228,"ipns-ns":229,"zeronet":230,"ed25519-pub":237,"dash-block":240,"dash-tx":241,"swarm-manifest":250,"swarm-feed":251,"udp":273,"p2p-webrtc-star":275,"p2p-webrtc-direct":276,"p2p-stardust":277,"p2p-circuit":290,"dag-json":297,"udt":301,"utp":302,"unix":400,"p2p":421,"ipfs":421,"https":443,"onion":444,"onion3":445,"garlic64":446,"garlic32":447,"tls":448,"quic":460,"ws":477,"wss":478,"p2p-websocket-star":479,"http":480,"json":512,"messagepack":513,"x11":4352,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"skein256-8":45825,"skein256-16":45826,"skein256-24":45827,"skein256-32":45828,"skein256-40":45829,"skein256-48":45830,"skein256-56":45831,"skein256-64":45832,"skein256-72":45833,"skein256-80":45834,"skein256-88":45835,"skein256-96":45836,"skein256-104":45837,"skein256-112":45838,"skein256-120":45839,"skein256-128":45840,"skein256-136":45841,"skein256-144":45842,"skein256-152":45843,"skein256-160":45844,"skein256-168":45845,"skein256-176":45846,"skein256-184":45847,"skein256-192":45848,"skein256-200":45849,"skein256-208":45850,"skein256-216":45851,"skein256-224":45852,"skein256-232":45853,"skein256-240":45854,"skein256-248":45855,"skein256-256":45856,"skein512-8":45857,"skein512-16":45858,"skein512-24":45859,"skein512-32":45860,"skein512-40":45861,"skein512-48":45862,"skein512-56":45863,"skein512-64":45864,"skein512-72":45865,"skein512-80":45866,"skein512-88":45867,"skein512-96":45868,"skein512-104":45869,"skein512-112":45870,"skein512-120":45871,"skein512-128":45872,"skein512-136":45873,"skein512-144":45874,"skein512-152":45875,"skein512-160":45876,"skein512-168":45877,"skein512-176":45878,"skein512-184":45879,"skein512-192":45880,"skein512-200":45881,"skein512-208":45882,"skein512-216":45883,"skein512-224":45884,"skein512-232":45885,"skein512-240":45886,"skein512-248":45887,"skein512-256":45888,"skein512-264":45889,"skein512-272":45890,"skein512-280":45891,"skein512-288":45892,"skein512-296":45893,"skein512-304":45894,"skein512-312":45895,"skein512-320":45896,"skein512-328":45897,"skein512-336":45898,"skein512-344":45899,"skein512-352":45900,"skein512-360":45901,"skein512-368":45902,"skein512-376":45903,"skein512-384":45904,"skein512-392":45905,"skein512-400":45906,"skein512-408":45907,"skein512-416":45908,"skein512-424":45909,"skein512-432":45910,"skein512-440":45911,"skein512-448":45912,"skein512-456":45913,"skein512-464":45914,"skein512-472":45915,"skein512-480":45916,"skein512-488":45917,"skein512-496":45918,"skein512-504":45919,"skein512-512":45920,"skein1024-8":45921,"skein1024-16":45922,"skein1024-24":45923,"skein1024-32":45924,"skein1024-40":45925,"skein1024-48":45926,"skein1024-56":45927,"skein1024-64":45928,"skein1024-72":45929,"skein1024-80":45930,"skein1024-88":45931,"skein1024-96":45932,"skein1024-104":45933,"skein1024-112":45934,"skein1024-120":45935,"skein1024-128":45936,"skein1024-136":45937,"skein1024-144":45938,"skein1024-152":45939,"skein1024-160":45940,"skein1024-168":45941,"skein1024-176":45942,"skein1024-184":45943,"skein1024-192":45944,"skein1024-200":45945,"skein1024-208":45946,"skein1024-216":45947,"skein1024-224":45948,"skein1024-232":45949,"skein1024-240":45950,"skein1024-248":45951,"skein1024-256":45952,"skein1024-264":45953,"skein1024-272":45954,"skein1024-280":45955,"skein1024-288":45956,"skein1024-296":45957,"skein1024-304":45958,"skein1024-312":45959,"skein1024-320":45960,"skein1024-328":45961,"skein1024-336":45962,"skein1024-344":45963,"skein1024-352":45964,"skein1024-360":45965,"skein1024-368":45966,"skein1024-376":45967,"skein1024-384":45968,"skein1024-392":45969,"skein1024-400":45970,"skein1024-408":45971,"skein1024-416":45972,"skein1024-424":45973,"skein1024-432":45974,"skein1024-440":45975,"skein1024-448":45976,"skein1024-456":45977,"skein1024-464":45978,"skein1024-472":45979,"skein1024-480":45980,"skein1024-488":45981,"skein1024-496":45982,"skein1024-504":45983,"skein1024-512":45984,"skein1024-520":45985,"skein1024-528":45986,"skein1024-536":45987,"skein1024-544":45988,"skein1024-552":45989,"skein1024-560":45990,"skein1024-568":45991,"skein1024-576":45992,"skein1024-584":45993,"skein1024-592":45994,"skein1024-600":45995,"skein1024-608":45996,"skein1024-616":45997,"skein1024-624":45998,"skein1024-632":45999,"skein1024-640":46000,"skein1024-648":46001,"skein1024-656":46002,"skein1024-664":46003,"skein1024-672":46004,"skein1024-680":46005,"skein1024-688":46006,"skein1024-696":46007,"skein1024-704":46008,"skein1024-712":46009,"skein1024-720":46010,"skein1024-728":46011,"skein1024-736":46012,"skein1024-744":46013,"skein1024-752":46014,"skein1024-760":46015,"skein1024-768":46016,"skein1024-776":46017,"skein1024-784":46018,"skein1024-792":46019,"skein1024-800":46020,"skein1024-808":46021,"skein1024-816":46022,"skein1024-824":46023,"skein1024-832":46024,"skein1024-840":46025,"skein1024-848":46026,"skein1024-856":46027,"skein1024-864":46028,"skein1024-872":46029,"skein1024-880":46030,"skein1024-888":46031,"skein1024-896":46032,"skein1024-904":46033,"skein1024-912":46034,"skein1024-920":46035,"skein1024-928":46036,"skein1024-936":46037,"skein1024-944":46038,"skein1024-952":46039,"skein1024-960":46040,"skein1024-968":46041,"skein1024-976":46042,"skein1024-984":46043,"skein1024-992":46044,"skein1024-1000":46045,"skein1024-1008":46046,"skein1024-1016":46047,"skein1024-1024":46048,"holochain-adr-v0":8417572,"holochain-adr-v1":8483108,"holochain-key-v0":9728292,"holochain-key-v1":9793828,"holochain-sig-v0":10645796,"holochain-sig-v1":10711332}')},2562:e=>{"use strict";e.exports=JSON.parse('{"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}')},9794:e=>{"use strict";e.exports={version:"1.0.34"}},8920:e=>{"use strict";e.exports={i8:"1.8.2"}}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={id:n,loaded:!1,exports:{}};return e[n](o,o.exports,r),o.loaded=!0,o.exports}return r.amdO={},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),r(7001)})(),e.exports=t()},47529:e=>{e.exports=function(){for(var e={},r=0;r{"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}},34411:(e,t,r)=>{"use strict";function n(e){var t=this;if(t instanceof n||(t=new n),t.tail=null,t.head=null,t.length=0,e&&"function"==typeof e.forEach)e.forEach((function(e){t.push(e)}));else if(arguments.length>0)for(var r=0,i=arguments.length;r1)r=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");n=this.head.next,r=this.head.value}for(var i=0;null!==n;i++)r=e(r,n.value,i),n=n.next;return r},n.prototype.reduceReverse=function(e,t){var r,n=this.tail;if(arguments.length>1)r=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");n=this.tail.prev,r=this.tail.value}for(var i=this.length-1;null!==n;i--)r=e(r,n.value,i),n=n.prev;return r},n.prototype.toArray=function(){for(var e=new Array(this.length),t=0,r=this.head;null!==r;t++)e[t]=r.value,r=r.next;return e},n.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,r=this.tail;null!==r;t++)e[t]=r.value,r=r.prev;return e},n.prototype.slice=function(e,t){(t=t||this.length)<0&&(t+=this.length),(e=e||0)<0&&(e+=this.length);var r=new n;if(tthis.length&&(t=this.length);for(var i=0,o=this.head;null!==o&&ithis.length&&(t=this.length);for(var i=this.length,o=this.tail;null!==o&&i>t;i--)o=o.prev;for(;null!==o&&i>e;i--,o=o.prev)r.push(o.value);return r},n.prototype.splice=function(e,t,...r){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var n=0,o=this.head;null!==o&&n{const n=r(2655),i=r(84071),o=r(63857),a=r(95200),s=r(33904),{BLOCKCHAINS_RENAME_PAIRS:u}=r(16381);e.exports=class{constructor(e){const t=e.blockchain?.name,r=e;t&&Object.keys(u).includes(t)&&(r.blockchain.name=u[t]),this.initializeServices(r)}initializeServices(e){this.blockchainService=this.initializeBlockchainService(e),this.nodeApiService=this.initializeNodeApiService(e),this.inputService=new s(e),this.validationService=new o}getServices(){return{blockchainService:this.blockchainService,nodeApiService:this.nodeApiService,validationService:this.validationService,inputService:this.inputService}}initializeNodeApiService(e){return e.communicationType&&n[e.communicationType]?new n[e.communicationType](e):new n.Default(e)}initializeBlockchainService(e){return a.nodeSupported()?new i.Node(e):a.nodeSupported()||window.ethereum||!e.blockchain?.privateKey?new i.Browser(e):new i.Node(e)}}},84071:(e,t,r)=>{const n=r(73597),i=r(38238);e.exports={Browser:n,Node:i}},92788:(e,t,r)=>{const n=r(37918),i=r(9669),o=r(84064),a=r(67448),s=r(60082),u=r(26758),c=r(44664),l=r(74066),f=r(64776),h=r(65177),d=r(11926),p=r(50575),m=r(12936),y=r(64004),g=r(88767),{OPERATIONS_STEP_STATUS:b,DEFAULT_GAS_PRICE:v}=r(16381),w=r(54209);e.exports=class{constructor(e={}){this.config=e,this.events={},this.abis={},this.abis.AssertionStorage=o,this.abis.Hub=a,this.abis.ServiceAgreementV1=s,this.abis.ServiceAgreementStorageProxy=u,this.abis.ContentAssetStorage=c,this.abis.UnfinalizedStateStorage=l,this.abis.ContentAsset=f,this.abis.Token=h,this.abis.Paranet=d,this.abis.ParanetsRegistry=p,this.abis.ParanetIncentivesPoolFactory=m,this.abis.ParanetNeuroIncentivesPool=y,this.abis.ParanetKnowledgeMinersRegistry=g,this.abis.ContentAsset.filter((e=>"event"===e.type)).forEach((e=>{const t=e.inputs.map((e=>e.internalType));this.events[e.name]={hash:n.utils.keccak256(`${e.name}(${t})`),inputs:e.inputs}}))}initializeWeb3(){return{}}async decodeEventLogs(){}async getPublicKey(){}async getNetworkGasPrice(e){const t=await this.getWeb3Instance(e);try{let r;if(e.name.startsWith("otp"))r=await t.eth.getGasPrice();else if(e.name.startsWith("base"))r=await t.eth.getGasPrice();else if(e.name.startsWith("gnosis")){const t=await i.get(e.gasPriceOracleLink);"100"===e.name.split(":")[1]?r=Number(t.data.result,10):"10200"===e.name.split(":")[1]&&(r=Math.round(1e9*t.data.average))}else r=n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei");return r}catch(t){return console.warn(`Failed to fetch the gas price from the network: ${t}. Using default value: 2 Gwei.`),n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei")}}async callContractFunction(e,t,r,n){let i=await this.getContractInstance(e,n);try{return await i.methods[t](...r).call()}catch(o){if(/revert|VM Exception/i.test(o.message)){let o;try{o=await i.methods.status().call()}catch(e){o=!1}if(!o&&"ParanetNeuroIncentivesPool"!==e)return await this.updateContractInstance(e,n,!0),i=await this.getContractInstance(e,n),i.methods[t](...r).call()}throw o}}async prepareTransaction(e,t,r,n){const i=await this.getPublicKey(n),o=await e.methods[t](...r).estimateGas({from:i}),a=await e.methods[t](...r).encodeABI();let s=Number(n.previousTxGasPrice||n.gasPrice||await this.getNetworkGasPrice(n));return n.retryTx&&(s=Math.round(1.2*s)),{from:i,to:e.options.address,data:a,gasPrice:s,gas:o}}ensureBlockchainInfo(e){this[e.name]||(this[e.name]={contracts:{[e.hubContract]:{}},contractAddresses:{[e.hubContract]:{Hub:e.hubContract}}})}async getWeb3Instance(e){if(this.ensureBlockchainInfo(e),!this[e.name].web3){const t={transactionPollingTimeout:e.transactionPollingTimeout};await this.initializeWeb3(e.name,e.rpc,t)}return this[e.name].web3}async getContractAddress(e,t,r=!1){if(this.ensureBlockchainInfo(t),this[t.name].contracts[t.hubContract]||(this[t.name].contracts[t.hubContract]={}),!this[t.name].contracts[t.hubContract].Hub){const e=await this.getWeb3Instance(t);this[t.name].contracts[t.hubContract].Hub=new e.eth.Contract(this.abis.Hub,t.hubContract,{from:t.publicKey})}return!r&&this[t.name].contractAddresses[t.hubContract][e]||(this[t.name].contractAddresses[t.hubContract][e]=await this.callContractFunction("Hub",e.includes("AssetStorage")?"getAssetStorageAddress":"getContractAddress",[e],t)),this[t.name].contractAddresses[t.hubContract][e]}async updateContractInstance(e,t,r=!1){if(this.ensureBlockchainInfo(t),!r&&this[t.name].contractAddresses[t.hubContract][e]||(this[t.name].contractAddresses[t.hubContract][e]=await this.getContractAddress(e,t,r)),r||!this[t.name].contracts[t.hubContract][e]){const r=await this.getWeb3Instance(t);this[t.name].contracts[t.hubContract][e]=await new r.eth.Contract(this.abis[e],this[t.name].contractAddresses[t.hubContract][e],{from:t.publicKey})}}async getContractInstance(e,t){return await this.updateContractInstance(e,t),this[t.name].contracts[t.hubContract][e]}async createAsset(e,t,r,n,i=w){const o=await this.getContractAddress("ServiceAgreementV1",n),a=await this.callContractFunction("Token","allowance",[await this.getPublicKey(n),o],n),s=BigInt(e.tokenAmount)-BigInt(a);s>0&&(await this.executeContractFunction("Token","increaseAllowance",[o,s],n),i.afterHook({status:b.INCREASE_ALLOWANCE_COMPLETED}));try{let o;o=null==t&&null==r?await this.executeContractFunction("ContentAsset","createAsset",[Object.values(e)],n):await this.executeContractFunction("Paranet","mintKnowledgeAsset",[t,r,Object.values(e)],n);let{tokenId:a}=await this.decodeEventLogs(o,"AssetMinted",n);return a=parseInt(a,10),i.afterHook({status:b.CREATE_ASSET_COMPLETED,data:{tokenId:a}}),a}catch(e){throw s>0&&await this.executeContractFunction("Token","decreaseAllowance",[o,s],n),e}}async updateAsset(e,t,r,n,i,o,a){const s=await this.getContractAddress("ServiceAgreementV1",a),u=await this.callContractFunction("Token","allowance",[await this.getPublicKey(a),s],a),c=BigInt(o)-BigInt(u);c>0&&await this.executeContractFunction("Token","increaseAllowance",[s,c],a);try{return this.executeContractFunction("ContentAsset","updateAssetState",[e,t,r,n,i,o],a)}catch(e){throw c>0&&await this.executeContractFunction("Token","decreaseAllowance",[s,c],a),e}}async hasPendingUpdate(e,t){return this.callContractFunction("UnfinalizedStateStorage","hasPendingUpdate",[e],t)}async cancelAssetUpdate(e,t){return this.executeContractFunction("ContentAsset","cancelAssetStateUpdate",[e],t)}async getLatestAssertionId(e,t){return this.callContractFunction("ContentAssetStorage","getLatestAssertionId",[e],t)}async getUnfinalizedState(e,t){return this.callContractFunction("UnfinalizedStateStorage","getUnfinalizedState",[e],t)}async getAssetOwner(e,t){return this.callContractFunction("ContentAssetStorage","ownerOf",[e],t)}async burnAsset(e,t){return this.executeContractFunction("ContentAsset","burnAsset",[e],t)}async extendAssetStoringPeriod(e,t,r,n){const i=await this.getContractAddress("ServiceAgreementV1",n);await this.executeContractFunction("Token","increaseAllowance",[i,r],n);try{return this.executeContractFunction("ContentAsset","extendAssetStoringPeriod",[e,t,r],n)}catch(e){throw await this.executeContractFunction("Token","decreaseAllowance",[i,r],n),e}}async addTokens(e,t,r){const n=await this.getContractAddress("ServiceAgreementV1",r);await this.executeContractFunction("Token","increaseAllowance",[n,t],r);try{return this.executeContractFunction("ContentAsset","increaseAssetTokenAmount",[e,t],r)}catch(e){throw await this.executeContractFunction("Token","decreaseAllowance",[n,t],r),e}}async addUpdateTokens(e,t,r){const n=await this.getContractAddress("ServiceAgreementV1",r);await this.executeContractFunction("Token","increaseAllowance",[n,t],r);try{return this.executeContractFunction("ContentAsset","increaseAssetUpdateTokenAmount",[e,t],r)}catch(e){throw await this.executeContractFunction("Token","decreaseAllowance",[n,t],r),e}}async getAssertionIdByIndex(e,t,r){return this.callContractFunction("ContentAssetStorage","getAssertionIdByIndex",[e,t],r)}async getAssertionIds(e,t){return this.callContractFunction("ContentAssetStorage","getAssertionIds",[e],t)}async getAssertionIssuer(e,t,r,n){return this.callContractFunction("ContentAssetStorage","getAssertionIssuer",[e,t,r],n)}async getAgreementData(e,t){const r=await this.callContractFunction("ServiceAgreementStorageProxy","getAgreementData",[e],t);return{startTime:Number(r[0]),epochsNumber:Number(r[1]),epochLength:Number(r[2]),tokenAmount:r[3][0],addedTokenAmount:r[3][1],scoreFunctionId:r[4][0],proofWindowOffsetPerc:r[4][1]}}async getAssertionSize(e,t){return this.callContractFunction("AssertionStorage","getAssertionSize",[e],t)}async registerParanet(e,t){return this.executeContractFunction("Paranet","registerParanet",Object.values(e),t)}async deployNeuroIncentivesPool(e,t){return this.executeContractFunction("ParanetIncentivesPoolFactory","deployNeuroIncentivesPool",Object.values(e),t)}async registerParanetService(e,t){return this.executeContractFunction("Paranet","registerParanetService",Object.values(e),t)}async addParanetServices(e,t){return this.executeContractFunction("Paranet","addParanetServices",Object.values(e),t)}async submitToParanet(e,t){return this.executeContractFunction("Paranet","submitKnowledgeAsset",Object.values(e),t)}async getUpdatingKnowledgeAssetStates(e,t){return this.callContractFunction("ParanetKnowledgeMinersRegistry","getUpdatingKnowledgeAssetStates",Object.values(e),t)}async updateClaimableRewards(e,t){return this.executeContractFunction("Paranet","processUpdatedKnowledgeAssetStatesMetadata",Object.values(e),t)}async getIncentivesPoolAddress(e,t){return this.callContractFunction("ParanetsRegistry","getIncentivesPoolAddress",Object.values(e),t)}async getNeuroIncentivesPoolAddress(e,t){return this.getIncentivesPoolAddress({paranetId:e,incentivesPoolType:"Neuroweb"},t)}async setIncentivesPool(e,t){const r=await this.getWeb3Instance(t);this[t.name].contractAddresses[t.hubContract].ParanetNeuroIncentivesPool!==e&&(this[t.name].contractAddresses[t.hubContract].ParanetNeuroIncentivesPool=e,this[t.name].contracts[t.hubContract].ParanetNeuroIncentivesPool=await new r.eth.Contract(this.abis.ParanetNeuroIncentivesPool,this[t.name].contractAddresses[t.hubContract].ParanetNeuroIncentivesPool,{from:t.publicKey}))}async claimKnowledgeMinerReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.executeContractFunction("ParanetNeuroIncentivesPool","claimKnowledgeMinerReward",[],t)}async claimVoterReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.executeContractFunction("ParanetNeuroIncentivesPool","claimIncentivizationProposalVoterReward",[],t)}async claimOperatorReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.executeContractFunction("ParanetNeuroIncentivesPool","claimParanetOperatorReward",[],t)}async getClaimableKnowledgeMinerReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableKnowledgeMinerRewardAmount",[],t)}async getClaimableAllKnowledgeMinersReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableAllKnowledgeMinersRewardAmount",[],t)}async getClaimableVoterReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableProposalVoterRewardAmount",[],t)}async getClaimableAllVotersReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableAllProposalVotersRewardAmount",[],t)}async getClaimableOperatorReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableParanetOperatorRewardAmount",[],t)}async isParanetKnowledgeMiner(e,t,r){const n=await this.getNeuroIncentivesPoolAddress(t,r);return await this.setIncentivesPool(n,r),this.callContractFunction("ParanetNeuroIncentivesPool","isKnowledgeMiner",[e],r)}async isParanetOperator(e,t,r){const n=await this.getNeuroIncentivesPoolAddress(t,r);return await this.setIncentivesPool(n,r),this.callContractFunction("ParanetNeuroIncentivesPool","isParanetOperator",[e],r)}async isParanetProposalVoter(e,t,r){const n=await this.getNeuroIncentivesPoolAddress(t,r);return await this.setIncentivesPool(n,r),this.callContractFunction("ParanetNeuroIncentivesPool","isProposalVoter",[e],r)}async getChainId(e){return(await this.getWeb3Instance(e)).eth.getChainId()}async getBlockchainTimestamp(e){if(!e.name.startsWith("hardhat"))return Math.floor(Date.now()/1e3);return(await this.getLatestBlock(e)).timestamp}async getGasPrice(e){const t=await this.getWeb3Instance(e);try{let r;if(e.name.startsWith("otp")||e.name.startsWith("base"))r=await t.eth.getGasPrice();else if(e.name.startsWith("gnosis")){const t=await i.get(e.gasPriceOracleLink);"100"===e.name.split(":")[1]?r=Number(t.result,10):"10200"===e.name.split(":")[1]&&(r=Math.round(1e9*t.data.average))}else r=n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei");return r}catch(t){return console.warn(`Failed to fetch the gas price from the network: ${t}. Using default value: 2 Gwei.`),n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei")}}async getWalletBalances(e){const t=await this.getWeb3Instance(e),r=await this.getPublicKey(e);return{blockchainToken:await t.eth.getBalance(r),trac:await this.callContractFunction("Token","balanceOf",[await this.getPublicKey(e)],e)}}async getLatestBlock(e){const t=await this.getWeb3Instance(e),r=await t.eth.getBlockNumber();return t.eth.getBlock(r)}convertToWei(e){return n.utils.toWei(e.toString(),"ether")}}},73597:(e,t,r)=>{const n=r(37918),i=r(92788),{WEBSOCKET_PROVIDER_OPTIONS:o}=r(16381);e.exports=class extends i{constructor(e={}){super(e),this.config=e}async initializeWeb3(e,t){if(void 0!==window.web3&&window.web3||console.error("No web3 implementation injected, please inject your own Web3 implementation."),window.ethereum){this[e].web3=new n(window.ethereum);try{await window.ethereum.enable()}catch(e){console.error(e)}}else if(t.startsWith("ws")){const r=(new n).providers.WebsocketProvider(t,o);this[e].web3=new n(r)}else this[e].web3=new n(t)}async decodeEventLogs(e,t,r){const n=await this.getWeb3Instance(r);let i;const{hash:o,inputs:a}=this.events[t];return Object.values(e.events).forEach((e=>{e.raw.topics[0]===o&&(i=n.eth.abi.decodeLog(a,e.raw.data,e.raw.topics.slice(1)))})),i}async executeContractFunction(e,t,r,n){let i=await this.getContractInstance(e,n);const o=await this.prepareTransaction(i,t,r,n);try{return await i.methods[t](...r).send(o)}catch(a){if(/revert|VM Exception/i.test(a.message)){let a;try{a=await i.methods.status().call()}catch(e){a=!1}if(!a)return await this.updateContractInstance(e,n,!0),i=await this.getContractInstance(e,n),i.methods[t](...r).send(o)}throw a}}async getPublicKey(){return this.getAccount()}async getAccount(){if(!this.account){if(!window.ethereum)throw Error("This operation can be performed only by using Metamask accounts.");const e=await window.ethereum.request({method:"eth_requestAccounts"}).catch((()=>console.error("There was an error fetching your accounts")));[this.account]=e}return this.account}async transferAsset(e,t,r){return this.executeContractFunction("ContentAssetStorage","transferFrom",[await this.getAccount(),t,e],r)}}},38238:(e,t,r)=>{const n=r(37918),{TRANSACTION_RETRY_ERRORS:i,WEBSOCKET_PROVIDER_OPTIONS:o}=r(16381),a=r(92788);e.exports=class extends a{constructor(e={}){super(e),this.config=e,this.events={},this.abis.ContentAsset.filter((e=>"event"===e.type)).forEach((e=>{const t=e.inputs.map((e=>e.internalType));this.events[e.name]={hash:n.utils.keccak256(`${e.name}(${t})`),inputs:e.inputs}}))}initializeWeb3(e,t,r){if(t.startsWith("ws")){const r=new n.providers.WebsocketProvider(t,o);this[e].web3=new n(r)}else this[e].web3=new n(t);r.transactionPollingTimeout&&(this[e].web3.eth.transactionPollingTimeout=r.transactionPollingTimeout)}async decodeEventLogs(e,t,r){const n=await this.getWeb3Instance(r);let i;const{hash:o,inputs:a}=this.events[t];return e.logs.forEach((e=>{e.topics[0]===o&&(i=n.eth.abi.decodeLog(a,e.data,e.topics.slice(1)))})),i}async getPublicKey(e){return e?.publicKey}async executeContractFunction(e,t,r,n){const o=await this.getWeb3Instance(n);let a,s,u=await this.getContractInstance(e,n),c=!1;for(;void 0===a;)try{const e=await this.prepareTransaction(u,t,r,n);s=e.gasPrice;const i=await o.eth.accounts.signTransaction(e,n.privateKey);a=await o.eth.sendSignedTransaction(i.rawTransaction)}catch(t){if(!c&&n.handleNotMinedError&&i.some((e=>t.message.toLowerCase().includes(e))))c=!0,n.retryTx=!0,n.previousTxGasPrice=s;else{if(c||!/revert|VM Exception/i.test(t.message))throw t;{let r;try{r=await u.methods.status().call()}catch(e){r=!1}if(r||"ParanetNeuroIncentivesPool"===e)throw t;await this.updateContractInstance(e,n,!0),u=await this.getContractInstance(e,n),c=!0,n.retryTx=!0}}}return a}async transferAsset(e,t,r){return this.executeContractFunction("ContentAssetStorage","transferFrom",[r.publicKey,t,e],r)}}},33904:(e,t,r)=>{const{DEFAULT_PARAMETERS:n,DEFAULT_PROXIMITY_SCORE_FUNCTIONS_PAIR_IDS:i,BLOCKCHAINS:o,LOW_BID_SUGGESTION:a}=r(16381);e.exports=class{constructor(e={}){this.config=e}getBidSuggestionArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),epochsNum:this.getEpochsNum(e),hashFunctionId:this.getHashFunctionId(e),authToken:this.getAuthToken(e),bidSuggestionRange:this.getBidSuggestionRange(e)}}getAssetCreateArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),epochsNum:this.getEpochsNum(e),hashFunctionId:this.getHashFunctionId(e),scoreFunctionId:this.getScoreFunctionId(e),immutable:this.getImmutable(e),tokenAmount:this.getTokenAmount(e),authToken:this.getAuthToken(e),paranetUAL:this.getParanetUAL(e)}}getAssetGetArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),state:this.getState(e),contentType:this.getContentType(e),validate:this.getValidate(e),outputFormat:this.getOutputFormat(e),authToken:this.getAuthToken(e),hashFunctionId:this.getHashFunctionId(e)}}getAssetUpdateArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),hashFunctionId:this.getHashFunctionId(e),scoreFunctionId:this.getScoreFunctionId(e),tokenAmount:this.getTokenAmount(e),authToken:this.getAuthToken(e)}}getQueryArguments(e){return{graphLocation:this.getGraphLocation(e),graphState:this.getGraphState(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),authToken:this.getAuthToken(e)}}getParanetCreateArguments(e){return{blockchain:this.getBlockchain(e),paranetName:this.getParanetName(e),paranetDescription:this.getParanetDescription(e)}}getParanetDeployIncentivesContractArguments(e){return{blockchain:this.getBlockchain(e),incentiveType:this.getIncentiveType(e),tracToNeuroEmissionMultiplier:this.getTracToNeuroEmissionMultiplier(e),operatorRewardPercentage:this.getOperatorRewardPercentage(e),incentivizationProposalVotersRewardPercentage:this.getIncentivizationProposalVotersRewardPercentage(e)}}getParanetCreateServiceArguments(e){return{blockchain:this.getBlockchain(e),paranetServiceName:this.getParanetServiceName(e),paranetServiceDescription:this.getParanetServiceDescription(e),paranetServiceAddresses:this.getParanetServiceAddresses(e)}}getParanetRoleCheckArguments(e){return{blockchain:this.getBlockchain(e),roleAddress:this.getRoleAddress(e)}}getBlockchain(e){const t=e.environment??this.config.environment??n.ENVIRONMENT,r=e.blockchain?.name??this.config.blockchain?.name??null,i=e.blockchain?.rpc??this.config.blockchain?.rpc??o[t][r]?.rpc,a=e.blockchain?.hubContract??this.config.blockchain?.hubContract??o[t][r]?.hubContract,s=e.blockchain?.publicKey??this.config.blockchain?.publicKey??null,u=e.blockchain?.privateKey??this.config.blockchain?.privateKey??null,c=e.blockchain?.handleNotMinedError??this.config.blockchain?.handleNotMinedError??n.HANDLE_NOT_MINED_ERROR;return{name:r,rpc:i,hubContract:a,publicKey:s,privateKey:u,gasPrice:e.blockchain?.gasPrice??this.config.blockchain?.gasPrice??void 0,transactionPollingTimeout:e.blockchain?.transactionPollingTimeout??this.config.blockchain?.transactionPollingTimeout??null,handleNotMinedError:c,gasPriceOracleLink:e.blockchain?.gasPriceOracleLink??this.config.blockchain?.gasPriceOracleLink??o[t][r]?.gasPriceOracleLink??void 0}}getGraphLocation(e){return e.graphLocation??e.paranetUAL??this.config.graphLocation??n.GRAPH_LOCATION}getGraphState(e){return e.graphState??this.config.graphState??n.GRAPH_STATE}getEndpoint(e){return e.endpoint??this.config.endpoint??null}getPort(e){return e.port??this.config.port??n.PORT}getFrequency(e){return e.frequency??this.config.frequency??n.FREQUENCY}getHashFunctionId(e){return e.hashFunctionId??this.config.hashFunctionId??n.HASH_FUNCTION_ID}getScoreFunctionId(e){const t=e.environment??this.config.environment??n.ENVIRONMENT,r=this.getBlockchain(e).name;return i[t][r]}getEpochsNum(e){return e.epochsNum??this.config.epochsNum??null}getImmutable(e){return e.immutable??this.config.immutable??n.IMMUTABLE}getTokenAmount(e){return e.tokenAmount??this.config.tokenAmount??null}getState(e){return e.state??this.config.state??n.STATE}getContentType(e){return e.contentType??this.config.contentType??n.CONTENT_TYPE}getValidate(e){return e.validate??this.config.validate??n.VALIDATE}getOutputFormat(e){return e.outputFormat??this.config.outputFormat??n.OUTPUT_FORMAT}getMaxNumberOfRetries(e){return e.maxNumberOfRetries??this.config.maxNumberOfRetries??n.MAX_NUMBER_OF_RETRIES}getAuthToken(e){return e.auth?.token??this.config?.auth?.token??null}getBidSuggestionRange(e){return e.bidSuggestionRange??a}getParanetUAL(e){return e.paranetUAL??this.config.paranetUAL??null}getParanetName(e){return e.paranetName??null}getParanetDescription(e){return e.paranetDescription??null}getTracToNeuroEmissionMultiplier(e){return e.tracToNeuroEmissionMultiplier??null}getIncentivizationProposalVotersRewardPercentage(e){return 100*e.incentivizationProposalVotersRewardPercentage??null}getOperatorRewardPercentage(e){return 100*e.operatorRewardPercentage??null}getIncentiveType(e){return e.incentiveType??null}getParanetServiceName(e){return e.paranetServiceName??null}getParanetServiceDescription(e){return e.paranetServiceDescription??null}getParanetServiceAddresses(e){return e.paranetServiceAddresses??[]}getRoleAddress(e){return e.roleAddress??null}}},64420:(e,t,r)=>{const n=r(9669),{OPERATION_STATUSES:i}=r(16381),{sleepForMilliseconds:o}=r(95200);e.exports=class{constructor(e={}){this.config=e}async info(e,t,r){try{return await n({method:"get",url:`${e}:${t}/info`,headers:this.prepareRequestConfig(r)})}catch(e){throw Error(`Unable to get node info: ${e.message}`)}}async getBidSuggestion(e,t,r,i,o,a,s,u,c,l){try{const f={blockchain:i,epochsNumber:o,assertionSize:a,contentAssetStorageAddress:s,firstAssertionId:u,hashFunctionId:c};null!=l&&(f.bidSuggestionRange=l);return(await n({method:"get",url:`${e}:${t}/bid-suggestion`,params:f,headers:this.prepareRequestConfig(r)})).data.bidSuggestion}catch(e){throw Error(`Unable to get bid suggestion: ${e.message}`)}}async localStore(e,t,r,i){try{return(await n({method:"post",url:`${e}:${t}/local-store`,data:i,headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to store locally: ${e.message}`)}}async publish(e,t,r,i,o,a,s,u,c){try{return(await n({method:"post",url:`${e}:${t}/publish`,data:{assertionId:i,assertion:o,blockchain:a,contract:s,tokenId:u,hashFunctionId:c},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to publish: ${e.message}`)}}async get(e,t,r,i,o,a){try{return(await n({method:"post",url:`${e}:${t}/get`,data:{id:i,state:o,hashFunctionId:a},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to get assertion: ${e.message}`)}}async update(e,t,r,i,o,a,s,u,c){try{return(await n({method:"post",url:`${e}:${t}/update`,data:{assertionId:i,assertion:o,blockchain:a,contract:s,tokenId:u,hashFunctionId:c},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to update: ${e.message}`)}}async query(e,t,r,i,o,a){try{return(await n({method:"post",url:`${e}:${t}/query`,data:{query:i,type:o,repository:a},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to query: ${e.message}`)}}async getOperationResult(e,t,r,a,s,u,c){await o(500);let l={status:i.PENDING},f=0;const h={method:"get",url:`${e}:${t}/${a}/${c}`,headers:this.prepareRequestConfig(r)};do{if(f>s){l.data={...l.data,data:{errorType:"DKG_CLIENT_ERROR",errorMessage:"Unable to get results. Max number of retries reached."}};break}f+=1,await o(1e3*u),l=await n(h)}while(l.data.status!==i.COMPLETED&&l.data.status!==i.FAILED);return l.data}prepareRequestConfig(e){return e?{Authorization:`Bearer ${e}`}:{}}}},67601:e=>{e.exports=class{publish(){}getOperationResult(){}}},2655:(e,t,r)=>{const n=r(67601),i=r(64420);e.exports={Sockets:n,Https:i,Http:i,Default:i}},95200:(e,t,r)=>{const n=r(36805),{GRAPH_LOCATIONS:i,GRAPH_STATES:o,OT_NODE_TRIPLE_STORE_REPOSITORIES:a}=r(16381);e.exports={nodeSupported:()=>"undefined"==typeof window,isEmptyObject:function(e){return 0===Object.keys(e).length&&e.constructor===Object},toNumber:e=>parseInt(e.slice(2),16),deriveUAL:(e,t,r)=>`did:dkg:${e.toLowerCase()}/${t.toLowerCase()}/${r}`,resolveUAL(e){const t=e.split(":"),r=(3===t.length?t[2]:`${t[2]}:${t[3]}`).split("/");if(3!==r.length)throw new Error(`UAL doesn't have correct format: ${e}`);return{blockchain:r[0],contract:r[1],tokenId:parseInt(r[2],10)}},deriveRepository(e,t){switch(e+t){case i.PUBLIC_KG+o.CURRENT:return a.PUBLIC_CURRENT;case i.PUBLIC_KG+o.HISTORICAL:return a.PUBLIC_HISTORY;case i.LOCAL_KG+o.CURRENT:return a.PRIVATE_CURRENT;case i.LOCAL_KG+o.HISTORICAL:return a.PRIVATE_HISTORY;default:return e}},async sleepForMilliseconds(e){await new Promise((t=>setTimeout(t,e)))},capitalizeFirstLetter:e=>e[0].toUpperCase()+e.slice(1),getOperationStatusObject:(e,t)=>({operationId:t,...e.data?.errorType?{status:e.status,...e.data}:{status:e.status}}),async toNQuads(e,t){const r={algorithm:"URDNA2015",format:"application/n-quads"};t&&(r.inputFormat=t);return(await n.canonize(e,r)).split("\n").filter((e=>""!==e))},toJSONLD:async e=>n.fromRDF(e,{algorithm:"URDNA2015",format:"application/n-quads"})}},63857:(e,t,r)=>{const{ASSET_STATES:n,CONTENT_TYPES:i,GRAPH_LOCATIONS:o,GRAPH_STATES:a,MAX_FILE_SIZE:s,OPERATIONS:u,GET_OUTPUT_FORMATS:c,QUERY_TYPES:l,BID_SUGGESTION_RANGE_ENUM:f}=r(16381),{nodeSupported:h}=r(95200);e.exports=class{validateNodeInfo(e,t,r){this.validateEndpoint(e),this.validatePort(t),this.validateAuthToken(r)}validateGraphQuery(e,t,r,n,i,o,a,s,u){this.validateQueryString(e),this.validateQueryType(t),this.validateGraphLocation(r),this.validateGraphState(n),this.validateEndpoint(i),this.validatePort(o),this.validateMaxNumberOfRetries(a),this.validateFrequency(s),this.validateAuthToken(u)}validateIsValidUAL(e){this.validateBlockchain(e)}validateSetAllowance(e){this.validateBlockchain(e)}validateIncreaseAllowance(e){this.validateBlockchain(e)}validateDecreaseAllowance(e){this.validateBlockchain(e)}validateAssetCreate(e,t,r,n,i,o,a,s,c,l,f,h,d){this.validateContent(e),this.validateBlockchain(t,u.PUBLISH),this.validateEndpoint(r),this.validatePort(n),this.validateMaxNumberOfRetries(i),this.validateFrequency(o),this.validateEpochsNum(a),this.validateHashFunctionId(s),this.validateScoreFunctionId(c),this.validateImmutable(l),this.validateTokenAmount(f),this.validateAuthToken(h),this.validateParanetUAL(d)}validateAssetGet(e,t,r,n,i,o,a,s,c,l,f,h){this.validateUAL(e),this.validateBlockchain(t,u.GET),this.validateEndpoint(r),this.validatePort(n),this.validateMaxNumberOfRetries(i),this.validateFrequency(o),this.validateState(a),this.validateContentType(s),this.validateHashFunctionId(c),this.validateValidate(l),this.validateOutputFormat(f),this.validateAuthToken(h)}validateAssetUpdate(e,t,r,n,i,o,a,s,c,l){this.validateContent(e),this.validateBlockchain(t,u.UPDATE),this.validateEndpoint(r),this.validatePort(n),this.validateMaxNumberOfRetries(i),this.validateFrequency(o),this.validateHashFunctionId(a),this.validateScoreFunctionId(s),this.validateTokenAmount(c),this.validateAuthToken(l)}validateWaitAssetUpdateFinalization(e,t,r,n){this.validateUAL(e),this.validateBlockchain(t),this.validateFrequency(r),this.validateMaxNumberOfRetries(n)}validateAssetUpdateCancel(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetTransfer(e,t,r){this.validateUAL(e),this.validateNewOwner(t),this.validateBlockchain(r)}validateAssetGetOwner(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetGetStateIssuer(e,t,r){this.validateUAL(e),this.validateStateIndex(t),this.validateBlockchain(r)}validateAssetGetStates(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetGetLatestStateIssuer(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetBurn(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateExtendAssetStoringPeriod(e,t,r,n){this.validateUAL(e),this.validateEpochsNum(t),this.validateTokenAmount(r),this.validateBlockchain(n)}validateAddTokens(e,t,r){this.validateUAL(e),this.validateTokenAmount(t),this.validateBlockchain(r)}validateParanetCreate(e,t,r,n){this.validateUAL(e),this.validateBlockchain(t),this.validateParanetName(r),this.validateParanetDescription(n)}validateDeployIncentivesContract(e,t,r,n,i){this.validateUAL(e),this.validateBlockchain(t),this.validateTracToNeuroEmissionMultiplier(r),this.validateOperatorRewardPercentage(n),this.validateIncentivizationProposalVotersRewardPercentage(i)}validateParanetRewardArguments(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateParanetRoleCheckArguments(e,t,r){this.validateAddress(e),this.validateUAL(t),this.validateBlockchain(r)}validateParanetCreateServiceArguments(e,t,r,n,i){this.validateUAL(e),this.validateBlockchain(i),this.validateParanetServiceName(t),this.validateParanetServiceDescription(r),this.validateParanetServiceAddresses(n)}validateParanetAddServicesArguments(e,t,r){this.validateUAL(e),this.validateBlockchain(r);for(const e of t)this.validateUAL(e)}validateSubmitToParanet(e,t,r){this.validateUAL(e),this.validateUAL(t),this.validateBlockchain(r)}validateRequiredParam(e,t){if(null==t)throw Error(`${e} is missing.`)}validateParamType(e,t,r){const n=Array.isArray(r);let i=t;if(n&&r.includes("number")){const e=parseInt(t,10);i=Number.isNaN(e)?t:e}else"number"===r&&(i=parseInt(t,10));const o=n?r:[r];if(!o.some((e=>typeof i===e)))throw new Error(`${e} must be of type ${o.join(" or ")}.`)}validateQueryString(e){this.validateRequiredParam("queryString",e),this.validateParamType("queryString",e,"string")}validateQueryType(e){this.validateRequiredParam("queryType",e);const t=Object.values(l);if(!t.includes(e))throw Error(`Invalid query Type: available query types: ${t}`)}validateGraphLocation(e){this.validateRequiredParam("graphLocation",e);const t=Object.keys(o);if(!t.includes(e)&&!this.validateUAL(e))throw Error(`Invalid graph location: available locations are valid Paranet UAL or: ${t}`)}validateGraphState(e){this.validateRequiredParam("graphState",e);const t=Object.keys(a);if(!t.includes(e))throw Error(`Invalid graph state: available states: ${t}`)}validateUAL(e){this.validateRequiredParam("UAL",e),this.validateParamType("UAL",e,"string");const t=e.split(":");if(3!==(3===t.length?t[2]:`${t[2]}:${t[3]}`).split("/")?.length)throw Error("Invalid UAL.");return!0}validateStateIndex(e){if(this.validateRequiredParam("stateIndex",e),this.validateParamType("stateIndex",e,"number"),e<0)throw Error("Invalid state index.")}validateObjectType(e){if(!e||"object"!=typeof e)throw Error("Content must be an object")}validateContent(e){this.validateRequiredParam("content",e);const t=Object.keys(e);if(!(1===t.length&&(t.includes("public")||t.includes("private"))||2===t.length&&(t.includes("public")||t.includes("private"))))throw Error('content keys can only be "public", "private" or both.');if(!e.public&&!e.private)throw Error("Public or private content must be defined")}validateAssertionSizeInBytes(e){if(e>s)throw Error(`File size limit is ${s/1048576}MB.`)}validateEndpoint(e){if(this.validateRequiredParam("endpoint",e),this.validateParamType("endpoint",e,"string"),!e.startsWith("http")&&!e.startsWith("ws"))throw Error('Endpoint should start with either "http" or "ws"')}validatePort(e){this.validateRequiredParam("port",e),this.validateParamType("port",e,"number")}validateMaxNumberOfRetries(e){this.validateRequiredParam("maxNumberOfRetries",e),this.validateParamType("maxNumberOfRetries",e,"number")}validateFrequency(e){this.validateRequiredParam("frequency",e),this.validateParamType("frequency",e,"number")}validateState(e){this.validateRequiredParam("state",e),this.validateParamType("state",e,["number","string"]);const t=Object.values(n);if("string"==typeof e&&!t.includes(e.toUpperCase())&&"number"!=typeof e&&!/^0x[a-fA-F0-9]{64}$/.test(e))throw Error(`Invalid state, available states: ${t},numerical or hash.`)}validateContentType(e){this.validateRequiredParam("contentType",e);const t=Object.values(i);if(!t.includes(e))throw Error(`Invalid content visibility! Available parameters: ${t}`)}validateEpochsNum(e){this.validateRequiredParam("epochsNum",e),this.validateParamType("epochsNum",e,"number")}validateHashFunctionId(e){this.validateRequiredParam("hashFunctionId",e),this.validateParamType("hashFunctionId",e,"number")}validateScoreFunctionId(e){this.validateRequiredParam("scoreFunctionId",e),this.validateParamType("scoreFunctionId",e,"number")}validateImmutable(e){this.validateRequiredParam("immutable",e),this.validateParamType("immutable",e,"boolean")}validateTokenAmount(e){null!=e&&this.validateParamType("tokenAmount",e,"number")}validateGasPrice(e){null!=e&&this.validateParamType("gasPrice",e,"number")}validateTransactionPollingTimeout(e){null!=e&&this.validateParamType("tokenAmount",e,"number")}validateAuthToken(e){null!=e&&this.validateParamType("authToken",e,"string")}validateParanetUAL(e){null!=e&&this.validateUAL(e)}validateValidate(e){this.validateRequiredParam("validate",e),this.validateParamType("validate",e,"boolean")}validateOutputFormat(e){this.validateRequiredParam("outputFormat",e);const t=Object.values(c);if(!t.includes(e))throw Error(`Invalid query Type: available query types: ${t}`)}validateBlockchain(e,t){this.validateRequiredParam("blockchain",e),this.validateRequiredParam("blockchain name",e.name),this.validateRequiredParam("blockchain hub contract",e.hubContract),this.validateGasPrice(e.gasPrice),this.validateTransactionPollingTimeout(e.transactionPollingTimeout),h()&&(this.validateRequiredParam("blockchain rpc",e.rpc),t!==u.GET&&(this.validateRequiredParam("blockchain public key",e.publicKey),this.validateRequiredParam("blockchain private key",e.privateKey)))}validateNewOwner(e){this.validateRequiredParam("newOwner",e),this.validateParamType("newOwner",e,"string")}validateGetBidSuggestion(e){this.validateBidSuggestionRange(e)}validateBidSuggestionRange(e){if(!f.includes(e))throw Error(`Invalid bidSuggestionRange parametar: supported parametars ${f}`)}validateParanetName(e){this.validateRequiredParam("paranetName",e),this.validateParamType("paranetName",e,"string")}validateParanetDescription(e){this.validateRequiredParam("paranetDescription",e),this.validateParamType("paranetDescription",e,"string")}validateTracToNeuroEmissionMultiplier(e){this.validateRequiredParam("tracToNeuroEmissionMultiplier",e),this.validateParamType("tracToNeuroEmissionMultiplier",e,"number")}validateIncentivizationProposalVotersRewardPercentage(e){if(this.validateRequiredParam("incentivizationProposalVotersRewardPercentage",e),this.validateParamType("incentivizationProposalVotersRewardPercentage",e,"number"),e>1e4||e<0)throw Error("Invalid percentage value for incentivization proposal voters reward.")}validateOperatorRewardPercentage(e){if(this.validateRequiredParam("operatorRewardPercentage",e),this.validateParamType("operatorRewardPercentage",e,"number"),e>1e4||e<0)throw Error("Invalid percentage value for operator reward.")}validateParanetServiceName(e){this.validateRequiredParam("paranetServiceName",e),this.validateParamType("paranetServiceName",e,"string")}validateParanetServiceDescription(e){this.validateRequiredParam("paranetServiceDescription",e),this.validateParamType("paranetServiceDescription",e,"string")}validateParanetServiceAddresses(e){if(0!==e.length)for(const t of e)this.validateAddress(t)}validateAddress(e){this.validateRequiredParam("address",e),this.validateParamType("address",e,"string")}}},54209:e=>{e.exports={afterHook:()=>{}}},69159:()=>{},80950:()=>{},46601:()=>{},89214:()=>{},8623:()=>{},7748:()=>{},85568:()=>{},47444:()=>{},47911:()=>{},59477:()=>{},32859:()=>{},3996:()=>{},56619:()=>{},28325:()=>{},84574:()=>{},24654:()=>{},77108:()=>{},97670:()=>{},52361:()=>{},94616:()=>{},40030:(e,t)=>{"use strict";function r(e){return function(e){let t=0;return()=>e[t++]}(function(e){let t=0;function r(){return e[t++]<<8|e[t++]}let n=r(),i=1,o=[0,1];for(let e=1;e>--u&1}const f=2**31,h=f>>>1,d=f-1;let p=0;for(let e=0;e<31;e++)p=p<<1|l();let m=[],y=0,g=f;for(;;){let e=Math.floor(((p-y+1)*i-1)/g),t=0,r=n;for(;r-t>1;){let n=t+r>>>1;e>>1|l(),a=a<<1^h,s=(s^h)<<1|h|1;y=a,g=1+s-a}let b=n-4;return m.map((t=>{switch(t-b){case 3:return b+65792+(e[s++]<<16|e[s++]<<8|e[s++]);case 2:return b+256+(e[s++]<<8|e[s++]);case 1:return b+e[s++];default:return t-1}}))}(function(e){let t=[];[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"].forEach(((e,r)=>t[e.charCodeAt(0)]=r));let r=e.length,n=new Uint8Array(6*r>>3);for(let i=0,o=0,a=0,s=0;i=8&&(n[o++]=s>>(a-=8));return n}(e)))}function n(e){return 1&e?~e>>1:e>>1}function i(e,t){let r=Array(e);for(let i=0,o=0;i{let t=o(e);if(t.length)return t}))}function s(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(l(r,e))}for(;;){let r=e()-1;if(r<0)break;t.push(f(r,e))}return t.flat()}function u(e){let t=[];for(;;){let r=e(t.length);if(!r)break;t.push(r)}return t}function c(e,t,r){let n=Array(e).fill().map((()=>[]));for(let o=0;on[t].push(e)));return n}function l(e,t){let r=1+t(),n=t(),i=u(t);return c(i.length,1+e,t).flatMap(((e,t)=>{let[o,...a]=e;return Array(i[t]).fill().map(((e,t)=>{let i=t*n;return[o+t*r,a.map((e=>e+i))]}))}))}function f(e,t){return c(1+t(),1+e,t).map((e=>[e[0],e.slice(1)]))}Object.defineProperty(t,"__esModule",{value:!0});var h=r("AEIRrQh1DccBuQJ+APkBMQDiASoAnADQAHQAngBmANQAaACKAEQAgwBJAHcAOQA9ACoANQAmAGMAHgAvACgAJQAWACwAGQAjAB8ALwAVACgAEQAdAAkAHAARABgAFwA7ACcALAAtADcAEwApABAAHQAfABAAGAAeABsAFwAUBLoF3QEXE7k3ygXaALgArkYBbgCsCAPMAK6GNjY2NjFiAQ0ODBDyAAQHRgbrOAVeBV8APTI5B/a9GAUNz8gAFQPPBeelYALMCjYCjqgCht8/lW+QAsXSAoP5ASbmEADytAFIAjSUCkaWAOoA6QocAB7bwM8TEkSkBCJ+AQQCQBjED/IQBjDwDASIbgwDxAeuBzQAsgBwmO+snIYAYgaaAioG8AAiAEIMmhcCqgLKQiDWCMIwA7gCFAIA9zRyqgCohB8AHgQsAt4dASQAwBnUBQEQIFM+CZ4JjyUiIVbATOqDSQAaABMAHAAVclsAKAAVAE71HN89+gI5X8qc5jUKFyRfVAJfPfMAGgATABwAFXIgY0CeAMPyACIAQAzMFsKqAgHavwViBekC0KYCxLcCClMjpGwUehp0TPwAwhRuAugAEjQ0kBfQmAKBggETIgDEFG4C6AASNAFPUCyYTBEDLgIFMBDecB60Ad5KAHgyEn4COBYoAy4uwD5yAEDoAfwsAM4OqLwBImqIALgMAAwCAIraUAUi3HIeAKgu2AGoBgYGBgYrNAOiAG4BCiA+9Dd7BB8eALEBzgIoAgDmMhJ6OvpQtzOoLjVPBQAGAS4FYAVftr8FcDtkQhlBWEiee5pmZqH/EhoDzA4s+H4qBKpSAlpaAnwisi4BlqqsPGIDTB4EimgQANgCBrJGNioCBzACQGQAcgFoJngAiiQgAJwBUL4ALnAeAbbMAz40KEoEWgF2YAZsAmwA+FAeAzAIDABQSACyAABkAHoAMrwGDvr2IJSGBgAQKAAwALoiTgHYAeIOEjiXf4HvABEAGAA7AEQAPzp3gNrHEGYQYwgFTRBMc0EVEgKzD60L7BEcDNgq0tPfADSwB/IDWgfyA1oDWgfyB/IDWgfyA1oDWgNaA1ocEfAh2scQZg9PBHQFlQWSBN0IiiZQEYgHLwjZVBR0JRxOA0wBAyMsSSM7mjMSJUlME00KCAM2SWyufT8DTjGyVPyQqQPSMlY5cwgFHngSpwAxD3ojNbxOhXpOcacKUk+1tYZJaU5uAsU6rz//CigJmm/Cd1UGRBAeJ6gQ+gw2AbgBPg3wS9sE9AY+BMwfgBkcD9CVnwioLeAM8CbmLqSAXSP4KoYF8Ev3POALUFFrD1wLaAnmOmaBUQMkARAijgrgDTwIcBD2CsxuDegRSAc8A9hJnQCoBwQLFB04FbgmE2KvCww5egb+GvkLkiayEyx6/wXWGiQGUAEsGwIA0i7qhbNaNFwfT2IGBgsoI8oUq1AjDShAunhLGh4HGCWsApRDc0qKUTkeliH5PEANaS4WUX8H+DwIGVILhDyhRq5FERHVPpA9SyJMTC8EOIIsMieOCdIPiAy8fHUBXAkkCbQMdBM0ERo3yAg8BxwwlycnGAgkRphgnQT6ogP2E9QDDgVCCUQHFgO4HDATMRUsBRCBJ9oC9jbYLrYCklaDARoFzg8oH+IQU0fjDuwIngJoA4Yl7gAwFSQAGiKeCEZmAGKP21MILs4IympvI3cDahTqZBF2B5QOWgeqHDYVwhzkcMteDoYLKKayCV4BeAmcAWIE5ggMNV6MoyBEZ1aLWxieIGRBQl3/AjQMaBWiRMCHewKOD24SHgE4AXYHPA0EAnoR8BFuEJgI7oYHNbgz+zooBFIhhiAUCioDUmzRCyom/Az7bAGmEmUDDzRAd/FnrmC5JxgABxwyyEFjIfQLlU/QDJ8axBhFVDEZ5wfCA/Ya9iftQVoGAgOmBhY6UDPxBMALbAiOCUIATA6mGgfaGG0KdIzTATSOAbqcA1qUhgJykgY6Bw4Aag6KBXzoACACqgimAAgA0gNaADwCsAegABwAiEQBQAMqMgEk6AKSA5YINM4BmDIB9iwEHsYMGAD6Om5NAsO0AoBtZqUF4FsCkQJMOAFQKAQIUUpUA7J05ADeAE4GFuJKARiuTc4d5kYB4nIuAMoA/gAIOAcIRAHQAfZwALoBYgs0CaW2uAFQ7CwAhgAYbgHaAowA4AA4AIL0AVYAUAVc/AXWAlJMARQ0Gy5aZAG+AyIBNgEQAHwGzpCozAoiBHAH1gIQHhXkAu8xB7gEAyLiE9BCyAK94VgAMhkKOwqqCqlgXmM2CTR1PVMAER+rPso/UQVUO1Y7WztWO1s7VjtbO1Y7WztWO1sDmsLlwuUKb19IYe4MqQ3XRMs6TBPeYFRgNRPLLboUxBXRJVkZQBq/Jwgl51UMDwct1mYzCC80eBe/AEIpa4NEY4keMwpOHOpTlFT7LR4AtEulM7INrxsYREMFSnXwYi0WEQolAmSEAmJFXlCyAF43IwKh+gJomwJmDAKfhzgeDgJmPgJmKQRxBIIDfxYDfpU5CTl6GjmFOiYmAmwgAjI5OA0CbcoCbbHyjQI2akguAWoA4QDkAE0IB5sMkAEBDsUAELgCdzICdqVCAnlORgJ4vSBf3kWxRvYCfEICessCfQwCfPNIA0iAZicALhhJW0peGBpKzwLRBALQz0sqA4hSA4fpRMiRNQLypF0GAwOxS9FMMCgG0k1PTbICi0ICitvEHgogRmoIugKOOgKOX0OahAKO3AKOX3tRt1M4AA1S11SIApP+ApMPAOwAH1UhVbJV0wksHimYiTLkeGlFPjwCl6IC77VYJKsAXCgClpICln+fAKxZr1oMhFAAPgKWuAKWUVxHXNQCmc4CmWdczV0KHAKcnjnFOqACnBkCn54CnruNACASNC0SAp30Ap6VALhAYTdh8gKe1gKgcQGsAp6iIgKeUahjy2QqKC4CJ7ICJoECoP4CoE/aAqYyAqXRAqgCAIACp/Vof2i0AAZMah9q1AKs5gKssQKtagKtBQJXIAJV3wKx5NoDH1FsmgKywBACsusabONtZm1LYgMl0AK2Xz5CbpMDKUgCuGECuUoYArktenA5cOQCvRwDLbUDMhQCvotyBQMzdAK+HXMlc1ICw84CwwdzhXROOEh04wM8qgADPJ0DPcICxX8CxkoCxhOMAshsVALIRwLJUgLJMQJkoALd1Xh8ZHixeShL0wMYpmcFAmH3GfaVJ3sOXpVevhQCz24Cz28yTlbV9haiAMmwAs92ASztA04Vfk4IAtwqAtuNAtJSA1JfA1NiAQQDVY+AjEIDzhnwY0h4AoLRg5AC2soC2eGEE4RMpz8DhqgAMgNkEYZ0XPwAWALfaALeu3Z6AuIy7RcB8zMqAfSeAfLVigLr9gLpc3wCAur8AurnAPxKAbwC7owC65+WrZcGAu5CA4XjmHxw43GkAvMGAGwDjhmZlgL3FgORcQOSigL3mwL53AL4aZofmq6+OpshA52GAv79AR4APJ8fAJ+2AwWQA6ZtA6bcANTIAwZtoYuiCAwDDEwBIAEiB3AGZLxqCAC+BG7CFI4ethAAGng8ACYDNrIDxAwQA4yCAWYqJACM8gAkAOamCqKUCLoGIqbIBQCuBRjCBfAkREUEFn8Fbz5FRzJCKEK7X3gYX8MAlswFOQCQUyCbwDstYDkYutYONhjNGJDJ/QVeBV8FXgVfBWoFXwVeBV8FXgVfBV4FXwVeBV9NHAjejG4JCQkKa17wMgTQA7gGNsLCAMIErsIA7kcwFrkFTT5wPndCRkK9X3w+X+8AWBgzsgCNBcxyzAOm7kaBRC0qCzIdLj08fnTfccH4GckscAFy13U3HgVmBXHJyMm/CNZQYgcHBwqDXoSSxQA6P4gAChbYBuy0KgwAjMoSAwgUAOVsJEQrJlFCuELDSD8qXy5gPS4/KgnIRAUKSz9KPn8+iD53PngCkELDUElCX9JVVnFUETNyWzYCcQASdSZf5zpBIgluogppKjJDJC1CskLDMswIzANf0BUmNRAPEAMGAQYpfqTfcUE0UR7JssmzCWzI0tMKZ0FmD+wQqhgAk5QkTEIsG7BtQM4/Cjo/Sj53QkYcDhEkU05zYjM0Wui8GQqE9CQyQkYcZA9REBU6W0pJPgs7SpwzCogiNEJGG/wPWikqHzc4BwyPaPBlCnhk0GASYDQqdQZKYCBACSIlYLoNCXIXbFVgVBgIBQZk7mAcYJxghGC6YFJgmG8WHga8FdxcsLxhC0MdsgHCMtTICSYcByMKJQGAAnMBNjecWYcCAZEKv04hAOsqdJUR0RQErU3xAaICjqNWBUdmAP4ARBEHOx1egRKsEysmwbZOAFYTOwMAHBO+NVsC2RJLbBEiAN9VBnwEESVhADgAvQKhLgsWdrIgAWIBjQoDA+D0FgaxBlEGwAAky1ywYRC7aBOQCy1GDsIBwgEpCU4DYQUvLy8nJSYoMxktDSgTlABbAnVel1CcCHUmBA94TgHadRbVWCcgsLdN8QcYBVNmAP4ARBEHgQYNK3MRjhKsPzc0zrZdFBIAZsMSAGpKblAoIiLGADgAvQKhLi1CFdUClxiCAVDCWM90eY7epaIO/KAVRBvzEuASDQ8iAwHOCUEQmgwXMhM9EgBCALrVAQkAqwDoAJuRNgAbAGIbzTVzfTEUyAIXCUIrStroIyUSG4QCggTIEbHxcwA+QDQOrT8u1agjB8IQABBBLtUYIAB9suEjD8IhThzUqHclAUQqZiMC8qAPBFPz6x9sDMMNAQhDCkUABccLRAJSDcIIww1DLtWoMQrDCUMPkhroBCIOwgyYCCILwhZCAKcQwgsFGKd74wA7cgtCDEMAAq0JwwUi1/UMBQ110QaCAAfCEmIYEsMBCADxCAAAexViDRbSG/x2F8IYQgAuwgLyqMIAHsICXCcxhgABwgAC6hVDFcIr8qPCz6hCCgKlJ1IAAmIA5+QZwqViFb/LAPsaggioBRH/dwDfwqfCGOIBGsKjknl5BwKpoooAEsINGxIAA5oAbcINAAvCp0IIGkICwQionNEPAgfHqUIFAOGCL71txQNPAAPyABXCAAcCAAnCAGmSABrCAA7CCRjCjnAWAgABYgAOcgAuUiUABsIAF8IIKAANUQC6wi0AA8IADqIq8gCyYQAcIgAbwgAB8gqoAAXNCxwV4gAHogBCwgEJAGnCAAuCAB3CAAjCCagABdEAbqYZ3ACYCCgABdEAAUIAB+IAHaIIKAAGoQAJggAbMgBtIgDmwocACGIACEIAFMIDAGkCCSgABtEA45IACUILqA7L+2YAB0IAbqNATwBOAArCCwADQgAJtAM+AAciABmCAAISpwIACiIACkIACgKn8gbCAAkiAAMSABBCBwAUQgARcgAPkgAN8gANwgAZEg0WIgAVQgBuoha6AcIAwQATQgBpMhEA4VIAAkIABFkAF4IFIgAG1wAYwgQlAYIvWQBATAC2DwcUDHkALzF3AasMCGUCcyoTBgQQDnZSc2YxkCYFhxsFaTQ9A6gKuwYI3wAdAwIKdQF9eU5ZGygDVgIcRQEzBgp6TcSCWYFHADAAOAgAAgAAAFoR4gCClzMBMgB97BQYOU0IUQBeDAAIVwEOkdMAf0IEJ6wAYQDdHACcbz4mkgDUcrgA1tsBHQ/JfHoiH10kENgBj5eyKVpaVE8ZQ8mQAAAAhiM+RzAy5xieVgB5ATAsNylJIBYDN1wE/sz1AFJs4wBxAngCRhGBOs54NTXcAgEMFxkmCxsOsrMAAAMCBAICABnRAgAqAQAFBQUFBQUEBAQEBAQDBAUGBwgDBAQEBAMBASEAigCNAJI8AOcAuADZAKFDAL8ArwCqAKUA6wCjANcAoADkAQUBAADEAH4AXwDPANEBAADbAO8AjQCmAS4A5wDcANkKAAgOMTrZ2dnZu8Xh0tXTSDccAU8BWTRMAVcBZgFlAVgBSVBISm0SAVAaDA8KOT0SDQAmEyosLjE9Pz9CQkJDRBNFBSNWVlZWWFhXWC5ZWlxbWyJiZmZlZ2Ypa211dHd3d3d3d3l5eXl5eXl5eXl5e3t8e3phAEPxAEgAmQB3ADEAZfcAjQBWAFYANgJz7gCKAAT39wBjAJLxAJ4ATgBhAGP+/q8AhACEAGgAVQCwACMAtQCCAj0CQAD7AOYA/QD9AOcA/gDoAOgA5wDlAC4CeAFQAT8BPQFTAT0BPQE9ATgBNwE3ATcBGwFXFgAwDwcAAFIeER0KHB0VAI0AlQClAFAAaR8CMAB1AG4AlgMSAyQxAx5IRU4wAJACTgDGAlYCoQC/ApMCkwKTApMCkwKTAogCkwKTApMCkwKTApMCkgKSApUCnQKUApMCkwKRApECkQKQAnIB0QKUApoCkwKTApIbfhACAPsKA5oCXgI3HAFRFToC3RYPMBgBSzwYUpYBeKlBAWZeAQIDPEwBAwCWMB4flnEAMGcAcAA1AJADm8yS8LWLYQzBMhXJARgIpNx7MQsEKmEBuQDkhYeGhYeFiImJhYqNi4WMj42HjomPiZCFkYWShZORlIWVhZaJl4WYhZmFmoWbipyPnYmehQCJK6cAigRCBD8EQQREBEIESARFBEAERgRIBEcEQwRFBEgAqgOOANBYANYCEwD9YQD9ASAA/QD7APsA/AD72wOLKmzFAP0A+wD7APwA+yMAkGEA/QCQASAA/QCQAvMA/QCQ2wOLKmzFIwD+YQEgAP0A/QD7APsA/AD7AP4A+wD7APwA+9sDiypsxSMAkGEBIAD9AJAA/QCQAvMA/QCQ2wOLKmzFIwJKAT0CUQFAAlLIA6UC8wOl2wOLKmzFIwCQYQEgA6UAkAOlAJAC8wOlAJDbA4sqbMUjBDcAkAQ4AJANlDh0JwEzAJAHRXUKKgEEAM1hCQBbYQAFGjkJAJAJRN8AUAkAkAkAnW0/6mOd3brkH5dB9mNQ/eNThoJ1CP8EZzy46pMulzRpOAZDJDXL2yXaVtAh1MxM82zfnsL/FXSaOaxJlgv345IW0Dfon3fzkx0WByY6wfCroENsWq/bORcfBvtlWbGzP5ju+gqE1DjyFssbkkSeqLAdrCkLOfItA7XNe1PctDPFKoNd/aZ6IQq6JTB6IrDBZ5/nJIbTHMeaaIWRoDvc42ORs9KtvcQWZd+Nv1D2C/hrzaOrFUjpItLWRI4x3GmzQqZbVH5LoCEJpk3hzt1pmM7bPitwOPG8gTKLVFszSrDZyLmfq8LkwkSUhIQlN4nFJUEhU2N7NBTOGk4Y2q9A2M7ps8jcevOKfycp9u3DyCe9hCt7i5HV8U5pm5LnVnKnyzbIyAN/LU4aqT3JK+e9JsdusAsUCgAuCnc4IwbgPBg4EPGOv5gR8D+96c8fLb09f7L6ON2k+Zxe/Y0AYoZIZ8yuu1At7f70iuSFoFmyPpwDU/4lQ+mHkFmq/CwtE7A979KNdD8zaHSx4HoxWsM8vl+2brNxN0QtIUvOfNGAYyv1R5DaM1JAR0C+Ugp6/cNq4pUDyDPKJjFeP4/L1TBoOJak3PVlmDCi/1oF8k1mnzTCz15BdAvmFjQrjide74m2NW1NG/qRrzhbNwwejlhnPfRn4mIfYmXzj5Fbu3C2TUpnYg+djp65dxZJ8XhwUqJ8JYrrR4WtrHKdKjz0i77K+QitukOAZSfFIwvBr1GKYpSukYTqF4gNtgaNDqh78ZDH4Qerglo3VpTLT0wOglaX6bDNhfs04jHVcMfCHwIb+y5bAaBvh2RARFYEjxjr1xTfU09JEjdY1vfcPrPVmnBBSDPj9TcZ1V/Dz8fvy0WLWZM0JPbRL0hLSPeVoC8hgQIGaeE6AYVZnnqm62/wt00pDl5Nw/nDo+bF1tC4qo5DryXVn8ffL3kuT51e+VcBTGiibvP+vqX50dppfxyNORSr48S5WXV8fzcsgjRQH6zjl+nuUYFVloiEnZOPDpHD/7ILh3JuFCdvAi2ANXYXjTDA5Up6YLihbc7d+dBlI9+mdgr8m8+3/Dp26W/Jssn7b9/pOEP4i+/9TsPI9m2NfNKwEI35mqKV+HpZ+W69Y8sM/sIA9Ltvhd+evQTUUfSkYxki28/CBT0cT96HrlrSrE+V9RzhskX0CsDsCfHffBVybkxmHOFOgaUurWNQ2AcZbi1WjkZzYArWZBHFd1SYwtqQ0DIZt7OV40ewQxCr/LgxAc8dLJeAJFseWJq9XiOp21hLv/HhsFbYbg3zCR8JmonZjhuKYrS/KJc30vnOL2CM+GfogNWug2DstZPzauCNeeD8zlP8wxPyfLHYQB/J+wQE3aDpXH/5tdIQpLn3JXNJYZFiXInGB7FqxRxHYJ/re/lHprE5sngUMm11uOIA3bbtkk06I8DYxuwPD+e4sAeNfor0DkWmiCQFiNptkmiD2xGO1kIKGr/Tuu4bHe6z2NaS7Ih0c+Gpv+QbLY9ea122BXNSitM41sxUSlnWl+uJBIFoLqt66v/VfGIQos2lzhOOLDuScVxcyrqH3/FI4vaYB0b8gFHLXtxyX/9JpUCYNwlLZ1v5CeB99l0F795R5wl5UHRq1OYyKqsoIY07wJz2CT0TOf5/JRBPtJIIk5pOJ60SHayS9kMSKbI3fLLYztsY3B4MlSyoEfc9gL4yJVrPo+OGGunCK4p15UbCArJP/PQgUWDW4l+2P/tCqRRy2flIZL/nVeY/vyAfILUM5qEGfcFXXXrAit7skwDEFnD7mL1ATtyrz7HcodhzP7gShFhazIPm7X0+mTCeSWfrOr5WcvJfip19JRRLfXjuQpQjcNCuXo8kqkxQ68ukJQoxlnfjevc0WcKnGpUvyY54eJTS1IRWDqfHANukJLw56ts5yS6Nea7IrL6/78aKmZsch4Q694ujxgx5+0PhlGpzWimajpvkBOOUQlHLkJorzqu4e768L9nJtZWYturb7dsBxjzlNhd/gZcBuRgIUSdgZjg7Rx+f/zLcs4mAa3qDbJNUQVNbSg+dm0L3KH1uhesTPaErVYjZ8Isvfr+zfiX3DT0PlaOv+hdGvLUIlKSEcYHPMs0NtTGzyqMe74yciNFdAVZVzol/XtLsEqivKqfW7zWTCNCvZkPnnBlMv3UHW5RNNEJfuyR3MvYH/9E6gcts5GAwKIgCaBQ+V2Eh9O0IJkxFksPI1V9obqDKCpmPM55mLd+VQgRqgD+9XvsUxjbh/AXXPxOpc0FXFyJzc85aa1VQZa90LAWR4oinrBaOBr8DymCpFbdXMTn7Cv18S0hMR7T/o5VkRqN1g1/dvaDdZsRArO3bopkfee4efLF+hyVdcX4u3aNGTkWvLRafW+sXPktA1lla4UkSB7uJIULfxy/RAflk2miyw9xq9uVGgCNzqCv4iX+AUchfMkZdEgRZ9TZ+1CPTH2jXjMXjFl/+bEPzSjM7zPKKWhyZUgQG1lpp+DNz+Zz+85kD59q99U5R4B3vuI9WenCWqroy2U2Ruq6I+di5N/v9SmYnqJ5H1HLWCbIg6iVrn3s2gFBVFhrc1zzNqoFe275K3Jy1T0Mc5yeE1iRwO2b1L/j/S8jyvGDz6B3NMFEHErGHMM2+oJ5LobazyWEitdgMjQnsd0cjYrCqRpx8idpfwRq6hz/LleX6obpuJh/AGIu4sxD35hwkIEr5ShH8xro7tTDYK1GPHGylK6rp7NCG0lMr7YqwziMUBwXv0zPW667f3/IRLJRD7mkuwUP6mpkxyVjNlcBiAX12r//+WTuzWxsue7bsjRp7xFjpR2tRLqGHLvjYt3TpeybR82K61iLn+pOSWDfUv/HU8ecBtML+Gbz0v9vmlxSgZeBBzbGeP1KSqsH14ZM2kibgDhbS21hIALSOYFCE9LY+2CNvtzT2QuSJMiKP3zwvvs+/JkDwTg0jHVE0XH//U0nu5HKQtCL2KGDQYUgT7qIMVN/OoWqEz1oeG4wG7InZg47NE7rfHB2i7rkpYCUzaPfVtDYgTEPNpa8gXHI2Pp8A6YB8OYHkXDZMMcOL3rJD0Hxk+mRlsSJ12/7T52IcFst5zRc7uDJtQTXBdm9GvsvyXcBbMfKXWqsDSeEnFyPUXZGTafti4a0it8SN1qXxzBmzj+gVZ/FojNy+x73AuuqtJ/oaMZF6m5kbW6ItpfnUT/BrQunS+gLjTTUz0d8jTMpAfFQ40RQi9uM5qdFYzqk85hqSH1zsPOhiO5CN+hNZvL/RIs7m7LyLDuV80ZtyHHqVEngTVPBctHQhmcPjM30m1veDmHCXEpjybWAbgj3TqLUPNazzdHgxYmNuT7trWFcGOi7iTeL5YeK2yp2H98yoLN+skqhffZI/5n/ivceo44wJRY8bzC6DGwdgkMOulYhzW5m6OKyK2Mg+E3YE19L8ngE08TdAuNu0mIzd6kw0i03zzm4oqfVSZjZyxXnBhvt0v89EmnArya/UvHQrdQxBDAJagK2y+OqgBqzQ4FnUeiKfb7HFoUvFSknWhwq58TpBlVRZ0B0A7QWz7X4GLHcbdh5kFI/PKJ91OEh/kmnMEdh+Z23myFH8sXjR/KaHttrpz80N+bl0HM17RX48UjUWslrYHYW7oiHVgcGqTBoTrqK4JYwTTArFO1/APJ8DnEYf+wD92Dw15a9wrPxyJA88yYcv9RypzXLKAWmMuE0KAtIGjfKx1GbRQIq0AkttuRpBO7p4SGrTZuAOat3hTxXEcIKh3HgC1d88K7bz1+Jsi+y7tL/7zc0ZxCBB3hSxvP90GkUp1Lm2wuESafZyFy4Opir+o3gMWtDSuLF3LRHXTUGkKQtvARnwam8BuKv8Q2fHH/cEwPCQd3dhzgri8eTezRsQoGz6ha+S4E7ZzDB/LXwl04vA70NeVsf5rmv1TLvcQSNIBk3U6Qh6Bm+0905B91hopTLnTJRWZkUmbckEw0woG81azyw6LZaBL5Qx2HPvd3LHGLpN6mPZlto50NwW2zFOkgoPKV1gr142teD9aok2HNkPMepl3NIi78ShnAlJCzjZplteUoqz0+iUEOym1LZGGFHMBkc6/5f+sRCCFZZW6KrEby64o/ZfefQAPP6b5ko2fuujIv7uonIKXN6XiJsZmcOeGxteQ+b/ope3Z1HFeXYoW1AJrU/OiCpsyQP1Pr1BdQKFzS0oYnLCAweSnIh7qMFMRBMY7BcnJ5oskUbbRNiosqMzCYUAZPbo8tjCCsCBm5SoGcTHBMXcE+yQpl/OfBkcTw3oa4X7V+ohEh/Zkcv0cqc8sY40IsOW6lLiIrvYND/exZbRlOMgaHvb/QQKaY0k6Aamee2o3LVARCbIP4RoSd7u3CXkG+Iz6iFLfsN38F9xU4n3ueeVgiRs3jw70SMWu1QzDdiLsKtU1qvaLhv7dUbnLimdqYG+pa2aRZ8A6Q9JSr3yTs1MiAvfFHPQJTiqpI/hVUMmL6gPj6eL7lH0IkLCNcaogBA0TGfO0wO6ddf8Fju0L3YbRrWe8J3IewsNBCbpC2b6etQRJnSGLuWDiFoBez9hJHw6+bMQQGQS8YV/kzQ5AFHEqPaMgOjyR5zaHtlOBI4mjo8gdNItHUHQ7Bzq/E/xV1B+L0uoRcLIEj4hcv0yWQTwWLHzoFrvEZPygABpc4rnVjhfcBw5wOvaVVtgiG5qjklrTY1ZaXHkasyVYBd+lgo6zEHMumfK8XR2eD0cVn5w8l1uxGz2ACwtFob/CTV/TUx1kCKp+QROanLrNBiSPTxAf1eOFE+JifgAJ+pyrFqS/0wKlPWUVKlB2Bhu1Ggx2cvfdiR49VIsgBNnE75pf5lpFaQuz8+VPreUd/HLlW8kDSr25AnETsVRrOycLBPYD9/j/7Z0KKdOjtrM71AT+VsjD3D97aUDP5WrHp1DWghsk/lS/hp2VMwo0eqoEerLL/4/SlmyjStwWVDqF6jHC89niCwr1tMSe8GxeC9wjzMKmE7ZtdHOWqqc1OoTI24eVQc++crbyxSU4TxiB+vWoaAUpYQxZ06KKIPq6EvN/rN4DZ0/tQWYVqZ3FTIftPBfIuOWX3PonIKTUArpSvfmQRpkWD00wc3AQS98i4ZYaUbI+DGv90tuEKRjb2ocfdddC21YGUATYQmzelz7JqWBAQqKrWYdWEJlfPeRFZHtUm2MaISZsoOvURowxJKveGRegmBiKZ3d1cMFioJL33RoIKT0eDeK8FH/ybAhZU5TQIsWYmjyeT7EOLL5xZuRPf4qRIo6bbLtFOV6SX60fR8Smys/u1D5DjkmHJyr/woVAvBP2dxGo9gH1LgIm8XlFF1KSYvfj+0w7aTEfoFpcO+Jv3Ssbv8wwkED5JEC+jdln2dzToPNRtWiPbRb8f8G4aZX1j/2Vdbu7jM3gAVD5BKR+yJaOwLtwJodwjWu5di47tnNs9ahpnCUzVMObQfbTqMNs64MGANlgyihKjhwZ6p1Jsnro0/SfkOk6wx+HgUB6Mz9cUiF7KrJkhxnOVjCCcqPZglIojIRoDtkd2AkLNZC88GdP2qZV/1N6PBAe+fpgWZ36oHnewQ8CHdXcxbwQVjOn8U3qD9+e7FzWpg135vgdEMZ9fH5agDnNzdjKFZQ4tDsJs/S6Lk8FqjFJpHMjaRU6FI/DBDM0g+RRkxNoUvm14JAn5dgd6aVHt1aMkSXiJVenbm2FfrIEaFKHtm1erv1BJ5056ULL8AMGLmHav4yxg6F6n5oBq7bdP6zEr6f+QTDJ/KE1XfoG24JvVk2GL7Fb+me27otVFnq1e/2wEuqv6X+2zLQuJQszy5YJi/M5888fMy34L6z8ykD5sCHgzliAoAtEeoaFmnPT63kOYrZWspxYzqQBu/QKNyQ8e4QwKJUCVazmIUp6/zpLA3bWH2ch7QZN0rzWGxMRl3K1osWeETxL95TZSG/atM8LB9B92/71+g9UGWDPfD+lu/KdOQ85rocuHe91/gHA/iprG9PZ2juX49kaRxZ+1/sB3Ck35eWYBFsmCl0wC4QZWX5c5QMuSAEz1CJj0JWArSReV4D/vrgLw+EyhBB6aA4+B34PdlDaTLpm9q9Pkl+bzVWrSO+7uVrIECzsvk8RcmfmNSJretRcoI7ZcIfAqwciU9nJ8O4u1EgkcMOzC/MM2l6OYZRrGcqXCitp4LPXruVPzeD402JGV9grZyz9wJolMLC/YCcWs9CjiWv+DNRLaoSgD5M8T4PzmG8cXYM4jPo5SG1wY3QK/4wzVPrc33wI+AcGI//yXgvyBjocGrl768DMaYCGglwIit4r6t6ulwhwHJ4KeV3VHjspXXG4DIlDR2HNFvPaqkBViIvr433qZPuUINp6oi1LyVVC+EE1j6+wab8uPMeAo6e9uWYequvZynhnYazrvrDQJVkK3KZRoSR5BHi6vOC+AVCujMiQ1GVzGDZ4RFv8jFm7z5CU0iPH2JeXqUzqaKKP4P7osPkcIL99Y7fP3l+TzeFXO2kSpLIJW51oEY8DRIhqexGnxj0nmtGOseStuViIE2mJge45LENf77xjuI7egRNpzthNiajnuqikg0aQS1JqlIZf+hwSUlOp8BEQ0y3xiTOJkohBP3eyYiPDlZpFY88EWOpp4+hC/tQdhrQ56h2VJ2XA6vhPAbj+wH6iA2XYuTvRV25N8wNPQuA0Vzzem2ADZPFK2vr8l0I3GTV3fUN4S6FFYygW2Pu98f+lsgPf67rwVCbgMFAACW3P10GbxnK3SNuNK+VlPRiL7U3dK1o3spH/MFfDkgXuXjxDTxJrYctqHdwUg4rhUCNA13lGjuhJDatpFb/mExsBWS46aLFtROqVm8xQNPXK6A2rRfazJSWpIyh+FMmorXPXYnHQ7YLOmD4B5QTI8rzp7OomiarnaFs5syYjQ0ucc7g1/JzT446IFlDtpUL7DP9bLRCLJryUvi5R71/qX7ycqRSwunQ7+tfJz44Na3aJNszaMEZ/BV4iOGopabYdmvAPe+kIdGCNq5Q8fg8Ld0VNNXV0ZiiGej7zSA+pexy6wKC5k4rZa0k+qaN8bKq3oJWMQCSGaK7PrwMvA8t8BZTzjDqXcFTAIeRtl0SdlGSuAziVXItFcgAkeqwuNsbsrUZFcU6KUZLmvG415kHa0AwMFW2cNSUvPR0U9iCPh0nyslT92B5slYXiDWeSXvxHXItvjI8z5KCIVTIHqGZsbDBTr7WdHzcUAI1ipR86H3o0p2wPhfp7xg9oWOxWIK4a5BWdaV9OAPc0XuvlbwitCVtZDzZxGhIOl77ZgrRYR7LZQFE+Ih23hW3gI914ekkjgbKCi2bsqSAvij6GGj5p+k6evQtJp3qVh9vg+jiJvFCGcKBCITMWpqHZNKfE6IT0dKntS0rhu0DB5D9qIS0/RboNLsx2DlRMlx1QIBeBpHJNKdCL9uWM9eS7RJXKNOpraULtutuJYOl0apdE4LxfsyRSZb6fJkd51SHrI7lLB4vEg4fifJ1dqcWSeY4DgcyjrUcymK+gd3o+qj+3gHKWlLVdMUr3IeF8aClYBq+eeCV9Y7n1Ye8yL7rEvxY7jAlLwucKQ51pu59N8we8XwrbXPChBHXP4LnD3kDwQ85w1DKghtwvpO609fZOrPq8Q7GOOAjHhfR5VqvpoFne8oMHbCrWb1L0IdATo+h1PFeLLI8wc+FEyftLvskCdOtxKfAx3IEJXzBfWTKq5viKP/uu99dxnEpoNJhRtjSZGwOTWr7Ys44++P58O+nkYxd1Gcqm8G3Gh7AHSCxiPNyJWijI/lECrKrAXgBqkRShvdkd7IfoqUlziFDiglx+jdHnmRVmGnk3p/3n78M/HkzFUGZOS07cPnPn9jAnBWl4qDrB1ECf9idIKOdkJTKcZ690nuLW2yDsqwNpgrlT+wx2gv+Engha74lfVqbwqS15FRwuFDfq3bVCZcPy78TL2pH/DOdHeL9MFAtyybQNwHaO781rnJZAhR4M+AYWoSoa0EjQ99xivreM+FKwd7Jp/FC2vvvcq1z3RnRau/BM5KGkBPBSUBOzTNdfaJS/PWTDb1jRSgn2MuY3pVZbY9peHBVI3Ce/u70hg4f7MCVeAjYJfzTkDVLuB6jyjZs5Kko3u39ozgLK4LuwSbUrNIU5cl6Bs3De62AE084XRsm64Gs5W1ofxsWIZ9cYl8PNa5zQHl9ls5aiIKN0rHIIzBnLr03Kle2qq+n/gLDAzvF89vdZCvUFEHRoi9n33O3i49UWyeHP+ZAeRf+psM867nfqON092zE4Pj7AbLtvIUFJFr1y9Le0CL2flc7LUqbgGzOw4/q3vA/cJO5JeI8S+8bc1Y7pqYSzoEWSFn5G7EoPHTGHPMU6SeLKEeli+i8dHY3lWxSrIOU2y0TNo1SeRYewhVx05OXeVDf0xhHNckqp0arRk+bgToeSaHbVZ5nj3IH3m2oayt3sXY78qSPcDpc/5C7VXDRj6bROvvBG5JCsKl/yeMPAUn1flMsmr/FaFdb7gVUXnhLa+/Ilj87PpCC6rILQ6wkIP1ywEg0PztSEzbsJoRwQzDaxkiTN27YDnsy/YKfe6jKcqZWs64skzUAHIt+nXxju0dUVtbCSDAUXYw78Yd4bJKuYU8gbzLzgL4XIUC2HcPIVCUYvM7cybOBFVBdeGR4cOVB7QbGnohTRpiPrGqi1a8QXFBYqENawROuR43OG8dl+Jx4TpwAoi2kkPXW7b/ARSs4DO/z4H6oTIUpN3+/K6Iuc49C4/Uf1NxQTEE91VP8RnLKTpxjywMe2VxM1l4YGXSFY80HUAKIdqczBnnLMPklFV8mrr5hFDypn5TAT00ruU6AjDPNvncoVzX4ac6wAzTwrNH7oz1XLH1wzjQs5k7hcNLbznXQGB7M+rXxKtZXPrz1Ar+OxYGDkJvElknZsHD/IcxRd7ujmmLYpDDbverynroCnSKVQWEGjHL57PaI/WokvhYRpPMk4ni2EUhjDuIF+IU2R0fs40i+66bw8sz8OzyC2eFAxxicd2n5Juta2eWa9KtObD7xLmPvtK+8cjQt+NLjcZCTt+Ss9p1od0bklVgaIV1qJbWxUOr6iUzLDzFefYxAtyRcBr53IaDB25n60KQdhroQWMUpuWSUpELSFxiu4vgQeRoEZe78/ua3TlrszB8sLVZoecnV9YMYz+HkZA/pLqbFhzurB52Wl/WEM6sVk4q04OnzWZFi76JkcGgeeUyYUIwhCDMdIfTUdD4wQpYm3LBw0sp33CVK2q305jeyzgGnBzSMXjesm4XjcEhhrjPSLtwqqoaFCqD5DlHYhoTVafWtBUQXoNfDk19IFxq8sImCcqgMhOToIZUO2530aasY908dMX2nTMFjgv+lapdI8k/e0a7pFw6X3Tgf0m99bbCpOzVgRu2Dw/13CehVfFj+8BeKP6SZV4g/qiX42NWP568PzMajFm2ANmKtHjEIAIc2hc1iecBR9elGP4LmAQwAVmZT8kWc7JSY0ag583ch/Z16krGrjn2YdIaa22egy4/niU6m0WAG3K/yP65cfL//CP+JzcnoLHQFb/KJQeBrEbR1/IKo+YOFXWIQ8ghNxYdMwa49NeXzFqFOIXTmk3w/v5KneS8sGHiPGACh0DE9a1uLAochB79g3IqYObhlswemMucZnAE7dBkp5OAfToa5gHFbIPcec0fVWEOOLftQXsuffyv3wo1LWDDm+SyNMWgSEWtjMyYkjLjTkUtmj7DQlfbpHf38lDvoEN9d2ALxnWCjph4jvfEIRbHvltKbvE2BiYlz45mnJPeFrwZcBny3k0/pyXNrSbEIWvvZw14Y0Fqy4tba1Fu0yNNYaf47jfnz7VCCxKsrJz5oz3F8jXUdQqFu+gDq6EzvKDipXf/3NmcsCC74VB3OgHPgN7W9cU54pjGFDMfifl3m5Vhy21uk1U2nYCrddrifkpwGLYmLSSQAAjC6M3yB1fc6KHpgDnMXh2bYX2ns+Qma+DBgyCkZ0TqZK8Mp2Sryx7HdMM74X9hrwYhQbwlK+zgATAXRzQyS+hK4OTnP17/cyJ2WzY6DChYWGJYXGCnEdMswF5VTYQdSyTpdLXYuh+x2Qr7DR3H2x+YdP0qsLAzYJIWKwrrKkpBgWCmgNCn5t+QbWqf/LoLuvjgDFLtMoxNK5axIA9kammelvwh5ZI52ktrEm/OVEESPQPZGHAIhP7oWDBnGnuzG45XOTpZWsxwNO4UiyxH8riTvQq4JVq5GwX3yqVCbSR0ef/gVYDgiYaiD2EAAxuEPKyXTp/HhL96eVTpaDqFEoV2x1PP/UMcs/XqeGc1gZQG1ot6YxaIEWHanYavH9YdLFjlyU5yrYALVg/sxBjT39oD+BIXvf4LTbvvvpX3srxckEX1XAM9s2uajUTlpPq32mcx4T+sibdQEHQV2WmgwMhbYovh7WWTPfLF03ZbV5a+ElsSIyH6kgJ8+D6aN/6f+ZstkZOYZYx9GbagcrEqwNblz0iZ9NTyvIAeNn3Oup7rtyD4wVE0PoqcnR/LoSK1s1esmOGPjs3zHB8xW4iL8IrhqAJfsWNBYW9TGR11C3KZJaN7MP4O5Ykmpvw94hHzVmsYA68RQdFYfPlFOgCNBoSdy5ODcv11l9bLs135M4okEc4/e8hQczcz2PWipIVSBxa/5sr9xyTFbjG4xm8f4LmrAhD1uEDGrFDl/6X7Nw7/WZPW7fZJGYN8eZ68Td5KGfJyKjD+pTysvTi+8Q8R0L9wKAxAUrYswdvAuiNeenxSplQZjYTxbcH/wP97fOY215SozY3UDRhv7lomztURB2O2UriTX3oAiTKoInkHQietZyhBQ9wMTVHgMrxOP5T/0gN14eFTz0m2D6/iJMbXYGHdIkKEGV2Voa8k/hVNvAVAZKrDEXthUxotwYkYysTDk8j27XEVy+4a30jopuAp5+/xWYb0ne6lwKZwR3j6kDXroOOtrHqWlkJHSWLoPEQJQo/ARzR8UBZSckmeBPn3gJwY62Zo2dyy1AyRRDQBFAJKH9KX+7auP8U8XDo7mMSzq5ZxmaJ5bLpNg4ZM7938SAjMHcu1yB4+lkHnVLnIp86AOPgigH+ZFDRq1QuKWK3pK5JkLDJdakj176NCbjXDASt1h/t1p+GHyKbAoevHSnHuPfoBmQ3nJrDjOhPfwVYi8V5r0KB8BsrfFu8BvhYCbNrvCVnd4Q8RktqIR/ZilioC6g3++L7PHzuXa8NFSF5zd+ISzGLTjrfaKXsBFCkkK0ksSDbl91yXUghMFOskQBeUoo7o3wuIsE29goRIORuJ4b1jSumvR0gR8B21iyW1G4FqHkZOlWz9zq5FnaJX1WbeAxe2DfGSAnw4cqDwg3LFalk6eH89Sdc41Fr6voEa0hfwdkb54yOM7WevDugT1FRzEqdg9zZZ44ZAKGH3ZyqFve3SE4UDN6tLmIFTdIwMrtYRXWBQDB7vvqOuYj7cN31av64+jg/g1uce+am3TOl0cUUL6s0l35FJ9p8vJcG+G8lAFqC0pdmd/aaWYpqDLvB5LEasLMgbPN2N+Wvkh6HYxPOrZEfoxQX/67AzcWOR0K3eYGOgQhyWL7cwKGlxmY/E2b8CKi6Ssgok+7B+zTtq/DXmaDAHRnwbwvCDJ9pITO5RQgBuprEWT0avZv7QjbzITYD8Fzgy4TSYG3z9tLso0Z7MfgHDLKU+kHrzxWkBPwJRydKMXG4AaCA7mlAmjzpNhGOrMGZGZlHSjPbmO5jPd/lKBrViZ0BaXMmqaFOwA/f03O04qQX6MSVA37+SA5Pne/KP7caLJKuOCJXoXpzArUrYesMVc/RXnOv03YrwKgPlR2SjpqIycyulmodZBy6gVc1jA9y6lJqWgR6SY6tc24sVcYuh2GaTeikYJnhr2d6BiL3oLx8M8wuJBdI3FRVIIAx4XougScOw2xWgwUoSYKeLUHc310kVBzSE/vFeHAjlUil8KZftctMgwGjwrhMbjDbK4rB32fTe9jnsqijdp5kOwkD9+klel+lNh3joAFQ");const d=new Map([[8217,"apostrophe"],[8260,"fraction slash"],[12539,"middle dot"]]);function p(e){return`{${function(e){return e.toString(16).toUpperCase().padStart(2,"0")}(e)}}`}function m(e){let t=[];for(let r=0,n=e.length;r>24&255}function w(e){return 16777215&e}const A=new Map(a(b).flatMap(((e,t)=>e.map((e=>[e,t+1<<24]))))),S=new Set(o(b)),k=new Map,E=new Map;for(let[e,t]of s(b)){if(!S.has(e)&&2==t.length){let[r,n]=t,i=E.get(r);i||(i=new Map,E.set(r,i)),i.set(n,e)}k.set(e,t.reverse())}const _=44032,M=4352,T=4449,x=4519,P=28,I=588;function O(e){return e>=_&&e<55204}function R(e,t){if(e>=M&&e<4371&&t>=T&&t<4470)return _+(e-M)*I+(t-T)*P;if(O(e)&&t>x&&t<4547&&(e-_)%P==0)return e+(t-x);{let r=E.get(e);return r&&(r=r.get(t),r)?r:-1}}function C(e){let t=[],r=[],n=!1;function i(e){let r=A.get(e);r&&(n=!0,e|=r),t.push(e)}for(let n of e)for(;;){if(n<128)t.push(n);else if(O(n)){let e=n-_,t=e%I/P|0,r=e%P;i(M+(e/I|0)),i(T+t),r>0&&i(x+r)}else{let e=k.get(n);e?r.push(...e):i(n)}if(!r.length)break;n=r.pop()}if(n&&t.length>1){let e=v(t[0]);for(let r=1;r0&&i>=e)0==e?(t.push(n,...r),r.length=0,n=a):r.push(a),i=e;else{let o=R(n,a);o>=0?n=o:0==i&&0==e?(t.push(n),n=a):(r.push(a),i=e)}}return n>=0&&t.push(n,...r),t}(C(e))}const L=65039,U=".";function F(){return new Set(o(h))}const D=new Map(s(h)),j=F(),H=F(),J=F(),z=F(),G=a(h);function q(){return new Set([o(h).map((e=>G[e])),o(h)].flat(2))}const K=h(),V=u((e=>{let t=u(h).map((e=>e+96));if(t.length){let r=e>=K;t[0]-=32,t=y(t),r&&(t=`Restricted[${t}]`);let n=q(),i=q(),o=[...n,...i].sort(((e,t)=>e-t));return{N:t,P:n,M:h()-1,R:r,V:new Set(o)}}})),X=F(),Q=new Map;[...X,...F()].sort(((e,t)=>e-t)).map(((e,t,r)=>{let n=h(),i=r[t]=n?r[t-n]:{V:[],M:new Map};i.V.push(e),X.has(e)||Q.set(e,i)}));for(let{V:e,M:t}of new Set(Q.values())){let r=[];for(let t of e){let e=V.filter((e=>e.V.has(t))),n=r.find((({G:t})=>e.some((e=>t.has(e)))));n||(n={G:new Set,V:[]},r.push(n)),n.V.push(t),e.forEach((e=>n.G.add(e)))}let n=r.flatMap((({G:e})=>[...e]));for(let{G:e,V:i}of r){let r=new Set(n.filter((t=>!e.has(t))));for(let e of i)t.set(e,r)}}let W=new Set,Z=new Set;for(let e of V)for(let t of e.V)(W.has(t)?Z:W).add(t);for(let e of W)Q.has(e)||Z.has(e)||Q.set(e,1);const Y=new Set([...W,...B(W)]),$=o(h),ee=function e(t){let r=u((()=>{let t=o(h).map((e=>$[e]));if(t.length)return e(t)})).sort(((e,t)=>t.Q.size-e.Q.size)),n=h(),i=n%3;n=n/3|0;let a=1&n;return n>>=1,{B:r,V:i,F:a,S:1&n,C:2&n,Q:new Set(t)}}([]);class te extends Array{get is_emoji(){return!0}}function re(e,t=p){let r=[];oe(e[0])&&r.push("◌");let n=0,i=e.length;for(let o=0;o0;)if(95!==e[--t])throw new Error("underscore allowed only at start")}function oe(e){return H.has(e)}function ae(e){return J.has(e)}function se(e,t){let r=0;return e.split(U).map((e=>{let n,i=m(e),o={input:i,offset:r};r+=i.length+1;try{let e,r=o.tokens=he(i,N),a=r.length;if(!a)throw new Error("empty label");{let i=r[0],s=a>1||i.is_emoji;if(!s&&i.every((e=>e<128)))n=i,ie(n),function(e){if(e.length>=4&&45==e[2]&&45==e[3])throw new Error("invalid label extension")}(n),e="ASCII";else if(s&&(o.emoji=!0,i=r.flatMap((e=>e.is_emoji?[]:e))),n=r.flatMap((e=>!t&&e.is_emoji?de(e):e)),ie(n),i.length){if(H.has(n[0]))throw fe("leading combining mark");for(let e=1;ee.V.has(r)));if(!e.length)throw t===V?ce(r):le(t[0],r);if(t=e,1==e.length)break}return t}(t);!function(e,t){let{V:r,M:n}=e;for(let n of t)if(!r.has(n))throw le(e,n);if(n>=0){for(let r=1,i=B(t).length;rn)throw new Error(`too many combining marks: ${e.N} "${y(t.slice(r-1,o))}" (${o-r}/${n})`);r=o}}}(o,i),function(e,t){let r,n=[];for(let e of t){let t=Q.get(e);if(1===t)return;if(t){let n=t.M.get(e);if(r=r?r.filter((e=>n.has(e))):[...n],!r.length)return}else n.push(e)}if(r)for(let t of r)if(n.every((e=>t.V.has(e))))throw new Error(`whole-script confusable: ${e.N}/${t.N}`)}(o,t),e=o.N}else e="Emoji"}o.type=e}catch(e){o.error=e}return o.output=n,o}))}function ue(e){return e.map((({input:t,error:r,output:n})=>{if(r){let n=r.message;throw new Error(1==e.length?n:`Invalid label "${re(t)}": ${n}`)}return y(n)})).join(U)}function ce(e){return new Error(`disallowed character: ${ne(e)}`)}function le(e,t){let r=ne(t),n=V.find((e=>e.P.has(t)));return n&&(r=`${n.N} ${r}`),new Error(`illegal mixture: ${e.N} + ${r}`)}function fe(e){return new Error(`illegal placement: ${e}`)}function he(e,t){let r=[],n=[];for(e=e.slice().reverse();e.length;){let i=pe(e);if(i)n.length&&(r.push(t(n)),n=[]),r.push(i);else{let t=e.pop();if(Y.has(t))n.push(t);else{let e=D.get(t);if(e)n.push(...e);else if(!j.has(t))throw ce(t)}}}return n.length&&r.push(t(n)),r}function de(e){return e.filter((e=>e!=L))}function pe(e,t){let r,n,i=ee,o=[],a=e.length;for(t&&(t.length=0);a;){let s=e[--a];if(i=i.B.find((e=>e.Q.has(s))),!i)break;if(i.S)n=s;else if(i.C&&s===n)break;o.push(s),i.F&&(o.push(L),a>0&&e[a-1]==L&&a--),i.V&&(r=me(o,i),t&&t.push(...e.slice(a).reverse()),e.length=a)}return r}function me(e,t){let r=te.from(e);return 2==t.V&&r.splice(1,1),r}const ye="valid",ge="mapped",be="ignored";function ve(e){return e==ye||e==ge}function we(e){return e.some((e=>z.has(e)))}function Ae(e){for(let t=0;te.cps))})}return e}t.ens_beautify=function(e){let t=se(e,!0);for(let{type:e,output:r,error:n}of t)if(!n&&"Greek"!==e){let e=0;for(;;){let t=r.indexOf(958,e);if(t<0)break;r[t]=926,e=t+1}}return ue(t)},t.ens_emoji=function(){let e=[];return function t(r,n,i){if(r.S)i=n[n.length-1];else if(r.C&&i===n[n.length-1])return;r.F&&n.push(L);r.V&&e.push(me(n,r));for(let e of r.B)for(let r of e.Q)t(e,[...n,r],i)}(ee,[]),e.sort(g)},t.ens_normalize=function(e){return ue(se(e))},t.ens_normalize_fragment=function(e,t){let r=t?B:N;return e.split(U).map((e=>y(he(m(e),r).flatMap((e=>e.is_emoji?de(e):e))))).join(U)},t.ens_split=se,t.ens_tokenize=function e(t,{nf:r=!0}={}){let n=m(t).reverse(),i=[],o=[];for(;n.length;){let e=pe(n,i);if(e)o.push({type:"emoji",emoji:e,input:i.slice(),cps:de(e)});else{let e=n.pop();if(46==e)o.push({type:"stop",cp:e});else if(Y.has(e))o.push({type:ye,cps:[e]});else if(j.has(e))o.push({type:be,cp:e});else{let t=D.get(e);t?o.push({type:ge,cp:e,cps:t.slice()}):o.push({type:"disallowed",cp:e})}}}if(r)for(let t=0,r=-1;tve(e.type)?e.cps:[])),s=N(a);g(s,a)?(o.splice(r,n-r,{type:"nfc",input:a,cps:s,tokens0:Ae(i),tokens:e(y(s),{nf:!1})}),t=r):t=n-1,r=-1}else r=t;else n.type!==be&&(r=-1)}return Ae(o)},t.is_combining_mark=oe,t.nfc=N,t.nfd=B,t.safe_str_from_cps=re,t.should_escape=ae},40517:function(e,t){"use strict";var r,n,i,o=this&&this.__classPrivateFieldSet||function(e,t,r,n,i){if("m"===n)throw new TypeError("Private method is not writable");if("a"===n&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===n?i.call(e,r):i?i.value=r:t.set(e,r),r},a=this&&this.__classPrivateFieldGet||function(e,t,r,n){if("a"===r&&!n)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?n:"a"===r?n.call(e):n?n.value:t.get(e)};Object.defineProperty(t,"__esModule",{value:!0}),t.AES=void 0;const s={16:10,24:12,32:14},u=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],c=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],l=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],f=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],h=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],d=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],p=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],m=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],y=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],g=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],b=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],v=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],w=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],A=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],S=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function k(e){const t=[];for(let r=0;r>2,a(this,i,"f")[d][e%4]=h[e],a(this,n,"f")[t-d][e%4]=h[e];let p,m=0,y=f;for(;y>16&255]<<24^c[p>>8&255]<<16^c[255&p]<<8^c[p>>24&255]^u[m]<<24,m+=1,8!=f)for(let e=1;e>8&255]<<8^c[p>>16&255]<<16^c[p>>24&255]<<24;for(let e=f/2+1;e>2,r=y%4,a(this,i,"f")[e][r]=h[o],a(this,n,"f")[t-e][r]=h[o++],y++}for(let e=1;e>24&255]^w[p>>16&255]^A[p>>8&255]^S[255&p]}get key(){return a(this,r,"f").slice()}encrypt(e){if(16!=e.length)throw new TypeError("invalid plaintext size (must be 16 bytes)");const t=a(this,i,"f").length-1,r=[0,0,0,0];let n=k(e);for(let e=0;e<4;e++)n[e]^=a(this,i,"f")[0][e];for(let e=1;e>24&255]^h[n[(t+1)%4]>>16&255]^d[n[(t+2)%4]>>8&255]^p[255&n[(t+3)%4]]^a(this,i,"f")[e][t];n=r.slice()}const o=new Uint8Array(16);let s=0;for(let e=0;e<4;e++)s=a(this,i,"f")[t][e],o[4*e]=255&(c[n[e]>>24&255]^s>>24),o[4*e+1]=255&(c[n[(e+1)%4]>>16&255]^s>>16),o[4*e+2]=255&(c[n[(e+2)%4]>>8&255]^s>>8),o[4*e+3]=255&(c[255&n[(e+3)%4]]^s);return o}decrypt(e){if(16!=e.length)throw new TypeError("invalid ciphertext size (must be 16 bytes)");const t=a(this,n,"f").length-1,r=[0,0,0,0];let i=k(e);for(let e=0;e<4;e++)i[e]^=a(this,n,"f")[0][e];for(let e=1;e>24&255]^y[i[(t+3)%4]>>16&255]^g[i[(t+2)%4]>>8&255]^b[255&i[(t+1)%4]]^a(this,n,"f")[e][t];i=r.slice()}const o=new Uint8Array(16);let s=0;for(let e=0;e<4;e++)s=a(this,n,"f")[t][e],o[4*e]=255&(l[i[e]>>24&255]^s>>24),o[4*e+1]=255&(l[i[(e+3)%4]>>16&255]^s>>16),o[4*e+2]=255&(l[i[(e+2)%4]>>8&255]^s>>8),o[4*e+3]=255&(l[255&i[(e+1)%4]]^s);return o}}t.AES=E,r=new WeakMap,n=new WeakMap,i=new WeakMap},93260:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pkcs7Strip=t.pkcs7Pad=t.OFB=t.ECB=t.CTR=t.CFB=t.CBC=t.ModeOfOperation=t.AES=void 0;var n=r(40517);Object.defineProperty(t,"AES",{enumerable:!0,get:function(){return n.AES}});var i=r(2868);Object.defineProperty(t,"ModeOfOperation",{enumerable:!0,get:function(){return i.ModeOfOperation}});var o=r(52805);Object.defineProperty(t,"CBC",{enumerable:!0,get:function(){return o.CBC}});var a=r(73169);Object.defineProperty(t,"CFB",{enumerable:!0,get:function(){return a.CFB}});var s=r(83310);Object.defineProperty(t,"CTR",{enumerable:!0,get:function(){return s.CTR}});var u=r(89915);Object.defineProperty(t,"ECB",{enumerable:!0,get:function(){return u.ECB}});var c=r(22023);Object.defineProperty(t,"OFB",{enumerable:!0,get:function(){return c.OFB}});var l=r(99533);Object.defineProperty(t,"pkcs7Pad",{enumerable:!0,get:function(){return l.pkcs7Pad}}),Object.defineProperty(t,"pkcs7Strip",{enumerable:!0,get:function(){return l.pkcs7Strip}})},52805:function(e,t,r){"use strict";var n,i,o=this&&this.__classPrivateFieldSet||function(e,t,r,n,i){if("m"===n)throw new TypeError("Private method is not writable");if("a"===n&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===n?i.call(e,r):i?i.value=r:t.set(e,r),r},a=this&&this.__classPrivateFieldGet||function(e,t,r,n){if("a"===r&&!n)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?n:"a"===r?n.call(e):n?n.value:t.get(e)};Object.defineProperty(t,"__esModule",{value:!0}),t.CBC=void 0;const s=r(2868);class u extends s.ModeOfOperation{constructor(e,t){if(super("ECC",e,u),n.set(this,void 0),i.set(this,void 0),t){if(t.length%16)throw new TypeError("invalid iv size (must be 16 bytes)");o(this,n,new Uint8Array(t),"f")}else o(this,n,new Uint8Array(16),"f");o(this,i,this.iv,"f")}get iv(){return new Uint8Array(a(this,n,"f"))}encrypt(e){if(e.length%16)throw new TypeError("invalid plaintext size (must be multiple of 16 bytes)");const t=new Uint8Array(e.length);for(let r=0;rNumber.MAX_SAFE_INTEGER)throw new TypeError("invalid counter initial integer value");for(let t=15;t>=0;--t)s(this,o,"f")[t]=e%256,e=Math.floor(e/256)}setCounterBytes(e){if(16!==e.length)throw new TypeError("invalid counter initial Uint8Array value length");s(this,o,"f").set(e)}increment(){for(let e=15;e>=0;e--){if(255!==s(this,o,"f")[e]){s(this,o,"f")[e]++;break}s(this,o,"f")[e]=0}}encrypt(e){var t,r;const u=new Uint8Array(e);for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ECB=void 0;const n=r(2868);class i extends n.ModeOfOperation{constructor(e){super("ECB",e,i)}encrypt(e){if(e.length%16)throw new TypeError("invalid plaintext size (must be multiple of 16 bytes)");const t=new Uint8Array(e.length);for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ModeOfOperation=void 0;const n=r(40517);t.ModeOfOperation=class{constructor(e,t,r){if(r&&!(this instanceof r))throw new Error(`${e} must be instantiated with "new"`);Object.defineProperties(this,{aes:{enumerable:!0,value:new n.AES(t)},name:{enumerable:!0,value:e}})}}},99533:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pkcs7Strip=t.pkcs7Pad=void 0,t.pkcs7Pad=function(e){const t=16-e.length%16,r=new Uint8Array(e.length+t);r.set(e);for(let n=e.length;n16)throw new TypeError("PKCS#7 padding byte out of range");const r=e.length-t;for(let n=0;n{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="6.1.0"},54760:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AbiCoder=void 0;const n=r(42120),i=r(12900),o=r(32063),a=r(8151),s=r(38583),u=r(5949),c=r(4148),l=r(36341),f=r(96893),h=r(53524),d=r(46701),p=r(66711),m=r(45475),y=r(42120),g=new Map;g.set(0,"GENERIC_PANIC"),g.set(1,"ASSERT_FALSE"),g.set(17,"OVERFLOW"),g.set(18,"DIVIDE_BY_ZERO"),g.set(33,"ENUM_RANGE_ERROR"),g.set(34,"BAD_STORAGE_DATA"),g.set(49,"STACK_UNDERFLOW"),g.set(50,"ARRAY_RANGE_ERROR"),g.set(65,"OUT_OF_MEMORY"),g.set(81,"UNINITIALIZED_FUNCTION_CALL");const b=new RegExp(/^bytes([0-9]*)$/),v=new RegExp(/^(u?int)([0-9]*)$/);let w=null;class A{#e(e){if(e.isArray())return new a.ArrayCoder(this.#e(e.arrayChildren),e.arrayLength,e.name);if(e.isTuple())return new d.TupleCoder(e.components.map((e=>this.#e(e))),e.name);switch(e.baseType){case"address":return new o.AddressCoder(e.name);case"bool":return new s.BooleanCoder(e.name);case"string":return new h.StringCoder(e.name);case"bytes":return new u.BytesCoder(e.name);case"":return new l.NullCoder(e.name)}let t=e.type.match(v);if(t){let r=parseInt(t[2]||"256");return(0,n.assertArgument)(0!==r&&r<=256&&r%8==0,"invalid "+t[1]+" bit length","param",e),new f.NumberCoder(r/8,"int"===t[1],e.name)}if(t=e.type.match(b),t){let r=parseInt(t[1]);return(0,n.assertArgument)(0!==r&&r<=32,"invalid bytes length","param",e),new c.FixedBytesCoder(r,e.name)}(0,n.assertArgument)(!1,"invalid type","type",e.type)}getDefaultValue(e){const t=e.map((e=>this.#e(p.ParamType.from(e))));return new d.TupleCoder(t,"_").defaultValue()}encode(e,t){(0,n.assertArgumentCount)(t.length,e.length,"types/values length mismatch");const r=e.map((e=>this.#e(p.ParamType.from(e)))),o=new d.TupleCoder(r,"_"),a=new i.Writer;return o.encode(a,t),a.data}decode(e,t,r){const n=e.map((e=>this.#e(p.ParamType.from(e))));return new d.TupleCoder(n,"_").decode(new i.Reader(t,r))}static defaultAbiCoder(){return null==w&&(w=new A),w}static getBuiltinCallException(e,t,r){return function(e,t,r,n){let i="missing revert data",o=null,a=null;if(r){i="execution reverted";const e=(0,y.getBytes)(r);if(r=(0,y.hexlify)(r),0===e.length)i+=" (no data present; likely require(false) occurred",o="require(false)";else if(e.length%32!=4)i+=" (could not decode reason; invalid data length)";else if("0x08c379a0"===(0,y.hexlify)(e.slice(0,4)))try{o=n.decode(["string"],e.slice(4))[0],a={signature:"Error(string)",name:"Error",args:[o]},i+=`: ${JSON.stringify(o)}`}catch(e){i+=" (could not decode reason; invalid string data)"}else if("0x4e487b71"===(0,y.hexlify)(e.slice(0,4)))try{const t=Number(n.decode(["uint256"],e.slice(4))[0]);a={signature:"Panic(uint256)",name:"Panic",args:[t]},o=`Panic due to ${g.get(t)||"UNKNOWN"}(${t})`,i+=`: ${o}`}catch(e){i+=" (could not decode panic code)"}else i+=" (unknown custom error)"}const s={to:t.to?(0,m.getAddress)(t.to):null,data:t.data||"0x"};return t.from&&(s.from=(0,m.getAddress)(t.from)),(0,y.makeError)(i,"CALL_EXCEPTION",{action:e,data:r,reason:o,transaction:s,invocation:null,revert:a})}(e,t,r,A.defaultAbiCoder())}}t.AbiCoder=A},12472:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBytes32String=t.encodeBytes32String=void 0;const n=r(42120);t.encodeBytes32String=function(e){const t=(0,n.toUtf8Bytes)(e);if(t.length>31)throw new Error("bytes32 string must be less than 32 bytes");return(0,n.zeroPadBytes)(t,32)},t.decodeBytes32String=function(e){const t=(0,n.getBytes)(e,"bytes");if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");let r=31;for(;0===t[r-1];)r--;return(0,n.toUtf8String)(t.slice(0,r))}},12900:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Reader=t.Writer=t.Coder=t.checkResultErrors=t.Result=t.WordSize=void 0;const n=r(42120);t.WordSize=32;const i=new Uint8Array(t.WordSize),o=["then"],a={};function s(e,t){const r=new Error(`deferred error during ABI decoding triggered accessing ${e}`);throw r.error=t,r}class u extends Array{#t;constructor(...e){const t=e[0];let r=e[1],i=(e[2]||[]).slice(),u=!0;t!==a&&(r=e,i=[],u=!1),super(r.length),r.forEach(((e,t)=>{this[t]=e}));const c=i.reduce(((e,t)=>("string"==typeof t&&e.set(t,(e.get(t)||0)+1),e)),new Map);if(this.#t=Object.freeze(r.map(((e,t)=>{const r=i[t];return null!=r&&1===c.get(r)?r:null}))),u)return Object.freeze(this),new Proxy(this,{get:(e,t,r)=>{if("string"==typeof t){if(t.match(/^[0-9]+$/)){const r=(0,n.getNumber)(t,"%index");if(r<0||r>=this.length)throw new RangeError("out of result range");const i=e[r];return i instanceof Error&&s(`index ${r}`,i),i}if(o.indexOf(t)>=0)return Reflect.get(e,t,r);const i=e[t];if(i instanceof Function)return function(...t){return i.apply(this===r?e:this,t)};if(!(t in e))return e.getValue.apply(this===r?e:this,[t])}return Reflect.get(e,t,r)}})}toArray(){const e=[];return this.forEach(((t,r)=>{t instanceof Error&&s(`index ${r}`,t),e.push(t)})),e}toObject(){return this.#t.reduce(((e,t,r)=>((0,n.assert)(null!=t,"value at index ${ index } unnamed","UNSUPPORTED_OPERATION",{operation:"toObject()"}),t in e||(e[t]=this.getValue(t)),e)),{})}slice(e,t){null==e&&(e=0),e<0&&(e+=this.length)<0&&(e=0),null==t&&(t=this.length),t<0&&(t+=this.length)<0&&(t=0),t>this.length&&(t=this.length);const r=[],n=[];for(let i=e;i{this.#r[e]=c(t)}}};class l{allowLoose;#r;#o;constructor(e,t){(0,n.defineProperties)(this,{allowLoose:!!t}),this.#r=(0,n.getBytesCopy)(e),this.#o=0}get data(){return(0,n.hexlify)(this.#r)}get dataLength(){return this.#r.length}get consumed(){return this.#o}get bytes(){return new Uint8Array(this.#r)}#a(e,r,i){let o=Math.ceil(r/t.WordSize)*t.WordSize;return this.#o+o>this.#r.length&&(this.allowLoose&&i&&this.#o+r<=this.#r.length?o=r:(0,n.assert)(!1,"data out-of-bounds","BUFFER_OVERRUN",{buffer:(0,n.getBytesCopy)(this.#r),length:this.#r.length,offset:this.#o+o})),this.#r.slice(this.#o,this.#o+o)}subReader(e){return new l(this.#r.slice(this.#o+e),this.allowLoose)}readBytes(e,t){let r=this.#a(0,e,!!t);return this.#o+=r.length,r.slice(0,e)}readValue(){return(0,n.toBigInt)(this.readBytes(t.WordSize))}readIndex(){return(0,n.toNumber)(this.readBytes(t.WordSize))}}t.Reader=l},32063:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AddressCoder=void 0;const n=r(45475),i=r(90358),o=r(3762),a=r(12900);class s extends a.Coder{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,t){let r=o.Typed.dereference(t,"string");try{r=(0,n.getAddress)(r)}catch(e){return this._throwError(e.message,t)}return e.writeValue(r)}decode(e){return(0,n.getAddress)((0,i.toBeHex)(e.readValue(),20))}}t.AddressCoder=s},56347:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AnonymousCoder=void 0;const n=r(12900);class i extends n.Coder{coder;constructor(e){super(e.name,e.type,"_",e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,t){return this.coder.encode(e,t)}decode(e){return this.coder.decode(e)}}t.AnonymousCoder=i},8151:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ArrayCoder=t.unpack=t.pack=void 0;const n=r(42120),i=r(3762),o=r(12900),a=r(56347);function s(e,t,r){let i=[];if(Array.isArray(r))i=r;else if(r&&"object"==typeof r){let e={};i=t.map((t=>{const i=t.localName;return(0,n.assert)(i,"cannot encode object for signature with missing names","INVALID_ARGUMENT",{argument:"values",info:{coder:t},value:r}),(0,n.assert)(!e[i],"cannot encode object for signature with duplicate names","INVALID_ARGUMENT",{argument:"values",info:{coder:t},value:r}),e[i]=!0,r[i]}))}else(0,n.assertArgument)(!1,"invalid tuple value","tuple",r);(0,n.assertArgument)(t.length===i.length,"types/value length mismatch","tuple",r);let a=new o.Writer,s=new o.Writer,u=[];t.forEach(((e,t)=>{let r=i[t];if(e.dynamic){let t=s.length;e.encode(s,r);let n=a.writeUpdatableValue();u.push((e=>{n(e+t)}))}else e.encode(a,r)})),u.forEach((e=>{e(a.length)}));let c=e.appendWriter(a);return c+=e.appendWriter(s),c}function u(e,t){let r=[],i=[],a=e.subReader(0);return t.forEach((t=>{let o=null;if(t.dynamic){let r=e.readIndex(),i=a.subReader(r);try{o=t.decode(i)}catch(e){if((0,n.isError)(e,"BUFFER_OVERRUN"))throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}}else try{o=t.decode(e)}catch(e){if((0,n.isError)(e,"BUFFER_OVERRUN"))throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}if(null==o)throw new Error("investigate");r.push(o),i.push(t.localName||null)})),o.Result.fromItems(r,i)}t.pack=s,t.unpack=u;class c extends o.Coder{coder;length;constructor(e,t,r){super("array",e.type+"["+(t>=0?t:"")+"]",r,-1===t||e.dynamic),(0,n.defineProperties)(this,{coder:e,length:t})}defaultValue(){const e=this.coder.defaultValue(),t=[];for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BooleanCoder=void 0;const n=r(3762),i=r(12900);class o extends i.Coder{constructor(e){super("bool","bool",e,!1)}defaultValue(){return!1}encode(e,t){const r=n.Typed.dereference(t,"bool");return e.writeValue(r?1:0)}decode(e){return!!e.readValue()}}t.BooleanCoder=o},5949:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BytesCoder=t.DynamicBytesCoder=void 0;const n=r(42120),i=r(12900);class o extends i.Coder{constructor(e,t){super(e,e,t,!0)}defaultValue(){return"0x"}encode(e,t){t=(0,n.getBytesCopy)(t);let r=e.writeValue(t.length);return r+=e.writeBytes(t),r}decode(e){return e.readBytes(e.readIndex(),!0)}}t.DynamicBytesCoder=o;t.BytesCoder=class extends o{constructor(e){super("bytes",e)}decode(e){return(0,n.hexlify)(super.decode(e))}}},4148:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FixedBytesCoder=void 0;const n=r(42120),i=r(3762),o=r(12900);class a extends o.Coder{size;constructor(e,t){let r="bytes"+String(e);super(r,r,t,!1),(0,n.defineProperties)(this,{size:e},{size:"number"})}defaultValue(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+2*this.size)}encode(e,t){let r=(0,n.getBytesCopy)(i.Typed.dereference(t,this.type));return r.length!==this.size&&this._throwError("incorrect data length",t),e.writeBytes(r)}decode(e){return(0,n.hexlify)(e.readBytes(this.size))}}t.FixedBytesCoder=a},36341:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NullCoder=void 0;const n=r(12900),i=new Uint8Array([]);class o extends n.Coder{constructor(e){super("null","",e,!1)}defaultValue(){return null}encode(e,t){return null!=t&&this._throwError("not null",t),e.writeBytes(i)}decode(e){return e.readBytes(0),null}}t.NullCoder=o},96893:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NumberCoder=void 0;const n=r(42120),i=r(3762),o=r(12900),a=BigInt(0),s=BigInt(1),u=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");class c extends o.Coder{size;signed;constructor(e,t,r){const i=(t?"int":"uint")+8*e;super(i,i,r,!1),(0,n.defineProperties)(this,{size:e,signed:t},{size:"number",signed:"boolean"})}defaultValue(){return 0}encode(e,t){let r=(0,n.getBigInt)(i.Typed.dereference(t,this.type)),c=(0,n.mask)(u,8*o.WordSize);if(this.signed){let e=(0,n.mask)(c,8*this.size-1);(r>e||r<-(e+s))&&this._throwError("value out-of-bounds",t),r=(0,n.toTwos)(r,8*o.WordSize)}else(r(0,n.mask)(c,8*this.size))&&this._throwError("value out-of-bounds",t);return e.writeValue(r)}decode(e){let t=(0,n.mask)(e.readValue(),8*this.size);return this.signed&&(t=(0,n.fromTwos)(t,8*this.size)),t}}t.NumberCoder=c},53524:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StringCoder=void 0;const n=r(82119),i=r(3762),o=r(5949);class a extends o.DynamicBytesCoder{constructor(e){super("string",e)}defaultValue(){return""}encode(e,t){return super.encode(e,(0,n.toUtf8Bytes)(i.Typed.dereference(t,"string")))}decode(e){return(0,n.toUtf8String)(super.decode(e))}}t.StringCoder=a},46701:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TupleCoder=void 0;const n=r(39290),i=r(3762),o=r(12900),a=r(8151);class s extends o.Coder{coders;constructor(e,t){let r=!1;const i=[];e.forEach((e=>{e.dynamic&&(r=!0),i.push(e.type)}));super("tuple","tuple("+i.join(",")+")",t,r),(0,n.defineProperties)(this,{coders:Object.freeze(e.slice())})}defaultValue(){const e=[];this.coders.forEach((t=>{e.push(t.defaultValue())}));const t=this.coders.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach(((r,n)=>{let i=r.localName;i&&1===t[i]&&("length"===i&&(i="_length"),null==e[i]&&(e[i]=e[n]))})),Object.freeze(e)}encode(e,t){const r=i.Typed.dereference(t,"tuple");return(0,a.pack)(e,this.coders,r)}decode(e){return(0,a.unpack)(e,this.coders)}}t.TupleCoder=s},66711:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StructFragment=t.FunctionFragment=t.FallbackFragment=t.ConstructorFragment=t.EventFragment=t.ErrorFragment=t.NamedFragment=t.Fragment=t.ParamType=void 0;const n=r(42120),i=r(98336);function o(e){const t=new Set;return e.forEach((e=>t.add(e))),Object.freeze(t)}const a="constant external internal payable private public pure view",s=o(a.split(" ")),u="constructor error event fallback function receive struct",c=o(u.split(" ")),l="calldata memory storage payable indexed",f=o(l.split(" ")),h=o([u,l,"tuple returns",a].join(" ").split(" ")),d={"(":"OPEN_PAREN",")":"CLOSE_PAREN","[":"OPEN_BRACKET","]":"CLOSE_BRACKET",",":"COMMA","@":"AT"},p=new RegExp("^(\\s*)"),m=new RegExp("^([0-9]+)"),y=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)"),g=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)$"),b=new RegExp("^(address|bool|bytes([0-9]*)|string|u?int([0-9]*))$");class v{#o;#s;get offset(){return this.#o}get length(){return this.#s.length-this.#o}constructor(e){this.#o=0,this.#s=e.slice()}clone(){return new v(this.#s)}reset(){this.#o=0}#u(e=0,t=0){return new v(this.#s.slice(e,t).map((t=>Object.freeze(Object.assign({},t,{match:t.match-e,linkBack:t.linkBack-e,linkNext:t.linkNext-e})))))}popKeyword(e){const t=this.peek();if("KEYWORD"!==t.type||!e.has(t.text))throw new Error(`expected keyword ${t.text}`);return this.pop().text}popType(e){if(this.peek().type!==e)throw new Error(`expected ${e}; got ${JSON.stringify(this.peek())}`);return this.pop().text}popParen(){const e=this.peek();if("OPEN_PAREN"!==e.type)throw new Error("bad start");const t=this.#u(this.#o+1,e.match+1);return this.#o=e.match+1,t}popParams(){const e=this.peek();if("OPEN_PAREN"!==e.type)throw new Error("bad start");const t=[];for(;this.#o=this.#s.length)throw new Error("out-of-bounds");return this.#s[this.#o]}peekKeyword(e){const t=this.peekType("KEYWORD");return null!=t&&e.has(t)?t:null}peekType(e){if(0===this.length)return null;const t=this.peek();return t.type===e?t.text:null}pop(){const e=this.peek();return this.#o++,e}toString(){const e=[];for(let t=this.#o;t`}}function w(e){const t=[],r=t=>{const r=a0&&"NUMBER"===t[t.length-1].type){const r=t.pop().text;e=r+e,t[t.length-1].value=(0,n.getNumber)(r)}if(0===t.length||"BRACKET"!==t[t.length-1].type)throw new Error("missing opening bracket");t[t.length-1].text+=e}}else if(u=s.match(y),u){if(c.text=u[1],a+=c.text.length,h.has(c.text)){c.type="KEYWORD";continue}if(c.text.match(b)){c.type="TYPE";continue}c.type="ID"}else{if(u=s.match(m),!u)throw new Error(`unexpected token ${JSON.stringify(s[0])} at position ${a}`);c.text=u[1],c.type="NUMBER",a+=c.text.length}}return new v(t.map((e=>Object.freeze(e))))}function A(e,t){let r=[];for(const n in t.keys())e.has(n)&&r.push(n);if(r.length>1)throw new Error(`conflicting types: ${r.join(", ")}`)}function S(e,t){if(t.peekKeyword(c)){const r=t.pop().text;if(r!==e)throw new Error(`expected ${e}, got ${r}`)}return t.popType("ID")}function k(e,t){const r=new Set;for(;;){const n=e.peekType("KEYWORD");if(null==n||t&&!t.has(n))break;if(e.pop(),r.has(n))throw new Error(`duplicate keywords: ${JSON.stringify(n)}`);r.add(n)}return Object.freeze(r)}function E(e){let t=k(e,s);return A(t,o("constant payable nonpayable".split(" "))),A(t,o("pure view payable nonpayable".split(" "))),t.has("view")?"view":t.has("pure")?"pure":t.has("payable")?"payable":t.has("nonpayable")?"nonpayable":t.has("constant")?"view":"nonpayable"}function _(e,t){return e.popParams().map((e=>D.from(e,t)))}function M(e){if(e.peekType("AT")){if(e.pop(),e.peekType("NUMBER"))return(0,n.getBigInt)(e.pop().text);throw new Error("invalid gas")}return null}function T(e){if(e.length)throw new Error(`unexpected tokens: ${e.toString()}`)}const x=new RegExp(/^(.*)\[([0-9]*)\]$/);function P(e){const t=e.match(b);if((0,n.assertArgument)(t,"invalid type","type",e),"uint"===e)return"uint256";if("int"===e)return"int256";if(t[2]){const r=parseInt(t[2]);(0,n.assertArgument)(0!==r&&r<=32,"invalid bytes length","type",e)}else if(t[3]){const r=parseInt(t[3]);(0,n.assertArgument)(0!==r&&r<=256&&r%8==0,"invalid numeric width","type",e)}return e}const I={},O=Symbol.for("_ethers_internal"),R="_ParamTypeInternal",C="_ErrorInternal",B="_EventInternal",N="_ConstructorInternal",L="_FallbackInternal",U="_FunctionInternal",F="_StructInternal";class D{name;type;baseType;indexed;components;arrayLength;arrayChildren;constructor(e,t,r,i,o,a,s,u){if((0,n.assertPrivate)(e,I,"ParamType"),Object.defineProperty(this,O,{value:R}),a&&(a=Object.freeze(a.slice())),"array"===i){if(null==s||null==u)throw new Error("")}else if(null!=s||null!=u)throw new Error("");if("tuple"===i){if(null==a)throw new Error("")}else if(null!=a)throw new Error("");(0,n.defineProperties)(this,{name:t,type:r,baseType:i,indexed:o,components:a,arrayLength:s,arrayChildren:u})}format(e){if(null==e&&(e="sighash"),"json"===e){let t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.isTuple()&&(t.components=this.components.map((t=>JSON.parse(t.format(e))))),JSON.stringify(t)}let t="";return this.isArray()?(t+=this.arrayChildren.format(e),t+=`[${this.arrayLength<0?"":String(this.arrayLength)}]`):this.isTuple()?("sighash"!==e&&(t+=this.type),t+="("+this.components.map((t=>t.format(e))).join("full"===e?", ":",")+")"):t+=this.type,"sighash"!==e&&(!0===this.indexed&&(t+=" indexed"),"full"===e&&this.name&&(t+=" "+this.name)),t}isArray(){return"array"===this.baseType}isTuple(){return"tuple"===this.baseType}isIndexable(){return null!=this.indexed}walk(e,t){if(this.isArray()){if(!Array.isArray(e))throw new Error("invalid array value");if(-1!==this.arrayLength&&e.length!==this.arrayLength)throw new Error("array is wrong length");const r=this;return e.map((e=>r.arrayChildren.walk(e,t)))}if(this.isTuple()){if(!Array.isArray(e))throw new Error("invalid tuple value");if(e.length!==this.components.length)throw new Error("array is wrong length");const r=this;return e.map(((e,n)=>r.components[n].walk(e,t)))}return t(this.type,e)}#c(e,t,r,n){if(this.isArray()){if(!Array.isArray(t))throw new Error("invalid array value");if(-1!==this.arrayLength&&t.length!==this.arrayLength)throw new Error("array is wrong length");const i=this.arrayChildren,o=t.slice();return o.forEach(((t,n)=>{i.#c(e,t,r,(e=>{o[n]=e}))})),void n(o)}if(this.isTuple()){const i=this.components;let o;if(Array.isArray(t))o=t.slice();else{if(null==t||"object"!=typeof t)throw new Error("invalid tuple value");o=i.map((e=>{if(!e.name)throw new Error("cannot use object value with unnamed components");if(!(e.name in t))throw new Error(`missing value for component ${e.name}`);return t[e.name]}))}if(o.length!==this.components.length)throw new Error("array is wrong length");return o.forEach(((t,n)=>{i[n].#c(e,t,r,(e=>{o[n]=e}))})),void n(o)}const i=r(this.type,t);i.then?e.push(async function(){n(await i)}()):n(i)}async walkAsync(e,t){const r=[],n=[e];return this.#c(r,e,t,(e=>{n[0]=e})),r.length&&await Promise.all(r),n[0]}static from(e,t){if(D.isParamType(e))return e;if("string"==typeof e)return D.from(w(e),t);if(e instanceof v){let r="",n="",i=null;k(e,o(["tuple"])).has("tuple")||e.peekType("OPEN_PAREN")?(n="tuple",i=e.popParams().map((e=>D.from(e))),r=`tuple(${i.map((e=>e.format())).join(",")})`):(r=P(e.popType("TYPE")),n=r);let a=null,s=null;for(;e.length&&e.peekType("BRACKET");){const t=e.pop();a=new D(I,"",r,n,null,i,s,a),s=t.value,r+=t.text,n="array",i=null}let u=null;if(k(e,f).has("indexed")){if(!t)throw new Error("");u=!0}const c=e.peekType("ID")?e.pop().text:"";if(e.length)throw new Error("leftover tokens");return new D(I,c,r,n,u,i,s,a)}const r=e.name;(0,n.assertArgument)(!r||"string"==typeof r&&r.match(g),"invalid name","obj.name",r);let i=e.indexed;null!=i&&((0,n.assertArgument)(t,"parameter cannot be indexed","obj.indexed",e.indexed),i=!!i);let a=e.type,s=a.match(x);if(s){const t=parseInt(s[2]||"-1"),n=D.from({type:s[1],components:e.components});return new D(I,r||"",a,"array",i,null,t,n)}if("tuple"===a||a.startsWith("tuple(")||a.startsWith("(")){const t=null!=e.components?e.components.map((e=>D.from(e))):null;return new D(I,r||"",a,"tuple",i,t,null,null)}return a=P(e.type),new D(I,r||"",a,a,i,null,null,null)}static isParamType(e){return e&&e[O]===R}}t.ParamType=D;class j{type;inputs;constructor(e,t,r){(0,n.assertPrivate)(e,I,"Fragment"),r=Object.freeze(r.slice()),(0,n.defineProperties)(this,{type:t,inputs:r})}static from(e){if("string"==typeof e){try{j.from(JSON.parse(e))}catch(e){}return j.from(w(e))}if(e instanceof v){switch(e.peekKeyword(c)){case"constructor":return q.from(e);case"error":return z.from(e);case"event":return G.from(e);case"fallback":case"receive":return K.from(e);case"function":return V.from(e);case"struct":return X.from(e)}}else if("object"==typeof e){switch(e.type){case"constructor":return q.from(e);case"error":return z.from(e);case"event":return G.from(e);case"fallback":case"receive":return K.from(e);case"function":return V.from(e);case"struct":return X.from(e)}(0,n.assert)(!1,`unsupported type: ${e.type}`,"UNSUPPORTED_OPERATION",{operation:"Fragment.from"})}(0,n.assertArgument)(!1,"unsupported frgament object","obj",e)}static isConstructor(e){return q.isFragment(e)}static isError(e){return z.isFragment(e)}static isEvent(e){return G.isFragment(e)}static isFunction(e){return V.isFragment(e)}static isStruct(e){return X.isFragment(e)}}t.Fragment=j;class H extends j{name;constructor(e,t,r,i){super(e,t,i),(0,n.assertArgument)("string"==typeof r&&r.match(g),"invalid identifier","name",r),i=Object.freeze(i.slice()),(0,n.defineProperties)(this,{name:r})}}function J(e,t){return"("+t.map((t=>t.format(e))).join("full"===e?", ":",")+")"}t.NamedFragment=H;class z extends H{constructor(e,t,r){super(e,"error",t,r),Object.defineProperty(this,O,{value:C})}get selector(){return(0,i.id)(this.format("sighash")).substring(0,10)}format(e){if(null==e&&(e="sighash"),"json"===e)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});const t=[];return"sighash"!==e&&t.push("error"),t.push(this.name+J(e,this.inputs)),t.join(" ")}static from(e){if(z.isFragment(e))return e;if("string"==typeof e)return z.from(w(e));if(e instanceof v){const t=S("error",e),r=_(e);return T(e),new z(I,t,r)}return new z(I,e.name,e.inputs?e.inputs.map(D.from):[])}static isFragment(e){return e&&e[O]===C}}t.ErrorFragment=z;class G extends H{anonymous;constructor(e,t,r,i){super(e,"event",t,r),Object.defineProperty(this,O,{value:B}),(0,n.defineProperties)(this,{anonymous:i})}get topicHash(){return(0,i.id)(this.format("sighash"))}format(e){if(null==e&&(e="sighash"),"json"===e)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});const t=[];return"sighash"!==e&&t.push("event"),t.push(this.name+J(e,this.inputs)),"sighash"!==e&&this.anonymous&&t.push("anonymous"),t.join(" ")}static getTopicHash(e,t){t=(t||[]).map((e=>D.from(e)));return new G(I,e,t,!1).topicHash}static from(e){if(G.isFragment(e))return e;if("string"==typeof e)return G.from(w(e));if(e instanceof v){const t=S("event",e),r=_(e,!0),n=!!k(e,o(["anonymous"])).has("anonymous");return T(e),new G(I,t,r,n)}return new G(I,e.name,e.inputs?e.inputs.map((e=>D.from(e,!0))):[],!!e.anonymous)}static isFragment(e){return e&&e[O]===B}}t.EventFragment=G;class q extends j{payable;gas;constructor(e,t,r,i,o){super(e,t,r),Object.defineProperty(this,O,{value:N}),(0,n.defineProperties)(this,{payable:i,gas:o})}format(e){if((0,n.assert)(null!=e&&"sighash"!==e,"cannot format a constructor for sighash","UNSUPPORTED_OPERATION",{operation:"format(sighash)"}),"json"===e)return JSON.stringify({type:"constructor",stateMutability:this.payable?"payable":"undefined",payable:this.payable,gas:null!=this.gas?this.gas:void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});const t=[`constructor${J(e,this.inputs)}`];return t.push(this.payable?"payable":"nonpayable"),null!=this.gas&&t.push(`@${this.gas.toString()}`),t.join(" ")}static from(e){if(q.isFragment(e))return e;if("string"==typeof e)return q.from(w(e));if(e instanceof v){k(e,o(["constructor"]));const t=_(e),r=!!k(e,o(["payable"])).has("payable"),n=M(e);return T(e),new q(I,"constructor",t,r,n)}return new q(I,"constructor",e.inputs?e.inputs.map(D.from):[],!!e.payable,null!=e.gas?e.gas:null)}static isFragment(e){return e&&e[O]===N}}t.ConstructorFragment=q;class K extends j{payable;constructor(e,t,r){super(e,"fallback",t),Object.defineProperty(this,O,{value:L}),(0,n.defineProperties)(this,{payable:r})}format(e){const t=0===this.inputs.length?"receive":"fallback";if("json"===e){const e=this.payable?"payable":"nonpayable";return JSON.stringify({type:t,stateMutability:e})}return`${t}()${this.payable?" payable":""}`}static from(e){if(K.isFragment(e))return e;if("string"==typeof e)return K.from(w(e));if(e instanceof v){const t=e.toString(),r=e.peekKeyword(o(["fallback","receive"]));(0,n.assertArgument)(r,"type must be fallback or receive","obj",t);if("receive"===e.popKeyword(o(["fallback","receive"]))){const t=_(e);return(0,n.assertArgument)(0===t.length,"receive cannot have arguments","obj.inputs",t),k(e,o(["payable"])),T(e),new K(I,[],!0)}let i=_(e);i.length?(0,n.assertArgument)(1===i.length&&"bytes"===i[0].type,"invalid fallback inputs","obj.inputs",i.map((e=>e.format("minimal"))).join(", ")):i=[D.from("bytes")];const a=E(e);if((0,n.assertArgument)("nonpayable"===a||"payable"===a,"fallback cannot be constants","obj.stateMutability",a),k(e,o(["returns"])).has("returns")){const t=_(e);(0,n.assertArgument)(1===t.length&&"bytes"===t[0].type,"invalid fallback outputs","obj.outputs",t.map((e=>e.format("minimal"))).join(", "))}return T(e),new K(I,i,"payable"===a)}if("receive"===e.type)return new K(I,[],!0);if("fallback"===e.type){const t=[D.from("bytes")],r="payable"===e.stateMutability;return new K(I,t,r)}(0,n.assertArgument)(!1,"invalid fallback description","obj",e)}static isFragment(e){return e&&e[O]===L}}t.FallbackFragment=K;class V extends H{constant;outputs;stateMutability;payable;gas;constructor(e,t,r,i,o,a){super(e,"function",t,i),Object.defineProperty(this,O,{value:U}),o=Object.freeze(o.slice());const s="view"===r||"pure"===r,u="payable"===r;(0,n.defineProperties)(this,{constant:s,gas:a,outputs:o,payable:u,stateMutability:r})}get selector(){return(0,i.id)(this.format("sighash")).substring(0,10)}format(e){if(null==e&&(e="sighash"),"json"===e)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:null!=this.gas?this.gas:void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e)))),outputs:this.outputs.map((t=>JSON.parse(t.format(e))))});const t=[];return"sighash"!==e&&t.push("function"),t.push(this.name+J(e,this.inputs)),"sighash"!==e&&("nonpayable"!==this.stateMutability&&t.push(this.stateMutability),this.outputs&&this.outputs.length&&(t.push("returns"),t.push(J(e,this.outputs))),null!=this.gas&&t.push(`@${this.gas.toString()}`)),t.join(" ")}static getSelector(e,t){t=(t||[]).map((e=>D.from(e)));return new V(I,e,"view",t,[],null).selector}static from(e){if(V.isFragment(e))return e;if("string"==typeof e)return V.from(w(e));if(e instanceof v){const t=S("function",e),r=_(e),n=E(e);let i=[];k(e,o(["returns"])).has("returns")&&(i=_(e));const a=M(e);return T(e),new V(I,t,n,r,i,a)}return new V(I,e.name,e.stateMutability,e.inputs?e.inputs.map(D.from):[],e.outputs?e.outputs.map(D.from):[],null!=e.gas?e.gas:null)}static isFragment(e){return e&&e[O]===U}}t.FunctionFragment=V;class X extends H{constructor(e,t,r){super(e,"struct",t,r),Object.defineProperty(this,O,{value:F})}format(){throw new Error("@TODO")}static from(e){if("string"==typeof e)return X.from(w(e));if(e instanceof v){const t=S("struct",e),r=_(e);return T(e),new X(I,t,r)}return new X(I,e.name,e.inputs?e.inputs.map(D.from):[])}static isFragment(e){return e&&e[O]===F}}t.StructFragment=X},93707:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Typed=t.Result=t.TransactionDescription=t.LogDescription=t.ErrorDescription=t.Interface=t.Indexed=t.checkResultErrors=t.StructFragment=t.ParamType=t.NamedFragment=t.FunctionFragment=t.Fragment=t.FallbackFragment=t.EventFragment=t.ErrorFragment=t.ConstructorFragment=t.encodeBytes32String=t.decodeBytes32String=t.AbiCoder=void 0;var n=r(54760);Object.defineProperty(t,"AbiCoder",{enumerable:!0,get:function(){return n.AbiCoder}});var i=r(12472);Object.defineProperty(t,"decodeBytes32String",{enumerable:!0,get:function(){return i.decodeBytes32String}}),Object.defineProperty(t,"encodeBytes32String",{enumerable:!0,get:function(){return i.encodeBytes32String}});var o=r(66711);Object.defineProperty(t,"ConstructorFragment",{enumerable:!0,get:function(){return o.ConstructorFragment}}),Object.defineProperty(t,"ErrorFragment",{enumerable:!0,get:function(){return o.ErrorFragment}}),Object.defineProperty(t,"EventFragment",{enumerable:!0,get:function(){return o.EventFragment}}),Object.defineProperty(t,"FallbackFragment",{enumerable:!0,get:function(){return o.FallbackFragment}}),Object.defineProperty(t,"Fragment",{enumerable:!0,get:function(){return o.Fragment}}),Object.defineProperty(t,"FunctionFragment",{enumerable:!0,get:function(){return o.FunctionFragment}}),Object.defineProperty(t,"NamedFragment",{enumerable:!0,get:function(){return o.NamedFragment}}),Object.defineProperty(t,"ParamType",{enumerable:!0,get:function(){return o.ParamType}}),Object.defineProperty(t,"StructFragment",{enumerable:!0,get:function(){return o.StructFragment}});var a=r(16401);Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return a.checkResultErrors}}),Object.defineProperty(t,"Indexed",{enumerable:!0,get:function(){return a.Indexed}}),Object.defineProperty(t,"Interface",{enumerable:!0,get:function(){return a.Interface}}),Object.defineProperty(t,"ErrorDescription",{enumerable:!0,get:function(){return a.ErrorDescription}}),Object.defineProperty(t,"LogDescription",{enumerable:!0,get:function(){return a.LogDescription}}),Object.defineProperty(t,"TransactionDescription",{enumerable:!0,get:function(){return a.TransactionDescription}}),Object.defineProperty(t,"Result",{enumerable:!0,get:function(){return a.Result}});var s=r(3762);Object.defineProperty(t,"Typed",{enumerable:!0,get:function(){return s.Typed}})},16401:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Interface=t.Indexed=t.ErrorDescription=t.TransactionDescription=t.LogDescription=t.Result=t.checkResultErrors=void 0;const n=r(96965),i=r(98336),o=r(42120),a=r(54760),s=r(12900);Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return s.checkResultErrors}}),Object.defineProperty(t,"Result",{enumerable:!0,get:function(){return s.Result}});const u=r(66711),c=r(3762);class l{fragment;name;signature;topic;args;constructor(e,t,r){const n=e.name,i=e.format();(0,o.defineProperties)(this,{fragment:e,name:n,signature:i,topic:t,args:r})}}t.LogDescription=l;class f{fragment;name;args;signature;selector;value;constructor(e,t,r,n){const i=e.name,a=e.format();(0,o.defineProperties)(this,{fragment:e,name:i,args:r,signature:a,selector:t,value:n})}}t.TransactionDescription=f;class h{fragment;name;args;signature;selector;constructor(e,t,r){const n=e.name,i=e.format();(0,o.defineProperties)(this,{fragment:e,name:n,args:r,signature:i,selector:t})}}t.ErrorDescription=h;class d{hash;_isIndexed;static isIndexed(e){return!(!e||!e._isIndexed)}constructor(e){(0,o.defineProperties)(this,{hash:e,_isIndexed:!0})}}t.Indexed=d;const p={0:"generic panic",1:"assert(false)",17:"arithmetic overflow",18:"division or modulo by zero",33:"enum overflow",34:"invalid encoded storage byte array accessed",49:"out-of-bounds array access; popping on an empty array",50:"out-of-bounds access of an array or bytesN",65:"out of memory",81:"uninitialized function"},m={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:e=>`reverted with reason string ${JSON.stringify(e)}`},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"],reason:e=>{let t="unknown panic code";return e>=0&&e<=255&&p[e.toString()]&&(t=p[e.toString()]),`reverted with panic code 0x${e.toString(16)} (${t})`}}};class y{fragments;deploy;fallback;receive;#l;#f;#h;#d;constructor(e){let t=[];t="string"==typeof e?JSON.parse(e):e,this.#h=new Map,this.#l=new Map,this.#f=new Map;const r=[];for(const e of t)try{r.push(u.Fragment.from(e))}catch(e){console.log("EE",e)}(0,o.defineProperties)(this,{fragments:Object.freeze(r)});let n=null,i=!1;this.#d=this.getAbiCoder(),this.fragments.forEach(((e,t)=>{let r;switch(e.type){case"constructor":return this.deploy?void console.log("duplicate definition - constructor"):void(0,o.defineProperties)(this,{deploy:e});case"fallback":return void(0===e.inputs.length?i=!0:((0,o.assertArgument)(!n||e.payable!==n.payable,"conflicting fallback fragments",`fragments[${t}]`,e),n=e,i=n.payable));case"function":r=this.#h;break;case"event":r=this.#f;break;case"error":r=this.#l;break;default:return}const a=e.format();r.has(a)||r.set(a,e)})),this.deploy||(0,o.defineProperties)(this,{deploy:u.ConstructorFragment.from("constructor()")}),(0,o.defineProperties)(this,{fallback:n,receive:i})}format(e){const t=e?"minimal":"full";return this.fragments.map((e=>e.format(t)))}formatJson(){const e=this.fragments.map((e=>e.format("json")));return JSON.stringify(e.map((e=>JSON.parse(e))))}getAbiCoder(){return a.AbiCoder.defaultAbiCoder()}#p(e,t,r){if((0,o.isHexString)(e)){const t=e.toLowerCase();for(const e of this.#h.values())if(t===e.selector)return e;return null}if(-1===e.indexOf("(")){const n=[];for(const[t,r]of this.#h)t.split("(")[0]===e&&n.push(r);if(t){const e=t.length>0?t[t.length-1]:null;let r=t.length,i=!0;c.Typed.isTyped(e)&&"overrides"===e.type&&(i=!1,r--);for(let e=n.length-1;e>=0;e--){const t=n[e].inputs.length;t===r||i&&t===r-1||n.splice(e,1)}for(let e=n.length-1;e>=0;e--){const r=n[e].inputs;for(let i=0;i=r.length){if("overrides"===t[i].type)continue;n.splice(e,1);break}if(t[i].type!==r[i].baseType){n.splice(e,1);break}}}}if(1===n.length&&t&&t.length!==n[0].inputs.length){const e=t[t.length-1];(null==e||Array.isArray(e)||"object"!=typeof e)&&n.splice(0,1)}if(0===n.length)return null;if(n.length>1&&r){const t=n.map((e=>JSON.stringify(e.format()))).join(", ");(0,o.assertArgument)(!1,`ambiguous function description (i.e. matches ${t})`,"key",e)}return n[0]}const n=this.#h.get(u.FunctionFragment.from(e).format());return n||null}getFunctionName(e){const t=this.#p(e,null,!1);return(0,o.assertArgument)(t,"no matching function","key",e),t.name}getFunction(e,t){return this.#p(e,t||null,!0)}forEachFunction(e){const t=Array.from(this.#h.keys());t.sort(((e,t)=>e.localeCompare(t)));for(let r=0;r=0;e--)n[e].inputs.length=0;e--){const r=n[e].inputs;for(let i=0;i1&&r){const t=n.map((e=>JSON.stringify(e.format()))).join(", ");(0,o.assertArgument)(!1,`ambiguous event description (i.e. matches ${t})`,"key",e)}return n[0]}const n=this.#f.get(u.EventFragment.from(e).format());return n||null}getEventName(e){const t=this.#m(e,null,!1);return(0,o.assertArgument)(t,"no matching event","key",e),t.name}getEvent(e,t){return this.#m(e,t||null,!0)}forEachEvent(e){const t=Array.from(this.#f.keys());t.sort(((e,t)=>e.localeCompare(t)));for(let r=0;r1){const r=t.map((e=>JSON.stringify(e.format()))).join(", ");(0,o.assertArgument)(!1,`ambiguous error description (i.e. ${r})`,"name",e)}return t[0]}if("Error(string)"===(e=u.ErrorFragment.from(e).format()))return u.ErrorFragment.from("error Error(string)");if("Panic(uint256)"===e)return u.ErrorFragment.from("error Panic(uint256)");const r=this.#l.get(e);return r||null}forEachError(e){const t=Array.from(this.#l.keys());t.sort(((e,t)=>e.localeCompare(t)));for(let r=0;r"string"===e.type?(0,i.id)(t):"bytes"===e.type?(0,n.keccak256)((0,o.hexlify)(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=(0,o.toBeHex)(t)),"address"===e.type&&this.#d.encode(["address"],[t]),(0,o.zeroPadValue)((0,o.hexlify)(t),32));for(t.forEach(((t,n)=>{const i=e.inputs[n];i.indexed?null==t?r.push(null):"array"===i.baseType||"tuple"===i.baseType?(0,o.assertArgument)(!1,"filtering with tuples or arrays not supported","contract."+i.name,t):Array.isArray(t)?r.push(t.map((e=>a(i,e)))):r.push(a(i,t)):(0,o.assertArgument)(null==t,"cannot filter non-indexed parameters; must be null","contract."+i.name,t)}));r.length&&null===r[r.length-1];)r.pop();return r}encodeEventLog(e,t){if("string"==typeof e){const t=this.getEvent(e);(0,o.assertArgument)(t,"unknown event","eventFragment",e),e=t}const r=[],a=[],s=[];return e.anonymous||r.push(e.topicHash),(0,o.assertArgument)(t.length===e.inputs.length,"event arguments/values mismatch","values",t),e.inputs.forEach(((e,o)=>{const u=t[o];if(e.indexed)if("string"===e.type)r.push((0,i.id)(u));else if("bytes"===e.type)r.push((0,n.keccak256)(u));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");r.push(this.#d.encode([e.type],[u]))}else a.push(e),s.push(u)})),{data:this.#d.encode(a,s),topics:r}}decodeEventLog(e,t,r){if("string"==typeof e){const t=this.getEvent(e);(0,o.assertArgument)(t,"unknown event","eventFragment",e),e=t}if(null!=r&&!e.anonymous){const t=e.topicHash;(0,o.assertArgument)((0,o.isHexString)(r[0],32)&&r[0].toLowerCase()===t,"fragment/topic mismatch","topics[0]",r[0]),r=r.slice(1)}const n=[],i=[],a=[];e.inputs.forEach(((e,t)=>{e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(n.push(u.ParamType.from({type:"bytes32",name:e.name})),a.push(!0)):(n.push(e),a.push(!1)):(i.push(e),a.push(!1))}));const c=null!=r?this.#d.decode(n,(0,o.concat)(r)):null,l=this.#d.decode(i,t,!0),f=[],h=[];let p=0,m=0;return e.inputs.forEach(((e,t)=>{let r=null;if(e.indexed)if(null==c)r=new d(null);else if(a[t])r=new d(c[m++]);else try{r=c[m++]}catch(e){r=e}else try{r=l[p++]}catch(e){r=e}f.push(r),h.push(e.name||null)})),s.Result.fromItems(f,h)}parseTransaction(e){const t=(0,o.getBytes)(e.data,"tx.data"),r=(0,o.getBigInt)(null!=e.value?e.value:0,"tx.value"),n=this.getFunction((0,o.hexlify)(t.slice(0,4)));if(!n)return null;const i=this.#d.decode(n.inputs,t.slice(4));return new f(n,n.selector,i,r)}parseCallResult(e){throw new Error("@TODO")}parseLog(e){const t=this.getEvent(e.topics[0]);return!t||t.anonymous?null:new l(t,t.topicHash,this.decodeEventLog(t,e.data,e.topics))}parseError(e){const t=(0,o.hexlify)(e),r=this.getError((0,o.dataSlice)(t,0,4));if(!r)return null;const n=this.#d.decode(r.inputs,(0,o.dataSlice)(t,4));return new h(r,r.selector,n)}static from(e){return e instanceof y?e:"string"==typeof e?new y(JSON.parse(e)):"function"==typeof e.format?new y(e.format("json")):new y(e)}}t.Interface=y},3762:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Typed=void 0;const n=r(42120),i={};function o(e,t){let r=!1;return t<0&&(r=!0,t*=-1),new u(i,`${r?"":"u"}int${t}`,e,{signed:r,width:t})}function a(e,t){return new u(i,`bytes${t||""}`,e,{size:t})}const s=Symbol.for("_ethers_typed");class u{type;value;#y;_typedSymbol;constructor(e,t,r,o){null==o&&(o=null),(0,n.assertPrivate)(i,e,"Typed"),(0,n.defineProperties)(this,{_typedSymbol:s,type:t,value:r}),this.#y=o,this.format()}format(){if("array"===this.type)throw new Error("");if("dynamicArray"===this.type)throw new Error("");return"tuple"===this.type?`tuple(${this.value.map((e=>e.format())).join(",")})`:this.type}defaultValue(){return 0}minValue(){return 0}maxValue(){return 0}isBigInt(){return!!this.type.match(/^u?int[0-9]+$/)}isData(){return this.type.startsWith("bytes")}isString(){return"string"===this.type}get tupleName(){if("tuple"!==this.type)throw TypeError("not a tuple");return this.#y}get arrayLength(){if("array"!==this.type)throw TypeError("not an array");return!0===this.#y?-1:!1===this.#y?this.value.length:null}static from(e,t){return new u(i,e,t)}static uint8(e){return o(e,8)}static uint16(e){return o(e,16)}static uint24(e){return o(e,24)}static uint32(e){return o(e,32)}static uint40(e){return o(e,40)}static uint48(e){return o(e,48)}static uint56(e){return o(e,56)}static uint64(e){return o(e,64)}static uint72(e){return o(e,72)}static uint80(e){return o(e,80)}static uint88(e){return o(e,88)}static uint96(e){return o(e,96)}static uint104(e){return o(e,104)}static uint112(e){return o(e,112)}static uint120(e){return o(e,120)}static uint128(e){return o(e,128)}static uint136(e){return o(e,136)}static uint144(e){return o(e,144)}static uint152(e){return o(e,152)}static uint160(e){return o(e,160)}static uint168(e){return o(e,168)}static uint176(e){return o(e,176)}static uint184(e){return o(e,184)}static uint192(e){return o(e,192)}static uint200(e){return o(e,200)}static uint208(e){return o(e,208)}static uint216(e){return o(e,216)}static uint224(e){return o(e,224)}static uint232(e){return o(e,232)}static uint240(e){return o(e,240)}static uint248(e){return o(e,248)}static uint256(e){return o(e,256)}static uint(e){return o(e,256)}static int8(e){return o(e,-8)}static int16(e){return o(e,-16)}static int24(e){return o(e,-24)}static int32(e){return o(e,-32)}static int40(e){return o(e,-40)}static int48(e){return o(e,-48)}static int56(e){return o(e,-56)}static int64(e){return o(e,-64)}static int72(e){return o(e,-72)}static int80(e){return o(e,-80)}static int88(e){return o(e,-88)}static int96(e){return o(e,-96)}static int104(e){return o(e,-104)}static int112(e){return o(e,-112)}static int120(e){return o(e,-120)}static int128(e){return o(e,-128)}static int136(e){return o(e,-136)}static int144(e){return o(e,-144)}static int152(e){return o(e,-152)}static int160(e){return o(e,-160)}static int168(e){return o(e,-168)}static int176(e){return o(e,-176)}static int184(e){return o(e,-184)}static int192(e){return o(e,-192)}static int200(e){return o(e,-200)}static int208(e){return o(e,-208)}static int216(e){return o(e,-216)}static int224(e){return o(e,-224)}static int232(e){return o(e,-232)}static int240(e){return o(e,-240)}static int248(e){return o(e,-248)}static int256(e){return o(e,-256)}static int(e){return o(e,-256)}static bytes1(e){return a(e,1)}static bytes2(e){return a(e,2)}static bytes3(e){return a(e,3)}static bytes4(e){return a(e,4)}static bytes5(e){return a(e,5)}static bytes6(e){return a(e,6)}static bytes7(e){return a(e,7)}static bytes8(e){return a(e,8)}static bytes9(e){return a(e,9)}static bytes10(e){return a(e,10)}static bytes11(e){return a(e,11)}static bytes12(e){return a(e,12)}static bytes13(e){return a(e,13)}static bytes14(e){return a(e,14)}static bytes15(e){return a(e,15)}static bytes16(e){return a(e,16)}static bytes17(e){return a(e,17)}static bytes18(e){return a(e,18)}static bytes19(e){return a(e,19)}static bytes20(e){return a(e,20)}static bytes21(e){return a(e,21)}static bytes22(e){return a(e,22)}static bytes23(e){return a(e,23)}static bytes24(e){return a(e,24)}static bytes25(e){return a(e,25)}static bytes26(e){return a(e,26)}static bytes27(e){return a(e,27)}static bytes28(e){return a(e,28)}static bytes29(e){return a(e,29)}static bytes30(e){return a(e,30)}static bytes31(e){return a(e,31)}static bytes32(e){return a(e,32)}static address(e){return new u(i,"address",e)}static bool(e){return new u(i,"bool",!!e)}static bytes(e){return new u(i,"bytes",e)}static string(e){return new u(i,"string",e)}static array(e,t){throw new Error("not implemented yet")}static tuple(e,t){throw new Error("not implemented yet")}static overrides(e){return new u(i,"overrides",Object.assign({},e))}static isTyped(e){return e&&e._typedSymbol===s}static dereference(e,t){if(u.isTyped(e)){if(e.type!==t)throw new Error(`invalid type: expecetd ${t}, got ${e.type}`);return e.value}return e}}t.Typed=u},40805:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getIcapAddress=t.getAddress=void 0;const n=r(96965),i=r(42120),o=BigInt(0),a=BigInt(36);function s(e){const t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40);for(let e=0;e<40;e++)r[e]=t[e].charCodeAt(0);const o=(0,i.getBytes)((0,n.keccak256)(r));for(let e=0;e<40;e+=2)o[e>>1]>>4>=8&&(t[e]=t[e].toUpperCase()),(15&o[e>>1])>=8&&(t[e+1]=t[e+1].toUpperCase());return"0x"+t.join("")}const u={};for(let e=0;e<10;e++)u[String(e)]=String(e);for(let e=0;e<26;e++)u[String.fromCharCode(65+e)]=String(10+e);function c(e){let t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((e=>u[e])).join("");for(;t.length>=15;){let e=t.substring(0,15);t=parseInt(e,10)%97+t.substring(e.length)}let r=String(98-parseInt(t,10)%97);for(;r.length<2;)r="0"+r;return r}const l=function(){const e={};for(let t=0;t<36;t++){e["0123456789abcdefghijklmnopqrstuvwxyz"[t]]=BigInt(t)}return e}();function f(e){if((0,i.assertArgument)("string"==typeof e,"invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/)){e.startsWith("0x")||(e="0x"+e);const t=s(e);return(0,i.assertArgument)(!e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)||t===e,"bad address checksum","address",e),t}if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){(0,i.assertArgument)(e.substring(2,4)===c(e),"bad icap checksum","address",e);let t=function(e){e=e.toLowerCase();let t=o;for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolveAddress=t.isAddress=t.isAddressable=void 0;const n=r(42120),i=r(40805);function o(e){return e&&"function"==typeof e.getAddress}async function a(e,t){const r=await t;return null!=r&&"0x0000000000000000000000000000000000000000"!==r||((0,n.assert)("string"!=typeof e,"unconfigured name","UNCONFIGURED_NAME",{value:e}),(0,n.assertArgument)(!1,"invalid AddressLike value; did not resolve to a value address","target",e)),(0,i.getAddress)(r)}t.isAddressable=o,t.isAddress=function(e){try{return(0,i.getAddress)(e),!0}catch(e){}return!1},t.resolveAddress=function(e,t){return"string"==typeof e?e.match(/^0x[0-9a-f]{40}$/i)?(0,i.getAddress)(e):((0,n.assert)(null!=t,"ENS resolution requires a provider","UNSUPPORTED_OPERATION",{operation:"resolveName"}),a(e,t.resolveName(e))):o(e)?a(e,e.getAddress()):e&&"function"==typeof e.then?a(e,e):void(0,n.assertArgument)(!1,"unsupported addressable value","target",e)}},96067:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getCreate2Address=t.getCreateAddress=void 0;const n=r(96965),i=r(42120),o=r(40805);t.getCreateAddress=function(e){const t=(0,o.getAddress)(e.from);let r=(0,i.getBigInt)(e.nonce,"tx.nonce").toString(16);return r="0"===r?"0x":r.length%2?"0x0"+r:"0x"+r,(0,o.getAddress)((0,i.dataSlice)((0,n.keccak256)((0,i.encodeRlp)([t,r])),12))},t.getCreate2Address=function(e,t,r){const a=(0,o.getAddress)(e),s=(0,i.getBytes)(t,"salt"),u=(0,i.getBytes)(r,"initCodeHash");return(0,i.assertArgument)(32===s.length,"salt must be 32 bytes","salt",t),(0,i.assertArgument)(32===u.length,"initCodeHash must be 32 bytes","initCodeHash",r),(0,o.getAddress)((0,i.dataSlice)((0,n.keccak256)((0,i.concat)(["0xff",a,s,u])),12))}},45475:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolveAddress=t.isAddress=t.isAddressable=t.getCreate2Address=t.getCreateAddress=t.getIcapAddress=t.getAddress=void 0;var n=r(40805);Object.defineProperty(t,"getAddress",{enumerable:!0,get:function(){return n.getAddress}}),Object.defineProperty(t,"getIcapAddress",{enumerable:!0,get:function(){return n.getIcapAddress}});var i=r(96067);Object.defineProperty(t,"getCreateAddress",{enumerable:!0,get:function(){return i.getCreateAddress}}),Object.defineProperty(t,"getCreate2Address",{enumerable:!0,get:function(){return i.getCreate2Address}});var o=r(93442);Object.defineProperty(t,"isAddressable",{enumerable:!0,get:function(){return o.isAddressable}}),Object.defineProperty(t,"isAddress",{enumerable:!0,get:function(){return o.isAddress}}),Object.defineProperty(t,"resolveAddress",{enumerable:!0,get:function(){return o.resolveAddress}})},23223:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ZeroAddress=void 0,t.ZeroAddress="0x0000000000000000000000000000000000000000"},90688:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ZeroHash=void 0,t.ZeroHash="0x0000000000000000000000000000000000000000000000000000000000000000"},30087:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MessagePrefix=t.EtherSymbol=t.MaxInt256=t.MinInt256=t.MaxUint256=t.WeiPerEther=t.N=t.ZeroHash=t.ZeroAddress=void 0;var n=r(23223);Object.defineProperty(t,"ZeroAddress",{enumerable:!0,get:function(){return n.ZeroAddress}});var i=r(90688);Object.defineProperty(t,"ZeroHash",{enumerable:!0,get:function(){return i.ZeroHash}});var o=r(24456);Object.defineProperty(t,"N",{enumerable:!0,get:function(){return o.N}}),Object.defineProperty(t,"WeiPerEther",{enumerable:!0,get:function(){return o.WeiPerEther}}),Object.defineProperty(t,"MaxUint256",{enumerable:!0,get:function(){return o.MaxUint256}}),Object.defineProperty(t,"MinInt256",{enumerable:!0,get:function(){return o.MinInt256}}),Object.defineProperty(t,"MaxInt256",{enumerable:!0,get:function(){return o.MaxInt256}});var a=r(82359);Object.defineProperty(t,"EtherSymbol",{enumerable:!0,get:function(){return a.EtherSymbol}}),Object.defineProperty(t,"MessagePrefix",{enumerable:!0,get:function(){return a.MessagePrefix}})},24456:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MaxInt256=t.MinInt256=t.MaxUint256=t.WeiPerEther=t.N=void 0,t.N=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),t.WeiPerEther=BigInt("1000000000000000000"),t.MaxUint256=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),t.MinInt256=BigInt("0x8000000000000000000000000000000000000000000000000000000000000000")*BigInt(-1),t.MaxInt256=BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff")},82359:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MessagePrefix=t.EtherSymbol=void 0,t.EtherSymbol="Ξ",t.MessagePrefix="Ethereum Signed Message:\n"},44350:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Contract=t.BaseContract=t.resolveArgs=t.copyOverrides=void 0;const n=r(93707),i=r(45475),o=r(37143),a=r(42120),s=r(97151),u=BigInt(0);function c(e){return e&&"function"==typeof e.call}function l(e){return e&&"function"==typeof e.estimateGas}function f(e){return e&&"function"==typeof e.resolveName}function h(e){return e&&"function"==typeof e.sendTransaction}class d{#g;fragment;constructor(e,t,r){if((0,a.defineProperties)(this,{fragment:t}),t.inputs.lengthnull==r[t]?null:e.walkAsync(r[t],((e,t)=>"address"===e?(0,i.resolveAddress)(t,o):t)))));return e.interface.encodeFilterTopics(t,n)}()}getTopicFilter(){return this.#g}}function p(e,t){return null==e?null:"function"==typeof e[t]?e:e.provider&&"function"==typeof e.provider[t]?e.provider:null}function m(e){return null==e?null:e.provider||null}async function y(e,t){const r=(0,o.copyRequest)(n.Typed.dereference(e,"overrides"));return(0,a.assertArgument)(null==r.to||(t||[]).indexOf("to")>=0,"cannot override to","overrides.to",r.to),(0,a.assertArgument)(null==r.data||(t||[]).indexOf("data")>=0,"cannot override data","overrides.data",r.data),r.from&&(r.from=await(0,i.resolveAddress)(r.from)),r}async function g(e,t,r){const o=p(e,"resolveName"),a=f(o)?o:null;return await Promise.all(t.map(((e,t)=>e.walkAsync(r[t],((e,t)=>(t=n.Typed.dereference(t,e),"address"===e?(0,i.resolveAddress)(t,a):t))))))}t.copyOverrides=y,t.resolveArgs=g;class b{_contract;constructor(e){(0,a.defineProperties)(this,{_contract:e});return new Proxy(this,{apply:async(e,t,r)=>await e.send(...r)})}async populateTransaction(e){const t=await y(e,["data"]);t.to=await this._contract.getAddress();const r=this._contract.interface,n=r.receive||r.fallback&&r.fallback.payable;return(0,a.assertArgument)(n||(t.value||u)===u,"cannot send value to non-payable contract","overrides.value",t.value),(0,a.assertArgument)(r.fallback||"0x"===(t.data||"0x"),"cannot send data to receive-only contract","overrides.data",t.data),t}async staticCall(e){const t=p(this._contract.runner,"call");(0,a.assert)(c(t),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const r=await this.populateTransaction(e);try{return await t.call(r)}catch(e){if((0,a.isCallException)(e)&&e.data)throw this._contract.interface.makeError(e.data,r);throw e}}async send(e){const t=this._contract.runner;(0,a.assert)(h(t),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const r=await t.sendTransaction(await this.populateTransaction(e)),n=m(this._contract.runner);return new s.ContractTransactionResponse(this._contract.interface,n,r)}async estimateGas(e){const t=p(this._contract.runner,"estimateGas");return(0,a.assert)(l(t),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await t.estimateGas(await this.populateTransaction(e))}}class v extends(function(){return Function}()){name="";_contract;_key;constructor(e,t){super(),(0,a.defineProperties)(this,{name:e.interface.getFunctionName(t),_contract:e,_key:t});return new Proxy(this,{apply:async(e,t,r)=>e.getFragment(...r).constant?await e.staticCall(...r):await e.send(...r)})}get fragment(){const e=this._contract.interface.getFunction(this._key);return(0,a.assert)(e,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),e}getFragment(...e){const t=this._contract.interface.getFunction(this._key,e);return(0,a.assert)(t,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),t}async populateTransaction(...e){const t=this.getFragment(...e);let r={};if(t.inputs.length+1===e.length&&(r=await y(e.pop())),t.inputs.length!==e.length)throw new Error("internal error: fragment inputs doesn't match arguments; should not happen");const n=await g(this._contract.runner,t.inputs,e);return Object.assign({},r,await(0,a.resolveProperties)({to:this._contract.getAddress(),data:this._contract.interface.encodeFunctionData(t,n)}))}async staticCall(...e){const t=await this.staticCallResult(...e);return 1===t.length?t[0]:t}async send(...e){const t=this._contract.runner;(0,a.assert)(h(t),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const r=await t.sendTransaction(await this.populateTransaction(...e)),n=m(this._contract.runner);return new s.ContractTransactionResponse(this._contract.interface,n,r)}async estimateGas(...e){const t=p(this._contract.runner,"estimateGas");return(0,a.assert)(l(t),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await t.estimateGas(await this.populateTransaction(...e))}async staticCallResult(...e){const t=p(this._contract.runner,"call");(0,a.assert)(c(t),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const r=await this.populateTransaction(...e);let n="0x";try{n=await t.call(r)}catch(e){if((0,a.isCallException)(e)&&e.data)throw this._contract.interface.makeError(e.data,r);throw e}const i=this.getFragment(...e);return this._contract.interface.decodeFunctionResult(i,n)}}class w extends(function(){return Function}()){name="";_contract;_key;constructor(e,t){return super(),(0,a.defineProperties)(this,{name:e.interface.getEventName(t),_contract:e,_key:t}),new Proxy(this,{apply:(t,r,n)=>new d(e,t.getFragment(...n),n)})}get fragment(){const e=this._contract.interface.getEvent(this._key);return(0,a.assert)(e,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),e}getFragment(...e){const t=this._contract.interface.getEvent(this._key,e);return(0,a.assert)(t,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),t}}const A=Symbol.for("_ethersInternal_contract"),S=new WeakMap;function k(e){return S.get(e[A])}async function E(e,t){let r,n=null;if(Array.isArray(t)){const n=function(t){if((0,a.isHexString)(t,32))return t;const r=e.interface.getEvent(t);return(0,a.assertArgument)(r,"unknown fragment","name",t),r.topicHash};r=t.map((e=>null==e?null:Array.isArray(e)?e.map(n):n(e)))}else"*"===t?r=[null]:"string"==typeof t?(0,a.isHexString)(t,32)?r=[t]:(n=e.interface.getEvent(t),(0,a.assertArgument)(n,"unknown fragment","event",t),r=[n.topicHash]):(i=t)&&"object"==typeof i&&"getTopicFilter"in i&&"function"==typeof i.getTopicFilter&&i.fragment?r=await t.getTopicFilter():"fragment"in t?(n=t.fragment,r=[n.topicHash]):(0,a.assertArgument)(!1,"unknown event name","event",t);var i;r=r.map((e=>{if(null==e)return null;if(Array.isArray(e)){const t=Array.from(new Set(e.map((e=>e.toLowerCase()))).values());return 1===t.length?t[0]:(t.sort(),t)}return e.toLowerCase()}));return{fragment:n,tag:r.map((e=>null==e?"null":Array.isArray(e)?e.join("|"):e)).join("&"),topics:r}}async function _(e,t){const{subs:r}=k(e);return r.get((await E(e,t)).tag)||null}async function M(e,t,r){const n=m(e.runner);(0,a.assert)(n,"contract runner does not support subscribing","UNSUPPORTED_OPERATION",{operation:t});const{fragment:i,tag:o,topics:u}=await E(e,r),{addr:c,subs:l}=k(e);let f=l.get(o);if(!f){const t={address:c||e,topics:u},a=t=>{let n=i;if(null==n)try{n=e.interface.getEvent(t.topics[0])}catch(e){}if(n){const o=n,a=i?e.interface.decodeEventLog(i,t.data,t.topics):[];x(e,r,a,(n=>new s.ContractEventPayload(e,n,r,o,t)))}else x(e,r,[],(n=>new s.ContractUnknownEventPayload(e,n,r,t)))};let h=[];f={tag:o,listeners:[],start:()=>{h.length||h.push(n.on(t,a))},stop:async()=>{if(0==h.length)return;let e=h;h=[],await Promise.all(e),n.off(t,a)}},l.set(o,f)}return f}let T=Promise.resolve();async function x(e,t,r,n){try{await T}catch(e){}const i=async function(e,t,r,n){await T;const i=await _(e,t);if(!i)return!1;const o=i.listeners.length;return i.listeners=i.listeners.filter((({listener:t,once:i})=>{const o=Array.from(r);n&&o.push(n(i?null:t));try{t.call(e,...o)}catch(e){}return!i})),o>0}(e,t,r,n);return T=i,await i}const P=["then"];class I{target;interface;runner;filters;[A];fallback;constructor(e,t,r,i){null==r&&(r=null);const o=n.Interface.from(t);let u;(0,a.defineProperties)(this,{target:e,runner:r,interface:o}),Object.defineProperty(this,A,{value:{}});let c=null,l=null;if(i){const e=m(r);l=new s.ContractTransactionResponse(this.interface,e,i)}let h=new Map;if("string"==typeof e)if((0,a.isHexString)(e))c=e,u=Promise.resolve(e);else{const t=p(r,"resolveName");if(!f(t))throw(0,a.makeError)("contract runner does not support name resolution","UNSUPPORTED_OPERATION",{operation:"resolveName"});u=t.resolveName(e).then((e=>{if(null==e)throw new Error("TODO");return k(this).addr=e,e}))}else u=e.getAddress().then((e=>{if(null==e)throw new Error("TODO");return k(this).addr=e,e}));var d,y;d=this,y={addrPromise:u,addr:c,deployTx:l,subs:h},S.set(d[A],y);const g=new Proxy({},{get:(e,t,r)=>{if(P.indexOf(t)>=0)return Reflect.get(e,t,r);const n=String(t),i=this.getEvent(n);if(i)return i;throw new Error(`unknown contract event: ${n}`)}});return(0,a.defineProperties)(this,{filters:g}),(0,a.defineProperties)(this,{fallback:o.receive||o.fallback?new b(this):null}),new Proxy(this,{get:(e,t,r)=>{if(t in e||P.indexOf(t)>=0)return Reflect.get(e,t,r);const n=String(t),i=e.getFunction(n);if(i)return i;throw new Error(`unknown contract method: ${n}`)}})}connect(e){return new I(this.target,this.interface,e)}async getAddress(){return await k(this).addrPromise}async getDeployedCode(){const e=m(this.runner);(0,a.assert)(e,"runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"getDeployedCode"});const t=await e.getCode(await this.getAddress());return"0x"===t?null:t}async waitForDeployment(){const e=this.deploymentTransaction();if(e)return await e.wait(),this;if(null!=await this.getDeployedCode())return this;const t=m(this.runner);return(0,a.assert)(null!=t,"contract runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"waitForDeployment"}),new Promise(((e,r)=>{const n=async()=>{try{if(null!=await this.getDeployedCode())return e(this);t.once("block",n)}catch(e){r(e)}};n()}))}deploymentTransaction(){return k(this).deployTx}getFunction(e){return"string"!=typeof e&&(e=e.format()),new v(this,e)}getEvent(e){return"string"!=typeof e&&(e=e.format()),new w(this,e)}async queryTransaction(e){throw new Error("@TODO")}async queryFilter(e,t,r){null==t&&(t=0),null==r&&(r="latest");const{addr:n,addrPromise:i}=k(this),u=n||await i,{fragment:c,topics:l}=await E(this,e),f={address:u,topics:l,fromBlock:t,toBlock:r},h=m(this.runner);return(0,a.assert)(h,"contract runner does not have a provider","UNSUPPORTED_OPERATION",{operation:"queryFilter"}),(await h.getLogs(f)).map((e=>{let t=c;if(null==t)try{t=this.interface.getEvent(e.topics[0])}catch(e){}return t?new s.EventLog(e,this.interface,t):new o.Log(e,h)}))}async on(e,t){const r=await M(this,"on",e);return r.listeners.push({listener:t,once:!1}),r.start(),this}async once(e,t){const r=await M(this,"once",e);return r.listeners.push({listener:t,once:!0}),r.start(),this}async emit(e,...t){return await x(this,e,t,null)}async listenerCount(e){if(e){const t=await _(this,e);return t?t.listeners.length:0}const{subs:t}=k(this);let r=0;for(const{listeners:e}of t.values())r+=e.length;return r}async listeners(e){if(e){const t=await _(this,e);return t?t.listeners.map((({listener:e})=>e)):[]}const{subs:t}=k(this);let r=[];for(const{listeners:e}of t.values())r=r.concat(e.map((({listener:e})=>e)));return r}async off(e,t){const r=await _(this,e);if(!r)return this;if(t){const e=r.listeners.map((({listener:e})=>e)).indexOf(t);e>=0&&r.listeners.splice(e,1)}return null!=t&&0!==r.listeners.length||(r.stop(),k(this).subs.delete(r.tag)),this}async removeAllListeners(e){if(e){const t=await _(this,e);if(!t)return this;t.stop(),k(this).subs.delete(t.tag)}else{const{subs:e}=k(this);for(const{tag:t,stop:r}of e.values())r(),e.delete(t)}return this}async addListener(e,t){return await this.on(e,t)}async removeListener(e,t){return await this.off(e,t)}static buildClass(e){return class extends I{constructor(t,r=null){super(t,e,r)}}}static from(e,t,r){null==r&&(r=null);return new this(e,t,r)}}t.BaseContract=I;class O extends(function(){return I}()){}t.Contract=O},31018:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ContractFactory=void 0;const n=r(93707),i=r(45475),o=r(42120),a=r(44350);class s{interface;bytecode;runner;constructor(e,t,r){const i=n.Interface.from(e);t instanceof Uint8Array||("object"==typeof t&&(t=t.object),t.startsWith("0x")||(t="0x"+t)),t=(0,o.hexlify)((0,o.getBytes)(t)),(0,o.defineProperties)(this,{bytecode:t,interface:i,runner:r||null})}async getDeployTransaction(...e){let t={};const r=this.interface.deploy;if(r.inputs.length+1===e.length&&(t=await(0,a.copyOverrides)(e.pop())),r.inputs.length!==e.length)throw new Error("incorrect number of arguments to constructor");const n=await(0,a.resolveArgs)(this.runner,r.inputs,e),i=(0,o.concat)([this.bytecode,this.interface.encodeDeploy(n)]);return Object.assign({},t,{data:i})}async deploy(...e){const t=await this.getDeployTransaction(...e);(0,o.assert)(this.runner&&"function"==typeof this.runner.sendTransaction,"factory runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const r=await this.runner.sendTransaction(t),n=(0,i.getCreateAddress)(r);return new a.BaseContract(n,this.interface,this.runner,r)}connect(e){return new s(this.interface,this.bytecode,e)}static fromSolidity(e,t){(0,o.assertArgument)(null!=e,"bad compiler output","output",e),"string"==typeof e&&(e=JSON.parse(e));const r=e.abi;let n="";return e.bytecode?n=e.bytecode:e.evm&&e.evm.bytecode&&(n=e.evm.bytecode),new this(r,n,t)}}t.ContractFactory=s},37252:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EventLog=t.ContractTransactionResponse=t.ContractTransactionReceipt=t.ContractUnknownEventPayload=t.ContractEventPayload=t.ContractFactory=t.Contract=t.BaseContract=void 0;var n=r(44350);Object.defineProperty(t,"BaseContract",{enumerable:!0,get:function(){return n.BaseContract}}),Object.defineProperty(t,"Contract",{enumerable:!0,get:function(){return n.Contract}});var i=r(31018);Object.defineProperty(t,"ContractFactory",{enumerable:!0,get:function(){return i.ContractFactory}});var o=r(97151);Object.defineProperty(t,"ContractEventPayload",{enumerable:!0,get:function(){return o.ContractEventPayload}}),Object.defineProperty(t,"ContractUnknownEventPayload",{enumerable:!0,get:function(){return o.ContractUnknownEventPayload}}),Object.defineProperty(t,"ContractTransactionReceipt",{enumerable:!0,get:function(){return o.ContractTransactionReceipt}}),Object.defineProperty(t,"ContractTransactionResponse",{enumerable:!0,get:function(){return o.ContractTransactionResponse}}),Object.defineProperty(t,"EventLog",{enumerable:!0,get:function(){return o.EventLog}})},97151:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ContractEventPayload=t.ContractUnknownEventPayload=t.ContractTransactionResponse=t.ContractTransactionReceipt=t.EventLog=void 0;const n=r(37143),i=r(42120);class o extends n.Log{interface;fragment;args;constructor(e,t,r){super(e,e.provider);const n=t.decodeEventLog(r,e.data,e.topics);(0,i.defineProperties)(this,{args:n,fragment:r,interface:t})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}t.EventLog=o;class a extends n.TransactionReceipt{#b;constructor(e,t,r){super(r,t),this.#b=e}get logs(){return super.logs.map((e=>{const t=e.topics.length?this.#b.getEvent(e.topics[0]):null;return t?new o(e,this.#b,t):e}))}}t.ContractTransactionReceipt=a;class s extends n.TransactionResponse{#b;constructor(e,t,r){super(r,t),this.#b=e}async wait(e){const t=await super.wait();return null==t?null:new a(this.#b,this.provider,t)}}t.ContractTransactionResponse=s;class u extends i.EventPayload{log;constructor(e,t,r,n){super(e,t,r),(0,i.defineProperties)(this,{log:n})}async getBlock(){return await this.log.getBlock()}async getTransaction(){return await this.log.getTransaction()}async getTransactionReceipt(){return await this.log.getTransactionReceipt()}}t.ContractUnknownEventPayload=u;t.ContractEventPayload=class extends u{constructor(e,t,r,n,a){super(e,t,r,new o(a,e.interface,n));const s=e.interface.decodeEventLog(n,this.log.data,this.log.topics);(0,i.defineProperties)(this,{args:s,fragment:n})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}},84862:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.randomBytes=t.pbkdf2Sync=t.createHmac=t.createHash=void 0;var n=r(55835);Object.defineProperty(t,"createHash",{enumerable:!0,get:function(){return n.createHash}}),Object.defineProperty(t,"createHmac",{enumerable:!0,get:function(){return n.createHmac}}),Object.defineProperty(t,"pbkdf2Sync",{enumerable:!0,get:function(){return n.pbkdf2Sync}}),Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return n.randomBytes}})},76117:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.computeHmac=void 0;const n=r(84862),i=r(42120);let o=!1;const a=function(e,t,r){return(0,n.createHmac)(e,t).update(r).digest()};let s=a;function u(e,t,r){const n=(0,i.getBytes)(t,"key"),o=(0,i.getBytes)(r,"data");return(0,i.hexlify)(s(e,n,o))}t.computeHmac=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new Error("computeHmac is locked");s=e},Object.freeze(u)},96965:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.lock=t.Signature=t.SigningKey=t.scryptSync=t.scrypt=t.pbkdf2=t.sha512=t.sha256=t.ripemd160=t.keccak256=t.randomBytes=t.computeHmac=void 0;const n=r(76117);Object.defineProperty(t,"computeHmac",{enumerable:!0,get:function(){return n.computeHmac}});const i=r(33037);Object.defineProperty(t,"keccak256",{enumerable:!0,get:function(){return i.keccak256}});const o=r(7990);Object.defineProperty(t,"ripemd160",{enumerable:!0,get:function(){return o.ripemd160}});const a=r(64989);Object.defineProperty(t,"pbkdf2",{enumerable:!0,get:function(){return a.pbkdf2}});const s=r(62385);Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return s.randomBytes}});const u=r(16168);Object.defineProperty(t,"scrypt",{enumerable:!0,get:function(){return u.scrypt}}),Object.defineProperty(t,"scryptSync",{enumerable:!0,get:function(){return u.scryptSync}});const c=r(69233);Object.defineProperty(t,"sha256",{enumerable:!0,get:function(){return c.sha256}}),Object.defineProperty(t,"sha512",{enumerable:!0,get:function(){return c.sha512}});var l=r(33106);Object.defineProperty(t,"SigningKey",{enumerable:!0,get:function(){return l.SigningKey}});var f=r(63295);Object.defineProperty(t,"Signature",{enumerable:!0,get:function(){return f.Signature}}),t.lock=function(){n.computeHmac.lock(),i.keccak256.lock(),a.pbkdf2.lock(),s.randomBytes.lock(),o.ripemd160.lock(),u.scrypt.lock(),u.scryptSync.lock(),c.sha256.lock(),c.sha512.lock(),s.randomBytes.lock()}},33037:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.keccak256=void 0;const n=r(85426),i=r(42120);let o=!1;const a=function(e){return(0,n.keccak_256)(e)};let s=a;function u(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(s(t))}t.keccak256=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new TypeError("keccak256 is locked");s=e},Object.freeze(u)},64989:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pbkdf2=void 0;const n=r(84862),i=r(42120);let o=!1;const a=function(e,t,r,i,o){return(0,n.pbkdf2Sync)(e,t,r,i,o)};let s=a;function u(e,t,r,n,o){const a=(0,i.getBytes)(e,"password"),u=(0,i.getBytes)(t,"salt");return(0,i.hexlify)(s(a,u,r,n,o))}t.pbkdf2=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new Error("pbkdf2 is locked");s=e},Object.freeze(u)},62385:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.randomBytes=void 0;const n=r(84862);let i=!1;const o=function(e){return new Uint8Array((0,n.randomBytes)(e))};let a=o;function s(e){return a(e)}t.randomBytes=s,s._=o,s.lock=function(){i=!0},s.register=function(e){if(i)throw new Error("randomBytes is locked");a=e},Object.freeze(s)},7990:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ripemd160=void 0;const n=r(70830),i=r(42120);let o=!1;const a=function(e){return(0,n.ripemd160)(e)};let s=a;function u(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(s(t))}t.ripemd160=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new TypeError("ripemd160 is locked");s=e},Object.freeze(u)},16168:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.scryptSync=t.scrypt=void 0;const n=r(69514),i=r(42120);let o=!1,a=!1;const s=async function(e,t,r,i,o,a,s){return await(0,n.scryptAsync)(e,t,{N:r,r:i,p:o,dkLen:a,onProgress:s})},u=function(e,t,r,i,o,a){return(0,n.scrypt)(e,t,{N:r,r:i,p:o,dkLen:a})};let c=s,l=u;async function f(e,t,r,n,o,a,s){const u=(0,i.getBytes)(e,"passwd"),l=(0,i.getBytes)(t,"salt");return(0,i.hexlify)(await c(u,l,r,n,o,a,s))}function h(e,t,r,n,o,a){const s=(0,i.getBytes)(e,"passwd"),u=(0,i.getBytes)(t,"salt");return(0,i.hexlify)(l(s,u,r,n,o,a))}t.scrypt=f,f._=s,f.lock=function(){a=!0},f.register=function(e){if(a)throw new Error("scrypt is locked");c=e},Object.freeze(f),t.scryptSync=h,h._=u,h.lock=function(){o=!0},h.register=function(e){if(o)throw new Error("scryptSync is locked");l=e},Object.freeze(h)},69233:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha512=t.sha256=void 0;const n=r(84862),i=r(42120),o=function(e){return(0,n.createHash)("sha256").update(e).digest()},a=function(e){return(0,n.createHash)("sha512").update(e).digest()};let s=o,u=a,c=!1,l=!1;function f(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(s(t))}function h(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(u(t))}t.sha256=f,f._=o,f.lock=function(){c=!0},f.register=function(e){if(c)throw new Error("sha256 is locked");s=e},Object.freeze(f),t.sha512=h,h._=a,h.lock=function(){l=!0},h.register=function(e){if(l)throw new Error("sha512 is locked");u=e},Object.freeze(f)},63295:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Signature=void 0;const n=r(30087),i=r(42120),o=BigInt(0),a=BigInt(1),s=BigInt(2),u=BigInt(27),c=BigInt(28),l=BigInt(35),f={};function h(e){return(0,i.zeroPadValue)((0,i.toBeArray)(e),32)}class d{#v;#w;#A;#S;get r(){return this.#v}set r(e){(0,i.assertArgument)(32===(0,i.dataLength)(e),"invalid r","value",e),this.#v=(0,i.hexlify)(e)}get s(){return this.#w}set s(e){(0,i.assertArgument)(32===(0,i.dataLength)(e),"invalid r","value",e);const t=(0,i.hexlify)(e);(0,i.assertArgument)(parseInt(t.substring(0,3))<8,"non-canonical s","value",t),this.#w=t}get v(){return this.#A}set v(e){const t=(0,i.getNumber)(e,"value");(0,i.assertArgument)(27===t||28===t,"invalid v","v",e),this.#A=t}get networkV(){return this.#S}get legacyChainId(){const e=this.networkV;return null==e?null:d.getChainId(e)}get yParity(){return 27===this.v?0:1}get yParityAndS(){const e=(0,i.getBytes)(this.s);return this.yParity&&(e[0]|=128),(0,i.hexlify)(e)}get compactSerialized(){return(0,i.concat)([this.r,this.yParityAndS])}get serialized(){return(0,i.concat)([this.r,this.s,this.yParity?"0x1c":"0x1b"])}constructor(e,t,r,n){(0,i.assertPrivate)(e,f,"Signature"),this.#v=t,this.#w=r,this.#A=n,this.#S=null}[Symbol.for("nodejs.util.inspect.custom")](){return`Signature { r: "${this.r}", s: "${this.s}", yParity: ${this.yParity}, networkV: ${this.networkV} }`}clone(){const e=new d(f,this.r,this.s,this.v);return this.networkV&&(e.#S=this.networkV),e}toJSON(){const e=this.networkV;return{_type:"signature",networkV:null!=e?e.toString():null,r:this.r,s:this.s,v:this.v}}static getChainId(e){const t=(0,i.getBigInt)(e,"v");return t==u||t==c?o:((0,i.assertArgument)(t>=l,"invalid EIP-155 v","v",e),(t-l)/s)}static getChainIdV(e,t){return(0,i.getBigInt)(e)*s+BigInt(35+t-27)}static getNormalizedV(e){const t=(0,i.getBigInt)(e);return t===o||t===u?27:t===a||t===c?28:((0,i.assertArgument)(t>=l,"invalid v","v",e),t&a?27:28)}static from(e){function t(t,r){(0,i.assertArgument)(t,r,"signature",e)}if(null==e)return new d(f,n.ZeroHash,n.ZeroHash,27);if("string"==typeof e){const r=(0,i.getBytes)(e,"signature");if(64===r.length){const e=(0,i.hexlify)(r.slice(0,32)),t=r.slice(32,64),n=128&t[0]?28:27;return t[0]&=127,new d(f,e,(0,i.hexlify)(t),n)}if(65===r.length){const e=(0,i.hexlify)(r.slice(0,32)),n=r.slice(32,64);t(0==(128&n[0]),"non-canonical s");const o=d.getNormalizedV(r[64]);return new d(f,e,(0,i.hexlify)(n),o)}t(!1,"invalid raw signature length")}if(e instanceof d)return e.clone();const r=e.r;t(null!=r,"missing r");const o=h(r),a=function(e,r){if(null!=e)return h(e);if(null!=r){t((0,i.isHexString)(r,32),"invalid yParityAndS");const e=(0,i.getBytes)(r);return e[0]&=127,(0,i.hexlify)(e)}t(!1,"missing s")}(e.s,e.yParityAndS);t(0==(128&(0,i.getBytes)(a)[0]),"non-canonical s");const{networkV:s,v:u}=function(e,r,n){if(null!=e){const t=(0,i.getBigInt)(e);return{networkV:t>=l?t:void 0,v:d.getNormalizedV(t)}}if(null!=r)return t((0,i.isHexString)(r,32),"invalid yParityAndS"),{v:128&(0,i.getBytes)(r)[0]?28:27};if(null!=n){switch(n){case 0:return{v:27};case 1:return{v:28}}t(!1,"invalid yParity")}t(!1,"missing v")}(e.v,e.yParityAndS,e.yParity),c=new d(f,o,a,u);return s&&(c.#S=s),t(!("yParity"in e&&e.yParity!==c.yParity),"yParity mismatch"),t(!("yParityAndS"in e&&e.yParityAndS!==c.yParityAndS),"yParityAndS mismatch"),c}}t.Signature=d},33106:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.SigningKey=void 0;const a=o(r(79656)),s=r(42120),u=r(76117),c=r(63295);a.utils.hmacSha256Sync=function(e,...t){return(0,s.getBytes)((0,u.computeHmac)("sha256",e,(0,s.concat)(t)))};class l{#k;constructor(e){(0,s.assertArgument)(32===(0,s.dataLength)(e),"invalid private key","privateKey","[REDACTED]"),this.#k=(0,s.hexlify)(e)}get privateKey(){return this.#k}get publicKey(){return l.computePublicKey(this.#k)}get compressedPublicKey(){return l.computePublicKey(this.#k,!0)}sign(e){(0,s.assertArgument)(32===(0,s.dataLength)(e),"invalid digest length","digest",e);const[t,r]=a.signSync((0,s.getBytesCopy)(e),(0,s.getBytesCopy)(this.#k),{recovered:!0,canonical:!0}),n=a.Signature.fromHex(t);return c.Signature.from({r:(0,s.toBeHex)("0x"+n.r.toString(16),32),s:(0,s.toBeHex)("0x"+n.s.toString(16),32),v:r?28:27})}computeSharedSecret(e){const t=l.computePublicKey(e);return console.log(t),(0,s.hexlify)(a.getSharedSecret((0,s.getBytesCopy)(this.#k),(0,s.getBytes)(t)))}static computePublicKey(e,t){let r=(0,s.getBytes)(e,"key");if(32===r.length){const e=a.getPublicKey(r,!!t);return(0,s.hexlify)(e)}if(64===r.length){const e=new Uint8Array(65);e[0]=4,e.set(r,1),r=e}const n=a.Point.fromHex(r);return(0,s.hexlify)(n.toRawBytes(t))}static recoverPublicKey(e,t){(0,s.assertArgument)(32===(0,s.dataLength)(e),"invalid digest length","digest",e);const r=c.Signature.from(t),n=a.Signature.fromCompact((0,s.getBytesCopy)((0,s.concat)([r.r,r.s]))).toDERRawBytes(),i=a.recoverPublicKey((0,s.getBytesCopy)(e),n,r.yParity);if(null!=i)return(0,s.hexlify)(i);(0,s.assertArgument)(!1,"invalid signautre for digest","signature",t)}static addPoints(e,t,r){const n=a.Point.fromHex(l.computePublicKey(e).substring(2)),i=a.Point.fromHex(l.computePublicKey(t).substring(2));return"0x"+n.add(i).toHex(!!r)}}t.SigningKey=l},81097:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha256=t.ripemd160=t.keccak256=t.randomBytes=t.computeHmac=t.EventLog=t.ContractUnknownEventPayload=t.ContractTransactionResponse=t.ContractTransactionReceipt=t.ContractEventPayload=t.ContractFactory=t.Contract=t.BaseContract=t.MessagePrefix=t.EtherSymbol=t.ZeroHash=t.N=t.MaxInt256=t.MinInt256=t.MaxUint256=t.WeiPerEther=t.ZeroAddress=t.resolveAddress=t.isAddress=t.isAddressable=t.getCreate2Address=t.getCreateAddress=t.getIcapAddress=t.getAddress=t.Typed=t.TransactionDescription=t.Result=t.LogDescription=t.Interface=t.Indexed=t.ErrorDescription=t.checkResultErrors=t.StructFragment=t.ParamType=t.NamedFragment=t.FunctionFragment=t.FallbackFragment=t.Fragment=t.EventFragment=t.ErrorFragment=t.ConstructorFragment=t.AbiCoder=t.encodeBytes32String=t.decodeBytes32String=t.version=void 0,t.GasCostPlugin=t.FeeDataNetworkPlugin=t.EtherscanPlugin=t.EnsPlugin=t.Network=t.EnsResolver=t.WebSocketProvider=t.SocketProvider=t.IpcSocketProvider=t.QuickNodeProvider=t.PocketProvider=t.InfuraWebSocketProvider=t.InfuraProvider=t.EtherscanProvider=t.CloudflareProvider=t.AnkrProvider=t.AlchemyProvider=t.BrowserProvider=t.JsonRpcSigner=t.JsonRpcProvider=t.JsonRpcApiProvider=t.FallbackProvider=t.AbstractProvider=t.VoidSigner=t.NonceManager=t.AbstractSigner=t.TransactionResponse=t.TransactionReceipt=t.Log=t.FeeData=t.Block=t.getDefaultProvider=t.TypedDataEncoder=t.solidityPackedSha256=t.solidityPackedKeccak256=t.solidityPacked=t.verifyMessage=t.hashMessage=t.dnsEncode=t.namehash=t.isValidName=t.ensNormalize=t.id=t.SigningKey=t.Signature=t.lock=t.scryptSync=t.scrypt=t.pbkdf2=t.sha512=void 0,t.toQuantity=t.toNumber=t.toBeHex=t.toBigInt=t.toBeArray=t.getUint=t.getNumber=t.getBigInt=t.FixedNumber=t.FetchCancelSignal=t.FetchResponse=t.FetchRequest=t.EventPayload=t.isError=t.isCallException=t.makeError=t.assertPrivate=t.assertNormalize=t.assertArgumentCount=t.assertArgument=t.assert=t.resolveProperties=t.defineProperties=t.zeroPadValue=t.zeroPadBytes=t.stripZerosLeft=t.isBytesLike=t.isHexString=t.hexlify=t.getBytesCopy=t.getBytes=t.dataSlice=t.dataLength=t.concat=t.encodeBase64=t.decodeBase64=t.encodeBase58=t.decodeBase58=t.Transaction=t.recoverAddress=t.computeAddress=t.accessListify=t.showThrottleMessage=t.copyRequest=t.UnmanagedSubscriber=t.SocketSubscriber=t.SocketPendingSubscriber=t.SocketEventSubscriber=t.SocketBlockSubscriber=t.NetworkPlugin=void 0,t.wordlists=t.WordlistOwlA=t.WordlistOwl=t.LangEn=t.Wordlist=t.encryptKeystoreJsonSync=t.encryptKeystoreJson=t.decryptKeystoreJson=t.decryptKeystoreJsonSync=t.decryptCrowdsaleJson=t.isKeystoreJson=t.isCrowdsaleJson=t.getAccountPath=t.defaultPath=t.Wallet=t.HDNodeVoidWallet=t.HDNodeWallet=t.BaseWallet=t.Mnemonic=t.uuidV4=t.encodeRlp=t.decodeRlp=t.Utf8ErrorFuncs=t.toUtf8String=t.toUtf8CodePoints=t.toUtf8Bytes=t.parseUnits=t.formatUnits=t.parseEther=t.formatEther=t.mask=t.toTwos=t.fromTwos=void 0;var n=r(79406);Object.defineProperty(t,"version",{enumerable:!0,get:function(){return n.version}});var i=r(93707);Object.defineProperty(t,"decodeBytes32String",{enumerable:!0,get:function(){return i.decodeBytes32String}}),Object.defineProperty(t,"encodeBytes32String",{enumerable:!0,get:function(){return i.encodeBytes32String}}),Object.defineProperty(t,"AbiCoder",{enumerable:!0,get:function(){return i.AbiCoder}}),Object.defineProperty(t,"ConstructorFragment",{enumerable:!0,get:function(){return i.ConstructorFragment}}),Object.defineProperty(t,"ErrorFragment",{enumerable:!0,get:function(){return i.ErrorFragment}}),Object.defineProperty(t,"EventFragment",{enumerable:!0,get:function(){return i.EventFragment}}),Object.defineProperty(t,"Fragment",{enumerable:!0,get:function(){return i.Fragment}}),Object.defineProperty(t,"FallbackFragment",{enumerable:!0,get:function(){return i.FallbackFragment}}),Object.defineProperty(t,"FunctionFragment",{enumerable:!0,get:function(){return i.FunctionFragment}}),Object.defineProperty(t,"NamedFragment",{enumerable:!0,get:function(){return i.NamedFragment}}),Object.defineProperty(t,"ParamType",{enumerable:!0,get:function(){return i.ParamType}}),Object.defineProperty(t,"StructFragment",{enumerable:!0,get:function(){return i.StructFragment}}),Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return i.checkResultErrors}}),Object.defineProperty(t,"ErrorDescription",{enumerable:!0,get:function(){return i.ErrorDescription}}),Object.defineProperty(t,"Indexed",{enumerable:!0,get:function(){return i.Indexed}}),Object.defineProperty(t,"Interface",{enumerable:!0,get:function(){return i.Interface}}),Object.defineProperty(t,"LogDescription",{enumerable:!0,get:function(){return i.LogDescription}}),Object.defineProperty(t,"Result",{enumerable:!0,get:function(){return i.Result}}),Object.defineProperty(t,"TransactionDescription",{enumerable:!0,get:function(){return i.TransactionDescription}}),Object.defineProperty(t,"Typed",{enumerable:!0,get:function(){return i.Typed}});var o=r(45475);Object.defineProperty(t,"getAddress",{enumerable:!0,get:function(){return o.getAddress}}),Object.defineProperty(t,"getIcapAddress",{enumerable:!0,get:function(){return o.getIcapAddress}}),Object.defineProperty(t,"getCreateAddress",{enumerable:!0,get:function(){return o.getCreateAddress}}),Object.defineProperty(t,"getCreate2Address",{enumerable:!0,get:function(){return o.getCreate2Address}}),Object.defineProperty(t,"isAddressable",{enumerable:!0,get:function(){return o.isAddressable}}),Object.defineProperty(t,"isAddress",{enumerable:!0,get:function(){return o.isAddress}}),Object.defineProperty(t,"resolveAddress",{enumerable:!0,get:function(){return o.resolveAddress}});var a=r(30087);Object.defineProperty(t,"ZeroAddress",{enumerable:!0,get:function(){return a.ZeroAddress}}),Object.defineProperty(t,"WeiPerEther",{enumerable:!0,get:function(){return a.WeiPerEther}}),Object.defineProperty(t,"MaxUint256",{enumerable:!0,get:function(){return a.MaxUint256}}),Object.defineProperty(t,"MinInt256",{enumerable:!0,get:function(){return a.MinInt256}}),Object.defineProperty(t,"MaxInt256",{enumerable:!0,get:function(){return a.MaxInt256}}),Object.defineProperty(t,"N",{enumerable:!0,get:function(){return a.N}}),Object.defineProperty(t,"ZeroHash",{enumerable:!0,get:function(){return a.ZeroHash}}),Object.defineProperty(t,"EtherSymbol",{enumerable:!0,get:function(){return a.EtherSymbol}}),Object.defineProperty(t,"MessagePrefix",{enumerable:!0,get:function(){return a.MessagePrefix}});var s=r(37252);Object.defineProperty(t,"BaseContract",{enumerable:!0,get:function(){return s.BaseContract}}),Object.defineProperty(t,"Contract",{enumerable:!0,get:function(){return s.Contract}}),Object.defineProperty(t,"ContractFactory",{enumerable:!0,get:function(){return s.ContractFactory}}),Object.defineProperty(t,"ContractEventPayload",{enumerable:!0,get:function(){return s.ContractEventPayload}}),Object.defineProperty(t,"ContractTransactionReceipt",{enumerable:!0,get:function(){return s.ContractTransactionReceipt}}),Object.defineProperty(t,"ContractTransactionResponse",{enumerable:!0,get:function(){return s.ContractTransactionResponse}}),Object.defineProperty(t,"ContractUnknownEventPayload",{enumerable:!0,get:function(){return s.ContractUnknownEventPayload}}),Object.defineProperty(t,"EventLog",{enumerable:!0,get:function(){return s.EventLog}});var u=r(96965);Object.defineProperty(t,"computeHmac",{enumerable:!0,get:function(){return u.computeHmac}}),Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return u.randomBytes}}),Object.defineProperty(t,"keccak256",{enumerable:!0,get:function(){return u.keccak256}}),Object.defineProperty(t,"ripemd160",{enumerable:!0,get:function(){return u.ripemd160}}),Object.defineProperty(t,"sha256",{enumerable:!0,get:function(){return u.sha256}}),Object.defineProperty(t,"sha512",{enumerable:!0,get:function(){return u.sha512}}),Object.defineProperty(t,"pbkdf2",{enumerable:!0,get:function(){return u.pbkdf2}}),Object.defineProperty(t,"scrypt",{enumerable:!0,get:function(){return u.scrypt}}),Object.defineProperty(t,"scryptSync",{enumerable:!0,get:function(){return u.scryptSync}}),Object.defineProperty(t,"lock",{enumerable:!0,get:function(){return u.lock}}),Object.defineProperty(t,"Signature",{enumerable:!0,get:function(){return u.Signature}}),Object.defineProperty(t,"SigningKey",{enumerable:!0,get:function(){return u.SigningKey}});var c=r(98336);Object.defineProperty(t,"id",{enumerable:!0,get:function(){return c.id}}),Object.defineProperty(t,"ensNormalize",{enumerable:!0,get:function(){return c.ensNormalize}}),Object.defineProperty(t,"isValidName",{enumerable:!0,get:function(){return c.isValidName}}),Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return c.namehash}}),Object.defineProperty(t,"dnsEncode",{enumerable:!0,get:function(){return c.dnsEncode}}),Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return c.hashMessage}}),Object.defineProperty(t,"verifyMessage",{enumerable:!0,get:function(){return c.verifyMessage}}),Object.defineProperty(t,"solidityPacked",{enumerable:!0,get:function(){return c.solidityPacked}}),Object.defineProperty(t,"solidityPackedKeccak256",{enumerable:!0,get:function(){return c.solidityPackedKeccak256}}),Object.defineProperty(t,"solidityPackedSha256",{enumerable:!0,get:function(){return c.solidityPackedSha256}}),Object.defineProperty(t,"TypedDataEncoder",{enumerable:!0,get:function(){return c.TypedDataEncoder}});var l=r(4878);Object.defineProperty(t,"getDefaultProvider",{enumerable:!0,get:function(){return l.getDefaultProvider}}),Object.defineProperty(t,"Block",{enumerable:!0,get:function(){return l.Block}}),Object.defineProperty(t,"FeeData",{enumerable:!0,get:function(){return l.FeeData}}),Object.defineProperty(t,"Log",{enumerable:!0,get:function(){return l.Log}}),Object.defineProperty(t,"TransactionReceipt",{enumerable:!0,get:function(){return l.TransactionReceipt}}),Object.defineProperty(t,"TransactionResponse",{enumerable:!0,get:function(){return l.TransactionResponse}}),Object.defineProperty(t,"AbstractSigner",{enumerable:!0,get:function(){return l.AbstractSigner}}),Object.defineProperty(t,"NonceManager",{enumerable:!0,get:function(){return l.NonceManager}}),Object.defineProperty(t,"VoidSigner",{enumerable:!0,get:function(){return l.VoidSigner}}),Object.defineProperty(t,"AbstractProvider",{enumerable:!0,get:function(){return l.AbstractProvider}}),Object.defineProperty(t,"FallbackProvider",{enumerable:!0,get:function(){return l.FallbackProvider}}),Object.defineProperty(t,"JsonRpcApiProvider",{enumerable:!0,get:function(){return l.JsonRpcApiProvider}}),Object.defineProperty(t,"JsonRpcProvider",{enumerable:!0,get:function(){return l.JsonRpcProvider}}),Object.defineProperty(t,"JsonRpcSigner",{enumerable:!0,get:function(){return l.JsonRpcSigner}}),Object.defineProperty(t,"BrowserProvider",{enumerable:!0,get:function(){return l.BrowserProvider}}),Object.defineProperty(t,"AlchemyProvider",{enumerable:!0,get:function(){return l.AlchemyProvider}}),Object.defineProperty(t,"AnkrProvider",{enumerable:!0,get:function(){return l.AnkrProvider}}),Object.defineProperty(t,"CloudflareProvider",{enumerable:!0,get:function(){return l.CloudflareProvider}}),Object.defineProperty(t,"EtherscanProvider",{enumerable:!0,get:function(){return l.EtherscanProvider}}),Object.defineProperty(t,"InfuraProvider",{enumerable:!0,get:function(){return l.InfuraProvider}}),Object.defineProperty(t,"InfuraWebSocketProvider",{enumerable:!0,get:function(){return l.InfuraWebSocketProvider}}),Object.defineProperty(t,"PocketProvider",{enumerable:!0,get:function(){return l.PocketProvider}}),Object.defineProperty(t,"QuickNodeProvider",{enumerable:!0,get:function(){return l.QuickNodeProvider}}),Object.defineProperty(t,"IpcSocketProvider",{enumerable:!0,get:function(){return l.IpcSocketProvider}}),Object.defineProperty(t,"SocketProvider",{enumerable:!0,get:function(){return l.SocketProvider}}),Object.defineProperty(t,"WebSocketProvider",{enumerable:!0,get:function(){return l.WebSocketProvider}}),Object.defineProperty(t,"EnsResolver",{enumerable:!0,get:function(){return l.EnsResolver}}),Object.defineProperty(t,"Network",{enumerable:!0,get:function(){return l.Network}}),Object.defineProperty(t,"EnsPlugin",{enumerable:!0,get:function(){return l.EnsPlugin}}),Object.defineProperty(t,"EtherscanPlugin",{enumerable:!0,get:function(){return l.EtherscanPlugin}}),Object.defineProperty(t,"FeeDataNetworkPlugin",{enumerable:!0,get:function(){return l.FeeDataNetworkPlugin}}),Object.defineProperty(t,"GasCostPlugin",{enumerable:!0,get:function(){return l.GasCostPlugin}}),Object.defineProperty(t,"NetworkPlugin",{enumerable:!0,get:function(){return l.NetworkPlugin}}),Object.defineProperty(t,"SocketBlockSubscriber",{enumerable:!0,get:function(){return l.SocketBlockSubscriber}}),Object.defineProperty(t,"SocketEventSubscriber",{enumerable:!0,get:function(){return l.SocketEventSubscriber}}),Object.defineProperty(t,"SocketPendingSubscriber",{enumerable:!0,get:function(){return l.SocketPendingSubscriber}}),Object.defineProperty(t,"SocketSubscriber",{enumerable:!0,get:function(){return l.SocketSubscriber}}),Object.defineProperty(t,"UnmanagedSubscriber",{enumerable:!0,get:function(){return l.UnmanagedSubscriber}}),Object.defineProperty(t,"copyRequest",{enumerable:!0,get:function(){return l.copyRequest}}),Object.defineProperty(t,"showThrottleMessage",{enumerable:!0,get:function(){return l.showThrottleMessage}});var f=r(2290);Object.defineProperty(t,"accessListify",{enumerable:!0,get:function(){return f.accessListify}}),Object.defineProperty(t,"computeAddress",{enumerable:!0,get:function(){return f.computeAddress}}),Object.defineProperty(t,"recoverAddress",{enumerable:!0,get:function(){return f.recoverAddress}}),Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return f.Transaction}});var h=r(42120);Object.defineProperty(t,"decodeBase58",{enumerable:!0,get:function(){return h.decodeBase58}}),Object.defineProperty(t,"encodeBase58",{enumerable:!0,get:function(){return h.encodeBase58}}),Object.defineProperty(t,"decodeBase64",{enumerable:!0,get:function(){return h.decodeBase64}}),Object.defineProperty(t,"encodeBase64",{enumerable:!0,get:function(){return h.encodeBase64}}),Object.defineProperty(t,"concat",{enumerable:!0,get:function(){return h.concat}}),Object.defineProperty(t,"dataLength",{enumerable:!0,get:function(){return h.dataLength}}),Object.defineProperty(t,"dataSlice",{enumerable:!0,get:function(){return h.dataSlice}}),Object.defineProperty(t,"getBytes",{enumerable:!0,get:function(){return h.getBytes}}),Object.defineProperty(t,"getBytesCopy",{enumerable:!0,get:function(){return h.getBytesCopy}}),Object.defineProperty(t,"hexlify",{enumerable:!0,get:function(){return h.hexlify}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return h.isHexString}}),Object.defineProperty(t,"isBytesLike",{enumerable:!0,get:function(){return h.isBytesLike}}),Object.defineProperty(t,"stripZerosLeft",{enumerable:!0,get:function(){return h.stripZerosLeft}}),Object.defineProperty(t,"zeroPadBytes",{enumerable:!0,get:function(){return h.zeroPadBytes}}),Object.defineProperty(t,"zeroPadValue",{enumerable:!0,get:function(){return h.zeroPadValue}}),Object.defineProperty(t,"defineProperties",{enumerable:!0,get:function(){return h.defineProperties}}),Object.defineProperty(t,"resolveProperties",{enumerable:!0,get:function(){return h.resolveProperties}}),Object.defineProperty(t,"assert",{enumerable:!0,get:function(){return h.assert}}),Object.defineProperty(t,"assertArgument",{enumerable:!0,get:function(){return h.assertArgument}}),Object.defineProperty(t,"assertArgumentCount",{enumerable:!0,get:function(){return h.assertArgumentCount}}),Object.defineProperty(t,"assertNormalize",{enumerable:!0,get:function(){return h.assertNormalize}}),Object.defineProperty(t,"assertPrivate",{enumerable:!0,get:function(){return h.assertPrivate}}),Object.defineProperty(t,"makeError",{enumerable:!0,get:function(){return h.makeError}}),Object.defineProperty(t,"isCallException",{enumerable:!0,get:function(){return h.isCallException}}),Object.defineProperty(t,"isError",{enumerable:!0,get:function(){return h.isError}}),Object.defineProperty(t,"EventPayload",{enumerable:!0,get:function(){return h.EventPayload}}),Object.defineProperty(t,"FetchRequest",{enumerable:!0,get:function(){return h.FetchRequest}}),Object.defineProperty(t,"FetchResponse",{enumerable:!0,get:function(){return h.FetchResponse}}),Object.defineProperty(t,"FetchCancelSignal",{enumerable:!0,get:function(){return h.FetchCancelSignal}}),Object.defineProperty(t,"FixedNumber",{enumerable:!0,get:function(){return h.FixedNumber}}),Object.defineProperty(t,"getBigInt",{enumerable:!0,get:function(){return h.getBigInt}}),Object.defineProperty(t,"getNumber",{enumerable:!0,get:function(){return h.getNumber}}),Object.defineProperty(t,"getUint",{enumerable:!0,get:function(){return h.getUint}}),Object.defineProperty(t,"toBeArray",{enumerable:!0,get:function(){return h.toBeArray}}),Object.defineProperty(t,"toBigInt",{enumerable:!0,get:function(){return h.toBigInt}}),Object.defineProperty(t,"toBeHex",{enumerable:!0,get:function(){return h.toBeHex}}),Object.defineProperty(t,"toNumber",{enumerable:!0,get:function(){return h.toNumber}}),Object.defineProperty(t,"toQuantity",{enumerable:!0,get:function(){return h.toQuantity}}),Object.defineProperty(t,"fromTwos",{enumerable:!0,get:function(){return h.fromTwos}}),Object.defineProperty(t,"toTwos",{enumerable:!0,get:function(){return h.toTwos}}),Object.defineProperty(t,"mask",{enumerable:!0,get:function(){return h.mask}}),Object.defineProperty(t,"formatEther",{enumerable:!0,get:function(){return h.formatEther}}),Object.defineProperty(t,"parseEther",{enumerable:!0,get:function(){return h.parseEther}}),Object.defineProperty(t,"formatUnits",{enumerable:!0,get:function(){return h.formatUnits}}),Object.defineProperty(t,"parseUnits",{enumerable:!0,get:function(){return h.parseUnits}}),Object.defineProperty(t,"toUtf8Bytes",{enumerable:!0,get:function(){return h.toUtf8Bytes}}),Object.defineProperty(t,"toUtf8CodePoints",{enumerable:!0,get:function(){return h.toUtf8CodePoints}}),Object.defineProperty(t,"toUtf8String",{enumerable:!0,get:function(){return h.toUtf8String}}),Object.defineProperty(t,"Utf8ErrorFuncs",{enumerable:!0,get:function(){return h.Utf8ErrorFuncs}}),Object.defineProperty(t,"decodeRlp",{enumerable:!0,get:function(){return h.decodeRlp}}),Object.defineProperty(t,"encodeRlp",{enumerable:!0,get:function(){return h.encodeRlp}}),Object.defineProperty(t,"uuidV4",{enumerable:!0,get:function(){return h.uuidV4}});var d=r(91602);Object.defineProperty(t,"Mnemonic",{enumerable:!0,get:function(){return d.Mnemonic}}),Object.defineProperty(t,"BaseWallet",{enumerable:!0,get:function(){return d.BaseWallet}}),Object.defineProperty(t,"HDNodeWallet",{enumerable:!0,get:function(){return d.HDNodeWallet}}),Object.defineProperty(t,"HDNodeVoidWallet",{enumerable:!0,get:function(){return d.HDNodeVoidWallet}}),Object.defineProperty(t,"Wallet",{enumerable:!0,get:function(){return d.Wallet}}),Object.defineProperty(t,"defaultPath",{enumerable:!0,get:function(){return d.defaultPath}}),Object.defineProperty(t,"getAccountPath",{enumerable:!0,get:function(){return d.getAccountPath}}),Object.defineProperty(t,"isCrowdsaleJson",{enumerable:!0,get:function(){return d.isCrowdsaleJson}}),Object.defineProperty(t,"isKeystoreJson",{enumerable:!0,get:function(){return d.isKeystoreJson}}),Object.defineProperty(t,"decryptCrowdsaleJson",{enumerable:!0,get:function(){return d.decryptCrowdsaleJson}}),Object.defineProperty(t,"decryptKeystoreJsonSync",{enumerable:!0,get:function(){return d.decryptKeystoreJsonSync}}),Object.defineProperty(t,"decryptKeystoreJson",{enumerable:!0,get:function(){return d.decryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJson",{enumerable:!0,get:function(){return d.encryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJsonSync",{enumerable:!0,get:function(){return d.encryptKeystoreJsonSync}});var p=r(60659);Object.defineProperty(t,"Wordlist",{enumerable:!0,get:function(){return p.Wordlist}}),Object.defineProperty(t,"LangEn",{enumerable:!0,get:function(){return p.LangEn}}),Object.defineProperty(t,"WordlistOwl",{enumerable:!0,get:function(){return p.WordlistOwl}}),Object.defineProperty(t,"WordlistOwlA",{enumerable:!0,get:function(){return p.WordlistOwlA}}),Object.defineProperty(t,"wordlists",{enumerable:!0,get:function(){return p.wordlists}})},52625:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.id=void 0;const n=r(96965),i=r(42120);t.id=function(e){return(0,n.keccak256)((0,i.toUtf8Bytes)(e))}},98336:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypedDataEncoder=t.solidityPackedSha256=t.solidityPackedKeccak256=t.solidityPacked=t.verifyMessage=t.hashMessage=t.dnsEncode=t.namehash=t.isValidName=t.ensNormalize=t.id=void 0;var n=r(52625);Object.defineProperty(t,"id",{enumerable:!0,get:function(){return n.id}});var i=r(85420);Object.defineProperty(t,"ensNormalize",{enumerable:!0,get:function(){return i.ensNormalize}}),Object.defineProperty(t,"isValidName",{enumerable:!0,get:function(){return i.isValidName}}),Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return i.namehash}}),Object.defineProperty(t,"dnsEncode",{enumerable:!0,get:function(){return i.dnsEncode}});var o=r(18043);Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return o.hashMessage}}),Object.defineProperty(t,"verifyMessage",{enumerable:!0,get:function(){return o.verifyMessage}});var a=r(18191);Object.defineProperty(t,"solidityPacked",{enumerable:!0,get:function(){return a.solidityPacked}}),Object.defineProperty(t,"solidityPackedKeccak256",{enumerable:!0,get:function(){return a.solidityPackedKeccak256}}),Object.defineProperty(t,"solidityPackedSha256",{enumerable:!0,get:function(){return a.solidityPackedSha256}});var s=r(58993);Object.defineProperty(t,"TypedDataEncoder",{enumerable:!0,get:function(){return s.TypedDataEncoder}})},18043:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.verifyMessage=t.hashMessage=void 0;const n=r(96965),i=r(30087),o=r(2290),a=r(42120);function s(e){return"string"==typeof e&&(e=(0,a.toUtf8Bytes)(e)),(0,n.keccak256)((0,a.concat)([(0,a.toUtf8Bytes)(i.MessagePrefix),(0,a.toUtf8Bytes)(String(e.length)),e]))}t.hashMessage=s,t.verifyMessage=function(e,t){const r=s(e);return(0,o.recoverAddress)(r,t)}},85420:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dnsEncode=t.namehash=t.isValidName=t.ensNormalize=void 0;const n=r(96965),i=r(42120),o=r(40030),a=new Uint8Array(32);function s(e){return(0,i.assertArgument)(0!==e.length,"invalid ENS name; empty component","comp",e),e}function u(e){const t=(0,i.toUtf8Bytes)(c(e)),r=[];if(0===e.length)return r;let n=0;for(let e=0;e{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"}},18191:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.solidityPackedSha256=t.solidityPackedKeccak256=t.solidityPacked=void 0;const n=r(45475),i=r(96965),o=r(42120),a=new RegExp("^bytes([0-9]+)$"),s=new RegExp("^(u?int)([0-9]*)$"),u=new RegExp("^(.*)\\[([0-9]*)\\]$");function c(e,t,r){switch(e){case"address":return r?(0,o.getBytes)((0,o.zeroPadValue)(t,32)):(0,o.getBytes)((0,n.getAddress)(t));case"string":return(0,o.toUtf8Bytes)(t);case"bytes":return(0,o.getBytes)(t);case"bool":return t=t?"0x01":"0x00",r?(0,o.getBytes)((0,o.zeroPadValue)(t,32)):(0,o.getBytes)(t)}let i=e.match(s);if(i){let n="int"===i[1],a=parseInt(i[2]||"256");return(0,o.assertArgument)((!i[2]||i[2]===String(a))&&a%8==0&&0!==a&&a<=256,"invalid number type","type",e),r&&(a=256),n&&(t=(0,o.toTwos)(t,a)),(0,o.getBytes)((0,o.zeroPadValue)((0,o.toBeArray)(t),a/8))}if(i=e.match(a),i){const n=parseInt(i[1]);return(0,o.assertArgument)(String(n)===i[1]&&0!==n&&n<=32,"invalid bytes type","type",e),(0,o.assertArgument)((0,o.dataLength)(t)===n,`invalid value for ${e}`,"value",t),r?(0,o.getBytes)((0,o.zeroPadBytes)(t,32)):t}if(i=e.match(u),i&&Array.isArray(t)){const r=i[1],n=parseInt(i[2]||String(t.length));(0,o.assertArgument)(n===t.length,`invalid array length for ${e}`,"value",t);const a=[];return t.forEach((function(e){a.push(c(r,e,!0))})),(0,o.getBytes)((0,o.concat)(a))}(0,o.assertArgument)(!1,"invalid type","type",e)}function l(e,t){(0,o.assertArgument)(e.length===t.length,"wrong number of values; expected ${ types.length }","values",t);const r=[];return e.forEach((function(e,n){r.push(c(e,t[n]))})),(0,o.hexlify)((0,o.concat)(r))}t.solidityPacked=l,t.solidityPackedKeccak256=function(e,t){return(0,i.keccak256)(l(e,t))},t.solidityPackedSha256=function(e,t){return(0,i.sha256)(l(e,t))}},58993:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypedDataEncoder=void 0;const n=r(45475),i=r(96965),o=r(42120),a=r(52625),s=new Uint8Array(32);s.fill(0);const u=BigInt(-1),c=BigInt(0),l=BigInt(1),f=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");const h=(0,o.toBeHex)(l,32),d=(0,o.toBeHex)(c,32),p={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},m=["name","version","chainId","verifyingContract","salt"];function y(e){return function(t){return(0,o.assertArgument)("string"==typeof t,`invalid domain value for ${JSON.stringify(e)}`,`domain.${e}`,t),t}}const g={name:y("name"),version:y("version"),chainId:function(e){return(0,o.getBigInt)(e,"domain.chainId")},verifyingContract:function(e){try{return(0,n.getAddress)(e).toLowerCase()}catch(e){}(0,o.assertArgument)(!1,'invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){const t=(0,o.getBytes)(e,"domain.salt");return(0,o.assertArgument)(32===t.length,'invalid domain value "salt"',"domain.salt",e),(0,o.hexlify)(t)}};function b(e){{const t=e.match(/^(u?)int(\d*)$/);if(t){const r=""===t[1],n=parseInt(t[2]||"256");(0,o.assertArgument)(n%8==0&&0!==n&&n<=256&&(null==t[2]||t[2]===String(n)),"invalid numeric width","type",e);const i=(0,o.mask)(f,r?n-1:n),a=r?(i+l)*u:c;return function(t){const r=(0,o.getBigInt)(t,"value");return(0,o.assertArgument)(r>=a&&r<=i,`value out-of-bounds for ${e}`,"value",r),(0,o.toBeHex)((0,o.toTwos)(r,256),32)}}}{const t=e.match(/^bytes(\d+)$/);if(t){const r=parseInt(t[1]);return(0,o.assertArgument)(0!==r&&r<=32&&t[1]===String(r),"invalid bytes width","type",e),function(t){const n=(0,o.getBytes)(t);return(0,o.assertArgument)(n.length===r,`invalid length for ${e}`,"value",t),function(e){const t=(0,o.getBytes)(e),r=t.length%32;return r?(0,o.concat)([t,s.slice(r)]):(0,o.hexlify)(t)}(t)}}}switch(e){case"address":return function(e){return(0,o.zeroPadValue)((0,n.getAddress)(e),32)};case"bool":return function(e){return e?h:d};case"bytes":return function(e){return(0,i.keccak256)(e)};case"string":return function(e){return(0,a.id)(e)}}return null}function v(e,t){return`${e}(${t.map((({name:e,type:t})=>t+" "+e)).join(",")})`}class w{primaryType;#E;get types(){return JSON.parse(this.#E)}#_;#M;constructor(e){this.#E=JSON.stringify(e),this.#_=new Map,this.#M=new Map;const t=new Map,r=new Map,n=new Map;Object.keys(e).forEach((e=>{t.set(e,new Set),r.set(e,[]),n.set(e,new Set)}));for(const n in e){const i=new Set;for(const a of e[n]){(0,o.assertArgument)(!i.has(a.name),`duplicate variable name ${JSON.stringify(a.name)} in ${JSON.stringify(n)}`,"types",e),i.add(a.name);const s=a.type.match(/^([^\x5b]*)(\x5b|$)/)[1]||null;(0,o.assertArgument)(s!==n,`circular type reference to ${JSON.stringify(s)}`,"types",e);b(s)||((0,o.assertArgument)(r.has(s),`unknown type ${JSON.stringify(s)}`,"types",e),r.get(s).push(n),t.get(n).add(s))}}const i=Array.from(r.keys()).filter((e=>0===r.get(e).length));(0,o.assertArgument)(0!==i.length,"missing primary type","types",e),(0,o.assertArgument)(1===i.length,`ambiguous primary types or unused types: ${i.map((e=>JSON.stringify(e))).join(", ")}`,"types",e),(0,o.defineProperties)(this,{primaryType:i[0]}),function i(a,s){(0,o.assertArgument)(!s.has(a),`circular type reference to ${JSON.stringify(a)}`,"types",e),s.add(a);for(const e of t.get(a))if(r.has(e)){i(e,s);for(const t of s)n.get(t).add(e)}s.delete(a)}(this.primaryType,new Set);for(const[t,r]of n){const n=Array.from(r);n.sort(),this.#_.set(t,v(t,e[t])+n.map((t=>v(t,e[t]))).join(""))}}getEncoder(e){let t=this.#M.get(e);return t||(t=this.#T(e),this.#M.set(e,t)),t}#T(e){{const t=b(e);if(t)return t}const t=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(t){const e=t[1],r=this.getEncoder(e);return n=>{(0,o.assertArgument)(!t[3]||parseInt(t[3])===n.length,`array length mismatch; expected length ${parseInt(t[3])}`,"value",n);let a=n.map(r);return this.#_.has(e)&&(a=a.map(i.keccak256)),(0,i.keccak256)((0,o.concat)(a))}}const r=this.types[e];if(r){const t=(0,a.id)(this.#_.get(e));return e=>{const n=r.map((({name:t,type:r})=>{const n=this.getEncoder(r)(e[t]);return this.#_.has(r)?(0,i.keccak256)(n):n}));return n.unshift(t),(0,o.concat)(n)}}(0,o.assertArgument)(!1,`unknown type: ${e}`,"type",e)}encodeType(e){const t=this.#_.get(e);return(0,o.assertArgument)(t,`unknown type: ${JSON.stringify(e)}`,"name",e),t}encodeData(e,t){return this.getEncoder(e)(t)}hashStruct(e,t){return(0,i.keccak256)(this.encodeData(e,t))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,t,r){if(b(e))return r(e,t);const n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n)return(0,o.assertArgument)(!n[3]||parseInt(n[3])===t.length,`array length mismatch; expected length ${parseInt(n[3])}`,"value",t),t.map((e=>this._visit(n[1],e,r)));const i=this.types[e];if(i)return i.reduce(((e,{name:n,type:i})=>(e[n]=this._visit(i,t[n],r),e)),{});(0,o.assertArgument)(!1,`unknown type: ${e}`,"type",e)}visit(e,t){return this._visit(this.primaryType,e,t)}static from(e){return new w(e)}static getPrimaryType(e){return w.from(e).primaryType}static hashStruct(e,t,r){return w.from(t).hashStruct(e,r)}static hashDomain(e){const t=[];for(const r in e){if(null==e[r])continue;const n=p[r];(0,o.assertArgument)(n,`invalid typed-data domain key: ${JSON.stringify(r)}`,"domain",e),t.push({name:r,type:n})}return t.sort(((e,t)=>m.indexOf(e.name)-m.indexOf(t.name))),w.hashStruct("EIP712Domain",{EIP712Domain:t},e)}static encode(e,t,r){return(0,o.concat)(["0x1901",w.hashDomain(e),w.from(t).hash(r)])}static hash(e,t,r){return(0,i.keccak256)(w.encode(e,t,r))}static async resolveNames(e,t,r,n){e=Object.assign({},e);for(const t in e)null==e[t]&&delete e[t];const i={};e.verifyingContract&&!(0,o.isHexString)(e.verifyingContract,20)&&(i[e.verifyingContract]="0x");const a=w.from(t);a.visit(r,((e,t)=>("address"!==e||(0,o.isHexString)(t,20)||(i[t]="0x"),t)));for(const e in i)i[e]=await n(e);return e.verifyingContract&&i[e.verifyingContract]&&(e.verifyingContract=i[e.verifyingContract]),{domain:e,value:r=a.visit(r,((e,t)=>"address"===e&&i[t]?i[t]:t))}}static getPayload(e,t,r){w.hashDomain(e);const n={},i=[];m.forEach((t=>{const r=e[t];null!=r&&(n[t]=g[t](r),i.push({name:t,type:p[t]}))}));const a=w.from(t),s=Object.assign({},t);return(0,o.assertArgument)(null==s.EIP712Domain,"types must not contain EIP712Domain type","types.EIP712Domain",t),s.EIP712Domain=i,a.encode(r),{types:s,domain:n,primaryType:a.primaryType,message:a.visit(r,((e,t)=>{if(e.match(/^bytes(\d*)/))return(0,o.hexlify)((0,o.getBytes)(t));if(e.match(/^u?int/))return(0,o.getBigInt)(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return(0,o.assertArgument)("string"==typeof t,"invalid string","value",t),t}(0,o.assertArgument)(!1,"unsupported type","type",e)}))}}}t.TypedDataEncoder=w},59237:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t},a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.ethers=void 0;const s=o(r(81097));t.ethers=s,a(r(81097),t)},55142:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractProvider=t.UnmanagedSubscriber=void 0;const n=r(45475),i=r(30087),o=r(37252),a=r(98336),s=r(2290),u=r(42120),c=r(54087),l=r(83080),f=r(54837),h=r(37143),d=r(21097),p=BigInt(2);function m(e){return e&&"function"==typeof e.then}function y(e,t){return e+":"+JSON.stringify(t,((e,t)=>{if(null==t)return"null";if("bigint"==typeof t)return`bigint:${t.toString()}`;if("string"==typeof t)return t.toLowerCase();if("object"==typeof t&&!Array.isArray(t)){const e=Object.keys(t);return e.sort(),e.reduce(((e,r)=>(e[r]=t[r],e)),{})}return t}))}class g{name;constructor(e){(0,u.defineProperties)(this,{name:e})}start(){}stop(){}pause(e){}resume(){}}function b(e){return(e=Array.from(new Set(e).values())).sort(),e}async function v(e,t){if(null==e)throw new Error("invalid event");if(Array.isArray(e)&&(e={topics:e}),"string"==typeof e)switch(e){case"block":case"pending":case"debug":case"network":return{type:e,tag:e}}if((0,u.isHexString)(e,32)){const t=e.toLowerCase();return{type:"transaction",tag:y("tx",{hash:t}),hash:t}}if(e.orphan){const t=e;return{type:"orphan",tag:y("orphan",t),filter:(r=t,JSON.parse(JSON.stringify(r)))}}var r;if(e.address||e.topics){const r=e,i={topics:(r.topics||[]).map((e=>null==e?null:Array.isArray(e)?b(e.map((e=>e.toLowerCase()))):e.toLowerCase()))};if(r.address){const e=[],o=[],a=r=>{(0,u.isHexString)(r)?e.push(r):o.push((async()=>{e.push(await(0,n.resolveAddress)(r,t))})())};Array.isArray(r.address)?r.address.forEach(a):a(r.address),o.length&&await Promise.all(o),i.address=b(e.map((e=>e.toLowerCase())))}return{filter:i,tag:y("event",i),type:"event"}}(0,u.assertArgument)(!1,"unknown ProviderEvent","event",e)}function w(){return(new Date).getTime()}t.UnmanagedSubscriber=g;function A(e,t){try{const r=S(e,t);if(r)return(0,u.toUtf8String)(r)}catch(e){}return null}function S(e,t){if("0x"===e)return null;try{const r=(0,u.getNumber)((0,u.dataSlice)(e,t,t+32)),n=(0,u.getNumber)((0,u.dataSlice)(e,r,r+32));return(0,u.dataSlice)(e,r+32,r+32+n)}catch(e){}return null}function k(e){const t=(0,u.toBeArray)(e);if(t.length>32)throw new Error("internal; should not happen");const r=new Uint8Array(32);return r.set(t,32-t.length),r}function E(e){if(e.length%32==0)return e;const t=new Uint8Array(32*Math.ceil(e.length/32));return t.set(e),t}t.AbstractProvider=class{#x;#P;#I;#O;#R;#C;#B;#N;#L;#U;constructor(e){if("any"===e)this.#R=!0,this.#O=null;else if(e){const t=f.Network.from(e);this.#R=!1,this.#O=Promise.resolve(t),setTimeout((()=>{this.emit("network",t,null)}),0)}else this.#R=!1,this.#O=null;this.#B=-1,this.#C=new Map,this.#x=new Map,this.#P=new Map,this.#I=null,this.#N=1,this.#L=new Map,this.#U=!1}get provider(){return this}get plugins(){return Array.from(this.#P.values())}attachPlugin(e){if(this.#P.get(e.name))throw new Error(`cannot replace existing plugin: ${e.name} `);return this.#P.set(e.name,e.connect(this)),this}getPlugin(e){return this.#P.get(e)||null}get disableCcipRead(){return this.#U}set disableCcipRead(e){this.#U=!!e}async#F(e){const t=y(e.method,e);let r=this.#C.get(t);return r||(r=this._perform(e),this.#C.set(t,r),setTimeout((()=>{this.#C.get(t)===r&&this.#C.delete(t)}),250)),await r}async ccipReadFetch(e,t,r){if(this.disableCcipRead||0===r.length||null==e.to)return null;const n=e.to.toLowerCase(),i=t.toLowerCase(),o=[];for(let t=0;t=500,`response not found during CCIP fetch: ${l}`,"OFFCHAIN_FAULT",{reason:"404_MISSING_RESOURCE",transaction:e,info:{url:a,errorMessage:l}}),o.push(l)}(0,u.assert)(!1,`error encountered during CCIP fetch: ${o.map((e=>JSON.stringify(e))).join(", ")}`,"OFFCHAIN_FAULT",{reason:"500_SERVER_ERROR",transaction:e,info:{urls:r,errorMessages:o}})}_wrapBlock(e,t){return new h.Block((0,l.formatBlock)(e),this)}_wrapLog(e,t){return new h.Log((0,l.formatLog)(e),this)}_wrapTransactionReceipt(e,t){return new h.TransactionReceipt((0,l.formatTransactionReceipt)(e),this)}_wrapTransactionResponse(e,t){return new h.TransactionResponse(e,this)}_detectNetwork(){(0,u.assert)(!1,"sub-classes must implement this","UNSUPPORTED_OPERATION",{operation:"_detectNetwork"})}async _perform(e){(0,u.assert)(!1,`unsupported method: ${e.method}`,"UNSUPPORTED_OPERATION",{operation:e.method,info:e})}async getBlockNumber(){const e=(0,u.getNumber)(await this.#F({method:"getBlockNumber"}),"%response");return this.#B>=0&&(this.#B=e),e}_getAddress(e){return(0,n.resolveAddress)(e,this)}_getBlockTag(e){if(null==e)return"latest";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}return(0,u.isHexString)(e)?(0,u.isHexString)(e,32)?e:(0,u.toQuantity)(e):("bigint"==typeof e&&(e=(0,u.getNumber)(e,"blockTag")),"number"==typeof e?e>=0?(0,u.toQuantity)(e):this.#B>=0?(0,u.toQuantity)(this.#B+e):this.getBlockNumber().then((t=>(0,u.toQuantity)(t+e))):void(0,u.assertArgument)(!1,"invalid blockTag","blockTag",e))}_getFilter(e){const t=(e.topics||[]).map((e=>null==e?null:Array.isArray(e)?b(e.map((e=>e.toLowerCase()))):e.toLowerCase())),r="blockHash"in e?e.blockHash:void 0,n=(e,n,i)=>{let o;switch(e.length){case 0:break;case 1:o=e[0];break;default:e.sort(),o=e}if(r&&(null!=n||null!=i))throw new Error("invalid filter");const a={};return o&&(a.address=o),t.length&&(a.topics=t),n&&(a.fromBlock=n),i&&(a.toBlock=i),r&&(a.blockHash=r),a};let i,o,a=[];if(e.address)if(Array.isArray(e.address))for(const t of e.address)a.push(this._getAddress(t));else a.push(this._getAddress(e.address));return"fromBlock"in e&&(i=this._getBlockTag(e.fromBlock)),"toBlock"in e&&(o=this._getBlockTag(e.toBlock)),a.filter((e=>"string"!=typeof e)).length||null!=i&&"string"!=typeof i||null!=o&&"string"!=typeof o?Promise.all([Promise.all(a),i,o]).then((e=>n(e[0],e[1],e[2]))):n(a,i,o)}_getTransactionRequest(e){const t=(0,h.copyRequest)(e),r=[];if(["to","from"].forEach((e=>{if(null==t[e])return;const i=(0,n.resolveAddress)(t[e]);m(i)?r.push(async function(){t[e]=await i}()):t[e]=i})),null!=t.blockTag){const e=this._getBlockTag(t.blockTag);m(e)?r.push(async function(){t.blockTag=await e}()):t.blockTag=e}return r.length?async function(){return await Promise.all(r),t}():t}async getNetwork(){if(null==this.#O){const e=this._detectNetwork().then((e=>(this.emit("network",e,null),e)),(t=>{throw this.#O===e&&(this.#O=null),t}));return this.#O=e,(await e).clone()}const e=this.#O,[t,r]=await Promise.all([e,this._detectNetwork()]);return t.chainId!==r.chainId&&(this.#R?(this.emit("network",r,t),this.#O===e&&(this.#O=Promise.resolve(r))):(0,u.assert)(!1,`network changed: ${t.chainId} => ${r.chainId} `,"NETWORK_ERROR",{event:"changed"})),t.clone()}async getFeeData(){const{block:e,gasPrice:t}=await(0,u.resolveProperties)({block:this.getBlock("latest"),gasPrice:(async()=>{try{const e=await this.#F({method:"getGasPrice"});return(0,u.getBigInt)(e,"%response")}catch(e){}return null})()});let r=null,n=null;return e&&e.baseFeePerGas&&(n=BigInt("1000000000"),r=e.baseFeePerGas*p+n),new h.FeeData(t,r,n)}async estimateGas(e){let t=this._getTransactionRequest(e);return m(t)&&(t=await t),(0,u.getBigInt)(await this.#F({method:"estimateGas",transaction:t}),"%response")}async#D(e,t,r){(0,u.assert)(r<10,"CCIP read exceeded maximum redirections","OFFCHAIN_FAULT",{reason:"TOO_MANY_REDIRECTS",transaction:Object.assign({},e,{blockTag:t,enableCcipRead:!0})});const i=(0,h.copyRequest)(e);try{return(0,u.hexlify)(await this._perform({method:"call",transaction:i,blockTag:t}))}catch(e){if(!this.disableCcipRead&&(0,u.isCallException)(e)&&e.data&&r>=0&&"latest"===t&&null!=i.to&&"0x556f1830"===(0,u.dataSlice)(e.data,0,4)){const o=e.data,a=await(0,n.resolveAddress)(i.to,this);let s;try{s=function(e){const t={sender:"",urls:[],calldata:"",selector:"",extraData:"",errorArgs:[]};(0,u.assert)((0,u.dataLength)(e)>=160,"insufficient OffchainLookup data","OFFCHAIN_FAULT",{reason:"insufficient OffchainLookup data"});const r=(0,u.dataSlice)(e,0,32);(0,u.assert)((0,u.dataSlice)(r,0,12)===(0,u.dataSlice)(T,0,12),"corrupt OffchainLookup sender","OFFCHAIN_FAULT",{reason:"corrupt OffchainLookup sender"}),t.sender=(0,u.dataSlice)(r,12);try{const r=[],n=(0,u.getNumber)((0,u.dataSlice)(e,32,64)),i=(0,u.getNumber)((0,u.dataSlice)(e,n,n+32)),o=(0,u.dataSlice)(e,n+32);for(let e=0;et[e])),t}((0,u.dataSlice)(e.data,4))}catch(e){(0,u.assert)(!1,e.message,"OFFCHAIN_FAULT",{reason:"BAD_DATA",transaction:i,info:{data:o}})}(0,u.assert)(s.sender.toLowerCase()===a.toLowerCase(),"CCIP Read sender mismatch","CALL_EXCEPTION",{action:"call",data:o,reason:"OffchainLookup",transaction:i,invocation:null,revert:{signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",name:"OffchainLookup",args:s.errorArgs}});const c=await this.ccipReadFetch(i,s.calldata,s.urls);(0,u.assert)(null!=c,"CCIP Read failed to fetch data","OFFCHAIN_FAULT",{reason:"FETCH_FAILED",transaction:i,info:{data:e.data,errorArgs:s.errorArgs}});const l={to:a,data:(0,u.concat)([s.selector,M([c,s.extraData])])};this.emit("debug",{action:"sendCcipReadCall",transaction:l});try{const e=await this.#D(l,t,r+1);return this.emit("debug",{action:"receiveCcipReadCallResult",transaction:Object.assign({},l),result:e}),e}catch(e){throw this.emit("debug",{action:"receiveCcipReadCallError",transaction:Object.assign({},l),error:e}),e}}throw e}}async#j(e){const{value:t}=await(0,u.resolveProperties)({network:this.getNetwork(),value:e});return t}async call(e){const{tx:t,blockTag:r}=await(0,u.resolveProperties)({tx:this._getTransactionRequest(e),blockTag:this._getBlockTag(e.blockTag)});return await this.#j(this.#D(t,r,e.enableCcipRead?0:-1))}async#H(e,t,r){let n=this._getAddress(t),i=this._getBlockTag(r);return"string"==typeof n&&"string"==typeof i||([n,i]=await Promise.all([n,i])),await this.#j(this.#F(Object.assign(e,{address:n,blockTag:i})))}async getBalance(e,t){return(0,u.getBigInt)(await this.#H({method:"getBalance"},e,t),"%response")}async getTransactionCount(e,t){return(0,u.getNumber)(await this.#H({method:"getTransactionCount"},e,t),"%response")}async getCode(e,t){return(0,u.hexlify)(await this.#H({method:"getCode"},e,t))}async getStorage(e,t,r){const n=(0,u.getBigInt)(t,"position");return(0,u.hexlify)(await this.#H({method:"getStorage",position:n},e,r))}async broadcastTransaction(e){const{blockNumber:t,hash:r,network:n}=await(0,u.resolveProperties)({blockNumber:this.getBlockNumber(),hash:this._perform({method:"broadcastTransaction",signedTransaction:e}),network:this.getNetwork()}),i=s.Transaction.from(e);if(i.hash!==r)throw new Error("@TODO: the returned hash did not match");return this._wrapTransactionResponse(i,n).replaceableTransaction(t)}async#J(e,t){if((0,u.isHexString)(e,32))return await this.#F({method:"getBlock",blockHash:e,includeTransactions:t});let r=this._getBlockTag(e);return"string"!=typeof r&&(r=await r),await this.#F({method:"getBlock",blockTag:r,includeTransactions:t})}async getBlock(e,t){const{network:r,params:n}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#J(e,!!t)});return null==n?null:this._wrapBlock((0,l.formatBlock)(n),r)}async getTransaction(e){const{network:t,params:r}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#F({method:"getTransaction",hash:e})});return null==r?null:this._wrapTransactionResponse((0,l.formatTransactionResponse)(r),t)}async getTransactionReceipt(e){const{network:t,params:r}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#F({method:"getTransactionReceipt",hash:e})});if(null==r)return null;if(null==r.gasPrice&&null==r.effectiveGasPrice){const t=await this.#F({method:"getTransaction",hash:e});if(null==t)throw new Error("report this; could not find tx or effectiveGasPrice");r.effectiveGasPrice=t.gasPrice}return this._wrapTransactionReceipt((0,l.formatTransactionReceipt)(r),t)}async getTransactionResult(e){const{result:t}=await(0,u.resolveProperties)({network:this.getNetwork(),result:this.#F({method:"getTransactionResult",hash:e})});return null==t?null:(0,u.hexlify)(t)}async getLogs(e){let t=this._getFilter(e);m(t)&&(t=await t);const{network:r,params:n}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#F({method:"getLogs",filter:t})});return n.map((e=>this._wrapLog((0,l.formatLog)(e),r)))}_getProvider(e){(0,u.assert)(!1,"provider cannot connect to target network","UNSUPPORTED_OPERATION",{operation:"_getProvider()"})}async getResolver(e){return await c.EnsResolver.fromName(this,e)}async getAvatar(e){const t=await this.getResolver(e);return t?await t.getAvatar():null}async resolveName(e){const t=await this.getResolver(e);return t?await t.getAddress():null}async lookupAddress(e){e=(0,n.getAddress)(e);const t=(0,a.namehash)(e.substring(2).toLowerCase()+".addr.reverse");try{const r=await c.EnsResolver.getEnsAddress(this),n=new o.Contract(r,["function resolver(bytes32) view returns (address)"],this),a=await n.resolver(t);if(null==a||a===i.ZeroHash)return null;const s=new o.Contract(a,["function name(bytes32) view returns (string)"],this),u=await s.name(t);return await this.resolveName(u)!==e?null:u}catch(e){if((0,u.isError)(e,"BAD_DATA")&&"0x"===e.value)return null;if((0,u.isError)(e,"CALL_EXCEPTION"))return null;throw e}return null}async waitForTransaction(e,t,r){const n=null!=t?t:1;return 0===n?this.getTransactionReceipt(e):new Promise((async(t,i)=>{let o=null;const a=async r=>{try{const i=await this.getTransactionReceipt(e);if(null!=i&&r-i.blockNumber+1>=n)return t(i),void(o&&(clearTimeout(o),o=null))}catch(e){console.log("EEE",e)}this.once("block",a)};null!=r&&(o=setTimeout((()=>{null!=o&&(o=null,this.off("block",a),i((0,u.makeError)("timeout","TIMEOUT",{reason:"timeout"})))}),r)),a(await this.getBlockNumber())}))}async waitForBlock(e){(0,u.assert)(!1,"not implemented yet","NOT_IMPLEMENTED",{operation:"waitForBlock"})}_clearTimeout(e){const t=this.#L.get(e);t&&(t.timer&&clearTimeout(t.timer),this.#L.delete(e))}_setTimeout(e,t){null==t&&(t=0);const r=this.#N++,n=()=>{this.#L.delete(r),e()};if(this.paused)this.#L.set(r,{timer:null,func:n,time:t});else{const e=setTimeout(n,t);this.#L.set(r,{timer:e,func:n,time:w()})}return r}_forEachSubscriber(e){for(const t of this.#x.values())e(t.subscriber)}_getSubscriber(e){switch(e.type){case"debug":case"network":return new g(e.type);case"block":return new d.PollingBlockSubscriber(this);case"event":return new d.PollingEventSubscriber(this,e.filter);case"transaction":return new d.PollingTransactionSubscriber(this,e.hash);case"orphan":return new d.PollingOrphanSubscriber(this,e.filter)}throw new Error(`unsupported event: ${e.type}`)}_recoverSubscriber(e,t){for(const r of this.#x.values())if(r.subscriber===e){r.started&&r.subscriber.stop(),r.subscriber=t,r.started&&t.start(),null!=this.#I&&t.pause(this.#I);break}}async#z(e,t){let r=await v(e,this);return"event"===r.type&&t&&t.length>0&&!0===t[0].removed&&(r=await v({orphan:"drop-log",log:t[0]},this)),this.#x.get(r.tag)||null}async#G(e){const t=await v(e,this),r=t.tag;let n=this.#x.get(r);if(!n){n={subscriber:this._getSubscriber(t),tag:r,addressableMap:new WeakMap,nameMap:new Map,started:!1,listeners:[]},this.#x.set(r,n)}return n}async on(e,t){const r=await this.#G(e);return r.listeners.push({listener:t,once:!1}),r.started||(r.subscriber.start(),r.started=!0,null!=this.#I&&r.subscriber.pause(this.#I)),this}async once(e,t){const r=await this.#G(e);return r.listeners.push({listener:t,once:!0}),r.started||(r.subscriber.start(),r.started=!0,null!=this.#I&&r.subscriber.pause(this.#I)),this}async emit(e,...t){const r=await this.#z(e,t);if(!r||0===r.listeners.length)return!1;const n=r.listeners.length;return r.listeners=r.listeners.filter((({listener:r,once:n})=>{const i=new u.EventPayload(this,n?null:r,e);try{r.call(this,...t,i)}catch(e){}return!n})),0===r.listeners.length&&(r.started&&r.subscriber.stop(),this.#x.delete(r.tag)),n>0}async listenerCount(e){if(e){const t=await this.#z(e);return t?t.listeners.length:0}let t=0;for(const{listeners:e}of this.#x.values())t+=e.length;return t}async listeners(e){if(e){const t=await this.#z(e);return t?t.listeners.map((({listener:e})=>e)):[]}let t=[];for(const{listeners:e}of this.#x.values())t=t.concat(e.map((({listener:e})=>e)));return t}async off(e,t){const r=await this.#z(e);if(!r)return this;if(t){const e=r.listeners.map((({listener:e})=>e)).indexOf(t);e>=0&&r.listeners.splice(e,1)}return t&&0!==r.listeners.length||(r.started&&r.subscriber.stop(),this.#x.delete(r.tag)),this}async removeAllListeners(e){if(e){const{tag:t,started:r,subscriber:n}=await this.#G(e);r&&n.stop(),this.#x.delete(t)}else for(const[e,{started:t,subscriber:r}]of this.#x)t&&r.stop(),this.#x.delete(e);return this}async addListener(e,t){return await this.on(e,t)}async removeListener(e,t){return this.off(e,t)}destroy(){this.removeAllListeners();for(const e of this.#L.keys())this._clearTimeout(e)}get paused(){return null!=this.#I}set paused(e){!!e!==this.paused&&(this.paused?this.resume():this.pause(!1))}pause(e){if(this.#B=-1,null!=this.#I){if(this.#I==!!e)return;(0,u.assert)(!1,"cannot change pause type; resume first","UNSUPPORTED_OPERATION",{operation:"pause"})}this._forEachSubscriber((t=>t.pause(e))),this.#I=!!e;for(const e of this.#L.values())e.timer&&clearTimeout(e.timer),e.time=w()-e.time}resume(){if(null!=this.#I){this._forEachSubscriber((e=>e.resume())),this.#I=null;for(const e of this.#L.values()){let t=e.time;t<0&&(t=0),e.time=w(),setTimeout(e.func,t)}}}};const _=new Uint8Array([]);function M(e){const t=[];let r=0;for(let n=0;n{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VoidSigner=t.AbstractSigner=void 0;const n=r(45475),i=r(2290),o=r(42120),a=r(37143);function s(e,t){if(e.provider)return e.provider;(0,o.assert)(!1,"missing provider","UNSUPPORTED_OPERATION",{operation:t})}async function u(e,t){let r=(0,a.copyRequest)(t);if(null!=r.to&&(r.to=(0,n.resolveAddress)(r.to,e)),null!=r.from){const t=r.from;r.from=Promise.all([e.getAddress(),(0,n.resolveAddress)(t,e)]).then((([e,t])=>((0,o.assertArgument)(e.toLowerCase()===t.toLowerCase(),"transaction from mismatch","tx.from",t),e)))}else r.from=e.getAddress();return await(0,o.resolveProperties)(r)}class c{provider;constructor(e){(0,o.defineProperties)(this,{provider:e||null})}async getNonce(e){return s(this,"getTransactionCount").getTransactionCount(await this.getAddress(),e)}async populateCall(e){return await u(this,e)}async populateTransaction(e){const t=s(this,"populateTransaction"),r=await u(this,e);null==r.nonce&&(r.nonce=await this.getNonce("pending")),null==r.gasLimit&&(r.gasLimit=await this.estimateGas(r));const n=await this.provider.getNetwork();if(null!=r.chainId){const t=(0,o.getBigInt)(r.chainId);(0,o.assertArgument)(t===n.chainId,"transaction chainId mismatch","tx.chainId",e.chainId)}else r.chainId=n.chainId;const i=null!=r.maxFeePerGas||null!=r.maxPriorityFeePerGas;if(null==r.gasPrice||2!==r.type&&!i?0!==r.type&&1!==r.type||!i||(0,o.assertArgument)(!1,"pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","tx",e):(0,o.assertArgument)(!1,"eip-1559 transaction do not support gasPrice","tx",e),2!==r.type&&null!=r.type||null==r.maxFeePerGas||null==r.maxPriorityFeePerGas)if(0===r.type||1===r.type){const e=await t.getFeeData();(0,o.assert)(null!=e.gasPrice,"network does not support gasPrice","UNSUPPORTED_OPERATION",{operation:"getGasPrice"}),null==r.gasPrice&&(r.gasPrice=e.gasPrice)}else{const e=await t.getFeeData();if(null==r.type)if(null!=e.maxFeePerGas&&null!=e.maxPriorityFeePerGas)if(r.type=2,null!=r.gasPrice){const e=r.gasPrice;delete r.gasPrice,r.maxFeePerGas=e,r.maxPriorityFeePerGas=e}else null==r.maxFeePerGas&&(r.maxFeePerGas=e.maxFeePerGas),null==r.maxPriorityFeePerGas&&(r.maxPriorityFeePerGas=e.maxPriorityFeePerGas);else null!=e.gasPrice?((0,o.assert)(!i,"network does not support EIP-1559","UNSUPPORTED_OPERATION",{operation:"populateTransaction"}),null==r.gasPrice&&(r.gasPrice=e.gasPrice),r.type=0):(0,o.assert)(!1,"failed to get consistent fee data","UNSUPPORTED_OPERATION",{operation:"signer.getFeeData"});else 2===r.type&&(null==r.maxFeePerGas&&(r.maxFeePerGas=e.maxFeePerGas),null==r.maxPriorityFeePerGas&&(r.maxPriorityFeePerGas=e.maxPriorityFeePerGas))}else r.type=2;return await(0,o.resolveProperties)(r)}async estimateGas(e){return s(this,"estimateGas").estimateGas(await this.populateCall(e))}async call(e){return s(this,"call").call(await this.populateCall(e))}async resolveName(e){const t=s(this,"resolveName");return await t.resolveName(e)}async sendTransaction(e){const t=s(this,"sendTransaction"),r=await this.populateTransaction(e);delete r.from;const n=i.Transaction.from(r);return await t.broadcastTransaction(await this.signTransaction(n))}}t.AbstractSigner=c;class l extends c{address;constructor(e,t){super(t),(0,o.defineProperties)(this,{address:e})}async getAddress(){return this.address}connect(e){return new l(this.address,e)}#q(e,t){(0,o.assert)(!1,`VoidSigner cannot sign ${e}`,"UNSUPPORTED_OPERATION",{operation:t})}async signTransaction(e){this.#q("transactions","signTransaction")}async signMessage(e){this.#q("messages","signMessage")}async signTypedData(e,t,r){this.#q("typed-data","signTypedData")}}t.VoidSigner=l},32813:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.showThrottleMessage=void 0;const r=new Set;t.showThrottleMessage=function(e){r.has(e)||(r.add(e),console.log("========= NOTICE ========="),console.log(`Request-Rate Exceeded for ${e} (this message will not be repeated)`),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.org/api-keys/"),console.log("=========================="))}},7994:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getDefaultProvider=void 0;const n=r(42120),i=r(16791),o=r(23815),a=r(3377),s=r(22880),u=r(35012),c=r(81333),l=r(24129),f=r(32013),h=r(62196);t.getDefaultProvider=function(e,t){if(null==t&&(t={}),"string"==typeof e&&e.match(/^https?:/))return new f.JsonRpcProvider(e);if("string"==typeof e&&e.match(/^wss?:/)||(r=e)&&"function"==typeof r.send&&"function"==typeof r.close)return new h.WebSocketProvider(e);var r;const d=[];if("-"!==t.alchemy)try{d.push(new o.AlchemyProvider(e,t.alchemy))}catch(e){console.log(e)}if("-"!==t.ankr)try{d.push(new i.AnkrProvider(e,t.ankr))}catch(e){console.log(e)}if("-"!==t.cloudflare)try{d.push(new a.CloudflareProvider(e))}catch(e){console.log(e)}if("-"!==t.etherscan)try{d.push(new s.EtherscanProvider(e,t.etherscan))}catch(e){console.log(e)}if("-"!==t.infura)try{let r,n=t.infura;"object"==typeof n&&(r=n.projectSecret,n=n.projectId),d.push(new u.InfuraProvider(e,n,r))}catch(e){console.log(e)}if("-"!==t.quicknode)try{let r=t.quicknode;d.push(new c.QuickNodeProvider(e,r))}catch(e){console.log(e)}return(0,n.assert)(d.length,"unsupported default network","UNSUPPORTED_OPERATION",{operation:"getDefaultProvider"}),1===d.length?d[0]:new l.FallbackProvider(d)}},54087:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EnsResolver=t.BasicMulticoinProviderPlugin=t.MulticoinProviderPlugin=void 0;const n=r(30087),i=r(37252),o=r(98336),a=r(42120);function s(e){return e.match(/^ipfs:\/\/ipfs\//i)?e=e.substring(12):e.match(/^ipfs:\/\//i)?e=e.substring(7):(0,a.assertArgument)(!1,"unsupported IPFS format","link",e),`https://gateway.ipfs.io/ipfs/${e}`}class u{name;constructor(e){(0,a.defineProperties)(this,{name:e})}connect(e){return this}supportsCoinType(e){return!1}async encodeAddress(e,t){throw new Error("unsupported coin")}async decodeAddress(e,t){throw new Error("unsupported coin")}}t.MulticoinProviderPlugin=u;t.BasicMulticoinProviderPlugin=class extends u{constructor(){super("org.ethers.plugins.provider.BasicMulticoin")}};const c=new RegExp("^(ipfs)://(.*)$","i"),l=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),c,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];class f{provider;address;name;#K;#V;constructor(e,t,r){(0,a.defineProperties)(this,{provider:e,address:t,name:r}),this.#K=null,this.#V=new i.Contract(t,["function supportsInterface(bytes4) view returns (bool)","function resolve(bytes, bytes) view returns (bytes)","function addr(bytes32) view returns (address)","function addr(bytes32, uint) view returns (address)","function text(bytes32, string) view returns (string)","function contenthash(bytes32) view returns (bytes)"],e)}async supportsWildcard(){return null==this.#K&&(this.#K=(async()=>{try{return await this.#V.supportsInterface("0x9061b923")}catch(e){if((0,a.isError)(e,"CALL_EXCEPTION"))return!1;throw this.#K=null,e}})()),await this.#K}async#X(e,t){t=(t||[]).slice();const r=this.#V.interface;t.unshift((0,o.namehash)(this.name));let n=null;await this.supportsWildcard()&&(n=r.getFunction(e),(0,a.assert)(n,"missing fragment","UNKNOWN_ERROR",{info:{funcName:e}}),t=[(0,o.dnsEncode)(this.name),r.encodeFunctionData(n,t)],e="resolve(bytes,bytes)"),t.push({ccipReadEnable:!0});try{const i=await this.#V[e](...t);return n?r.decodeFunctionResult(n,i)[0]:i}catch(e){if(!(0,a.isError)(e,"CALL_EXCEPTION"))throw e}return null}async getAddress(e){if(null==e&&(e=60),60===e)try{const e=await this.#X("addr(bytes32)");return null==e||e===n.ZeroAddress?null:e}catch(e){if((0,a.isError)(e,"CALL_EXCEPTION"))return null;throw e}let t=null;for(const r of this.provider.plugins)if(r instanceof u&&r.supportsCoinType(e)){t=r;break}if(null==t)return null;const r=await this.#X("addr(bytes32,uint)",[e]);if(null==r||"0x"===r)return null;const i=await t.encodeAddress(e,r);if(null!=i)return i;(0,a.assert)(!1,"invalid coin data","UNSUPPORTED_OPERATION",{operation:`getAddress(${e})`,info:{coinType:e,data:r}})}async getText(e){const t=await this.#X("text(bytes32,string)",[e]);return null==t||"0x"===t?null:t}async getContentHash(){const e=await this.#X("contenthash(bytes32)");if(null==e||"0x"===e)return null;const t=e.match(/^0x(e3010170|e5010172)(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(t){const e="e3010170"===t[1]?"ipfs":"ipns",r=parseInt(t[4],16);if(t[5].length===2*r)return`${e}://${(0,a.encodeBase58)("0x"+t[2])}`}const r=e.match(/^0xe40101fa011b20([0-9a-f]*)$/);if(r&&64===r[1].length)return`bzz://${r[1]}`;(0,a.assert)(!1,"invalid or unsupported content hash data","UNSUPPORTED_OPERATION",{operation:"getContentHash()",info:{data:e}})}async getAvatar(){return(await this._getAvatar()).url}async _getAvatar(){const e=[{type:"name",value:this.name}];try{const t=await this.getText("avatar");if(null==t)return e.push({type:"!avatar",value:""}),{url:null,linkage:e};e.push({type:"avatar",value:t});for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatTransactionResponse=t.formatTransactionReceipt=t.formatReceiptLog=t.formatBlock=t.formatLog=t.formatUint256=t.formatHash=t.formatData=t.formatBoolean=t.object=t.arrayOf=t.allowNull=void 0;const n=r(45475),i=r(96965),o=r(2290),a=r(42120),s=BigInt(0);function u(e,t){return function(r){return null==r?t:e(r)}}function c(e){return t=>{if(!Array.isArray(t))throw new Error("not an array");return t.map((t=>e(t)))}}function l(e,t){return r=>{const n={};for(const i in e){let o=i;if(t&&i in t&&!(o in r))for(const e of t[i])if(e in r){o=e;break}try{const t=e[i](r[o]);void 0!==t&&(n[i]=t)}catch(e){const t=e instanceof Error?e.message:"not-an-error";(0,a.assert)(!1,`invalid value for value.${i} (${t})`,"BAD_DATA",{value:r})}}return n}}function f(e){switch(e){case!0:case"true":return!0;case!1:case"false":return!1}(0,a.assertArgument)(!1,`invalid boolean; ${JSON.stringify(e)}`,"value",e)}function h(e){return(0,a.assertArgument)((0,a.isHexString)(e,!0),"invalid data","value",e),e}function d(e){return(0,a.assertArgument)((0,a.isHexString)(e,32),"invalid hash","value",e),e}t.allowNull=u,t.arrayOf=c,t.object=l,t.formatBoolean=f,t.formatData=h,t.formatHash=d,t.formatUint256=function(e){if(!(0,a.isHexString)(e))throw new Error("invalid uint256");return(0,a.zeroPadValue)(e,32)};const p=l({address:n.getAddress,blockHash:d,blockNumber:a.getNumber,data:h,index:a.getNumber,removed:f,topics:c(d),transactionHash:d,transactionIndex:a.getNumber},{index:["logIndex"]});t.formatLog=function(e){return p(e)};const m=l({hash:u(d),parentHash:d,number:a.getNumber,timestamp:a.getNumber,nonce:u(h),difficulty:a.getBigInt,gasLimit:a.getBigInt,gasUsed:a.getBigInt,miner:u(n.getAddress),extraData:h,baseFeePerGas:u(a.getBigInt)});t.formatBlock=function(e){const t=m(e);return t.transactions=e.transactions.map((e=>"string"==typeof e?e:v(e))),t};const y=l({transactionIndex:a.getNumber,blockNumber:a.getNumber,transactionHash:d,address:n.getAddress,topics:c(d),data:h,index:a.getNumber,blockHash:d},{index:["logIndex"]});function g(e){return y(e)}t.formatReceiptLog=g;const b=l({to:u(n.getAddress,null),from:u(n.getAddress,null),contractAddress:u(n.getAddress,null),index:a.getNumber,root:u(a.hexlify),gasUsed:a.getBigInt,logsBloom:u(h),blockHash:d,hash:d,logs:c(g),blockNumber:a.getNumber,cumulativeGasUsed:a.getBigInt,effectiveGasPrice:u(a.getBigInt),status:u(a.getNumber),type:u(a.getNumber,0)},{effectiveGasPrice:["gasPrice"],hash:["transactionHash"],index:["transactionIndex"]});function v(e){e.to&&(0,a.getBigInt)(e.to)===s&&(e.to="0x0000000000000000000000000000000000000000");const t=l({hash:d,type:e=>"0x"===e||null==e?0:(0,a.getNumber)(e),accessList:u(o.accessListify,null),blockHash:u(d,null),blockNumber:u(a.getNumber,null),transactionIndex:u(a.getNumber,null),from:n.getAddress,gasPrice:u(a.getBigInt),maxPriorityFeePerGas:u(a.getBigInt),maxFeePerGas:u(a.getBigInt),gasLimit:a.getBigInt,to:u(n.getAddress,null),value:a.getBigInt,nonce:a.getNumber,data:h,creates:u(n.getAddress,null),chainId:u(a.getBigInt,null)},{data:["input"],gasLimit:["gas"]})(e);if(null==t.to&&null==t.creates&&(t.creates=(0,n.getCreateAddress)(t)),1!==e.type&&2!==e.type||null!=e.accessList||(t.accessList=[]),e.signature?t.signature=i.Signature.from(e.signature):t.signature=i.Signature.from(e),null==t.chainId){const e=t.signature.legacyChainId;null!=e&&(t.chainId=e)}return t.blockHash&&(0,a.getBigInt)(t.blockHash)===s&&(t.blockHash=null),t}t.formatTransactionReceipt=function(e){return b(e)},t.formatTransactionResponse=v},4878:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SocketEventSubscriber=t.SocketPendingSubscriber=t.SocketBlockSubscriber=t.SocketSubscriber=t.WebSocketProvider=t.SocketProvider=t.IpcSocketProvider=t.QuickNodeProvider=t.PocketProvider=t.InfuraWebSocketProvider=t.InfuraProvider=t.EtherscanPlugin=t.EtherscanProvider=t.CloudflareProvider=t.AnkrProvider=t.AlchemyProvider=t.BrowserProvider=t.JsonRpcSigner=t.JsonRpcProvider=t.JsonRpcApiProvider=t.FallbackProvider=t.copyRequest=t.TransactionResponse=t.TransactionReceipt=t.Log=t.FeeData=t.Block=t.FeeDataNetworkPlugin=t.EnsPlugin=t.GasCostPlugin=t.NetworkPlugin=t.NonceManager=t.Network=t.EnsResolver=t.getDefaultProvider=t.showThrottleMessage=t.VoidSigner=t.AbstractSigner=t.UnmanagedSubscriber=t.AbstractProvider=void 0;var n=r(55142);Object.defineProperty(t,"AbstractProvider",{enumerable:!0,get:function(){return n.AbstractProvider}}),Object.defineProperty(t,"UnmanagedSubscriber",{enumerable:!0,get:function(){return n.UnmanagedSubscriber}});var i=r(35649);Object.defineProperty(t,"AbstractSigner",{enumerable:!0,get:function(){return i.AbstractSigner}}),Object.defineProperty(t,"VoidSigner",{enumerable:!0,get:function(){return i.VoidSigner}});var o=r(32813);Object.defineProperty(t,"showThrottleMessage",{enumerable:!0,get:function(){return o.showThrottleMessage}});var a=r(7994);Object.defineProperty(t,"getDefaultProvider",{enumerable:!0,get:function(){return a.getDefaultProvider}});var s=r(54087);Object.defineProperty(t,"EnsResolver",{enumerable:!0,get:function(){return s.EnsResolver}});var u=r(54837);Object.defineProperty(t,"Network",{enumerable:!0,get:function(){return u.Network}});var c=r(22992);Object.defineProperty(t,"NonceManager",{enumerable:!0,get:function(){return c.NonceManager}});var l=r(67004);Object.defineProperty(t,"NetworkPlugin",{enumerable:!0,get:function(){return l.NetworkPlugin}}),Object.defineProperty(t,"GasCostPlugin",{enumerable:!0,get:function(){return l.GasCostPlugin}}),Object.defineProperty(t,"EnsPlugin",{enumerable:!0,get:function(){return l.EnsPlugin}}),Object.defineProperty(t,"FeeDataNetworkPlugin",{enumerable:!0,get:function(){return l.FeeDataNetworkPlugin}});var f=r(37143);Object.defineProperty(t,"Block",{enumerable:!0,get:function(){return f.Block}}),Object.defineProperty(t,"FeeData",{enumerable:!0,get:function(){return f.FeeData}}),Object.defineProperty(t,"Log",{enumerable:!0,get:function(){return f.Log}}),Object.defineProperty(t,"TransactionReceipt",{enumerable:!0,get:function(){return f.TransactionReceipt}}),Object.defineProperty(t,"TransactionResponse",{enumerable:!0,get:function(){return f.TransactionResponse}}),Object.defineProperty(t,"copyRequest",{enumerable:!0,get:function(){return f.copyRequest}});var h=r(24129);Object.defineProperty(t,"FallbackProvider",{enumerable:!0,get:function(){return h.FallbackProvider}});var d=r(32013);Object.defineProperty(t,"JsonRpcApiProvider",{enumerable:!0,get:function(){return d.JsonRpcApiProvider}}),Object.defineProperty(t,"JsonRpcProvider",{enumerable:!0,get:function(){return d.JsonRpcProvider}}),Object.defineProperty(t,"JsonRpcSigner",{enumerable:!0,get:function(){return d.JsonRpcSigner}});var p=r(30292);Object.defineProperty(t,"BrowserProvider",{enumerable:!0,get:function(){return p.BrowserProvider}});var m=r(23815);Object.defineProperty(t,"AlchemyProvider",{enumerable:!0,get:function(){return m.AlchemyProvider}});var y=r(16791);Object.defineProperty(t,"AnkrProvider",{enumerable:!0,get:function(){return y.AnkrProvider}});var g=r(3377);Object.defineProperty(t,"CloudflareProvider",{enumerable:!0,get:function(){return g.CloudflareProvider}});var b=r(22880);Object.defineProperty(t,"EtherscanProvider",{enumerable:!0,get:function(){return b.EtherscanProvider}}),Object.defineProperty(t,"EtherscanPlugin",{enumerable:!0,get:function(){return b.EtherscanPlugin}});var v=r(35012);Object.defineProperty(t,"InfuraProvider",{enumerable:!0,get:function(){return v.InfuraProvider}}),Object.defineProperty(t,"InfuraWebSocketProvider",{enumerable:!0,get:function(){return v.InfuraWebSocketProvider}});var w=r(52751);Object.defineProperty(t,"PocketProvider",{enumerable:!0,get:function(){return w.PocketProvider}});var A=r(81333);Object.defineProperty(t,"QuickNodeProvider",{enumerable:!0,get:function(){return A.QuickNodeProvider}});const S=r(74019);Object.defineProperty(t,"IpcSocketProvider",{enumerable:!0,get:function(){return S.IpcSocketProvider}});var k=r(12394);Object.defineProperty(t,"SocketProvider",{enumerable:!0,get:function(){return k.SocketProvider}});var E=r(62196);Object.defineProperty(t,"WebSocketProvider",{enumerable:!0,get:function(){return E.WebSocketProvider}});var _=r(12394);Object.defineProperty(t,"SocketSubscriber",{enumerable:!0,get:function(){return _.SocketSubscriber}}),Object.defineProperty(t,"SocketBlockSubscriber",{enumerable:!0,get:function(){return _.SocketBlockSubscriber}}),Object.defineProperty(t,"SocketPendingSubscriber",{enumerable:!0,get:function(){return _.SocketPendingSubscriber}}),Object.defineProperty(t,"SocketEventSubscriber",{enumerable:!0,get:function(){return _.SocketEventSubscriber}})},54837:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Network=void 0;const n=r(2290),i=r(42120),o=r(67004),a=new Map;class s{#W;#Z;#P;constructor(e,t){this.#W=e,this.#Z=(0,i.getBigInt)(t),this.#P=new Map}toJSON(){return{name:this.name,chainId:this.chainId}}get name(){return this.#W}set name(e){this.#W=e}get chainId(){return this.#Z}set chainId(e){this.#Z=(0,i.getBigInt)(e,"chainId")}get plugins(){return Array.from(this.#P.values())}attachPlugin(e){if(this.#P.get(e.name))throw new Error(`cannot replace existing plugin: ${e.name} `);return this.#P.set(e.name,e.clone()),this}getPlugin(e){return this.#P.get(e)||null}getPlugins(e){return this.plugins.filter((t=>t.name.split("#")[0]===e))}clone(){const e=new s(this.name,this.chainId);return this.plugins.forEach((t=>{e.attachPlugin(t.clone())})),e}computeIntrinsicGas(e){const t=this.getPlugin("org.ethers.plugins.network.GasCost")||new o.GasCostPlugin;let r=t.txBase;if(null==e.to&&(r+=t.txCreate),e.data)for(let n=2;n{s.register(e,n)}))}u=!0,e("mainnet",1,{ensNetwork:1,altNames:["homestead"]}),e("ropsten",3,{ensNetwork:3}),e("rinkeby",4,{ensNetwork:4}),e("goerli",5,{ensNetwork:5}),e("kovan",42,{ensNetwork:42}),e("sepolia",11155111,{}),e("classic",61,{}),e("classicKotti",6,{}),e("xdai",100,{ensNetwork:1}),e("optimism",10,{ensNetwork:1,etherscan:{url:"https://api-optimistic.etherscan.io/"}}),e("optimism-goerli",420,{etherscan:{url:"https://api-goerli-optimistic.etherscan.io/"}}),e("arbitrum",42161,{ensNetwork:1,etherscan:{url:"https://api.arbiscan.io/"}}),e("arbitrum-goerli",421613,{etherscan:{url:"https://api-goerli.arbiscan.io/"}}),e("matic",137,{ensNetwork:1,etherscan:{url:"https://api.polygonscan.com/"}}),e("matic-mumbai",80001,{altNames:["maticMumbai","maticmum"],etherscan:{url:"https://api-testnet.polygonscan.com/"}}),e("bnb",56,{ensNetwork:1,etherscan:{url:"http://api.bscscan.com"}}),e("bnbt",97,{etherscan:{url:"http://api-testnet.bscscan.com"}})}(),null==e)return s.from("mainnet");if("number"==typeof e&&(e=BigInt(e)),"string"==typeof e||"bigint"==typeof e){const t=a.get(e);if(t)return t();if("bigint"==typeof e)return new s("unknown",e);(0,i.assertArgument)(!1,"unknown network","network",e)}if("function"==typeof e.clone){return e.clone()}if("object"==typeof e){(0,i.assertArgument)("string"==typeof e.name&&"number"==typeof e.chainId,"invalid network object name or chainId","network",e);const t=new s(e.name,e.chainId);return(e.ensAddress||null!=e.ensNetwork)&&t.attachPlugin(new o.EnsPlugin(e.ensAddress,e.ensNetwork)),t}(0,i.assertArgument)(!1,"invalid network","network",e)}static register(e,t){"number"==typeof e&&(e=BigInt(e));const r=a.get(e);r&&(0,i.assertArgument)(!1,`conflicting network for ${JSON.stringify(r.name)}`,"nameOrChainId",e),a.set(e,t)}}t.Network=s;let u=!1},67004:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FeeDataNetworkPlugin=t.EnsPlugin=t.GasCostPlugin=t.NetworkPlugin=void 0;const n=r(39290),i=r(42120);class o{name;constructor(e){(0,n.defineProperties)(this,{name:e})}clone(){return new o(this.name)}}t.NetworkPlugin=o;class a extends o{effectiveBlock;txBase;txCreate;txDataZero;txDataNonzero;txAccessListStorageKey;txAccessListAddress;constructor(e,t){null==e&&(e=0),super(`org.ethers.network.plugins.GasCost#${e||0}`);const r={effectiveBlock:e};function o(e,n){let o=(t||{})[e];null==o&&(o=n),(0,i.assertArgument)("number"==typeof o,`invalud value for ${e}`,"costs",t),r[e]=o}o("txBase",21e3),o("txCreate",32e3),o("txDataZero",4),o("txDataNonzero",16),o("txAccessListStorageKey",1900),o("txAccessListAddress",2400),(0,n.defineProperties)(this,r)}clone(){return new a(this.effectiveBlock,this)}}t.GasCostPlugin=a;class s extends o{address;targetNetwork;constructor(e,t){super("org.ethers.plugins.network.Ens"),(0,n.defineProperties)(this,{address:e||"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",targetNetwork:null==t?1:t})}clone(){return new s(this.address,this.targetNetwork)}}t.EnsPlugin=s;class u extends o{#Y;get feeDataFunc(){return this.#Y}constructor(e){super("org.ethers.plugins.network.FeeData"),this.#Y=e}async getFeeData(e){return await this.#Y(e)}clone(){return new u(this.#Y)}}t.FeeDataNetworkPlugin=u},23815:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AlchemyProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC";class u extends a.JsonRpcProvider{apiKey;constructor(e,t){null==e&&(e="mainnet");const r=o.Network.from(e);null==t&&(t=s);super(u.getRequest(r,t),r,{staticNetwork:r}),(0,n.defineProperties)(this,{apiKey:t})}_getProvider(e){try{return new u(e,this.apiKey)}catch(e){}return super._getProvider(e)}async _perform(e){if("getTransactionResult"===e.method){const{trace:t,tx:r}=await(0,n.resolveProperties)({trace:this.send("trace_transaction",[e.hash]),tx:this.getTransaction(e.hash)});if(null==t||null==r)return null;let i,o=!1;try{i=t[0].result.output,o="Reverted"===t[0].error}catch(e){}if(i)return(0,n.assert)(!o,"an error occurred during transaction executions","CALL_EXCEPTION",{action:"getTransactionResult",data:i,reason:null,transaction:r,invocation:null,revert:null}),i;(0,n.assert)(!1,"could not parse trace result","BAD_DATA",{value:t})}return await super._perform(e)}isCommunityResource(){return this.apiKey===s}static getRequest(e,t){null==t&&(t=s);const r=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"eth-mainnet.alchemyapi.io";case"goerli":return"eth-goerli.g.alchemy.com";case"sepolia":return"eth-sepolia.g.alchemy.com";case"arbitrum":return"arb-mainnet.g.alchemy.com";case"arbitrum-goerli":return"arb-goerli.g.alchemy.com";case"matic":return"polygon-mainnet.g.alchemy.com";case"matic-mumbai":return"polygon-mumbai.g.alchemy.com";case"optimism":return"opt-mainnet.g.alchemy.com";case"optimism-goerli":return"opt-goerli.g.alchemy.com"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/v2/${t}`);return r.allowGzip=!0,t===s&&(r.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("alchemy"),!0)),r}}t.AlchemyProvider=u},16791:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AnkrProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";class u extends a.JsonRpcProvider{apiKey;constructor(e,t){null==e&&(e="mainnet");const r=o.Network.from(e);null==t&&(t=s);const i={polling:!0,staticNetwork:r};super(u.getRequest(r,t),r,i),(0,n.defineProperties)(this,{apiKey:t})}_getProvider(e){try{return new u(e,this.apiKey)}catch(e){}return super._getProvider(e)}static getRequest(e,t){null==t&&(t=s);const r=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"rpc.ankr.com/eth";case"goerli":return"rpc.ankr.com/eth_goerli";case"matic":return"rpc.ankr.com/polygon";case"arbitrum":return"rpc.ankr.com/arbitrum"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/${t}`);return r.allowGzip=!0,t===s&&(r.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("AnkrProvider"),!0)),r}getRpcError(e,t){return"eth_sendRawTransaction"===e.method&&t&&t.error&&"INTERNAL_ERROR: could not replace existing tx"===t.error.message&&(t.error.message="replacement transaction underpriced"),super.getRpcError(e,t)}isCommunityResource(){return this.apiKey===s}}t.AnkrProvider=u},30292:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BrowserProvider=void 0;const n=r(42120),i=r(32013);class o extends i.JsonRpcApiPollingProvider{#$;constructor(e,t){super(t,{batchMaxCount:1}),this.#$=async(t,r)=>{const n={method:t,params:r};this.emit("debug",{action:"sendEip1193Request",payload:n});try{const t=await e.request(n);return this.emit("debug",{action:"receiveEip1193Result",result:t}),t}catch(e){const t=new Error(e.message);throw t.code=e.code,t.data=e.data,t.payload=n,this.emit("debug",{action:"receiveEip1193Error",error:t}),t}}}async send(e,t){return await this._start(),await super.send(e,t)}async _send(e){(0,n.assertArgument)(!Array.isArray(e),"EIP-1193 does not support batch request","payload",e);try{const t=await this.#$(e.method,e.params||[]);return[{id:e.id,result:t}]}catch(t){return[{id:e.id,error:{code:t.code,data:t.data,message:t.message}}]}}getRpcError(e,t){switch((t=JSON.parse(JSON.stringify(t))).error.code||-1){case 4001:t.error.message=`ethers-user-denied: ${t.error.message}`;break;case 4200:t.error.message=`ethers-unsupported: ${t.error.message}`}return super.getRpcError(e,t)}async hasSigner(e){null==e&&(e=0);const t=await this.send("eth_accounts",[]);return"number"==typeof e?t.length>e:(e=e.toLowerCase(),0!==t.filter((t=>t.toLowerCase()===e)).length)}async getSigner(e){if(null==e&&(e=0),!await this.hasSigner(e))try{await this.#$("eth_requestAccounts",[])}catch(e){const t=e.payload;throw this.getRpcError(t,{id:t.id,error:e})}return await super.getSigner(e)}}t.BrowserProvider=o},3377:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CloudflareProvider=void 0;const n=r(42120),i=r(54837),o=r(32013);class a extends o.JsonRpcProvider{constructor(e){null==e&&(e="mainnet");const t=i.Network.from(e);(0,n.assertArgument)("mainnet"===t.name,"unsupported network","network",e),super("https://cloudflare-eth.com/",t,{staticNetwork:t})}}t.CloudflareProvider=a},22880:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EtherscanProvider=t.EtherscanPlugin=void 0;const n=r(93707),i=r(37252),o=r(2290),a=r(42120),s=r(55142),u=r(54837),c=r(67004),l=r(32813);const f="org.ethers.plugins.provider.Etherscan";class h extends c.NetworkPlugin{baseUrl;constructor(e){super(f),(0,a.defineProperties)(this,{baseUrl:e})}clone(){return new h(this.baseUrl)}}t.EtherscanPlugin=h;let d=1;class p extends s.AbstractProvider{network;apiKey;#ee;constructor(e,t){const r=null!=t?t:null;super();const n=u.Network.from(e);this.#ee=n.getPlugin(f),(0,a.defineProperties)(this,{apiKey:r,network:n}),this.getBaseUrl()}getBaseUrl(){if(this.#ee)return this.#ee.baseUrl;switch(this.network.name){case"mainnet":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"matic":return"https://api.polygonscan.com";case"matic-mumbai":return"https://api-testnet.polygonscan.com";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io"}(0,a.assertArgument)(!1,"unsupported network","network",this.network)}getUrl(e,t){const r=Object.keys(t).reduce(((e,r)=>{const n=t[r];return null!=n&&(e+=`&${r}=${n}`),e}),""),n=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.getBaseUrl()}/api?module=${e}${r}${n}`}getPostUrl(){return`${this.getBaseUrl()}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}async detectNetwork(){return this.network}async fetch(e,t,r){const n=d++,i=r?this.getPostUrl():this.getUrl(e,t),o=r?this.getPostData(e,t):null;this.emit("debug",{action:"sendRequest",id:n,url:i,payload:o});const s=new a.FetchRequest(i);s.setThrottleParams({slotInterval:1e3}),s.retryFunc=(e,t,r)=>(this.isCommunityResource()&&(0,l.showThrottleMessage)("Etherscan"),Promise.resolve(!0)),s.processFunc=async(t,r)=>{const i=r.hasBody()?JSON.parse((0,a.toUtf8String)(r.body)):{},o=("string"==typeof i.result?i.result:"").toLowerCase().indexOf("rate limit")>=0;return"proxy"===e?i&&0==i.status&&"NOTOK"==i.message&&o&&(this.emit("debug",{action:"receiveError",id:n,reason:"proxy-NOTOK",error:i}),r.throwThrottleError(i.result,2e3)):o&&(this.emit("debug",{action:"receiveError",id:n,reason:"null result",error:i.result}),r.throwThrottleError(i.result,2e3)),r},o&&(s.setHeader("content-type","application/x-www-form-urlencoded; charset=UTF-8"),s.body=Object.keys(o).map((e=>`${e}=${o[e]}`)).join("&"));const u=await s.send();try{u.assertOk()}catch(e){this.emit("debug",{action:"receiveError",id:n,error:e,reason:"assertOk"}),(0,a.assert)(!1,"response error","SERVER_ERROR",{request:s,response:u})}u.hasBody()||(this.emit("debug",{action:"receiveError",id:n,error:"missing body",reason:"null body"}),(0,a.assert)(!1,"missing response","SERVER_ERROR",{request:s,response:u}));const c=JSON.parse((0,a.toUtf8String)(u.body));return"proxy"===e?("2.0"!=c.jsonrpc&&(this.emit("debug",{action:"receiveError",id:n,result:c,reason:"invalid JSON-RPC"}),(0,a.assert)(!1,"invalid JSON-RPC response (missing jsonrpc='2.0')","SERVER_ERROR",{request:s,response:u,info:{result:c}})),c.error&&(this.emit("debug",{action:"receiveError",id:n,result:c,reason:"JSON-RPC error"}),(0,a.assert)(!1,"error response","SERVER_ERROR",{request:s,response:u,info:{result:c}})),this.emit("debug",{action:"receiveRequest",id:n,result:c}),c.result):0!=c.status||"No records found"!==c.message&&"No transactions found"!==c.message?((1!=c.status||"string"==typeof c.message&&!c.message.match(/^OK/))&&(this.emit("debug",{action:"receiveError",id:n,result:c}),(0,a.assert)(!1,"error response","SERVER_ERROR",{request:s,response:u,info:{result:c}})),this.emit("debug",{action:"receiveRequest",id:n,result:c}),c.result):(this.emit("debug",{action:"receiveRequest",id:n,result:c}),c.result)}_getTransactionPostData(e){const t={};for(let r in e){if(null==e[r])continue;let n=e[r];"type"===r&&0===n||(n={type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[r]?(0,a.toQuantity)(n):"accessList"===r?"["+(0,o.accessListify)(n).map((e=>`{address:"${e.address}",storageKeys:["${e.storageKeys.join('","')}"]}`)).join(",")+"]":(0,a.hexlify)(n),t[r]=n)}return t}_checkError(e,t,r){let i="";if((0,a.isError)(t,"SERVER_ERROR")){try{i=t.info.result.error.message}catch(e){}if(!i)try{i=t.info.message}catch(e){}}if("estimateGas"===e.method&&!i.match(/revert/i)&&i.match(/insufficient funds/i)&&(0,a.assert)(!1,"insufficient funds","INSUFFICIENT_FUNDS",{transaction:e.transaction}),("call"===e.method||"estimateGas"===e.method)&&i.match(/execution reverted/i)){let r="";try{r=t.info.result.error.data}catch(t){}const i=n.AbiCoder.getBuiltinCallException(e.method,e.transaction,r);throw i.info={request:e,error:t},i}if(i&&"broadcastTransaction"===e.method){const t=o.Transaction.from(e.signedTransaction);i.match(/replacement/i)&&i.match(/underpriced/i)&&(0,a.assert)(!1,"replacement fee too low","REPLACEMENT_UNDERPRICED",{transaction:t}),i.match(/insufficient funds/)&&(0,a.assert)(!1,"insufficient funds for intrinsic transaction cost","INSUFFICIENT_FUNDS",{transaction:t}),i.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&(0,a.assert)(!1,"nonce has already been used","NONCE_EXPIRED",{transaction:t})}throw t}async _detectNetwork(){return this.network}async _perform(e){switch(e.method){case"chainId":return this.network.chainId;case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:e.address,tag:e.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:e.address,tag:e.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:e.address,tag:e.blockTag});case"getStorage":return this.fetch("proxy",{action:"eth_getStorageAt",address:e.address,position:e.position,tag:e.blockTag});case"broadcastTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:e.signedTransaction},!0).catch((t=>this._checkError(e,t,e.signedTransaction)));case"getBlock":if("blockTag"in e)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:e.blockTag,boolean:e.includeTransactions?"true":"false"});(0,a.assert)(!1,"getBlock by blockHash not supported by Etherscan","UNSUPPORTED_OPERATION",{operation:"getBlock(blockHash)"});case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:e.hash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:e.hash});case"call":{if("latest"!==e.blockTag)throw new Error("EtherscanProvider does not support blockTag for call");const t=this._getTransactionPostData(e.transaction);t.module="proxy",t.action="eth_call";try{return await this.fetch("proxy",t,!0)}catch(t){return this._checkError(e,t,e.transaction)}}case"estimateGas":{const t=this._getTransactionPostData(e.transaction);t.module="proxy",t.action="eth_estimateGas";try{return await this.fetch("proxy",t,!0)}catch(t){return this._checkError(e,t,e.transaction)}}}return super._perform(e)}async getNetwork(){return this.network}async getEtherPrice(){return"mainnet"!==this.network.name?0:parseFloat((await this.fetch("stats",{action:"ethprice"})).ethusd)}async getContract(e){let t=this._getAddress(e);var r;(r=t)&&"function"==typeof r.then&&(t=await t);try{const e=await this.fetch("contract",{action:"getabi",address:t}),r=JSON.parse(e);return new i.Contract(t,r,this)}catch(e){return null}}isCommunityResource(){return null==this.apiKey}}t.EtherscanProvider=p},24129:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FallbackProvider=void 0;const n=r(42120),i=r(55142),o=r(54837),a=BigInt("1"),s=BigInt("2");function u(){return(new Date).getTime()}function c(e){return JSON.stringify(e,((e,t)=>"bigint"==typeof t?{type:"bigint",value:t.toString()}:t))}const l={stallTimeout:400,priority:1,weight:1},f={blockNumber:-2,requests:0,lateResponses:0,errorResponses:0,outOfSync:-1,unsupportedEvents:0,rollingDuration:0,score:0,_network:null,_updateNumber:null,_totalTime:0};function h(e){if(null==e)return"null";if(Array.isArray(e))return"["+e.map(h).join(",")+"]";if("object"==typeof e&&"function"==typeof e.toJSON)return h(e.toJSON());switch(typeof e){case"boolean":case"symbol":return e.toString();case"bigint":case"number":return BigInt(e).toString();case"string":return JSON.stringify(e);case"object":{const t=Object.keys(e);return t.sort(),"{"+t.map((t=>`${JSON.stringify(t)}:${h(e[t])}`)).join(",")+"}"}}throw console.log("Could not serialize",e),new Error("Hmm...")}function d(e){if("error"in e){const t=e.error;return{tag:h(t),value:t}}const t=e.result;return{tag:h(t),value:t}}function p(e,t){const r=new Map;for(const{value:e,tag:n,weight:i}of t){const t=r.get(n)||{value:e,weight:0};t.weight+=i,r.set(n,t)}let n=null;for(const t of r.values())t.weight>=e&&(!n||t.weight>n.weight)&&(n=t);if(n)return n.value}function m(e,t){let r=0;const n=new Map;let i=null;const o=[];for(const{value:e,tag:a,weight:s}of t)if(e instanceof Error){const t=n.get(a)||{value:e,weight:0};t.weight+=s,n.set(a,t),(null==i||t.weight>i.weight)&&(i=t)}else o.push(BigInt(e)),r+=s;if(r=e?i.value:void 0;o.sort(((e,t)=>ee?1:0));const u=Math.floor(o.length/2);return o.length%2?o[u]:(o[u-1]+o[u]+a)/s}function y(e,t){const r=p(e,t);if(void 0!==r)return r;for(const e of t)if(e.value)return e.value}class g extends i.AbstractProvider{quorum;eventQuorum;eventWorkers;#te;#re;#ne;constructor(e,t){super(t),this.#te=e.map((e=>e instanceof i.AbstractProvider?Object.assign({provider:e},l,f):Object.assign({},l,e,f))),this.#re=-2,this.#ne=null,this.quorum=2,this.eventQuorum=1,this.eventWorkers=1,(0,n.assertArgument)(this.quorum<=this.#te.reduce(((e,t)=>e+t.weight),0),"quorum exceed provider wieght","quorum",this.quorum)}get providerConfigs(){return this.#te.map((e=>{const t=Object.assign({},e);for(const e in t)"_"===e[0]&&delete t[e];return t}))}async _detectNetwork(){return o.Network.from((0,n.getBigInt)(await this._perform({method:"chainId"})))}async _translatePerform(e,t){switch(t.method){case"broadcastTransaction":return await e.broadcastTransaction(t.signedTransaction);case"call":return await e.call(Object.assign({},t.transaction,{blockTag:t.blockTag}));case"chainId":return(await e.getNetwork()).chainId;case"estimateGas":return await e.estimateGas(t.transaction);case"getBalance":return await e.getBalance(t.address,t.blockTag);case"getBlock":{const r="blockHash"in t?t.blockHash:t.blockTag;return await e.getBlock(r,t.includeTransactions)}case"getBlockNumber":return await e.getBlockNumber();case"getCode":return await e.getCode(t.address,t.blockTag);case"getGasPrice":return(await e.getFeeData()).gasPrice;case"getLogs":return await e.getLogs(t.filter);case"getStorage":return await e.getStorage(t.address,t.position,t.blockTag);case"getTransaction":return await e.getTransaction(t.hash);case"getTransactionCount":return await e.getTransactionCount(t.address,t.blockTag);case"getTransactionReceipt":return await e.getTransactionReceipt(t.hash);case"getTransactionResult":return await e.getTransactionResult(t.hash)}}#ie(e){const t=Array.from(e).map((e=>e.config)),r=this.#te.slice();!function(e){for(let t=e.length-1;t>0;t--){const r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}}(r),r.sort(((e,t)=>t.priority-e.priority));for(const e of r)if(-1===t.indexOf(e))return e;return null}#oe(e,t){const r=this.#ie(e);if(null==r)return null;const n={config:r,result:null,didBump:!1,perform:null,staller:null},i=u();return n.perform=(async()=>{try{r.requests++;const e=await this._translatePerform(r.provider,t);n.result={result:e}}catch(e){r.errorResponses++,n.result={error:e}}const e=u()-i;r._totalTime+=e,r.rollingDuration=.95*r.rollingDuration+.05*e,n.perform=null})(),n.staller=(async()=>{var e;await(e=r.stallTimeout,new Promise((t=>{setTimeout(t,e)}))),n.staller=null})(),e.add(n),n}async#ae(){let e=this.#ne;if(!e){const t=[];this.#te.forEach((e=>{t.push(async function(e,t){for(;e.blockNumber<0||e.blockNumber{const t=await e.provider.getBlockNumber();t>e.blockNumber&&(e.blockNumber=t),e._updateNumber=null})()),await e._updateNumber,e.outOfSync++}(e,0)),t.push((async()=>{e._network=await e.provider.getNetwork()})())})),this.#ne=e=(async()=>{await Promise.all(t);let e=null;for(const t of this.#te){const r=t._network;null==e?e=r.chainId:r.chainId!==e&&(0,n.assert)(!1,"cannot mix providers on different networks","UNSUPPORTED_OPERATION",{operation:"new FallbackProvider"})}})()}await e}async#se(e,t){const r=[];for(const t of e)if(null!=t.result){const{tag:e,value:n}=d(t.result);r.push({tag:e,value:n,weight:t.config.weight})}if(!(r.reduce(((e,t)=>e+t.weight),0)({value:e.blockNumber,tag:(0,n.getNumber)(e.blockNumber).toString(),weight:e.weight})))))));const e=function(e,t){if(1===e)return(0,n.getNumber)(m(e,t),"%internal");const r=new Map,i=(e,t)=>{const n=r.get(e)||{result:e,weight:0};n.weight+=t,r.set(e,n)};for(const{weight:e,value:r}of t){const t=(0,n.getNumber)(r);i(t-1,e),i(t,e),i(t+1,e)}let o,a=0;for(const{weight:t,result:n}of r.values())t>=e&&(t>a||null!=o&&t===a&&n>o)&&(a=t,o=n);return o}(this.quorum,r);if(void 0===e)return;return e>this.#re&&(this.#re=e),this.#re}case"getGasPrice":case"estimateGas":return m(this.quorum,r);case"getBlock":return"blockTag"in t&&"pending"===t.blockTag?y(this.quorum,r):p(this.quorum,r);case"call":case"chainId":case"getBalance":case"getTransactionCount":case"getCode":case"getStorage":case"getTransaction":case"getTransactionReceipt":case"getLogs":return p(this.quorum,r);case"broadcastTransaction":return y(this.quorum,r)}(0,n.assert)(!1,"unsupported method","UNSUPPORTED_OPERATION",{operation:`_perform(${c(t.method)})`})}}async#ue(e,t){if(0===e.size)throw new Error("no runners?!");const r=[];let i=0;for(const t of e)t.perform&&r.push(t.perform),t.staller?r.push(t.staller):t.didBump||(t.didBump=!0,i++);const o=await this.#se(e,t);if(void 0!==o){if(o instanceof Error)throw o;return o}for(let r=0;r0,"quorum not met","SERVER_ERROR",{request:"%sub-requests",info:{request:t,results:Array.from(e).map((e=>c(e.result)))}}),await Promise.race(r),await this.#ue(e,t)}async _perform(e){if("broadcastTransaction"===e.method){const t=await Promise.all(this.#te.map((async({provider:t,weight:r})=>{try{const n=await t._perform(e);return Object.assign(d({result:n}),{weight:r})}catch(e){return Object.assign(d({error:e}),{weight:r})}}))),r=y(this.quorum,t);if((0,n.assert)(void 0!==r,"problem multi-broadcasting","SERVER_ERROR",{request:"%sub-requests",info:{request:e,results:t.map(c)}}),r instanceof Error)throw r;return r}await this.#ae();const t=new Set;for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InfuraProvider=t.InfuraWebSocketProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s=r(62196),u="84842078b09946638c03157f83405213";class c extends s.WebSocketProvider{projectId;projectSecret;constructor(e,t){const r=new l(e,t),i=r._getConnection();(0,n.assert)(!i.credentials,"INFURA WebSocket project secrets unsupported","UNSUPPORTED_OPERATION",{operation:"InfuraProvider.getWebSocketProvider()"});super(i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/"),e),(0,n.defineProperties)(this,{projectId:r.projectId,projectSecret:r.projectSecret})}isCommunityResource(){return this.projectId===u}}t.InfuraWebSocketProvider=c;class l extends a.JsonRpcProvider{projectId;projectSecret;constructor(e,t,r){null==e&&(e="mainnet");const i=o.Network.from(e);null==t&&(t=u),null==r&&(r=null);super(l.getRequest(i,t,r),i,{staticNetwork:i}),(0,n.defineProperties)(this,{projectId:t,projectSecret:r})}_getProvider(e){try{return new l(e,this.projectId,this.projectSecret)}catch(e){}return super._getProvider(e)}isCommunityResource(){return this.projectId===u}static getWebSocketProvider(e,t){return new c(e,t)}static getRequest(e,t,r){null==t&&(t=u),null==r&&(r=null);const o=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"mainnet.infura.io";case"goerli":return"goerli.infura.io";case"sepolia":return"sepolia.infura.io";case"arbitrum":return"arbitrum-mainnet.infura.io";case"arbitrum-goerli":return"arbitrum-goerli.infura.io";case"matic":return"polygon-mainnet.infura.io";case"matic-mumbai":return"polygon-mumbai.infura.io";case"optimism":return"optimism-mainnet.infura.io";case"optimism-goerli":return"optimism-goerli.infura.io"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/v3/${t}`);return o.allowGzip=!0,r&&o.setCredentials("",r),t===u&&(o.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("InfuraProvider"),!0)),o}}t.InfuraProvider=l},74019:(e,t,r)=>{"use strict";var n=r(48764).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.IpcSocketProvider=void 0;const i=r(47444),o=r(12394);class a extends o.SocketProvider{#ce;get socket(){return this.#ce}constructor(e,t){super(t),this.#ce=(0,i.connect)(e),this.socket.on("ready",(async()=>{try{await this._start()}catch(e){console.log("failed to start IpcSocketProvider",e)}}));let r=n.alloc(0);this.socket.on("data",(e=>{r=n.concat([r,e]);const{messages:t,remaining:i}=function(e){const t=[];let r=0;for(;;){const n=e.indexOf(10,r);if(-1===n)break;t.push(e.subarray(r,n).toString().trim()),r=n+1}return{messages:t,remaining:e.subarray(r)}}(r);t.forEach((e=>{this._processMessage(e)})),r=i})),this.socket.on("end",(()=>{this.emit("close"),this.socket.destroy(),this.socket.end()}))}destroy(){this.socket.destroy(),this.socket.end(),super.destroy()}async _write(e){console.log(">>>",e),this.socket.write(e)}}t.IpcSocketProvider=a},32013:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.JsonRpcProvider=t.JsonRpcApiPollingProvider=t.JsonRpcApiProvider=t.JsonRpcSigner=void 0;const n=r(93707),i=r(45475),o=r(98336),a=r(2290),s=r(42120),u=r(55142),c=r(35649),l=r(54837),f=r(21570),h=r(21097),d="bigint,boolean,function,number,string,symbol".split(/,/g);function p(e){if(null==e||d.indexOf(typeof e)>=0)return e;if("function"==typeof e.getAddress)return e;if(Array.isArray(e))return e.map(p);if("object"==typeof e)return Object.keys(e).reduce(((t,r)=>(t[r]=e[r],t)),{});throw new Error(`should not happen: ${e} (${typeof e})`)}function m(e){return new Promise((t=>{setTimeout(t,e)}))}function y(e){return e?e.toLowerCase():e}function g(e){return e&&"number"==typeof e.pollingInterval}const b={polling:!1,staticNetwork:null,batchStallTime:10,batchMaxSize:1<<20,batchMaxCount:100};class v extends c.AbstractSigner{address;constructor(e,t){super(e),t=(0,i.getAddress)(t),(0,s.defineProperties)(this,{address:t})}connect(e){(0,s.assert)(!1,"cannot reconnect JsonRpcSigner","UNSUPPORTED_OPERATION",{operation:"signer.connect"})}async getAddress(){return this.address}async populateTransaction(e){return await this.populateCall(e)}async sendUncheckedTransaction(e){const t=p(e),r=[];if(t.from){const n=t.from;r.push((async()=>{const r=await(0,i.resolveAddress)(n,this.provider);(0,s.assertArgument)(null!=r&&r.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",e),t.from=r})())}else t.from=this.address;if(null==t.gasLimit&&r.push((async()=>{t.gasLimit=await this.provider.estimateGas({...t,from:this.address})})()),null!=t.to){const e=t.to;r.push((async()=>{t.to=await(0,i.resolveAddress)(e,this.provider)})())}r.length&&await Promise.all(r);const n=this.provider.getRpcTransaction(t);return this.provider.send("eth_sendTransaction",[n])}async sendTransaction(e){const t=await this.provider.getBlockNumber(),r=await this.sendUncheckedTransaction(e);return await new Promise(((e,n)=>{const i=[1e3,100],o=async()=>{const n=await this.provider.getTransaction(r);null==n?this.provider._setTimeout((()=>{o()}),i.pop()||4e3):e(n.replaceableTransaction(t))};o()}))}async signTransaction(e){const t=p(e);if(t.from){const r=await(0,i.resolveAddress)(t.from,this.provider);(0,s.assertArgument)(null!=r&&r.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",e),t.from=r}else t.from=this.address;const r=this.provider.getRpcTransaction(t);return await this.provider.send("eth_signTransaction",[r])}async signMessage(e){const t="string"==typeof e?(0,s.toUtf8Bytes)(e):e;return await this.provider.send("personal_sign",[(0,s.hexlify)(t),this.address.toLowerCase()])}async signTypedData(e,t,r){const n=p(r),a=await o.TypedDataEncoder.resolveNames(e,t,n,(async e=>{const t=await(0,i.resolveAddress)(e);return(0,s.assertArgument)(null!=t,"TypedData does not support null address","value",e),t}));return await this.provider.send("eth_signTypedData_v4",[this.address.toLowerCase(),JSON.stringify(o.TypedDataEncoder.getPayload(a.domain,t,a.value))])}async unlock(e){return this.provider.send("personal_unlockAccount",[this.address.toLowerCase(),e,null])}async _legacySignMessage(e){const t="string"==typeof e?(0,s.toUtf8Bytes)(e):e;return await this.provider.send("eth_sign",[this.address.toLowerCase(),(0,s.hexlify)(t)])}}t.JsonRpcSigner=v;class w extends u.AbstractProvider{#y;#le;#fe;#he;#de;#pe;#me(){if(this.#he)return;const e=1===this._getOption("batchMaxCount")?0:this._getOption("batchStallTime");this.#he=setTimeout((()=>{this.#he=null;const e=this.#fe;for(this.#fe=[];e.length;){const t=[e.shift()];for(;e.length&&t.length!==this.#y.batchMaxCount;){t.push(e.shift());if(JSON.stringify(t.map((e=>e.payload))).length>this.#y.batchMaxSize){e.unshift(t.pop());break}}(async()=>{const e=1===t.length?t[0].payload:t.map((e=>e.payload));this.emit("debug",{action:"sendRpcPayload",payload:e});try{const r=await this._send(e);this.emit("debug",{action:"receiveRpcResult",result:r});for(const{resolve:e,reject:n,payload:i}of t){const t=r.filter((e=>e.id===i.id))[0];if(null==t)return n(new Error("@TODO: no result"));if("error"in t)return n(this.getRpcError(i,t));e(t.result)}}catch(e){this.emit("debug",{action:"receiveRpcError",error:e});for(const{reject:r}of t)r(e)}})()}}),e)}constructor(e,t){super(e),this.#le=1,this.#y=Object.assign({},b,t||{}),this.#fe=[],this.#he=null,this.#pe=null;{let e=null;const t=new Promise((t=>{e=t}));this.#de={promise:t,resolve:e}}const r=this._getOption("staticNetwork");r&&((0,s.assertArgument)(r===e,"staticNetwork MUST match network object","options",t),this.#pe=r)}_getOption(e){return this.#y[e]}get _network(){return(0,s.assert)(this.#pe,"network is not available yet","NETWORK_ERROR"),this.#pe}async _perform(e){if("call"===e.method||"estimateGas"===e.method){let t=e.transaction;if(t&&null!=t.type&&(0,s.getBigInt)(t.type)&&null==t.maxFeePerGas&&null==t.maxPriorityFeePerGas){const r=await this.getFeeData();null==r.maxFeePerGas&&null==r.maxPriorityFeePerGas&&(e=Object.assign({},e,{transaction:Object.assign({},t,{type:void 0})}))}}const t=this.getRpcRequest(e);return null!=t?await this.send(t.method,t.args):super._perform(e)}async _detectNetwork(){const e=this._getOption("staticNetwork");if(e)return e;if(this.ready)return l.Network.from((0,s.getBigInt)(await this.send("eth_chainId",[])));const t={id:this.#le++,method:"eth_chainId",params:[],jsonrpc:"2.0"};let r;this.emit("debug",{action:"sendRpcPayload",payload:t});try{r=(await this._send(t))[0]}catch(e){throw this.emit("debug",{action:"receiveRpcError",error:e}),e}if(this.emit("debug",{action:"receiveRpcResult",result:r}),"result"in r)return l.Network.from((0,s.getBigInt)(r.result));throw this.getRpcError(t,r)}_start(){null!=this.#de&&null!=this.#de.resolve&&(this.#de.resolve(),this.#de=null,(async()=>{for(;null==this.#pe;)try{this.#pe=await this._detectNetwork()}catch(e){console.log("JsonRpcProvider failed to startup; retry in 1s"),await m(1e3)}this.#me()})())}async _waitUntilReady(){if(null!=this.#de)return await this.#de.promise}_getSubscriber(e){return"pending"===e.type?new f.FilterIdPendingSubscriber(this):"event"===e.type?this._getOption("polling")?new h.PollingEventSubscriber(this,e.filter):new f.FilterIdEventSubscriber(this,e.filter):"orphan"===e.type&&"drop-log"===e.filter.orphan?new u.UnmanagedSubscriber("orphan"):super._getSubscriber(e)}get ready(){return null==this.#de}getRpcTransaction(e){const t={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach((r=>{if(null==e[r])return;let n=r;"gasLimit"===r&&(n="gas"),t[n]=(0,s.toQuantity)((0,s.getBigInt)(e[r],`tx.${r}`))})),["from","to","data"].forEach((r=>{null!=e[r]&&(t[r]=(0,s.hexlify)(e[r]))})),e.accessList&&(t.accessList=(0,a.accessListify)(e.accessList)),t}getRpcRequest(e){switch(e.method){case"chainId":return{method:"eth_chainId",args:[]};case"getBlockNumber":return{method:"eth_blockNumber",args:[]};case"getGasPrice":return{method:"eth_gasPrice",args:[]};case"getBalance":return{method:"eth_getBalance",args:[y(e.address),e.blockTag]};case"getTransactionCount":return{method:"eth_getTransactionCount",args:[y(e.address),e.blockTag]};case"getCode":return{method:"eth_getCode",args:[y(e.address),e.blockTag]};case"getStorage":return{method:"eth_getStorageAt",args:[y(e.address),"0x"+e.position.toString(16),e.blockTag]};case"broadcastTransaction":return{method:"eth_sendRawTransaction",args:[e.signedTransaction]};case"getBlock":if("blockTag"in e)return{method:"eth_getBlockByNumber",args:[e.blockTag,!!e.includeTransactions]};if("blockHash"in e)return{method:"eth_getBlockByHash",args:[e.blockHash,!!e.includeTransactions]};break;case"getTransaction":return{method:"eth_getTransactionByHash",args:[e.hash]};case"getTransactionReceipt":return{method:"eth_getTransactionReceipt",args:[e.hash]};case"call":return{method:"eth_call",args:[this.getRpcTransaction(e.transaction),e.blockTag]};case"estimateGas":return{method:"eth_estimateGas",args:[this.getRpcTransaction(e.transaction)]};case"getLogs":return e.filter&&null!=e.filter.address&&(Array.isArray(e.filter.address)?e.filter.address=e.filter.address.map(y):e.filter.address=y(e.filter.address)),{method:"eth_getLogs",args:[e.filter]}}return null}getRpcError(e,t){const{method:r}=e,{error:i}=t;if("eth_estimateGas"===r&&i.message){const t=i.message;if(!t.match(/revert/i)&&t.match(/insufficient funds/i))return(0,s.makeError)("insufficient funds","INSUFFICIENT_FUNDS",{transaction:e.params[0]})}if("eth_call"===r||"eth_estimateGas"===r){const t=S(i),o=n.AbiCoder.getBuiltinCallException("eth_call"===r?"call":"estimateGas",e.params[0],t?t.data:null);return o.info={error:i,payload:e},o}const o=JSON.stringify(function(e){const t=[];return k(e,t),t}(i));if("string"==typeof i.message&&i.message.match(/user denied|ethers-user-denied/i)){const t={eth_sign:"signMessage",personal_sign:"signMessage",eth_signTypedData_v4:"signTypedData",eth_signTransaction:"signTransaction",eth_sendTransaction:"sendTransaction",eth_requestAccounts:"requestAccess",wallet_requestAccounts:"requestAccess"};return(0,s.makeError)("user rejected action","ACTION_REJECTED",{action:t[r]||"unknown",reason:"rejected",info:{payload:e,error:i}})}if("eth_sendRawTransaction"===r||"eth_sendTransaction"===r){const t=e.params[0];if(o.match(/insufficient funds|base fee exceeds gas limit/i))return(0,s.makeError)("insufficient funds for intrinsic transaction cost","INSUFFICIENT_FUNDS",{transaction:t,info:{error:i}});if(o.match(/nonce/i)&&o.match(/too low/i))return(0,s.makeError)("nonce has already been used","NONCE_EXPIRED",{transaction:t});if(o.match(/replacement transaction/i)&&o.match(/underpriced/i))return(0,s.makeError)("replacement fee too low","REPLACEMENT_UNDERPRICED",{transaction:t});if(o.match(/only replay-protected/i))return(0,s.makeError)("legacy pre-eip-155 transactions not supported","UNSUPPORTED_OPERATION",{operation:r,info:{transaction:t}})}return o.match(/the method .* does not exist/i)?(0,s.makeError)("unsupported operation","UNSUPPORTED_OPERATION",{operation:e.method,info:{error:i}}):(0,s.makeError)("could not coalesce error","UNKNOWN_ERROR",{error:i})}send(e,t){const r=this.#le++,n=new Promise(((n,i)=>{this.#fe.push({resolve:n,reject:i,payload:{method:e,params:t,id:r,jsonrpc:"2.0"}})}));return this.#me(),n}async getSigner(e){null==e&&(e=0);const t=this.send("eth_accounts",[]);if("number"==typeof e){const r=await t;if(e>=r.length)throw new Error("no such account");return new v(this,r[e])}const{accounts:r}=await(0,s.resolveProperties)({network:this.getNetwork(),accounts:t});e=(0,i.getAddress)(e);for(const t of r)if((0,i.getAddress)(t)===e)return new v(this,e);throw new Error("invalid account")}async listAccounts(){return(await this.send("eth_accounts",[])).map((e=>new v(this,e)))}}t.JsonRpcApiProvider=w;class A extends w{#ye;constructor(e,t){super(e,t),this.#ye=4e3}_getSubscriber(e){const t=super._getSubscriber(e);return g(t)&&(t.pollingInterval=this.#ye),t}get pollingInterval(){return this.#ye}set pollingInterval(e){if(!Number.isInteger(e)||e<0)throw new Error("invalid interval");this.#ye=e,this._forEachSubscriber((e=>{g(e)&&(e.pollingInterval=this.#ye)}))}}t.JsonRpcApiPollingProvider=A;function S(e){if(null==e)return null;if("string"==typeof e.message&&e.message.match("reverted")&&(0,s.isHexString)(e.data))return{message:e.message,data:e.data};if("object"==typeof e){for(const t in e){const r=S(e[t]);if(r)return r}return null}if("string"==typeof e)try{return S(JSON.parse(e))}catch(e){}return null}function k(e,t){if(null!=e){if("string"==typeof e.message&&t.push(e.message),"object"==typeof e)for(const r in e)k(e[r],t);if("string"==typeof e)try{return k(JSON.parse(e),t)}catch(e){}}}t.JsonRpcProvider=class extends A{#ge;constructor(e,t,r){null==e&&(e="http://localhost:8545"),super(t,r),this.#ge="string"==typeof e?new s.FetchRequest(e):e.clone()}_getConnection(){return this.#ge.clone()}async send(e,t){return await this._start(),await super.send(e,t)}async _send(e){const t=this._getConnection();t.body=JSON.stringify(e),t.setHeader("content-type","application/json");const r=await t.send();r.assertOk();let n=r.bodyJson;return Array.isArray(n)||(n=[n]),n}}},52751:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PocketProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="62e1ad51b37b8e00394bda3b";class u extends a.JsonRpcProvider{applicationId;applicationSecret;constructor(e,t,r){null==e&&(e="mainnet");const i=o.Network.from(e);null==t&&(t=s),null==r&&(r=null);const a={staticNetwork:i};super(u.getRequest(i,t,r),i,a),(0,n.defineProperties)(this,{applicationId:t,applicationSecret:r})}_getProvider(e){try{return new u(e,this.applicationId,this.applicationSecret)}catch(e){}return super._getProvider(e)}static getRequest(e,t,r){null==t&&(t=s);const o=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"eth-mainnet.gateway.pokt.network";case"goerli":return"eth-goerli.gateway.pokt.network";case"matic":return"poly-mainnet.gateway.pokt.network";case"matic-mumbai":return"polygon-mumbai-rpc.gateway.pokt.network"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/v1/lb/${t}`);return o.allowGzip=!0,r&&o.setCredentials("",r),t===s&&(o.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("PocketProvider"),!0)),o}isCommunityResource(){return this.applicationId===s}}t.PocketProvider=u},81333:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.QuickNodeProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="919b412a057b5e9c9b6dce193c5a60242d6efadb";class u extends a.JsonRpcProvider{token;constructor(e,t){null==e&&(e="mainnet");const r=o.Network.from(e);null==t&&(t=s);super(u.getRequest(r,t),r,{staticNetwork:r}),(0,n.defineProperties)(this,{token:t})}_getProvider(e){try{return new u(e,this.token)}catch(e){}return super._getProvider(e)}isCommunityResource(){return this.token===s}static getRequest(e,t){null==t&&(t=s);const r=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"ethers.quiknode.pro";case"goerli":return"ethers.ethereum-goerli.quiknode.pro";case"arbitrum":return"ethers.arbitrum-mainnet.quiknode.pro";case"arbitrum-goerli":return"ethers.arbitrum-goerli.quiknode.pro";case"matic":return"ethers.matic.quiknode.pro";case"matic-mumbai":return"ethers.matic-testnet.quiknode.pro";case"optimism":return"ethers.optimism.quiknode.pro";case"optimism-goerli":return"ethers.optimism-goerli.quiknode.pro"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/${t}`);return r.allowGzip=!0,t===s&&(r.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("QuickNodeProvider"),!0)),r}}t.QuickNodeProvider=u},12394:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SocketProvider=t.SocketEventSubscriber=t.SocketPendingSubscriber=t.SocketBlockSubscriber=t.SocketSubscriber=void 0;const n=r(55142),i=r(42120),o=r(32013);class a{#be;#g;get filter(){return JSON.parse(this.#g)}#ve;#we;#Ae;constructor(e,t){this.#be=e,this.#g=JSON.stringify(t),this.#ve=null,this.#we=null,this.#Ae=null}start(){this.#ve=this.#be.send("eth_subscribe",this.filter).then((e=>(this.#be._register(e,this),e)))}stop(){this.#ve.then((e=>{this.#be.send("eth_unsubscribe",[e])})),this.#ve=null}pause(e){(0,i.assert)(e,"preserve logs while paused not supported by SocketSubscriber yet","UNSUPPORTED_OPERATION",{operation:"pause(false)"}),this.#we=!!e}resume(){this.#we=null}_handleMessage(e){if(null!=this.#ve&&null===this.#we){let t=this.#Ae;t=null==t?this._emit(this.#be,e):t.then((async()=>{await this._emit(this.#be,e)})),this.#Ae=t.then((()=>{this.#Ae===t&&(this.#Ae=null)}))}}async _emit(e,t){throw new Error("sub-classes must implemente this; _emit")}}t.SocketSubscriber=a;class s extends a{constructor(e){super(e,["newHeads"])}async _emit(e,t){e.emit("block",parseInt(t.number))}}t.SocketBlockSubscriber=s;class u extends a{constructor(e){super(e,["newPendingTransactions"])}async _emit(e,t){e.emit("pending",t)}}t.SocketPendingSubscriber=u;class c extends a{#Se;get logFilter(){return JSON.parse(this.#Se)}constructor(e,t){super(e,["logs",t]),this.#Se=JSON.stringify(t)}async _emit(e,t){e.emit(this.#Se,e._wrapLog(t,e._network))}}t.SocketEventSubscriber=c;class l extends o.JsonRpcApiProvider{#ke;#x;#Ee;constructor(e){super(e,{batchMaxCount:1}),this.#ke=new Map,this.#x=new Map,this.#Ee=new Map}_getSubscriber(e){switch(e.type){case"close":return new n.UnmanagedSubscriber("close");case"block":return new s(this);case"pending":return new u(this);case"event":return new c(this,e.filter);case"orphan":if("drop-log"===e.filter.orphan)return new n.UnmanagedSubscriber("drop-log")}return super._getSubscriber(e)}_register(e,t){this.#x.set(e,t);const r=this.#Ee.get(e);if(r){for(const e of r)t._handleMessage(e);this.#Ee.delete(e)}}async _send(e){(0,i.assertArgument)(!Array.isArray(e),"WebSocket does not support batch send","payload",e);const t=new Promise(((t,r)=>{this.#ke.set(e.id,{payload:e,resolve:t,reject:r})}));return await this._waitUntilReady(),await this._write(JSON.stringify(e)),[await t]}async _processMessage(e){const t=JSON.parse(e);if("id"in t){const e=this.#ke.get(t.id);if(null==e)return void console.log("Weird... Response for not a thing we sent");this.#ke.delete(t.id),e.resolve(t)}else if("eth_subscription"===t.method){const e=t.params.subscription,r=this.#x.get(e);if(r)r._handleMessage(t.params.result);else{let r=this.#Ee.get(e);null==r&&(r=[],this.#Ee.set(e,r)),r.push(t.params.result)}}}async _write(e){throw new Error("sub-classes must override this")}}t.SocketProvider=l},62196:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebSocketProvider=void 0;const n=r(39896),i=r(12394);class o extends i.SocketProvider{#ge;#_e;get websocket(){if(null==this.#_e)throw new Error("websocket closed");return this.#_e}constructor(e,t){super(t),"string"==typeof e?(this.#ge=()=>new n.WebSocket(e),this.#_e=this.#ge()):"function"==typeof e?(this.#ge=e,this.#_e=e()):(this.#ge=null,this.#_e=e),this.websocket.onopen=async()=>{try{await this._start(),this.resume()}catch(e){console.log("failed to start WebsocketProvider",e)}},this.websocket.onmessage=e=>{this._processMessage(e.data)}}async _write(e){this.websocket.send(e)}async destroy(){null!=this.#_e&&(this.#_e.close(),this.#_e=null),super.destroy()}}t.WebSocketProvider=o},37143:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionResponse=t.TransactionReceipt=t.Log=t.Block=t.copyRequest=t.FeeData=void 0;const n=r(42120),i=r(2290),o=BigInt(0);function a(e){return null==e?null:e}function s(e){return null==e?null:e.toString()}t.FeeData=class{gasPrice;maxFeePerGas;maxPriorityFeePerGas;constructor(e,t,r){(0,n.defineProperties)(this,{gasPrice:a(e),maxFeePerGas:a(t),maxPriorityFeePerGas:a(r)})}toJSON(){const{gasPrice:e,maxFeePerGas:t,maxPriorityFeePerGas:r}=this;return{_type:"FeeData",gasPrice:s(e),maxFeePerGas:s(t),maxPriorityFeePerGas:s(r)}}},t.copyRequest=function(e){const t={};e.to&&(t.to=e.to),e.from&&(t.from=e.from),e.data&&(t.data=(0,n.hexlify)(e.data));const r="chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);for(const i of r)i in e&&null!=e[i]&&(t[i]=(0,n.getBigInt)(e[i],`request.${i}`));const o="type,nonce".split(/,/);for(const r of o)r in e&&null!=e[r]&&(t[r]=(0,n.getNumber)(e[r],`request.${r}`));return e.accessList&&(t.accessList=(0,i.accessListify)(e.accessList)),"blockTag"in e&&(t.blockTag=e.blockTag),"enableCcipRead"in e&&(t.enableCcipReadEnabled=!!e.enableCcipRead),"customData"in e&&(t.customData=e.customData),t};class u{provider;number;hash;timestamp;parentHash;nonce;difficulty;gasLimit;gasUsed;miner;extraData;baseFeePerGas;#Me;constructor(e,t){this.#Me=e.transactions.map((e=>"string"!=typeof e?new f(e,t):e)),(0,n.defineProperties)(this,{provider:t,hash:a(e.hash),number:e.number,timestamp:e.timestamp,parentHash:e.parentHash,nonce:e.nonce,difficulty:e.difficulty,gasLimit:e.gasLimit,gasUsed:e.gasUsed,miner:e.miner,extraData:e.extraData,baseFeePerGas:a(e.baseFeePerGas)})}get transactions(){return this.#Me.map((e=>"string"==typeof e?e:e.hash))}get prefetchedTransactions(){const e=this.#Me.slice();return 0===e.length?[]:((0,n.assert)("object"==typeof e[0],"transactions were not prefetched with block request","UNSUPPORTED_OPERATION",{operation:"transactionResponses()"}),e)}toJSON(){const{baseFeePerGas:e,difficulty:t,extraData:r,gasLimit:n,gasUsed:i,hash:o,miner:a,nonce:u,number:c,parentHash:l,timestamp:f,transactions:h}=this;return{_type:"Block",baseFeePerGas:s(e),difficulty:s(t),extraData:r,gasLimit:s(n),gasUsed:s(i),hash:o,miner:a,nonce:u,number:c,parentHash:l,timestamp:f,transactions:h}}[Symbol.iterator](){let e=0;const t=this.transactions;return{next:()=>enew c(e,t)))),(0,n.defineProperties)(this,{provider:t,to:e.to,from:e.from,contractAddress:e.contractAddress,hash:e.hash,index:e.index,blockHash:e.blockHash,blockNumber:e.blockNumber,logsBloom:e.logsBloom,gasUsed:e.gasUsed,cumulativeGasUsed:e.cumulativeGasUsed,gasPrice:e.effectiveGasPrice||e.gasPrice,type:e.type,status:e.status,root:e.root})}get logs(){return this.#Te}toJSON(){const{to:e,from:t,contractAddress:r,hash:n,index:i,blockHash:o,blockNumber:a,logsBloom:u,logs:c,status:l,root:f}=this;return{_type:"TransactionReceipt",blockHash:o,blockNumber:a,contractAddress:r,cumulativeGasUsed:s(this.cumulativeGasUsed),from:t,gasPrice:s(this.gasPrice),gasUsed:s(this.gasUsed),hash:n,index:i,logs:c,logsBloom:u,root:f,status:l,to:e}}get length(){return this.logs.length}[Symbol.iterator](){let e=0;return{next:()=>e{if(u)return null;const{blockNumber:e,nonce:t}=await(0,n.resolveProperties)({blockNumber:this.provider.getBlockNumber(),nonce:this.provider.getTransactionCount(this.from)});if(t=r)return l}else if(await c(),0===r)return null;const f=new Promise(((e,t)=>{const o=[],s=()=>{o.forEach((e=>e()))};if(o.push((()=>{u=!0})),i>0){const e=setTimeout((()=>{s(),t((0,n.makeError)("wait for transaction timeout","TIMEOUT"))}),i);o.push((()=>{clearTimeout(e)}))}const l=async t=>{await t.confirmations()>=r&&(s(),e(t))};if(o.push((()=>{this.provider.off(this.hash,l)})),this.provider.on(this.hash,l),a>=0){const e=async()=>{try{await c()}catch(e){if((0,n.isError)(e,"TRANSACTION_REPLACED"))return s(),void t(e)}u||this.provider.once("block",e)};o.push((()=>{this.provider.off("block",e)})),this.provider.once("block",e)}}));return await f}isMined(){return null!=this.blockHash}isLegacy(){return 0===this.type}isBerlin(){return 1===this.type}isLondon(){return 2===this.type}removedEvent(){return(0,n.assert)(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),d(this)}reorderedEvent(e){return(0,n.assert)(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),(0,n.assert)(!e||e.isMined(),"unmined 'other' transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),h(this,e)}replaceableTransaction(e){(0,n.assertArgument)(Number.isInteger(e)&&e>=0,"invalid startBlock","startBlock",e);const t=new f(this,this.provider);return t.#xe=e,t}}function h(e,t){return{orphan:"reorder-transaction",tx:e,other:t}}function d(e){return{orphan:"drop-transaction",tx:e}}t.TransactionResponse=f},22992:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NonceManager=void 0;const n=r(42120),i=r(35649);class o extends i.AbstractSigner{signer;#Pe;#Ie;constructor(e){super(e.provider),(0,n.defineProperties)(this,{signer:e}),this.#Pe=null,this.#Ie=0}async getAddress(){return this.signer.getAddress()}connect(e){return new o(this.signer.connect(e))}async getNonce(e){if("pending"===e){null==this.#Pe&&(this.#Pe=super.getNonce("pending"));const e=this.#Ie;return await this.#Pe+e}return super.getNonce(e)}increment(){this.#Ie++}reset(){this.#Ie=0,this.#Pe=null}async sendTransaction(e){const t=this.getNonce("pending");return this.increment(),(e=await this.signer.populateTransaction(e)).nonce=await t,await this.signer.sendTransaction(e)}signTransaction(e){return this.signer.signTransaction(e)}signMessage(e){return this.signer.signMessage(e)}signTypedData(e,t,r){return this.signer.signTypedData(e,t,r)}}t.NonceManager=o},21570:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FilterIdPendingSubscriber=t.FilterIdEventSubscriber=t.FilterIdSubscriber=void 0;const n=r(42120),i=r(21097);class o{#be;#Oe;#Re;#Ce;#pe;#Be;constructor(e){this.#be=e,this.#Oe=null,this.#Re=this.#Ne.bind(this),this.#Ce=!1,this.#pe=null,this.#Be=!1}_subscribe(e){throw new Error("subclasses must override this")}_emitResults(e,t){throw new Error("subclasses must override this")}_recover(e){throw new Error("subclasses must override this")}async#Ne(e){try{null==this.#Oe&&(this.#Oe=this._subscribe(this.#be));let e=null;try{e=await this.#Oe}catch(e){if(!(0,n.isError)(e,"UNSUPPORTED_OPERATION")||"eth_newFilter"!==e.operation)throw e}if(null==e)return this.#Oe=null,void this.#be._recoverSubscriber(this,this._recover(this.#be));const t=await this.#be.getNetwork();if(this.#pe||(this.#pe=t),this.#pe.chainId!==t.chainId)throw new Error("chaid changed");if(this.#Be)return;const r=await this.#be.send("eth_getFilterChanges",[e]);await this._emitResults(this.#be,r)}catch(e){console.log("@TODO",e)}this.#be.once("block",this.#Re)}#Le(){const e=this.#Oe;e&&(this.#Oe=null,e.then((e=>{this.#be.send("eth_uninstallFilter",[e])})))}start(){this.#Ce||(this.#Ce=!0,this.#Ne(-2))}stop(){this.#Ce&&(this.#Ce=!1,this.#Be=!0,this.#Le(),this.#be.off("block",this.#Re))}pause(e){e&&this.#Le(),this.#be.off("block",this.#Re)}resume(){this.start()}}t.FilterIdSubscriber=o;t.FilterIdEventSubscriber=class extends o{#Ue;constructor(e,t){var r;super(e),this.#Ue=(r=t,JSON.parse(JSON.stringify(r)))}_recover(e){return new i.PollingEventSubscriber(e,this.#Ue)}async _subscribe(e){return await e.send("eth_newFilter",[this.#Ue])}async _emitResults(e,t){for(const r of t)e.emit(this.#Ue,e._wrapLog(r,e._network))}};t.FilterIdPendingSubscriber=class extends o{async _subscribe(e){return await e.send("eth_newPendingTransactionFilter",[])}async _emitResults(e,t){for(const r of t)e.emit("pending",r)}}},21097:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PollingEventSubscriber=t.PollingTransactionSubscriber=t.PollingOrphanSubscriber=t.OnBlockSubscriber=t.PollingBlockSubscriber=t.getPollingSubscriber=void 0;const n=r(42120);function i(e){return JSON.parse(JSON.stringify(e))}t.getPollingSubscriber=function(e,t){return"block"===t?new o(e):(0,n.isHexString)(t,32)?new s(e,t):void(0,n.assert)(!1,"unsupported polling event","UNSUPPORTED_OPERATION",{operation:"getPollingSubscriber",info:{event:t}})};class o{#be;#Re;#Fe;#De;constructor(e){this.#be=e,this.#Re=null,this.#Fe=4e3,this.#De=-2}get pollingInterval(){return this.#Fe}set pollingInterval(e){this.#Fe=e}async#Ne(){const e=await this.#be.getBlockNumber();if(-2!==this.#De){if(e!==this.#De){for(let t=this.#De+1;t<=e;t++){if(null==this.#Re)return;await this.#be.emit("block",t)}this.#De=e}null!=this.#Re&&(this.#Re=this.#be._setTimeout(this.#Ne.bind(this),this.#Fe))}else this.#De=e}start(){this.#Re||(this.#Re=this.#be._setTimeout(this.#Ne.bind(this),this.#Fe),this.#Ne())}stop(){this.#Re&&(this.#be._clearTimeout(this.#Re),this.#Re=null)}pause(e){this.stop(),e&&(this.#De=-2)}resume(){this.start()}}t.PollingBlockSubscriber=o;class a{#be;#Ne;#Ce;constructor(e){this.#be=e,this.#Ce=!1,this.#Ne=e=>{this._poll(e,this.#be)}}async _poll(e,t){throw new Error("sub-classes must override this")}start(){this.#Ce||(this.#Ce=!0,this.#Ne(-2),this.#be.on("block",this.#Ne))}stop(){this.#Ce&&(this.#Ce=!1,this.#be.off("block",this.#Ne))}pause(e){this.stop()}resume(){this.start()}}t.OnBlockSubscriber=a;t.PollingOrphanSubscriber=class extends a{#g;constructor(e,t){super(e),this.#g=i(t)}async _poll(e,t){throw new Error("@TODO")}};class s extends a{#je;constructor(e,t){super(e),this.#je=t}async _poll(e,t){const r=await t.getTransactionReceipt(this.#je);r&&t.emit(this.#je,r)}}t.PollingTransactionSubscriber=s;t.PollingEventSubscriber=class{#be;#g;#Re;#Ce;#De;constructor(e,t){this.#be=e,this.#g=i(t),this.#Re=this.#Ne.bind(this),this.#Ce=!1,this.#De=-2}async#Ne(e){if(-2===this.#De)return;const t=i(this.#g);t.fromBlock=this.#De+1,t.toBlock=e;const r=await this.#be.getLogs(t);if(0!==r.length){this.#De=e;for(const e of r)this.#be.emit(this.#g,e)}else this.#De{this.#De=e})),this.#be.on("block",this.#Re))}stop(){this.#Ce&&(this.#Ce=!1,this.#be.off("block",this.#Re))}pause(e){this.stop(),e&&(this.#De=-2)}resume(){this.start()}}},39896:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebSocket=void 0;var n=r(10639);Object.defineProperty(t,"WebSocket",{enumerable:!0,get:function(){return n.WebSocket}})},484:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.accessListify=void 0;const n=r(45475),i=r(42120);function o(e,t){return{address:(0,n.getAddress)(e),storageKeys:t.map(((e,t)=>((0,i.assertArgument)((0,i.isHexString)(e,32),"invalid slot",`storageKeys[${t}]`,e),e.toLowerCase())))}}t.accessListify=function(e){if(Array.isArray(e))return e.map(((t,r)=>Array.isArray(t)?((0,i.assertArgument)(2===t.length,"invalid slot set",`value[${r}]`,t),o(t[0],t[1])):((0,i.assertArgument)(null!=t&&"object"==typeof t,"invalid address-slot set","value",e),o(t.address,t.storageKeys))));(0,i.assertArgument)(null!=e&&"object"==typeof e,"invalid access list","value",e);const t=Object.keys(e).map((t=>{const r=e[t].reduce(((e,t)=>(e[t]=!0,e)),{});return o(t,Object.keys(r).sort())}));return t.sort(((e,t)=>e.address.localeCompare(t.address))),t}},17782:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.recoverAddress=t.computeAddress=void 0;const n=r(45475),i=r(96965);function o(e){let t;return t="string"==typeof e?i.SigningKey.computePublicKey(e,!1):e.publicKey,(0,n.getAddress)((0,i.keccak256)("0x"+t.substring(4)).substring(26))}t.computeAddress=o,t.recoverAddress=function(e,t){return o(i.SigningKey.recoverPublicKey(e,t))}},2290:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Transaction=t.recoverAddress=t.computeAddress=t.accessListify=void 0;var n=r(484);Object.defineProperty(t,"accessListify",{enumerable:!0,get:function(){return n.accessListify}});var i=r(17782);Object.defineProperty(t,"computeAddress",{enumerable:!0,get:function(){return i.computeAddress}}),Object.defineProperty(t,"recoverAddress",{enumerable:!0,get:function(){return i.recoverAddress}});var o=r(31541);Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return o.Transaction}})},31541:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Transaction=void 0;const n=r(45475),i=r(96965),o=r(42120),a=r(484),s=r(17782),u=BigInt(0),c=BigInt(2),l=BigInt(27),f=BigInt(28),h=BigInt(35),d=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function p(e){return"0x"===e?null:(0,n.getAddress)(e)}function m(e,t){try{return(0,a.accessListify)(e)}catch(r){(0,o.assertArgument)(!1,r.message,t,e)}}function y(e,t){return"0x"===e?0:(0,o.getNumber)(e,t)}function g(e,t){if("0x"===e)return u;const r=(0,o.getBigInt)(e,t);return(0,o.assertArgument)(r<=d,"value exceeds uint size",t,r),r}function b(e,t){const r=(0,o.getBigInt)(e,"value"),n=(0,o.toBeArray)(r);return(0,o.assertArgument)(n.length<=32,"value too large",`tx.${t}`,r),n}function v(e){return(0,a.accessListify)(e).map((e=>[e.address,e.storageKeys]))}function w(e,t){const r=[b(e.nonce||0,"nonce"),b(e.gasPrice||0,"gasPrice"),b(e.gasLimit||0,"gasLimit"),null!=e.to?(0,n.getAddress)(e.to):"0x",b(e.value||0,"value"),e.data||"0x"];let a=u;if(null!=e.chainId)a=(0,o.getBigInt)(e.chainId,"tx.chainId"),(0,o.assertArgument)(!t||null==t.networkV||t.legacyChainId===a,"tx.chainId/sig.v mismatch","sig",t);else if(t){const e=t.legacyChainId;null!=e&&(a=e)}if(!t)return a!==u&&(r.push((0,o.toBeArray)(a)),r.push("0x"),r.push("0x")),(0,o.encodeRlp)(r);let s=BigInt(27+t.yParity);return a!==u?s=i.Signature.getChainIdV(a,t.v):BigInt(t.v)!==s&&(0,o.assertArgument)(!1,"tx.chainId/sig.v mismatch","sig",t),r.push((0,o.toBeArray)(s)),r.push((0,o.toBeArray)(t.r)),r.push((0,o.toBeArray)(t.s)),(0,o.encodeRlp)(r)}function A(e,t,r){let n;try{if(n=y(t[0],"yParity"),0!==n&&1!==n)throw new Error("bad yParity")}catch(e){(0,o.assertArgument)(!1,"invalid yParity","yParity",t[0])}const a=(0,o.zeroPadValue)(t[1],32),s=(0,o.zeroPadValue)(t[2],32),u=i.Signature.from({r:a,s,yParity:n});e.signature=u}function S(e,t){const r=[b(e.chainId||0,"chainId"),b(e.nonce||0,"nonce"),b(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),b(e.maxFeePerGas||0,"maxFeePerGas"),b(e.gasLimit||0,"gasLimit"),null!=e.to?(0,n.getAddress)(e.to):"0x",b(e.value||0,"value"),e.data||"0x",v(e.accessList||[])];return t&&(r.push(b(t.yParity,"yParity")),r.push((0,o.toBeArray)(t.r)),r.push((0,o.toBeArray)(t.s))),(0,o.concat)(["0x02",(0,o.encodeRlp)(r)])}function k(e,t){const r=[b(e.chainId||0,"chainId"),b(e.nonce||0,"nonce"),b(e.gasPrice||0,"gasPrice"),b(e.gasLimit||0,"gasLimit"),null!=e.to?(0,n.getAddress)(e.to):"0x",b(e.value||0,"value"),e.data||"0x",v(e.accessList||[])];return t&&(r.push(b(t.yParity,"recoveryParam")),r.push((0,o.toBeArray)(t.r)),r.push((0,o.toBeArray)(t.s))),(0,o.concat)(["0x01",(0,o.encodeRlp)(r)])}class E{#He;#Je;#r;#ze;#Ge;#qe;#Ke;#Ve;#Xe;#Z;#Qe;#We;get type(){return this.#He}set type(e){switch(e){case null:this.#He=null;break;case 0:case"legacy":this.#He=0;break;case 1:case"berlin":case"eip-2930":this.#He=1;break;case 2:case"london":case"eip-1559":this.#He=2;break;default:(0,o.assertArgument)(!1,"unsupported transaction type","type",e)}}get typeName(){switch(this.type){case 0:return"legacy";case 1:return"eip-2930";case 2:return"eip-1559"}return null}get to(){return this.#Je}set to(e){this.#Je=null==e?null:(0,n.getAddress)(e)}get nonce(){return this.#ze}set nonce(e){this.#ze=(0,o.getNumber)(e,"value")}get gasLimit(){return this.#Ge}set gasLimit(e){this.#Ge=(0,o.getBigInt)(e)}get gasPrice(){const e=this.#qe;return null!=e||0!==this.type&&1!==this.type?e:u}set gasPrice(e){this.#qe=null==e?null:(0,o.getBigInt)(e,"gasPrice")}get maxPriorityFeePerGas(){const e=this.#Ke;return null==e?2===this.type?u:null:e}set maxPriorityFeePerGas(e){this.#Ke=null==e?null:(0,o.getBigInt)(e,"maxPriorityFeePerGas")}get maxFeePerGas(){const e=this.#Ve;return null==e?2===this.type?u:null:e}set maxFeePerGas(e){this.#Ve=null==e?null:(0,o.getBigInt)(e,"maxFeePerGas")}get data(){return this.#r}set data(e){this.#r=(0,o.hexlify)(e)}get value(){return this.#Xe}set value(e){this.#Xe=(0,o.getBigInt)(e,"value")}get chainId(){return this.#Z}set chainId(e){this.#Z=(0,o.getBigInt)(e)}get signature(){return this.#Qe||null}set signature(e){this.#Qe=null==e?null:i.Signature.from(e)}get accessList(){const e=this.#We||null;return null==e?1===this.type||2===this.type?[]:null:e}set accessList(e){this.#We=null==e?null:(0,a.accessListify)(e)}constructor(){this.#He=null,this.#Je=null,this.#ze=0,this.#Ge=BigInt(0),this.#qe=null,this.#Ke=null,this.#Ve=null,this.#r="0x",this.#Xe=BigInt(0),this.#Z=BigInt(0),this.#Qe=null,this.#We=null}get hash(){return null==this.signature?null:(0,i.keccak256)(this.serialized)}get unsignedHash(){return(0,i.keccak256)(this.unsignedSerialized)}get from(){return null==this.signature?null:(0,s.recoverAddress)(this.unsignedHash,this.signature)}get fromPublicKey(){return null==this.signature?null:i.SigningKey.recoverPublicKey(this.unsignedHash,this.signature)}isSigned(){return null!=this.signature}get serialized(){switch((0,o.assert)(null!=this.signature,"cannot serialize unsigned transaction; maybe you meant .unsignedSerialized","UNSUPPORTED_OPERATION",{operation:".serialized"}),this.inferType()){case 0:return w(this,this.signature);case 1:return k(this,this.signature);case 2:return S(this,this.signature)}(0,o.assert)(!1,"unsupported transaction type","UNSUPPORTED_OPERATION",{operation:".serialized"})}get unsignedSerialized(){switch(this.inferType()){case 0:return w(this);case 1:return k(this);case 2:return S(this)}(0,o.assert)(!1,"unsupported transaction type","UNSUPPORTED_OPERATION",{operation:".unsignedSerialized"})}inferType(){return this.inferTypes().pop()}inferTypes(){const e=null!=this.gasPrice,t=null!=this.maxFeePerGas||null!=this.maxPriorityFeePerGas,r=null!=this.accessList;null!=this.maxFeePerGas&&null!=this.maxPriorityFeePerGas&&(0,o.assert)(this.maxFeePerGas>=this.maxPriorityFeePerGas,"priorityFee cannot be more than maxFee","BAD_DATA",{value:this}),(0,o.assert)(!t||0!==this.type&&1!==this.type,"transaction type cannot have maxFeePerGas or maxPriorityFeePerGas","BAD_DATA",{value:this}),(0,o.assert)(0!==this.type||!r,"legacy transaction cannot have accessList","BAD_DATA",{value:this});const n=[];return null!=this.type?n.push(this.type):t?n.push(2):e?(n.push(1),r||n.push(0)):r?(n.push(1),n.push(2)):(n.push(0),n.push(1),n.push(2)),n.sort(),n}isLegacy(){return 0===this.type}isBerlin(){return 1===this.type}isLondon(){return 2===this.type}clone(){return E.from(this)}toJSON(){const e=e=>null==e?null:e.toString();return{type:this.type,to:this.to,data:this.data,nonce:this.nonce,gasLimit:e(this.gasLimit),gasPrice:e(this.gasPrice),maxPriorityFeePerGas:e(this.maxPriorityFeePerGas),maxFeePerGas:e(this.maxFeePerGas),value:e(this.value),chainId:e(this.chainId),sig:this.signature?this.signature.toJSON():null,accessList:this.accessList}}static from(e){if(null==e)return new E;if("string"==typeof e){const t=(0,o.getBytes)(e);if(t[0]>=127)return E.from(function(e){const t=(0,o.decodeRlp)(e);(0,o.assertArgument)(Array.isArray(t)&&(9===t.length||6===t.length),"invalid field count for legacy transaction","data",e);const r={type:0,nonce:y(t[0],"nonce"),gasPrice:g(t[1],"gasPrice"),gasLimit:g(t[2],"gasLimit"),to:p(t[3]),value:g(t[4],"value"),data:(0,o.hexlify)(t[5]),chainId:u};if(6===t.length)return r;const n=g(t[6],"v"),a=g(t[7],"r"),s=g(t[8],"s");if(a===u&&s===u)r.chainId=n;else{let a=(n-h)/c;a{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBase58=t.encodeBase58=void 0;const n=r(86239),i=r(21766),o=r(90358),a="123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz";let s=null;function u(e){if(null==s){s={};for(let e=0;e{"use strict";var n=r(48764).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.encodeBase64=t.decodeBase64=void 0;const i=r(86239);t.decodeBase64=function(e){return(0,i.getBytesCopy)(n.from(e,"base64"))},t.encodeBase64=function(e){return n.from((0,i.getBytes)(e)).toString("base64")}},86239:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.zeroPadBytes=t.zeroPadValue=t.stripZerosLeft=t.dataSlice=t.dataLength=t.concat=t.hexlify=t.isBytesLike=t.isHexString=t.getBytesCopy=t.getBytes=void 0;const n=r(21766);function i(e,t,r){if(e instanceof Uint8Array)return r?new Uint8Array(e):e;if("string"==typeof e&&e.match(/^0x([0-9a-f][0-9a-f])*$/i)){const t=new Uint8Array((e.length-2)/2);let r=2;for(let n=0;n>4]+s[15&n]}return r}function c(e,t,r){const i=o(e);(0,n.assert)(t>=i.length,"padding exceeds data length","BUFFER_OVERRUN",{buffer:new Uint8Array(i),length:t,offset:t+1});const a=new Uint8Array(t);return a.fill(0),r?a.set(i,t-i.length):a.set(i,0),u(a)}t.hexlify=u,t.concat=function(e){return"0x"+e.map((e=>u(e).substring(2))).join("")},t.dataLength=function(e){return a(e,!0)?(e.length-2)/2:o(e).length},t.dataSlice=function(e,t,r){const i=o(e);return null!=r&&r>i.length&&(0,n.assert)(!1,"cannot slice beyond data bounds","BUFFER_OVERRUN",{buffer:i,length:i.length,offset:r}),u(i.slice(null==t?0:t,null==r?i.length:r))},t.stripZerosLeft=function(e){let t=u(e).substring(2);for(;t.startsWith("00");)t=t.substring(2);return"0x"+t},t.zeroPadValue=function(e,t){return c(e,t,!0)},t.zeroPadBytes=function(e,t){return c(e,t,!1)}},21766:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assertPrivate=t.assertNormalize=t.assertArgumentCount=t.assertArgument=t.assert=t.makeError=t.isCallException=t.isError=void 0;const n=r(79406),i=r(39290);function o(e){if(null==e)return"null";if(Array.isArray(e))return"[ "+e.map(o).join(", ")+" ]";if(e instanceof Uint8Array){const t="0123456789abcdef";let r="0x";for(let n=0;n>4],r+=t[15&e[n]];return r}if("object"==typeof e&&"function"==typeof e.toJSON)return o(e.toJSON());switch(typeof e){case"boolean":case"symbol":case"number":return e.toString();case"bigint":return BigInt(e).toString();case"string":return JSON.stringify(e);case"object":{const t=Object.keys(e);return t.sort(),"{ "+t.map((t=>`${o(t)}: ${o(e[t])}`)).join(", ")+" }"}}return"[ COULD NOT SERIALIZE ]"}function a(e,t){return e&&e.code===t}function s(e,t,r){{const i=[];if(r){if("message"in r||"code"in r||"name"in r)throw new Error(`value will overwrite populated values: ${o(r)}`);for(const e in r){const t=r[e];i.push(e+"="+o(t))}}i.push(`code=${t}`),i.push(`version=${n.version}`),i.length&&(e+=" ("+i.join(", ")+")")}let a;switch(t){case"INVALID_ARGUMENT":a=new TypeError(e);break;case"NUMERIC_FAULT":case"BUFFER_OVERRUN":a=new RangeError(e);break;default:a=new Error(e)}return(0,i.defineProperties)(a,{code:t}),r&&Object.assign(a,r),a}function u(e,t,r,n){if(!e)throw s(t,r,n)}t.isError=a,t.isCallException=function(e){return a(e,"CALL_EXCEPTION")},t.makeError=s,t.assert=u,t.assertArgument=function(e,t,r,n){u(e,t,"INVALID_ARGUMENT",{argument:r,value:n})},t.assertArgumentCount=function(e,t,r){null==r&&(r=""),r&&(r=": "+r),u(e>=t,"missing arguemnt"+r,"MISSING_ARGUMENT",{count:e,expectedCount:t}),u(e<=t,"too many arguemnts"+r,"UNEXPECTED_ARGUMENT",{count:e,expectedCount:t})};const c=["NFD","NFC","NFKD","NFKC"].reduce(((e,t)=>{try{if("test"!=="test".normalize(t))throw new Error("bad");if("NFD"===t){const e=String.fromCharCode(233).normalize("NFD");if(e!==String.fromCharCode(101,769))throw new Error("broken")}e.push(t)}catch(e){}return e}),[]);t.assertNormalize=function(e){u(c.indexOf(e)>=0,"platform missing String.prototype.normalize","UNSUPPORTED_OPERATION",{operation:"String.prototype.normalize",info:{form:e}})},t.assertPrivate=function(e,t,r){if(null==r&&(r=""),e!==t){let e=r,t="new";r&&(e+=".",t+=" "+r),u(!1,`private constructor; use ${e}from* methods`,"UNSUPPORTED_OPERATION",{operation:t})}}},52203:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EventPayload=void 0;const n=r(39290);t.EventPayload=class{filter;emitter;#Ze;constructor(e,t,r){this.#Ze=t,(0,n.defineProperties)(this,{emitter:e,filter:r})}async removeListener(){null!=this.#Ze&&await this.emitter.off(this.filter,this.#Ze)}}},93654:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FetchResponse=t.FetchRequest=t.FetchCancelSignal=void 0;const n=r(42946),i=r(86239),o=r(21766),a=r(39290),s=r(82119),u=r(30997);let c=u.getUrl;const l=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),f=new RegExp("^ipfs://(ipfs/)?(.*)$","i");let h=!1;async function d(e,t){try{const t=e.match(l);if(!t)throw new Error("invalid data");return new w(200,"OK",{"content-type":t[1]||"text/plain"},t[2]?(0,n.decodeBase64)(t[3]):(r=t[3],(0,s.toUtf8Bytes)(r.replace(/%([0-9a-f][0-9a-f])/gi,((e,t)=>String.fromCharCode(parseInt(t,16)))))))}catch(t){return new w(599,"BAD REQUEST (invalid data: URI)",{},null,new v(e))}var r}function p(e){return async function(t,r){try{const r=t.match(f);if(!r)throw new Error("invalid link");return new v(`${e}${r[2]}`)}catch(e){return new w(599,"BAD REQUEST (invalid IPFS URI)",{},null,new v(t))}}}const m={data:d,ipfs:p("https://gateway.ipfs.io/ipfs/")},y=new WeakMap;class g{#Ye;#$e;constructor(e){this.#Ye=[],this.#$e=!1,y.set(e,(()=>{if(!this.#$e){this.#$e=!0;for(const e of this.#Ye)setTimeout((()=>{e()}),0);this.#Ye=[]}}))}addListener(e){(0,o.assert)(!this.#$e,"singal already cancelled","UNSUPPORTED_OPERATION",{operation:"fetchCancelSignal.addCancelListener"}),this.#Ye.push(e)}get cancelled(){return this.#$e}checkSignal(){(0,o.assert)(!this.cancelled,"cancelled","CANCELLED",{})}}function b(e){if(null==e)throw new Error("missing signal; should not happen");return e.checkSignal(),e}t.FetchCancelSignal=g;class v{#et;#tt;#rt;#nt;#it;#ot;#at;#st;#ut;#ct;#lt;#ft;#ht;#dt;get url(){return this.#ot}set url(e){this.#ot=String(e)}get body(){return null==this.#at?null:new Uint8Array(this.#at)}set body(e){if(null==e)this.#at=void 0,this.#st=void 0;else if("string"==typeof e)this.#at=(0,s.toUtf8Bytes)(e),this.#st="text/plain";else if(e instanceof Uint8Array)this.#at=e,this.#st="application/octet-stream";else{if("object"!=typeof e)throw new Error("invalid body");this.#at=(0,s.toUtf8Bytes)(JSON.stringify(e)),this.#st="application/json"}}hasBody(){return null!=this.#at}get method(){return this.#nt?this.#nt:this.hasBody()?"POST":"GET"}set method(e){null==e&&(e=""),this.#nt=String(e).toUpperCase()}get headers(){const e=Object.assign({},this.#rt);return this.#ut&&(e.authorization=`Basic ${(0,n.encodeBase64)((0,s.toUtf8Bytes)(this.#ut))}`),this.allowGzip&&(e["accept-encoding"]="gzip"),null==e["content-type"]&&this.#st&&(e["content-type"]=this.#st),this.body&&(e["content-length"]=String(this.body.length)),e}getHeader(e){return this.headers[e.toLowerCase()]}setHeader(e,t){this.#rt[String(e).toLowerCase()]=String(t)}clearHeaders(){this.#rt={}}[Symbol.iterator](){const e=this.headers,t=Object.keys(e);let r=0;return{next:()=>{if(r=0,"timeout must be non-zero","timeout",e),this.#it=e}get preflightFunc(){return this.#ct||null}set preflightFunc(e){this.#ct=e}get processFunc(){return this.#lt||null}set processFunc(e){this.#lt=e}get retryFunc(){return this.#ft||null}set retryFunc(e){this.#ft=e}constructor(e){this.#ot=String(e),this.#et=!1,this.#tt=!0,this.#rt={},this.#nt="",this.#it=3e5,this.#dt={slotInterval:250,maxAttempts:12}}toString(){return``}setThrottleParams(e){null!=e.slotInterval&&(this.#dt.slotInterval=e.slotInterval),null!=e.maxAttempts&&(this.#dt.maxAttempts=e.maxAttempts)}async#pt(e,t,r,n,i){if(e>=this.#dt.maxAttempts)return i.makeServerError("exceeded maximum retry limit");(0,o.assert)(A()<=t,"timeout","TIMEOUT",{operation:"request.send",reason:"timeout",request:n}),r>0&&await function(e){return new Promise((t=>setTimeout(t,e)))}(r);let a=this.clone();const s=(a.url.split(":")[0]||"").toLowerCase();if(s in m){const e=await m[s](a.url,b(n.#ht));if(e instanceof w){let t=e;if(this.processFunc){b(n.#ht);try{t=await this.processFunc(a,t)}catch(e){null!=e.throttle&&"number"==typeof e.stall||t.makeServerError("error in post-processing function",e).assertOk()}}return t}a=e}this.preflightFunc&&(a=await this.preflightFunc(a));const u=await c(a,b(n.#ht));let l=new w(u.statusCode,u.statusMessage,u.headers,u.body,n);if(301===l.statusCode||302===l.statusCode){try{const r=l.headers.location||"";return a.redirect(r).#pt(e+1,t,0,n,l)}catch(e){}return l}if(429===l.statusCode&&(null==this.retryFunc||await this.retryFunc(a,l,e))){const r=l.headers["retry-after"];let i=this.#dt.slotInterval*Math.trunc(Math.random()*Math.pow(2,e));return"string"==typeof r&&r.match(/^[1-9][0-9]*$/)&&(i=parseInt(r)),a.clone().#pt(e+1,t,i,n,l)}if(this.processFunc){b(n.#ht);try{l=await this.processFunc(a,l)}catch(r){null!=r.throttle&&"number"==typeof r.stall||l.makeServerError("error in post-processing function",r).assertOk();let i=this.#dt.slotInterval*Math.trunc(Math.random()*Math.pow(2,e));return r.stall>=0&&(i=r.stall),a.clone().#pt(e+1,t,i,n,l)}}return l}send(){return(0,o.assert)(null==this.#ht,"request already sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.send"}),this.#ht=new g(this),this.#pt(0,A()+this.timeout,0,this,new w(0,"",{},null,this))}cancel(){(0,o.assert)(null!=this.#ht,"request has not been sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.cancel"});const e=y.get(this);if(!e)throw new Error("missing signal; should not happen");e()}redirect(e){const t=this.url.split(":")[0].toLowerCase(),r=e.split(":")[0].toLowerCase();(0,o.assert)("GET"===this.method&&("https"!==t||"http"!==r)&&e.match(/^https?:/),"unsupported redirect","UNSUPPORTED_OPERATION",{operation:`redirect(${this.method} ${JSON.stringify(this.url)} => ${JSON.stringify(e)})`});const n=new v(e);return n.method="GET",n.allowGzip=this.allowGzip,n.timeout=this.timeout,n.#rt=Object.assign({},this.#rt),this.#at&&(n.#at=new Uint8Array(this.#at)),n.#st=this.#st,n}clone(){const e=new v(this.url);return e.#nt=this.#nt,this.#at&&(e.#at=this.#at),e.#st=this.#st,e.#rt=Object.assign({},this.#rt),e.#ut=this.#ut,this.allowGzip&&(e.allowGzip=!0),e.timeout=this.timeout,this.allowInsecureAuthentication&&(e.allowInsecureAuthentication=!0),e.#ct=this.#ct,e.#lt=this.#lt,e.#ft=this.#ft,e}static lockConfig(){h=!0}static getGateway(e){return m[e.toLowerCase()]||null}static registerGateway(e,t){if("http"===(e=e.toLowerCase())||"https"===e)throw new Error(`cannot intercept ${e}; use registerGetUrl`);if(h)throw new Error("gateways locked");m[e]=t}static registerGetUrl(e){if(h)throw new Error("gateways locked");c=e}static createDataGateway(){return d}static createIpfsGatewayFunc(e){return p(e)}}t.FetchRequest=v;class w{#mt;#yt;#rt;#at;#$;#gt;toString(){return``}get statusCode(){return this.#mt}get statusMessage(){return this.#yt}get headers(){return Object.assign({},this.#rt)}get body(){return null==this.#at?null:new Uint8Array(this.#at)}get bodyText(){try{return null==this.#at?"":(0,s.toUtf8String)(this.#at)}catch(e){(0,o.assert)(!1,"response body is not valid UTF-8 data","UNSUPPORTED_OPERATION",{operation:"bodyText",info:{response:this}})}}get bodyJson(){try{return JSON.parse(this.bodyText)}catch(e){(0,o.assert)(!1,"response body is not valid JSON","UNSUPPORTED_OPERATION",{operation:"bodyJson",info:{response:this}})}}[Symbol.iterator](){const e=this.headers,t=Object.keys(e);let r=0;return{next:()=>{if(r(e[t.toLowerCase()]=String(r[t]),e)),{}),this.#at=null==n?null:new Uint8Array(n),this.#$=i||null,this.#gt={message:""}}makeServerError(e,t){let r;r=e?`CLIENT ESCALATED SERVER ERROR (${this.statusCode} ${this.statusMessage}; ${e})`:`CLIENT ESCALATED SERVER ERROR (${e=`${this.statusCode} ${this.statusMessage}`})`;const n=new w(599,r,this.headers,this.body,this.#$||void 0);return n.#gt={message:e,error:t},n}throwThrottleError(e,t){null==t?t=-1:(0,o.assertArgument)(Number.isInteger(t)&&t>=0,"invalid stall timeout","stall",t);const r=new Error(e||"throttling requests");throw(0,a.defineProperties)(r,{stall:t,throttle:!0}),r}getHeader(e){return this.headers[e.toLowerCase()]}hasBody(){return null!=this.#at}get request(){return this.#$}ok(){return""===this.#gt.message&&this.statusCode>=200&&this.statusCode<300}assertOk(){if(this.ok())return;let{message:e,error:t}=this.#gt;""===e&&(e=`server response ${this.statusCode} ${this.statusMessage}`),(0,o.assert)(!1,e,"SERVER_ERROR",{request:this.request||"unknown request",response:this,error:t})}}function A(){return(new Date).getTime()}t.FetchResponse=w},76539:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FixedNumber=void 0;const n=r(86239),i=r(21766),o=r(90358),a=r(39290),s=BigInt(-1),u=BigInt(0),c=BigInt(1),l=BigInt(5),f={};let h="0000";for(;h.length<80;)h+=h;function d(e){let t=h;for(;t.length=-t&&eu?(0,o.fromTwos)((0,o.mask)(e,n),n):-(0,o.fromTwos)((0,o.mask)(-e,n),n)}else{const t=c<=0&&enull==o[e]?r:((0,i.assertArgument)(typeof o[e]===t,"invalid fixed format ("+e+" not "+t+")","format."+e,o[e]),o[e]);t=a("signed","boolean",t),r=a("width","number",r),n=a("decimals","number",n)}(0,i.assertArgument)(r%8==0,"invalid FixedNumber width (not byte aligned)","format.width",r),(0,i.assertArgument)(n<=80,"invalid FixedNumber decimals (too large)","format.decimals",n);return{signed:t,width:r,decimals:n,name:(t?"":"u")+"fixed"+String(r)+"x"+String(n)}}class y{format;#bt;#vt;#wt;_value;constructor(e,t,r){(0,i.assertPrivate)(e,f,"FixedNumber"),this.#vt=t,this.#bt=r;const n=function(e,t){let r="";e0?r*=d(n):n<0&&(t*=d(-n)),tr?-1:0}eq(e){return 0===this.cmp(e)}lt(e){return this.cmp(e)<0}lte(e){return this.cmp(e)<=0}gt(e){return this.cmp(e)>0}gte(e){return this.cmp(e)>=0}floor(){let e=this.#vt;return this.#vtu&&(e+=this.#wt-c),e=this.#vt/this.#wt*this.#wt,this.#St(e,"ceiling")}round(e){if(null==e&&(e=0),e>=this.decimals)return this;const t=this.decimals-e,r=l*d(t-1);let n=this.value+r;const i=d(t);return n=n/i*i,p(n,this.#bt,"round"),new y(f,n,this.#bt)}isZero(){return this.#vt===u}isNegative(){return this.#vt0){const t=d(s);(0,i.assert)(a%t===u,"value loses precision for format","NUMERIC_FAULT",{operation:"fromValue",fault:"underflow",value:e}),a/=t}else s<0&&(a*=d(-s));return p(a,n,"fromValue"),new y(f,a,n)}static fromString(e,t){const r=e.match(/^(-?)([0-9]*)\.?([0-9]*)$/);(0,i.assertArgument)(r&&r[2].length+r[3].length>0,"invalid FixedNumber string value","value",e);const n=m(t);let o=r[2]||"0",a=r[3]||"";for(;a.length{l.once("response",(n=>{const i=n.statusCode||0,o=n.statusMessage||"",a=Object.keys(n.headers||{}).reduce(((e,t)=>{let r=n.headers[t]||"";return Array.isArray(r)&&(r=r.join(", ")),e[t]=r,e}),{});let u=null;n.on("data",(e=>{if(t)try{t.checkSignal()}catch(e){return r(e)}if(null==u)u=e;else{const t=new Uint8Array(u.length+e.length);t.set(u,0),t.set(e,u.length),u=t}})),n.on("end",(()=>{"gzip"===a["content-encoding"]&&u&&(u=(0,c.getBytes)((0,s.gunzipSync)(u))),e({statusCode:i,statusMessage:o,headers:a,body:u})})),n.on("error",(e=>{e.response={statusCode:i,statusMessage:o,headers:a,body:u},r(e)}))})),l.on("error",(e=>{r(e)}))}))}},42120:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toUtf8String=t.toUtf8CodePoints=t.toUtf8Bytes=t.parseUnits=t.formatUnits=t.parseEther=t.formatEther=t.encodeRlp=t.decodeRlp=t.defineProperties=t.resolveProperties=t.toQuantity=t.toBeArray=t.toBeHex=t.toNumber=t.toBigInt=t.getUint=t.getNumber=t.getBigInt=t.mask=t.toTwos=t.fromTwos=t.FixedNumber=t.FetchCancelSignal=t.FetchResponse=t.FetchRequest=t.EventPayload=t.makeError=t.assertNormalize=t.assertPrivate=t.assertArgumentCount=t.assertArgument=t.assert=t.isError=t.isCallException=t.zeroPadBytes=t.zeroPadValue=t.stripZerosLeft=t.dataSlice=t.dataLength=t.concat=t.hexlify=t.isBytesLike=t.isHexString=t.getBytesCopy=t.getBytes=t.encodeBase64=t.decodeBase64=t.encodeBase58=t.decodeBase58=void 0,t.uuidV4=t.Utf8ErrorFuncs=void 0;var n=r(20349);Object.defineProperty(t,"decodeBase58",{enumerable:!0,get:function(){return n.decodeBase58}}),Object.defineProperty(t,"encodeBase58",{enumerable:!0,get:function(){return n.encodeBase58}});var i=r(42946);Object.defineProperty(t,"decodeBase64",{enumerable:!0,get:function(){return i.decodeBase64}}),Object.defineProperty(t,"encodeBase64",{enumerable:!0,get:function(){return i.encodeBase64}});var o=r(86239);Object.defineProperty(t,"getBytes",{enumerable:!0,get:function(){return o.getBytes}}),Object.defineProperty(t,"getBytesCopy",{enumerable:!0,get:function(){return o.getBytesCopy}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return o.isHexString}}),Object.defineProperty(t,"isBytesLike",{enumerable:!0,get:function(){return o.isBytesLike}}),Object.defineProperty(t,"hexlify",{enumerable:!0,get:function(){return o.hexlify}}),Object.defineProperty(t,"concat",{enumerable:!0,get:function(){return o.concat}}),Object.defineProperty(t,"dataLength",{enumerable:!0,get:function(){return o.dataLength}}),Object.defineProperty(t,"dataSlice",{enumerable:!0,get:function(){return o.dataSlice}}),Object.defineProperty(t,"stripZerosLeft",{enumerable:!0,get:function(){return o.stripZerosLeft}}),Object.defineProperty(t,"zeroPadValue",{enumerable:!0,get:function(){return o.zeroPadValue}}),Object.defineProperty(t,"zeroPadBytes",{enumerable:!0,get:function(){return o.zeroPadBytes}});var a=r(21766);Object.defineProperty(t,"isCallException",{enumerable:!0,get:function(){return a.isCallException}}),Object.defineProperty(t,"isError",{enumerable:!0,get:function(){return a.isError}}),Object.defineProperty(t,"assert",{enumerable:!0,get:function(){return a.assert}}),Object.defineProperty(t,"assertArgument",{enumerable:!0,get:function(){return a.assertArgument}}),Object.defineProperty(t,"assertArgumentCount",{enumerable:!0,get:function(){return a.assertArgumentCount}}),Object.defineProperty(t,"assertPrivate",{enumerable:!0,get:function(){return a.assertPrivate}}),Object.defineProperty(t,"assertNormalize",{enumerable:!0,get:function(){return a.assertNormalize}}),Object.defineProperty(t,"makeError",{enumerable:!0,get:function(){return a.makeError}});var s=r(52203);Object.defineProperty(t,"EventPayload",{enumerable:!0,get:function(){return s.EventPayload}});var u=r(93654);Object.defineProperty(t,"FetchRequest",{enumerable:!0,get:function(){return u.FetchRequest}}),Object.defineProperty(t,"FetchResponse",{enumerable:!0,get:function(){return u.FetchResponse}}),Object.defineProperty(t,"FetchCancelSignal",{enumerable:!0,get:function(){return u.FetchCancelSignal}});var c=r(76539);Object.defineProperty(t,"FixedNumber",{enumerable:!0,get:function(){return c.FixedNumber}});var l=r(90358);Object.defineProperty(t,"fromTwos",{enumerable:!0,get:function(){return l.fromTwos}}),Object.defineProperty(t,"toTwos",{enumerable:!0,get:function(){return l.toTwos}}),Object.defineProperty(t,"mask",{enumerable:!0,get:function(){return l.mask}}),Object.defineProperty(t,"getBigInt",{enumerable:!0,get:function(){return l.getBigInt}}),Object.defineProperty(t,"getNumber",{enumerable:!0,get:function(){return l.getNumber}}),Object.defineProperty(t,"getUint",{enumerable:!0,get:function(){return l.getUint}}),Object.defineProperty(t,"toBigInt",{enumerable:!0,get:function(){return l.toBigInt}}),Object.defineProperty(t,"toNumber",{enumerable:!0,get:function(){return l.toNumber}}),Object.defineProperty(t,"toBeHex",{enumerable:!0,get:function(){return l.toBeHex}}),Object.defineProperty(t,"toBeArray",{enumerable:!0,get:function(){return l.toBeArray}}),Object.defineProperty(t,"toQuantity",{enumerable:!0,get:function(){return l.toQuantity}});var f=r(39290);Object.defineProperty(t,"resolveProperties",{enumerable:!0,get:function(){return f.resolveProperties}}),Object.defineProperty(t,"defineProperties",{enumerable:!0,get:function(){return f.defineProperties}});var h=r(14978);Object.defineProperty(t,"decodeRlp",{enumerable:!0,get:function(){return h.decodeRlp}});var d=r(49122);Object.defineProperty(t,"encodeRlp",{enumerable:!0,get:function(){return d.encodeRlp}});var p=r(88680);Object.defineProperty(t,"formatEther",{enumerable:!0,get:function(){return p.formatEther}}),Object.defineProperty(t,"parseEther",{enumerable:!0,get:function(){return p.parseEther}}),Object.defineProperty(t,"formatUnits",{enumerable:!0,get:function(){return p.formatUnits}}),Object.defineProperty(t,"parseUnits",{enumerable:!0,get:function(){return p.parseUnits}});var m=r(82119);Object.defineProperty(t,"toUtf8Bytes",{enumerable:!0,get:function(){return m.toUtf8Bytes}}),Object.defineProperty(t,"toUtf8CodePoints",{enumerable:!0,get:function(){return m.toUtf8CodePoints}}),Object.defineProperty(t,"toUtf8String",{enumerable:!0,get:function(){return m.toUtf8String}}),Object.defineProperty(t,"Utf8ErrorFuncs",{enumerable:!0,get:function(){return m.Utf8ErrorFuncs}});var y=r(4824);Object.defineProperty(t,"uuidV4",{enumerable:!0,get:function(){return y.uuidV4}})},90358:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toQuantity=t.toBeArray=t.toBeHex=t.toNumber=t.getNumber=t.toBigInt=t.getUint=t.getBigInt=t.mask=t.toTwos=t.fromTwos=void 0;const n=r(86239),i=r(21766),o=BigInt(0),a=BigInt(1),s=9007199254740991;function u(e,t){switch(typeof e){case"bigint":return e;case"number":return(0,i.assertArgument)(Number.isInteger(e),"underflow",t||"value",e),(0,i.assertArgument)(e>=-s&&e<=s,"overflow",t||"value",e),BigInt(e);case"string":try{if(""===e)throw new Error("empty string");return"-"===e[0]&&"-"!==e[1]?-BigInt(e.substring(1)):BigInt(e)}catch(r){(0,i.assertArgument)(!1,`invalid BigNumberish string: ${r.message}`,t||"value",e)}}(0,i.assertArgument)(!1,"invalid BigNumberish value",t||"value",e)}function c(e,t){const r=u(e,t);return(0,i.assert)(r>=o,"unsigned value cannot be negative","NUMERIC_FAULT",{fault:"overflow",operation:"getUint",value:e}),r}t.fromTwos=function(e,t){const r=c(e,"value"),n=BigInt(h(t,"width"));if((0,i.assert)(r>>n===o,"overflow","NUMERIC_FAULT",{operation:"fromTwos",fault:"overflow",value:e}),r>>n-a){return-((~r&(a<>4],t+=l[15&r];return BigInt(t)}return u(e)}function h(e,t){switch(typeof e){case"bigint":return(0,i.assertArgument)(e>=-s&&e<=s,"overflow",t||"value",e),Number(e);case"number":return(0,i.assertArgument)(Number.isInteger(e),"underflow",t||"value",e),(0,i.assertArgument)(e>=-s&&e<=s,"overflow",t||"value",e),e;case"string":try{if(""===e)throw new Error("empty string");return h(BigInt(e),t)}catch(r){(0,i.assertArgument)(!1,`invalid numeric string: ${r.message}`,t||"value",e)}}(0,i.assertArgument)(!1,"invalid numeric value",t||"value",e)}function d(e){const t=c(e,"value");if(t===o)return new Uint8Array([]);let r=t.toString(16);r.length%2&&(r="0"+r);const n=new Uint8Array(r.length/2);for(let e=0;e=r.length,`value exceeds width (${n} bits)`,"NUMERIC_FAULT",{operation:"toBeHex",fault:"overflow",value:e});r.length<2*n;)r="0"+r}return"0x"+r},t.toBeArray=d,t.toQuantity=function(e){let t=(0,n.hexlify)((0,n.isBytesLike)(e)?e:d(e)).substring(2);for(;t.startsWith("0");)t=t.substring(1);return""===t&&(t="0"),"0x"+t}},39290:(e,t)=>{"use strict";function r(e,t,r){const n=t.split("|").map((e=>e.trim()));for(let r=0;rPromise.resolve(e[t]))))).reduce(((e,r,n)=>(e[t[n]]=r,e)),{})},t.defineProperties=function(e,t,n){for(let i in t){let o=t[i];const a=n?n[i]:null;a&&r(o,a,i),Object.defineProperty(e,i,{enumerable:!0,value:o,writable:!1})}}},14978:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeRlp=void 0;const n=r(86239),i=r(21766),o=r(86239);function a(e){let t=e.toString(16);for(;t.length<2;)t="0"+t;return"0x"+t}function s(e,t,r){let n=0;for(let i=0;i{(0,i.assert)(t<=e.length,"data short segment too short","BUFFER_OVERRUN",{buffer:e,length:e.length,offset:t})};if(e[t]>=248){const n=e[t]-247;r(t+1+n);const i=s(e,t+1,n);return r(t+1+n+i),u(e,t,t+1+n,n+i)}if(e[t]>=192){const n=e[t]-192;return r(t+1+n),u(e,t,t+1,n)}if(e[t]>=184){const i=e[t]-183;r(t+1+i);const o=s(e,t+1,i);r(t+1+i+o);return{consumed:1+i+o,result:(0,n.hexlify)(e.slice(t+1+i,t+1+i+o))}}if(e[t]>=128){const i=e[t]-128;r(t+1+i);return{consumed:1+i,result:(0,n.hexlify)(e.slice(t+1,t+1+i))}}return{consumed:1,result:a(e[t])}}t.decodeRlp=function(e){const t=(0,o.getBytes)(e,"data"),r=c(t,0);return(0,i.assertArgument)(r.consumed===t.length,"unexpected junk after rlp payload","data",e),r.result}},49122:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeRlp=void 0;const n=r(86239);function i(e){const t=[];for(;e;)t.unshift(255&e),e>>=8;return t}function o(e){if(Array.isArray(e)){let t=[];if(e.forEach((function(e){t=t.concat(o(e))})),t.length<=55)return t.unshift(192+t.length),t;const r=i(t.length);return r.unshift(247+r.length),r.concat(t)}const t=Array.prototype.slice.call((0,n.getBytes)(e,"object"));if(1===t.length&&t[0]<=127)return t;if(t.length<=55)return t.unshift(128+t.length),t;const r=i(t.length);return r.unshift(183+r.length),r.concat(t)}const a="0123456789abcdef";t.encodeRlp=function(e){let t="0x";for(const r of o(e))t+=a[r>>4],t+=a[15&r];return t}},88680:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseEther=t.formatEther=t.parseUnits=t.formatUnits=void 0;const n=r(21766),i=r(76539),o=r(90358),a=["wei","kwei","mwei","gwei","szabo","finney","ether"];function s(e,t){let r=18;if("string"==typeof t){const e=a.indexOf(t);(0,n.assertArgument)(e>=0,"invalid unit","unit",t),r=3*e}else null!=t&&(r=(0,o.getNumber)(t,"unit"));return i.FixedNumber.fromValue(e,r,{decimals:r}).toString()}function u(e,t){(0,n.assertArgument)("string"==typeof e,"value must be a string","value",e);let r=18;if("string"==typeof t){const e=a.indexOf(t);(0,n.assertArgument)(e>=0,"invalid unit","unit",t),r=3*e}else null!=t&&(r=(0,o.getNumber)(t,"unit"));return i.FixedNumber.fromString(e,{decimals:r}).value}t.formatUnits=s,t.parseUnits=u,t.formatEther=function(e){return s(e,18)},t.parseEther=function(e){return u(e,18)}},82119:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toUtf8CodePoints=t.toUtf8String=t.toUtf8Bytes=t.Utf8ErrorFuncs=void 0;const n=r(86239),i=r(21766);function o(e,t,r,n,i){if("BAD_PREFIX"===e||"UNEXPECTED_CONTINUE"===e){let e=0;for(let n=t+1;n>6==2;n++)e++;return e}return"OVERRUN"===e?r.length-t-1:0}function a(e,r){null==r&&(r=t.Utf8ErrorFuncs.error);const i=(0,n.getBytes)(e,"bytes"),o=[];let a=0;for(;a>7==0){o.push(e);continue}let t=null,n=null;if(192==(224&e))t=1,n=127;else if(224==(240&e))t=2,n=2047;else{if(240!=(248&e)){a+=r(128==(192&e)?"UNEXPECTED_CONTINUE":"BAD_PREFIX",a-1,i,o);continue}t=3,n=65535}if(a-1+t>=i.length){a+=r("OVERRUN",a-1,i,o);continue}let s=e&(1<<8-t-1)-1;for(let e=0;e1114111?a+=r("OUT_OF_RANGE",a-1-t,i,o,s):s>=55296&&s<=57343?a+=r("UTF16_SURROGATE",a-1-t,i,o,s):s<=n?a+=r("OVERLONG",a-1-t,i,o,s):o.push(s))}return o}function s(e,t){null!=t&&((0,i.assertNormalize)(t),e=e.normalize(t));let r=[];for(let t=0;t>6|192),r.push(63&n|128);else if(55296==(64512&n)){t++;const o=e.charCodeAt(t);(0,i.assertArgument)(t>18|240),r.push(a>>12&63|128),r.push(a>>6&63|128),r.push(63&a|128)}else r.push(n>>12|224),r.push(n>>6&63|128),r.push(63&n|128)}return new Uint8Array(r)}t.Utf8ErrorFuncs=Object.freeze({error:function(e,t,r,n,o){(0,i.assertArgument)(!1,`invalid codepoint at offset ${t}; ${e}`,"bytes",r)},ignore:o,replace:function(e,t,r,n,a){return"OVERLONG"===e?((0,i.assertArgument)("number"==typeof a,"invalid bad code point for replacement","badCodepoint",a),n.push(a),0):(n.push(65533),o(e,t,r))}}),t.toUtf8Bytes=s,t.toUtf8String=function(e,t){return a(e,t).map((e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e))))).join("")},t.toUtf8CodePoints=function(e,t){return a(s(e,t))}},4824:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.uuidV4=void 0;const n=r(86239);t.uuidV4=function(e){const t=(0,n.getBytes)(e,"randomBytes");t[6]=15&t[6]|64,t[8]=63&t[8]|128;const r=(0,n.hexlify)(t);return[r.substring(2,10),r.substring(10,14),r.substring(14,18),r.substring(18,22),r.substring(22,34)].join("-")}},85662:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseWallet=void 0;const n=r(45475),i=r(98336),o=r(4878),a=r(2290),s=r(42120);class u extends o.AbstractSigner{address;#Tt;constructor(e,t){super(t),(0,s.assertArgument)(e&&"function"==typeof e.sign,"invalid private key","privateKey","[ REDACTED ]"),this.#Tt=e;const r=(0,a.computeAddress)(this.signingKey.publicKey);(0,s.defineProperties)(this,{address:r})}get signingKey(){return this.#Tt}get privateKey(){return this.signingKey.privateKey}async getAddress(){return this.address}connect(e){return new u(this.#Tt,e)}async signTransaction(e){const{to:t,from:r}=await(0,s.resolveProperties)({to:e.to?(0,n.resolveAddress)(e.to,this.provider):void 0,from:e.from?(0,n.resolveAddress)(e.from,this.provider):void 0});null!=t&&(e.to=t),null!=r&&(e.from=r),null!=e.from&&((0,s.assertArgument)((0,n.getAddress)(e.from)===this.address,"transaction from address mismatch","tx.from",e.from),delete e.from);const i=a.Transaction.from(e);return i.signature=this.signingKey.sign(i.unsignedHash),i.serialized}async signMessage(e){return this.signMessageSync(e)}signMessageSync(e){return this.signingKey.sign((0,i.hashMessage)(e)).serialized}async signTypedData(e,t,r){const n=await i.TypedDataEncoder.resolveNames(e,t,r,(async e=>{(0,s.assert)(null!=this.provider,"cannot resolve ENS names without a provider","UNSUPPORTED_OPERATION",{operation:"resolveName",info:{name:e}});const t=await this.provider.resolveName(e);return(0,s.assert)(null!=t,"unconfigured ENS name","UNCONFIGURED_NAME",{value:e}),t}));return this.signingKey.sign(i.TypedDataEncoder.hash(n.domain,t,n.value)).serialized}}t.BaseWallet=u},90483:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getIndexedAccountPath=t.getAccountPath=t.HDNodeVoidWallet=t.HDNodeWallet=t.defaultPath=void 0;const n=r(96965),i=r(4878),o=r(2290),a=r(42120),s=r(10847),u=r(85662),c=r(40075),l=r(10630);t.defaultPath="m/44'/60'/0'/0/0";const f=new Uint8Array([66,105,116,99,111,105,110,32,115,101,101,100]),h=2147483648,d=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141");function p(e,t){let r="";for(;e;)r="0123456789abcdef"[e%16]+r,e=Math.trunc(e/16);for(;r.length<2*t;)r="0"+r;return"0x"+r}function m(e){const t=(0,a.getBytes)(e),r=(0,a.dataSlice)((0,n.sha256)((0,n.sha256)(t)),0,4),i=(0,a.concat)([t,r]);return(0,a.encodeBase58)(i)}const y={};function g(e,t,r,i){const o=new Uint8Array(37);e&h?((0,a.assert)(null!=i,"cannot derive child of neutered node","UNSUPPORTED_OPERATION",{operation:"deriveChild"}),o.set((0,a.getBytes)(i),1)):o.set((0,a.getBytes)(r));for(let t=24;t>=0;t-=8)o[33+(t>>3)]=e>>24-t&255;const s=(0,a.getBytes)((0,n.computeHmac)("sha512",t,o));return{IL:s.slice(0,32),IR:s.slice(32)}}function b(e,t){const r=t.split("/");(0,a.assertArgument)(r.length>0&&("m"===r[0]||e.depth>0),"invalid path","path",t),"m"===r[0]&&r.shift();let n=e;for(let e=0;e=16&&r.length<=64,"invalid seed","seed","[REDACTED]");const i=(0,a.getBytes)((0,n.computeHmac)("sha512",f,r)),o=new n.SigningKey((0,a.hexlify)(i.slice(0,32)));return new v(y,o,"0x00000000",(0,a.hexlify)(i.slice(32)),"m",0,0,t,null)}static fromExtendedKey(e){const t=(0,a.toBeArray)((0,a.decodeBase58)(e));(0,a.assertArgument)(82===t.length||m(t.slice(0,78))===e,"invalid extended key","extendedKey","[ REDACTED ]");const r=t[4],i=(0,a.hexlify)(t.slice(5,9)),s=parseInt((0,a.hexlify)(t.slice(9,13)).substring(2),16),u=(0,a.hexlify)(t.slice(13,45)),c=t.slice(45,78);switch((0,a.hexlify)(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":{const e=(0,a.hexlify)(c);return new w(y,(0,o.computeAddress)(e),e,i,u,null,s,r,null)}case"0x0488ade4":case"0x04358394 ":if(0!==c[0])break;return new v(y,new n.SigningKey(c.slice(1)),i,u,null,s,r,null,null)}(0,a.assertArgument)(!1,"invalid extended key prefix","extendedKey","[ REDACTED ]")}static createRandom(e,r,i){null==e&&(e=""),null==r&&(r=t.defaultPath),null==i&&(i=s.LangEn.wordlist());const o=c.Mnemonic.fromEntropy((0,n.randomBytes)(16),e,i);return v.#Pt(o.computeSeed(),o).derivePath(r)}static fromMnemonic(e,r){return r||(r=t.defaultPath),v.#Pt(e.computeSeed(),e).derivePath(r)}static fromPhrase(e,r,n,i){null==r&&(r=""),null==n&&(n=t.defaultPath),null==i&&(i=s.LangEn.wordlist());const o=c.Mnemonic.fromPhrase(e,r,i);return v.#Pt(o.computeSeed(),o).derivePath(n)}static fromSeed(e){return v.#Pt(e,null)}}t.HDNodeWallet=v;class w extends i.VoidSigner{publicKey;fingerprint;parentFingerprint;chainCode;path;index;depth;constructor(e,t,r,i,o,s,u,c,l){super(t,l),(0,a.assertPrivate)(e,y,"HDNodeVoidWallet"),(0,a.defineProperties)(this,{publicKey:r});const f=(0,a.dataSlice)((0,n.ripemd160)((0,n.sha256)(r)),0,4);(0,a.defineProperties)(this,{publicKey:r,fingerprint:f,parentFingerprint:i,chainCode:o,path:s,index:u,depth:c})}connect(e){return new w(y,this.address,this.publicKey,this.parentFingerprint,this.chainCode,this.path,this.index,this.depth,e)}get extendedKey(){return(0,a.assert)(this.depth<256,"Depth too deep","UNSUPPORTED_OPERATION",{operation:"extendedKey"}),m((0,a.concat)(["0x0488B21E",p(this.depth,1),this.parentFingerprint,p(this.index,4),this.chainCode,this.publicKey]))}hasPath(){return null!=this.path}deriveChild(e){const t=(0,a.getNumber)(e,"index");(0,a.assertArgument)(t<=4294967295,"invalid index","index",t);let r=this.path;r&&(r+="/"+(2147483647&t),t&h&&(r+="'"));const{IR:i,IL:s}=g(t,this.chainCode,this.publicKey,null),u=n.SigningKey.addPoints(s,this.publicKey,!0),c=(0,o.computeAddress)(u);return new w(y,c,u,this.fingerprint,(0,a.hexlify)(i),r,t,this.depth+1,this.provider)}derivePath(e){return b(this,e)}}t.HDNodeVoidWallet=w,t.getAccountPath=function(e){const t=(0,a.getNumber)(e,"index");return(0,a.assertArgument)(t>=0&&t=0&&t{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Wallet=t.Mnemonic=t.encryptKeystoreJsonSync=t.encryptKeystoreJson=t.decryptKeystoreJson=t.decryptKeystoreJsonSync=t.isKeystoreJson=t.decryptCrowdsaleJson=t.isCrowdsaleJson=t.HDNodeVoidWallet=t.HDNodeWallet=t.getAccountPath=t.defaultPath=t.BaseWallet=void 0;var n=r(85662);Object.defineProperty(t,"BaseWallet",{enumerable:!0,get:function(){return n.BaseWallet}});var i=r(90483);Object.defineProperty(t,"defaultPath",{enumerable:!0,get:function(){return i.defaultPath}}),Object.defineProperty(t,"getAccountPath",{enumerable:!0,get:function(){return i.getAccountPath}}),Object.defineProperty(t,"HDNodeWallet",{enumerable:!0,get:function(){return i.HDNodeWallet}}),Object.defineProperty(t,"HDNodeVoidWallet",{enumerable:!0,get:function(){return i.HDNodeVoidWallet}});var o=r(78668);Object.defineProperty(t,"isCrowdsaleJson",{enumerable:!0,get:function(){return o.isCrowdsaleJson}}),Object.defineProperty(t,"decryptCrowdsaleJson",{enumerable:!0,get:function(){return o.decryptCrowdsaleJson}});var a=r(10630);Object.defineProperty(t,"isKeystoreJson",{enumerable:!0,get:function(){return a.isKeystoreJson}}),Object.defineProperty(t,"decryptKeystoreJsonSync",{enumerable:!0,get:function(){return a.decryptKeystoreJsonSync}}),Object.defineProperty(t,"decryptKeystoreJson",{enumerable:!0,get:function(){return a.decryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJson",{enumerable:!0,get:function(){return a.encryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJsonSync",{enumerable:!0,get:function(){return a.encryptKeystoreJsonSync}});var s=r(40075);Object.defineProperty(t,"Mnemonic",{enumerable:!0,get:function(){return s.Mnemonic}});var u=r(6389);Object.defineProperty(t,"Wallet",{enumerable:!0,get:function(){return u.Wallet}})},78668:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decryptCrowdsaleJson=t.isCrowdsaleJson=void 0;const n=r(93260),i=r(45475),o=r(96965),a=r(98336),s=r(42120),u=r(57668);t.isCrowdsaleJson=function(e){try{if(JSON.parse(e).encseed)return!0}catch(e){}return!1},t.decryptCrowdsaleJson=function(e,t){const r=JSON.parse(e),c=(0,u.getPassword)(t),l=(0,i.getAddress)((0,u.spelunk)(r,"ethaddr:string!")),f=(0,u.looseArrayify)((0,u.spelunk)(r,"encseed:string!"));(0,s.assertArgument)(f&&f.length%16==0,"invalid encseed","json",e);const h=(0,s.getBytes)((0,o.pbkdf2)(c,c,2e3,32,"sha256")).slice(0,16),d=f.slice(0,16),p=f.slice(16),m=new n.CBC(h,d),y=(0,n.pkcs7Strip)((0,s.getBytes)(m.decrypt(p)));let g="";for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encryptKeystoreJson=t.encryptKeystoreJsonSync=t.decryptKeystoreJson=t.decryptKeystoreJsonSync=t.isKeystoreJson=void 0;const n=r(93260),i=r(45475),o=r(96965),a=r(2290),s=r(42120),u=r(57668),c=r(79406),l="m/44'/60'/0'/0/0";function f(e,t){const r=(0,s.getBytes)(t),c=(0,u.spelunk)(e,"crypto.ciphertext:data!"),f=(0,s.hexlify)((0,o.keccak256)((0,s.concat)([r.slice(16,32),c]))).substring(2);(0,s.assertArgument)(f===(0,u.spelunk)(e,"crypto.mac:string!").toLowerCase(),"incorrect password","password","[ REDACTED ]");const h=function(e,t,r){if("aes-128-ctr"===(0,u.spelunk)(e,"crypto.cipher:string")){const i=(0,u.spelunk)(e,"crypto.cipherparams.iv:data!"),o=new n.CTR(t,i);return(0,s.hexlify)(o.decrypt(r))}(0,s.assert)(!1,"unsupported cipher","UNSUPPORTED_OPERATION",{operation:"decrypt"})}(e,r.slice(0,16),c),d=(0,a.computeAddress)(h);if(e.address){let t=e.address.toLowerCase();t.startsWith("0x")||(t="0x"+t),(0,s.assertArgument)((0,i.getAddress)(t)===d,"keystore address/privateKey mismatch","address",e.address)}const p={address:d,privateKey:h};if("0.1"===(0,u.spelunk)(e,"x-ethers.version:string")){const t=r.slice(32,64),i=(0,u.spelunk)(e,"x-ethers.mnemonicCiphertext:data!"),o=(0,u.spelunk)(e,"x-ethers.mnemonicCounter:data!"),a=new n.CTR(t,o);p.mnemonic={path:(0,u.spelunk)(e,"x-ethers.path:string")||l,locale:(0,u.spelunk)(e,"x-ethers.locale:string")||"en",entropy:(0,s.hexlify)((0,s.getBytes)(a.decrypt(i)))}}return p}function h(e){const t=(0,u.spelunk)(e,"crypto.kdf:string");if(t&&"string"==typeof t){if("scrypt"===t.toLowerCase()){const r=(0,u.spelunk)(e,"crypto.kdfparams.salt:data!"),n=(0,u.spelunk)(e,"crypto.kdfparams.n:int!"),i=(0,u.spelunk)(e,"crypto.kdfparams.r:int!"),o=(0,u.spelunk)(e,"crypto.kdfparams.p:int!");(0,s.assertArgument)(n>0&&0==(n&n-1),"invalid kdf.N","kdf.N",n),(0,s.assertArgument)(i>0&&o>0,"invalid kdf","kdf",t);const a=(0,u.spelunk)(e,"crypto.kdfparams.dklen:int!");return(0,s.assertArgument)(32===a,"invalid kdf.dklen","kdf.dflen",a),{name:"scrypt",salt:r,N:n,r:i,p:o,dkLen:64}}if("pbkdf2"===t.toLowerCase()){const t=(0,u.spelunk)(e,"crypto.kdfparams.salt:data!"),r=(0,u.spelunk)(e,"crypto.kdfparams.prf:string!"),n=r.split("-").pop();(0,s.assertArgument)("sha256"===n||"sha512"===n,"invalid kdf.pdf","kdf.pdf",r);const i=(0,u.spelunk)(e,"crypto.kdfparams.c:int!"),o=(0,u.spelunk)(e,"crypto.kdfparams.dklen:int!");return(0,s.assertArgument)(32===o,"invalid kdf.dklen","kdf.dklen",o),{name:"pbkdf2",salt:t,count:i,dkLen:o,algorithm:n}}}(0,s.assertArgument)(!1,"unsupported key-derivation function","kdf",t)}function d(e){return new Promise((t=>{setTimeout((()=>{t()}),e)}))}function p(e){const t=null!=e.salt?(0,s.getBytes)(e.salt,"options.salt"):(0,o.randomBytes)(32);let r=1<<17,n=8,i=1;return e.scrypt&&(e.scrypt.N&&(r=e.scrypt.N),e.scrypt.r&&(n=e.scrypt.r),e.scrypt.p&&(i=e.scrypt.p)),(0,s.assertArgument)("number"==typeof r&&r>0&&Number.isSafeInteger(r)&&(BigInt(r)&BigInt(r-1))===BigInt(0),"invalid scrypt N parameter","options.N",r),(0,s.assertArgument)("number"==typeof n&&n>0&&Number.isSafeInteger(n),"invalid scrypt r parameter","options.r",n),(0,s.assertArgument)("number"==typeof i&&i>0&&Number.isSafeInteger(i),"invalid scrypt p parameter","options.p",i),{name:"scrypt",dkLen:32,salt:t,N:r,r:n,p:i}}function m(e,t,r,i){const a=(0,s.getBytes)(r.privateKey,"privateKey"),f=null!=i.iv?(0,s.getBytes)(i.iv,"options.iv"):(0,o.randomBytes)(16);(0,s.assertArgument)(16===f.length,"invalid options.iv length","options.iv",i.iv);const h=null!=i.uuid?(0,s.getBytes)(i.uuid,"options.uuid"):(0,o.randomBytes)(16);(0,s.assertArgument)(16===h.length,"invalid options.uuid length","options.uuid",i.iv);const d=e.slice(0,16),p=e.slice(16,32),m=new n.CTR(d,f),y=(0,s.getBytes)(m.encrypt(a)),g=(0,o.keccak256)((0,s.concat)([p,y])),b={address:r.address.substring(2).toLowerCase(),id:(0,s.uuidV4)(h),version:3,Crypto:{cipher:"aes-128-ctr",cipherparams:{iv:(0,s.hexlify)(f).substring(2)},ciphertext:(0,s.hexlify)(y).substring(2),kdf:"scrypt",kdfparams:{salt:(0,s.hexlify)(t.salt).substring(2),n:t.N,dklen:32,p:t.p,r:t.r},mac:g.substring(2)}};if(r.mnemonic){const t=null!=i.client?i.client:`ethers/${c.version}`,a=r.mnemonic.path||l,f=r.mnemonic.locale||"en",h=e.slice(32,64),d=(0,s.getBytes)(r.mnemonic.entropy,"account.mnemonic.entropy"),p=(0,o.randomBytes)(16),m=new n.CTR(h,p),y=(0,s.getBytes)(m.encrypt(d)),g=new Date,v="UTC--"+(g.getUTCFullYear()+"-"+(0,u.zpad)(g.getUTCMonth()+1,2)+"-"+(0,u.zpad)(g.getUTCDate(),2)+"T"+(0,u.zpad)(g.getUTCHours(),2)+"-"+(0,u.zpad)(g.getUTCMinutes(),2)+"-"+(0,u.zpad)(g.getUTCSeconds(),2)+".0Z")+"--"+b.address;b["x-ethers"]={client:t,gethFilename:v,path:a,locale:f,mnemonicCounter:(0,s.hexlify)(p).substring(2),mnemonicCiphertext:(0,s.hexlify)(y).substring(2),version:"0.1"}}return JSON.stringify(b)}t.isKeystoreJson=function(e){try{const t=JSON.parse(e);if(3===(null!=t.version?parseInt(t.version):0))return!0}catch(e){}return!1},t.decryptKeystoreJsonSync=function(e,t){const r=JSON.parse(e),n=(0,u.getPassword)(t),i=h(r);if("pbkdf2"===i.name){const{salt:e,count:t,dkLen:a,algorithm:s}=i;return f(r,(0,o.pbkdf2)(n,e,t,a,s))}(0,s.assert)("scrypt"===i.name,"cannot be reached","UNKNOWN_ERROR",{params:i});const{salt:a,N:c,r:l,p:d,dkLen:p}=i;return f(r,(0,o.scryptSync)(n,a,c,l,d,p))},t.decryptKeystoreJson=async function(e,t,r){const n=JSON.parse(e),i=(0,u.getPassword)(t),a=h(n);if("pbkdf2"===a.name){r&&(r(0),await d(0));const{salt:e,count:t,dkLen:s,algorithm:u}=a,c=(0,o.pbkdf2)(i,e,t,s,u);return r&&(r(1),await d(0)),f(n,c)}(0,s.assert)("scrypt"===a.name,"cannot be reached","UNKNOWN_ERROR",{params:a});const{salt:c,N:l,r:p,p:m,dkLen:y}=a;return f(n,await(0,o.scrypt)(i,c,l,p,m,y,r))},t.encryptKeystoreJsonSync=function(e,t,r){null==r&&(r={});const n=(0,u.getPassword)(t),i=p(r),a=(0,o.scryptSync)(n,i.salt,i.N,i.r,i.p,64);return m((0,s.getBytes)(a),i,e,r)},t.encryptKeystoreJson=async function(e,t,r){null==r&&(r={});const n=(0,u.getPassword)(t),i=p(r),a=await(0,o.scrypt)(n,i.salt,i.N,i.r,i.p,64,r.progressCallback);return m((0,s.getBytes)(a),i,e,r)}},40075:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Mnemonic=void 0;const n=r(96965),i=r(42120),o=r(10847);function a(e){return(1<=12&&r.length<=24,"invalid mnemonic length","mnemonic","[ REDACTED ]");const s=new Uint8Array(Math.ceil(11*r.length/8));let u=0;for(let e=0;e=0,`invalid mnemonic word at index ${e}`,"mnemonic","[ REDACTED ]");for(let e=0;e<11;e++)n&1<<10-e&&(s[u>>3]|=1<<7-u%8),u++}const c=32*r.length/3,l=a(r.length/3),f=(0,i.getBytes)((0,n.sha256)(s.slice(0,c/8)))[0]&l;return(0,i.assertArgument)(f===(s[s.length-1]&l),"invalid mnemonic checksum","mnemonic","[ REDACTED ]"),(0,i.hexlify)(s.slice(0,c/8))}function u(e,t){(0,i.assertArgument)(e.length%4==0&&e.length>=16&&e.length<=32,"invalid entropy size","entropy","[ REDACTED ]"),null==t&&(t=o.LangEn.wordlist());const r=[0];let s=11;for(let t=0;t8?(r[r.length-1]<<=8,r[r.length-1]|=e[t],s-=8):(r[r.length-1]<<=s,r[r.length-1]|=e[t]>>8-s,r.push(e[t]&((1<<8-s)-1&255)),s+=3);const u=e.length/4,c=parseInt((0,n.sha256)(e).substring(2,4),16)&a(u);return r[r.length-1]<<=u,r[r.length-1]|=c>>8-u,t.join(r.map((e=>t.getWord(e))))}const c={};class l{phrase;password;wordlist;entropy;constructor(e,t,r,n,a){null==n&&(n=""),null==a&&(a=o.LangEn.wordlist()),(0,i.assertPrivate)(e,c,"Mnemonic"),(0,i.defineProperties)(this,{phrase:r,password:n,wordlist:a,entropy:t})}computeSeed(){const e=(0,i.toUtf8Bytes)("mnemonic"+this.password,"NFKD");return(0,n.pbkdf2)((0,i.toUtf8Bytes)(this.phrase,"NFKD"),e,2048,64,"sha512")}static fromPhrase(e,t,r){const n=s(e,r);return e=u((0,i.getBytes)(n),r),new l(c,n,e,t,r)}static fromEntropy(e,t,r){const n=(0,i.getBytes)(e,"entropy"),o=u(n,r);return new l(c,(0,i.hexlify)(n),o,t,r)}static entropyToPhrase(e,t){return u((0,i.getBytes)(e,"entropy"),t)}static phraseToEntropy(e,t){return s(e,t)}static isValidMnemonic(e,t){try{return s(e,t),!0}catch(e){}return!1}}t.Mnemonic=l},57668:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.spelunk=t.getPassword=t.zpad=t.looseArrayify=void 0;const n=r(42120);function i(e){return"string"!=typeof e||e.startsWith("0x")||(e="0x"+e),(0,n.getBytesCopy)(e)}t.looseArrayify=i,t.zpad=function(e,t){for(e=String(e);e.length{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Wallet=void 0;const n=r(96965),i=r(42120),o=r(85662),a=r(90483),s=r(78668),u=r(10630),c=r(40075);function l(e){return new Promise((t=>{setTimeout((()=>{t()}),e)}))}class f extends o.BaseWallet{constructor(e,t){"string"!=typeof e||e.startsWith("0x")||(e="0x"+e),super("string"==typeof e?new n.SigningKey(e):e,t)}connect(e){return new f(this.signingKey,e)}async encrypt(e,t){const r={address:this.address,privateKey:this.privateKey};return await(0,u.encryptKeystoreJson)(r,e,{progressCallback:t})}encryptSync(e){const t={address:this.address,privateKey:this.privateKey};return(0,u.encryptKeystoreJsonSync)(t,e)}static#It(e){if((0,i.assertArgument)(e,"invalid JSON wallet","json","[ REDACTED ]"),"mnemonic"in e&&e.mnemonic&&"en"===e.mnemonic.locale){const t=c.Mnemonic.fromEntropy(e.mnemonic.entropy),r=a.HDNodeWallet.fromMnemonic(t,e.mnemonic.path);if(r.address===e.address&&r.privateKey===e.privateKey)return r;console.log("WARNING: JSON mismatch address/privateKey != mnemonic; fallback onto private key")}const t=new f(e.privateKey);return(0,i.assertArgument)(t.address===e.address,"address/privateKey mismatch","json","[ REDACTED ]"),t}static async fromEncryptedJson(e,t,r){let n=null;return(0,u.isKeystoreJson)(e)?n=await(0,u.decryptKeystoreJson)(e,t,r):(0,s.isCrowdsaleJson)(e)&&(r&&(r(0),await l(0)),n=(0,s.decryptCrowdsaleJson)(e,t),r&&(r(1),await l(0))),f.#It(n)}static fromEncryptedJsonSync(e,t){let r=null;return(0,u.isKeystoreJson)(e)?r=(0,u.decryptKeystoreJsonSync)(e,t):(0,s.isCrowdsaleJson)(e)?r=(0,s.decryptCrowdsaleJson)(e,t):(0,i.assertArgument)(!1,"invalid JSON wallet","json","[ REDACTED ]"),f.#It(r)}static createRandom(e){const t=a.HDNodeWallet.createRandom();return e?t.connect(e):t}static fromPhrase(e,t){const r=a.HDNodeWallet.fromPhrase(e);return t?r.connect(t):r}}t.Wallet=f},75033:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBits=void 0;t.decodeBits=function(e,t){const r=(1<=e;){const t=i>>o-e;i&=(1<{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeOwl=t.decode=void 0;const n=r(42120),i=" !#$%&'()*+,-./<=>?@[]^_`{|}~",o=/^[a-z]*$/i;function a(e,t){let r=97;return e.reduce(((e,n)=>(n===t?r++:n.match(o)?e.push(String.fromCharCode(r)+n):(r=97,e.push(n)),e)),[])}function s(e,t){for(let r=i.length-1;r>=0;r--)e=e.split(i[r]).join(t.substring(2*r,2*r+2));const r=[],n=e.replace(/(:|([0-9])|([A-Z][a-z]*))/g,((e,t,n,i)=>{if(n)for(let e=parseInt(n);e>=0;e--)r.push(";");else r.push(t.toLowerCase());return""}));if(n)throw new Error(`leftovers: ${JSON.stringify(n)}`);return a(a(r,";"),":")}t.decode=s,t.decodeOwl=function(e){return(0,n.assertArgument)("0"===e[0],"unsupported auwl data","data",e),s(e.substring(1+2*i.length),e.substring(1,1+2*i.length))}},84603:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeOwlA=void 0;const n=r(42120),i=r(75033),o=r(82629);t.decodeOwlA=function(e,t){let r=(0,o.decodeOwl)(e).join(",");return t.split(/,/g).forEach((e=>{const o=e.match(/^([a-z]*)([0-9]+)([0-9])(.*)$/);(0,n.assertArgument)(null!==o,"internal error parsing accents","accents",t);let a=0;const s=(0,i.decodeBits)(parseInt(o[3]),o[4]),u=parseInt(o[2]),c=new RegExp(`([${o[1]}])`,"g");r=r.replace(c,((e,t)=>(0===--s[a]&&(t=String.fromCharCode(t.charCodeAt(0),u),a++),t)))})),r.split(",")}},60659:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wordlists=t.WordlistOwlA=t.WordlistOwl=t.LangEn=t.Wordlist=void 0;var n=r(51208);Object.defineProperty(t,"Wordlist",{enumerable:!0,get:function(){return n.Wordlist}});var i=r(10847);Object.defineProperty(t,"LangEn",{enumerable:!0,get:function(){return i.LangEn}});var o=r(21978);Object.defineProperty(t,"WordlistOwl",{enumerable:!0,get:function(){return o.WordlistOwl}});var a=r(99766);Object.defineProperty(t,"WordlistOwlA",{enumerable:!0,get:function(){return a.WordlistOwlA}});var s=r(84311);Object.defineProperty(t,"wordlists",{enumerable:!0,get:function(){return s.wordlists}})},8838:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangCz=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("cz","0itatkastcenaovo$taouleraeki&chor*teci%enbalodaeladet'!Chn=0Di#%E%^1Resa2Rese3CeT'#0EjKohol0Pu)%0A&sDul#Ekdo)Ke)Ti#Ul|3}aOgan%0FaltI$@tPi,%TmaTronom0LasL{i#Ol0Tobus4Yl:B#}R'?TaUb_U/!U^U+Ur!Xer2A^v#Ambo,An#AtrEp)Ike)KoLohOnzOskevUn{#Usin#Z^Zy2Bl.Bn|})D _D#D'aF{Jar(Kv?LdokLvaN^NkrRzaTikVolZola3D+tL.T'#0Ukot:PartRev&3DrDu+J/JnLaLerLkemLn?N.Nn(N'#NtrumNzZ(2O&2KolivUv!4It_N(0Dn(Ke)KrPot0Ak~AlIkRkot2Kli$a:L-oRe[T_Tum1E,1B!a}'#Cib_Fic Fla%KlKr{Mokr!PreseRbyS#T-tiv3Kob,zKt|O^P]mSkSp+jV`]Vo/2AhaOuhoUhopis1Es0BroByt-C@t}ut DnesH+dHo^H,JemJn?Kl`KolaKtAzeDolObn(OgerieOzdSn(T Z(2B@}'noD-HaH'#S SnoT(0Oj?Or>2Nam :9O]gOnomie0EktronIpsa0AilIseO%P!ie2Izo^O/aOpejOs2EjEn%K<)Kymo0Ike)0FR&S]Zky3StOhOup(T!Ub.U/o)0AtO)Yz0IsOjivoOut0Bl.Boj}DinyDl!Dno)D|Jn(KejLin#L#LubMo+N [No,%RalR^RizontRkoRliv>RmonRn.RoskopR$voSpo^St.T'(U[UfUp!Us#V<2Ad[An?Av(Az^Bo+kD.D]D(N-Ob#Oma^OtOu^Oz@St#Ub(Yz!2B@(B~D[KotMrS aSto)0Ozd2Bn(D,ntGie&M&Sterik:2Yl#3Ned2O&0Uze0Un a0F-%Fla%KasoOva%Sp-%Tern{Vali^Ve$N)rRmarkRoSanSnoT#VD+Dn!_HlanKotL@L oMn(NomP?S{erV Zd>Zero3NakNdyNo/Sk,Sto)Trn?Zva3En|1Gurt5R):Bar{B_Bin{}&D{Did]HanJakJu)KaoKtusLam aLhotyLibrLn(Me,MkolivM&Ni[lNoeNtB#BlihaBylaC*rH=J@>KosKtejlLapsLe^LizeLoMandoMe)MikMn!aMo,MpasMun aN!N%ptNd?N>NfeseNgresN.NkursN)ktNzervaPan>PieP~Pr'#Rb_R-tSt#T_T+)T*lUk!Up_&Us-Uz]VbojZaZMe+cMivoOcanOkOni#Op OupaOv#T-Uh`]Up?Ut(Vin#Y/+Yp)Y$alYt2Dlan#FrJn(KlaLaj^Li/L#Lom{Ltu,NaPodivuRtRzV`]:B,d<})nDn(IkKom>M_aMpaN'#S?SoStu,Tin#V.3B#CkdyD@Dn?D'#Dv.G@^GieG,%H%Hk(H~KtvarNo/odNtil#P@#Pid]T`]T>TmoTokruhVhartV a%Vobok3B,}ot#DojedDsk(H'.Jav>L-M{#NieN#No+umStop`T.T|5Bi$aDivodGi#GopedKal aK{Mc|P!aPu/RdSosTrU^lUhU#Usk!V>3Tiv(1Cer&CiferMpSkSt,%0I%2RaRi#S.:DamD]Gi$rHagonJ{-J _J< aKakK'?Kr_aL[L.L|Lv?Min#Nd+NkoRn(SakrSkotSopu$T?Tri#Tur aZan>ZivoZl Zur#2Lo[0}anikD a%D'.LasaL*nNtol#TlaTo^TrZe,3G,%H~Hu+K.KrofonL@>Lim{rL(Mi#Nc'&Ni[rNom{Nul(S#StrX|2Ad(HaH'.OkS!Uv 1I/Ohem0BilCn(D_#Dl [HylaKroL-ulaM@t#Nar/aNoklN$rumNt|NzunSazSkytStTiva%T<#Ty#U/aUdr(Zai#Z-Zol2AmKevTvolaZ{Zut(0T _1DrcF]nL!MieN?S{Ta%ZeumZi#nt3Sliv>0Da:B*r!}yt!Da%Dbyt-DhozDobroDpisHlasHn!Hodi+H,d Iv aJedn*Ji$oJm=K]n Kon>Krm LevoMaz!Mluv Nom{rOkoOpakO$roP`!PevnoPln P~Pos+dPr(oRod RubyRy/]S` S-!S+poSt!TolikV@-Vr/VzdR&Ru[RysSahSluhaS)r!UvVazVin VodVyk+Yv!_Z<0AsElEn Hl` Ho)H,&It~0BojByt}odCiz Ebr!Esl!Evzd!EzvaH`%Hod J{JinudKazK*p LivLu#Ml#Oln(P`PisPl=PLivoLu[Mf+tMls-N@#Ni#N&N|N$voNtof+Pri#Rke)RodieR)Ru#Ry[Se#Siv aSt_#T@tTro&V*kZnehtZ*r-3C#DagogJs-K]LotonNal)Ndr-NzeRiskopRoStr(Tar^T?Tro+jVn.Xeso3Ani$aHaJav?K+KnikL.Ln(Lul#Nze)Pe)S!_Sto+Tev&Vn?V'ar2A%n)Ak!Am@Ane)A$i#At Avid]AzE/Em@oEn)EsEtivoEv_Iv!N NoO/aOd.Om[OutUkYn2Bav Byt}odC Ctiv>D!D%n Deps!Dh+dDiv Dkl`Dman DnikDo[Dpo,D,zD$!aDvodDzimEzieHan#Hnut#H'S*d SpoluS)vaSud-SypTahT#nT+skTom-T,vaTupaTvo,U#zUtoUzdroVahaVidlaVlakVozVr/V$!VykVzde/Zd,vZem-Zn!-ZAp<-AseAv^IncipKnoObud O%ntoOdejOfeseOh,Oj-tO]m Omi+Onik!Op`OrokOs[OtonOut-OvazS#v#St@Udk(UtV-VohOvodTruh0Actvo0Ber)}DlKav>Kl.Kr+LtMpaNcP@SaSin#St.T|Ty#3Rami^SkT_::C-}otDia%Dn?DonFtGbyKe)K'.M@oMp*/NdeRa/R aS'&StrTo+$Zan%Zid]3Ag|Ak%CeptDaktMizd!Mo)N #Rdin#San#T_ Z[Z@?0Or0H|1B,n#CeseD`]Dim@tD]Hn!Jm=Ke,K)Kun^KvojeM@oNoRvisS` Sho,SkokSl!St,SuvSyp!T[T.Tk!T~Trv!VerZ&m2O^R~0FonLn?R#Rot-RupTua%1AfandrAliskoAnz@AutEptikIcaL`[L@?LoLuzO[O#nOroRip)RzUp.V(Vr&0Abi#Adid]An.A$Avn(Ed|Ep>EvaEz.IbI&Izn?OnOup-OvoU/UhaUn%Up#Za0A,gdE)&Il$voL*vaOgR`RkRt#Ut-Ysl0AdAhaOb0Bo)}aD'#KolP#TvaUbojUc Ud%UhlasUl`Um,kUp,vaUsedUtokUvis{0Al'&As _IsLavOd-Oj@>OluOnzOvn!P@StUb1An?Ar(aAti#Av[EhnoEz#OdolaO+kOpaOrnoOup!Ra/ResRh~RomRu&Ud&Upn?VolYk0Bj-tBtropy}arD(KnoNd!N=Rik!aR'.0AhAl$voEtrAt[Az-Is+It-Obo^Odid]Or#Rab2Kav#KotN-N'>P!Pk(R'(S_T(:B+t#Bu+H*nJemnoJfunJgaJ Jn(Kti#Mh+MponNc|N>NkerPe)V@.Z!_3}ni#HdyKut.LefonMno)Nd@%Ni$aNU/l Uhl?UsV!2DyH~H(Nd,Ri$aR&jZemsko0ArohOr[Rd(Rz2GrKev:0Oh(OzeR!R*s-RusYt'&0HoTiv(0Iv 3R` 1Edn!I$ M=0Az!_Lidn Lon Otv Roj 0I%I)Ov 0Yv`]0Av IfR*s 1Al Oln Oz'#3D,v ElEn.L.N!:GonL/aL*nNaN^lNil#RanRhanyR|1ElkuHod0Ova0DroGe)%J%Lbl*dL{rhL _LmocLry[Nk'Ran^RzeS_#SkrzeSn?SpoduS)Ter.Ver#3B,%}rDeoh,D.D+LaN?S{Tal aZeZ #0Ezd0L`Us0Aj#AkAs>EvoHk(IvN'#Oup!1Uc|Uk0DaDiv(Doz&kD$voJ@skyJ&JskoLantL[L LnoSk'#Zid]Z'&0Ravo1Ab>A%tAhA)Ba}o+kH!StvaTu+0Ad T*p Tup0Ip4Bav Br!}|D!D,Fot H+d!H~Hod H,d Hub Jasn J{Jm=K]p Kon!L-!Maz!Mez Miz{Mys+tNe/!Nik!Nut P`!Pl! P,v Pu$ Raz R'n!Rv!Sl' SokoS)v Su~Syp!Tas Tes!Tr! Vi~Vol!Vrh_Zdob Zn!0AduBud }op DJ{Ji$ K+p!K*p Lep Mez Mot!Mys+tNe/!Nik!Pl! Poj Ps!Raz S)v Su~Taj Temn Tk~Ujm=Val Ve+tVin Vol!Vrt!Zvon 0Av RusuUd|Yt-1A+#ArmaAtn(IvoOb RojVihYm`]0L@.ManM.Pt!Z`uZdola2At Lt~Lubo#Ot' Ru[0MaMn?0Emn 0Lam!Oum!R!#Umav#0AtoEh#O[OmO$Ozvyk0Ap|ArAt-IjeIz{Ocn Odr!Rzl.Ut|0AkAl(Am@!Ovu0B,z Tav Ub-Ufa+0Lod Omal RavaR( Rud#Rvu1A^An C`]N (NoOv&Y/l Zav(1I/aR! 0B'.Br0Ed~EnkuEs_aOnR!Uk'odYk","0x25f44555f4af25b51a711136e1c7d6e50ce9f8917d39d6b1f076b2bb4d2fac1a")}static wordlist(){return null==i&&(i=new o),i}}t.LangCz=o},10847:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangEn=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("en","0erleonalorenseinceregesticitStanvetearctssi#ch2Athck&tneLl0And#Il.yLeOutO=S|S%b/ra@SurdU'0Ce[Cid|CountCu'Hie=IdOu,-Qui*Ro[TT]T%T*[Tu$0AptDD-tD*[Ju,M.UltV<)Vi)0Rob-0FairF%dRaid0A(EEntRee0Ead0MRRp%tS!_rmBumCoholErtI&LLeyLowMo,O}PhaReadySoT Ways0A>urAz(gOngOuntU'd0Aly,Ch%Ci|G G!GryIm$K!Noun)Nu$O` Sw T&naTiqueXietyY1ArtOlogyPe?P!Pro=Ril1ChCt-EaEnaGueMMedM%MyOundR<+Re,Ri=RowTTefa@Ti,Tw%k0KPe@SaultSetSi,SumeThma0H!>OmTa{T&dT.udeTra@0Ct]D.Gu,NtTh%ToTumn0Era+OcadoOid0AkeA*AyEsomeFulKw?d0Is:ByChel%C#D+GL<)Lc#y~MbooN_{Ad!AftAmA}AshAt AwlAzyEamEd.EekEwI{etImeIspIt-OpO[Ou^OwdUci$UelUi'Umb!Un^UshYY,$2BeLtu*PPbo?dRiousRr|Rta(R=Sh]/omTe3C!:DMa+MpN)Ng R(gShUght WnY3AlBa>BrisCadeCemb CideCl(eC%a>C*a'ErF&'F(eFyG*eLayLiv M3AgramAlAm#dAryCeE'lEtFf G.$Gn.yLemmaNn NosaurRe@RtSag*eScov Sea'ShSmi[S%d Splay/<)V tVideV%)Zzy5Ct%Cum|G~Lph(Ma(Na>NkeyN%OrSeUb!Ve_ftAg#AmaA,-AwEamE[IftIllInkIpI=OpUmY2CkMbNeR(g/T^Ty1Arf1Nam-:G G!RlyRnR`Sily/Sy1HoOlogyOnomy0GeItUca>1F%t0G1GhtTh 2BowD E@r-EgSe0B?kBodyBra)Er+Ot]PloyPow Pty0Ab!A@DD![D%'EmyErgyF%)Ga+G(eH<)JoyLi,OughR-hRollSu*T Ti*TryVelope1Isode0U$Uip0AA'OdeOs]R%Upt0CapeSayS&)Ta>0Ern$H-s1Id&)IlOkeOl=1A@Amp!Ce[Ch<+C.eCludeCu'Ecu>Erci'Hau,Hib.I!I,ItOt-PM&'Mu}Pa@Po'Pro=Pul'0ChCludeComeC*a'DexD-a>Do%Du,ryFN Noc|PutQuirySSue0Em1Ory:CketGu?RZz3AlousAns~yWel9BInKeUr}yY5D+I)MpNg!Ni%Nk/:Ng?oo3EnEpT^upY3CkDD}yNdNgdomSsTT^&TeTt&Wi4EeIfeO{Ow:BBelB%Dd DyKeMpNgua+PtopR+T T(UghUndryVaWWnWsu.Y Zy3Ad AfArnA=Ctu*FtGG$G&dIsu*M#NdNg`NsOp?dSs#Tt Vel3ArB tyBr?yC&'FeFtGhtKeMbM.NkOnQuid/Tt!VeZ?d5AdAnB, C$CkG-NelyNgOpTt yUdUn+VeY$5CkyGga+Mb N?N^Xury3R-s:Ch(eDG-G}tIdIlInJ%KeMm$NNa+Nda>NgoNs]Nu$P!Rb!R^Rg(R(eRketRria+SkSs/ T^T i$ThTrixTt XimumZe3AdowAnAsu*AtCh<-D$DiaLodyLtMb M%yNt]NuRcyR+R.RryShSsa+T$Thod3Dd!DnightLk~]M-NdNimumN%Nu>Rac!Rr%S ySs/akeXXedXtu*5Bi!DelDifyMM|N.%NkeyN, N`OnR$ReRn(gSqu.oTh T]T%Unta(U'VeVie5ChFf(LeLtiplySc!SeumShroomS-/Tu$3Self/ yTh:I=MePk(Rrow/yT]Tu*3ArCkEdGati=G!@I` PhewR=/TTw%kUtr$V WsXt3CeGht5B!I'M(eeOd!Rm$R`SeTab!TeTh(gTi)VelW5C!?Mb R'T:K0EyJe@Li+Scu*S =Ta(Vious0CurEAyEa'Ed+U{UgUn+2EmEtIntL?LeLi)NdNyOlPul?Rt]S.]Ssib!/TatoTt yV tyWd W _@i)Ai'Ed-tEf Epa*Es|EttyEv|I)IdeIm?yIntI%.yIs#Iva>IzeOb!mO)[Odu)Of.OgramOje@Omo>OofOp tyOsp O>@OudOvide2Bl-Dd(g~LpL'Mpk(N^PilPpyR^a'R.yRpo'R'ShTZz!3Ramid:99Al.yAntumArt E,]I{ItIzO>:Bb.Cco#CeCkD?DioIlInI'~yMpN^NdomN+PidReTeTh V&WZ%3AdyAlAs#BelBuildC$lCei=CipeC%dCyc!Du)F!@F%mFu'G]G*tGul?Je@LaxLea'LiefLyMa(Memb M(dMo=Nd NewNtOp&PairPeatPla)P%tQui*ScueSemb!Si,Sour)Sp#'SultTi*T*atTurnUn]Ve$ViewW?d2Y`m0BBb#CeChDeD+F!GhtGidNgOtPp!SkTu$V$V 5AdA,BotBu,CketM<)OfOkieOmSeTa>UghUndU>Y$5Bb DeGLeNNwayR$:DDd!D}[FeIlLadLm#L#LtLu>MeMp!NdTisfyToshiU)Usa+VeY1A!AnA*Att E}HemeHoolI&)I[%sOrp]OutRapRe&RiptRub1AAr^As#AtC#dC*tCt]Cur.yEdEkGm|Le@~M(?Ni%N'Nt&)RiesRvi)Ss]Tt!TupV&_dowAftAllowA*EdEllEriffIeldIftI}IpIv O{OeOotOpOrtOuld O=RimpRugUff!Y0Bl(gCkDeE+GhtGnL|Lk~yLv Mil?Mp!N)NgR&/ Tua>XZe1A>Et^IIllInIrtUll0AbAmEepEnd I)IdeIghtImOgAyEakEelEmEpE*oI{IllIngO{Oma^O}OolOryO=Ra>gyReetRikeR#gRugg!Ud|UffUmb!Y!0Bje@Bm.BwayC)[ChDd&Ff G?G+,ItMm NNnyN'tP PplyP*meReRfa)R+Rpri'RroundR=ySpe@/a(1AllowAmpApArmE?EetIftImIngIt^Ord1MbolMptomRup/em:B!Ck!GIlL|LkNkPeR+tSk/eTtooXi3A^Am~NNGradeHoldOnP Set1BOng::Rd3Ar~ow9UUngU`:3BraRo9NeO","0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60")}static wordlist(){return null==i&&(i=new o),i}}t.LangEn=o},19321:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangEs=void 0;const n=r(99766);let i=null;class o extends n.WordlistOwlA{constructor(){super("es","0arertoiotadonoaRteirroenaNonaLsolocoiliaralaorrenadaChoN$n0A>Dom,EjaI!#Oga&O'Or#RazoR*Ue=U<0Ab Adem@CeLe%OmoRa!RozUn0DazD$GeLaM,#S,)T^0AlAnceA+EEl]`E`EstruzI.I<2ErU{U'0Af[nArO)Uc Uf_Ul:BaB^|eH@IleJ Lanz/c.LdeMbuN>Nd-oRb(>RnizR+Scu]S#nSu[Tal]T!@T*Tu%UlZ 3BeBid/=S SoSt@3|oEnNgo2An>OqueUsa2ABi`BoCaCi`DaDegaIn//!oLsaMb-{dNi#N}saiRdeRr SqueTeTinVe{Zal2AvoAzoEchaEveIl=In>IsaOcaOmaOnceO)UjaUs>U#2CeoCleE'EyFan{F.HoIt_L#Rbuj(l(+Sc TacaZ.:Bal=BezaBi`B[CaoDav!D,aErFeI{ImanJaJ.LLam Lc$L&Li{dLleLm/^LvoMaMb$Mel=Mi'Mp}c!Nd?Nel-gu+Nic-#N-.ObaOsPazPi%nPo)Pt Puch((b.RcelRe%Rg(i'RneRpe%R+R%SaS>S!oSpaS#rT^ceT_U{lUsaZo3Bol]D!D+Ld/eb_LoAmpuAnc]ApaAr]I>Is)IvoOqueOzaUle%Up 0Cl.EgoE=EnEr#F[G +M->NeN%P_sR>Rue]SneTaU{d2Am^AnA+AseAveI,)ImaInica2B_Cc~|i'Ci`CoDigoDoF_G!He)JinJoL/ch/eg$Lg Lin/l LmoLum`Mba)M!Mi{Mo&Mpr-deNej}g-oc!Nsej}t PaPi(az.Rba%RchoR&nR.(r!S!SmosS%2AneoAt!E Ec!Ei&EmaIaIm,Ip%IsisOmoOnicaOque%U&Uz2Ad+Ar#At+BoBr*| aEl=En#Er{Es%EvaId Lebr/p/#Mb_Mpl*N-e%O%P.Pul( R$Se'Sf[zVaVi'5BleCeL^Ming}N Ra&Rm*RAu%EchaOrO%U*UjoU^2B@CaGa%G.L$Lle#N&Rm(+Rtun(z SaTo2AcaA'AsaAtisAveIe%Il=IpeIsI#OG Gu!aJaMb_Ng}^Nr((mig('St?Yo5E>ElgaEr%ENgl-$Nt Pit!R S#V,?Zg :7Lo5A]:B$C$C[DoD+nG #GrimaGu`I>M!Mi`Mp --ch-gos%NzaPizRgoRvaStimaTaTexT*U_lV Zo3AlCc~|eC#rErG~Gumb_Ja'Ngu-#NaOnOp &S~TalT[VeY,{3B!%dB+C^D!Di EnzoGaG!oMaMi)M.Mp$NceN&Ne-go)N}t!`Qui&SoS%T!aT$T+2AgaAmaAn#AveEg En Ev Or Ov!Uv@2BoC~CoCu[GicaG+MbrizM}jaTe5|aC*G J}-esPaSt+ToZ:Ce%|oD!aD_Du+Est+F@G@GoIzL{dLe%Ll/oMaMboMutN>N&Nej Ng-iquiNj N}Re(f?Rg,Ri&RmolR+nR)sRzoSaSc aSivoT T!@TizTrizXimoY^Z^ca3|aDal]D$Du]J?]J^L,/.M^i-^NsajeN)NuRca&R,gueRi#SS.TaT!To&T+Zc]3E&ElEmb+G/Lag+Lit Ll.M}-!}im}u#OpeR SaS!@S?SmoTadTo5|?aC~DaDe=HoJ LdeL!Li'M,#Mi- c-ed-j-#NoRad(d!Re'R*R+Rs(%lScaStr TivoV!V?Zo5|oD EbleE]Er)Est[G_J!L/e%L%N&Nec(alRoScu=SeoSgoSicaS=:C C~D IpeRanj(izRr SalTalTivoTu[lUseaValVeVi{d3C$Ct G Goc$G+OnRv$ToUt+V V!a3|oDoEb]E#NezNoTi&Vel5Bleza|eMin(i(m()TaTic@Va#Ve]V$5BeCaCleoD?=DoE[EveEzLoM!oTr@:Sis0EC~E[In On!T TicaUes#1Ac~A&rAlBi%CaD,EjaGa'G@Gul=I,)Ig,Il]OQues%Uga0Ad@Cu+Ez'OT[0O'Ro1EjaU=1I&Ige'0En)0O':C#D_El]Gi`GoIsJ oLabr/>Le%Li&Lm/om/p NNalNi>Nt!-ue=PaPelP?]Que)R Rcel(edR*RoRpa&RqueR[foR)S SeoS~SoS%TaT$Tr@UsaU%VoYa<3A#nCa&C!a|oDalD*G IneL L{'Le/ig+LlejoLoLuc--s N.OnOrPi'Que'R(ch(d!Rez(f?Ri>Rl(mizEgun%Em$EnsaE|!oD^Eb=Er%Es#Lg/*Lm.LpoLrNd*N%P #Pet*PoN{PaP!oSaScaSt+T 5BiB^DoE{G*I&In/e%LoMboM^Ptu[TaTi`:Ba&B!B$BleC GazG[&L/&L!oL*Lm.L.Ls/#LudLv Mb-c~Ndi-e Ng_Ni{dN}#PoQueRdin()nSt_TanU`Xof.3Cc~CoC_#C%DGu*IsL=LvaMa`M?l-d-Re'Rg*S#T?:Ba>BiqueB]BuCoC#JoL L>L,#Ll/.Ma'Mb^Ng}quePaPe)P@P.Qu?l(deRe(if(je%RotR+R%TuajeU+ZaZ.3At+|oC]CnicaJa&J!Ji&L/efo'MaM^Mp=NazNd!N!NisNRmi'Rnur(+rSisSo+StigoT!aX#Z3B$Bu+nEmpoEn{Er[EPoR(.TanT!eTu=Za5Al]B?=C Ci'DoG/&M N}#P PeQueRaxR!oRm,%RneoRoRpe&R_RS!Xi>2AbajoAc#rA!Afi>AgoAjeAmoAnceA#AumaAz EbolEguaEin%EnEp EsIbuIgoIpaIs)IunfoOfeoOmpaOn>OpaO)OzoU>Ue'Ufa2B!@BoEr#MbaM^NelNic(bin(ismoR'T^:0Ic 9C!a0B[l0I{dIrIv!{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangFr=void 0;const n=r(99766);let i=null;class o extends n.WordlistOwlA{constructor(){super("fr","0erreleontiteurinueiriet cegeanseali medenel q)eniluxaus ch0Ais}And$Diqu E`#Ol*Ord Ou%rOy RasifReuv Ri,Rog RuptS_-SoluS'@UsifYss=0A@m+AjouAr+nCab]Cep,Clam Cola@Cro~eCu}ErbeHatHe,Idu]I Omp&Qu *R$y?Te'TifT)l0Ep&EquatHesifJec%fJug Mett!M* Op,Or Ouc*ResMab#S/-0Ou,Us,1Arm Chim+Er&Geb!G)I_ I?ntLeg Lia.Lou Lum O'd*PagaTesS' TicotT!Tu-0El>O?RiumRo-Ta^T_%fT* Trap 0Ba(eB .Da-Dib#G' Ro!Tom[Tru~e0A]Anc Ari-En*EreNqu>Rb>R`R$R^Rra.Ss(S%$Ta`#Te|T,+Udr>Vard 3Let&L>Lo&Nefi-R-|Rg Rl(eRmudaSa-Sog[Ta`Ur!3B $Cyc#Du#JouL/L(g)LlardNai!Olog+Ops+OtypeScuitS$Sto'iTu?Zar!2AfardAg)An~*Ess/tInd OndOqu Ous$2BardB(eI!I}Li@Nb$Nd*Nhe'Nif>NusRdu!R[T&Uc#Ue{Ug+Ul$Uqu(UrAveEbisE~eEuva.Ico]Iga@Ill/tIo~eI^O~u!Od Onz OusS^Ssu!U}U%$V=>V [Viar3D`#Intu!Les&Llu#Ndr>Ns' Ntr=Rc#Rebr=RiEr~ Ev=I_Iff!Ign$Im eIotLoru!OcolatOis*OI_tIgn ImatIva.O~eOna.Opor&2B=tBraCasFf!Gn Hesi$Iff Inc L eLibriLl(eLma,L$elMbatMed+Mm/@MpactNc tNdui!Nf>N.]Nno,Ns$[NtactNvexePa(P+Ra`Rbe|Rda.Rni~eRpusR!ctR&.Smi^Stu?T$U@Upu!Ura.U&|Uvr*Yo&2AbeA(&Ava&Ay$Eatu!Edi,E?{Eu}Evet&Ib]I Ist=I,eOi!Oqu Ota#Uci=UelYp,2Bi^E`l*Il]eIs(eIv!Lm( L%v Mu]Pi@Ra%fR<'3Anu!C#L(d!Ni^:Ign M>Ng N<'Uph(3Batt!Bi,Bord Brid But/tC= Cemb!Ch* Cid Clar Cor Cri!Cup]Da#Duc%fEsTa~ Tes,To' T!sTa%$U/>Ub#U-'U,Y_2Ag$Ap Es}Ibb]Oitu!2P +P#xeRab#Rc*3Nas%e:0Lou*0Ar,HarpeHel#La* LipUqu 1Fac Fec%fFig+FortFray Fusi$0Ali}Ar 2Ec,1Abor Arg*Ectr$Eg/tEph/tEveIgib#I%s?O.Ucid Ud 0B=]Bell*Bry$Er|@Issi$M_ O%$Ouvo*P e'Ploy Por,PriTo' Trav Um Vah*Viab#Voy Zy?0L+n0Aiss*Arg[At/tAu#Ic +I@m+I Ilog)I[Iso@ItapheO^ReuveRouv Uis/t0U !Uipe0Ig Osi$Re'Up%$0C=>Pad$Pe-P+g#Po*PritQuiv Say S_-S+uSor Ti?TomacTra@0Ag eA]An~eA%^E(d!Endo*Er[lH/olHi^Hn+Ir Off Oi#Onn/tO'd*R/.RoitU@0Phor+0Alu Asi$Enta`I@n-I,Olu%fOqu 1ActAg Auc Cel]Cit/tClusifCuPlor Po}Prim QuisT_sifTrai!Ul,:B#Bu#{Cet&Ci#Ctu!Ibl*Lai3AscoCe]C%fDe#Gu!Latu!Leta.L>eL#ulLm LouLtr N/c N*O#R?Ssu!X 2A* Am?As^At&'E|E~eE'Exi$Oc$O!Uctu Ui@Uvi=2L+Nd +Ngib#Nta(eRc Rg $Rmu]Rtu[Ssi#Ud!Ug eU`]Ulu!Urmi2Agi#AiC]RafeV!2A-AiveIs}ObeOi!Or+{2Lfe'M?Nf]R.R`#Udr$Uff!UlotUp`#Urm/dUt&2Ad)lAffi%A(eAndApp(AtuitAv*EnatIffu!Il]Imp Ogn Ond Ot&OupeUg U% Uy e2EpardErr>I@Im|veIta!Sta%f3Mnas&Rostat:Bitu@Cho*L&Me|NgarN[t$RicotRm$+Rp$Sard3LiumMato?RbeRiss$Rm(eR$Si,U!{3B n BouLar/tStoi!V 5MardMma.Mo.[N['Nor N&{R@Riz$Rlo.Rm$eRrib#U#{Us<5BlotI#{Ma(Mb#Mi@Mo'R]3Dro?lG+[M[Pno<:2Yl#2Nor U/e4Lici&Lusi$0A.Bib I,M_ReelRi,0O]2Oi!Res<:GuarIll*MbeNv>Rd(Ug U[Velot3Tab#T$UdiU[s<9Ind!N~ Ng]Ue'UissifUrn=Vi=Y|Ye{5Bi]Ge?ntNiorP$Ris&S%-Te{V_i#:Yak7M$oOs^:BelBi=Bo' C CtoVaboVo*3Ctu!G=G Gu?SsiveTt!V>Xi^Zard3AseS,ThiumTi.Ttor=V!'5Gi^Inta(Is*MbricT +U UrdUt!UveY=5B+Ci@Cra%fE'Gub!Is/tM>eNai!NdiR$T,X){:Ch(eGas(G_taGi^Ig!Ill$In%_Ir+Is$Jor Lax Lefi-Lhe'Li-L#t&MmouthNda,Niab#Nqu/tN&|N)lRath$Rb!R~/dRdiRi%?R^'Rr$R&]Scot&SsifT +lT>eTra^Udi!Ussa@UveXim=3Ch/tC$nuDa`#Dec(Di,DuUb#3Au]CrobeEt&Gn$Gr L+uLli$Mi^N-N =Nim=Nor Nu&Rac#Roi,Ssi#X&5Bi#D [El#{Ndi=Ni&'Nna+Not$eNst!Ntag[Nu?ntQ)'R-|Rsu!R% Te'TifU~eUf#Ul(Uss$Ut$Uv/t5L%p#Ni%$Ra`#Re[Rmu!Sc#SeumSic+nTa%$T T)l3Ria@R%l#S,eThi^:Ge'PpeRquoisRr Ta%$Ti$Tu!Ufra.U%^Vi!3Bu#{CtarFas&Ga%$Glig Goc>I.Rve{Ttoy Ur$eUtr$Veu3CheCkelTra&Ve|5B#CifCt'[Ir-'IToi!Urr*Uve|Va&'Vemb!Vi-5A.Anc I!Isib#M oP%=Q)Tri%f:0E*Jec%fLig Sc'S v Stac#T_*T' 0Casi$Cup E/Tob!Troy Tup]Ulai!0E'Or/t1F_}Fic>Fr*0Ive1Se|S`l$2Fac%fIv>0Bra.Ett!0Ct){Du]E!{Iri^1A#A^Er Ini$PortunPrim T Ti^1A.{An.Bi&D$n E`#G/eG)`Ifi-Ne?ntQ)T+0C`]MoPo,PyrusRadoxeR-l#ResIss$Iv!Lai!Lic>L#nLyg$eMma@Mp>Nct)lNd NeyR%^Si%$SZz#3Rami@:99AsarE!l#Es%$Ietu@It,O%_t:C(eC$,D+{G$d(I@'Is(L_%rLl$.Mas}Pi@Sa.Tis}Vag V(Y$n 3Ac%fAg*Ali}Anim Cevo*Ci,Clam Col,Cru,Cu]Cyc]Dig Dou,Fai!F#xeForm Fra(Fu.G=+nGi$Gla.Gul>I, Je,Jou La%fLev L+fMar^Me@MiPor,Prie5Che{M/-Mp!N-Nd(Se|S>Ta%fTorTu#U.U`#U#|U%[Y|?5B/BisCheEl#G){In Is<|S S%^3Th?:B]Bo,B!Co~eFariGesRcas?Rd(eT' Ug!nuUm$U,Uva.V/tV$n 1AlpelAnda#E]atEnarioEpt!HemaI_-Ind O!Ru%nUlp,1An-Cab#Ch Cou C!,Da%fDui!Ig['Jo'Lec%fMa(eMb]M_-M(=Na&'Nsib#N&n-Par Q)n-Re(R.ntR+{Rru!RumRvi-Sa?V*Vra.Xtup#3D =Ec#Eg Ff]G#Gn=L_-LiciumMp#Nc eNist!Ph$RopSmi^Tu 1I 3Ci=C#DiumIg[{LdatLe`Litu@Lub#Mb!M?`Mno]N@N.'N[t&No!Rc>R%rS+T%Rfa-Rica&R?n RpriC%#Il]L_tLism/L$n Mbo'Mi}Ngib#PisQu( Rd RifR%[SI$I^Itai!Iv s3AniumBa(Tic/t0A.I[UelU!0I#Op+:Car?Cc(Gab$dG)Ill/tInc!Is<|Lab#LiSe{Ss=S&3C&'Det&Get=Hicu#InardLo-Nd!diN Ng Ni?{Ntou{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangIt=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("it","0torea noica!iosorolotaleratelanena%oiadoencotivomai t ca%a0A]Bagl'Bin#E.Is(Oli!Rasi_Rog#0Cade!C[$Cus#E Roba+U 0Ag'Deb{DomeEgu#Eri!IpeOtt&Ul&1Fabi,Fe|Fis(F-n Oris`O(R~$0AveEn.E_,Ganc'I!It&OnismoR>*Rume Uzzo4AbardaA Bat)Ber#BoBumeCeCol>E|Ertu-OdePari!Pe^ Pogg'P)@Pun Ri,1Ab~AchideAgos+Ald~Anc'Atu-AzzoBit)Chiv'D{Eni,G[ GiSoTef%eZil*0Ciu|Col EpsiEtt>Fal I$O/Pir#P)Sagg'SeSolu Sur@TaT[u T%eT-|0Av>EismoOm>O$TesaTiv&Tor$Tr{Tua,0Sil'Str?Tis+To$moTun$0Anz#E!V[i!Vi(Volge!3IoS(Tos+Ttu U,VaVosa3C]FfaLg'LvaNdaNe_,Nig$Nzi=ReRli=Ta3Bi+CiDoR@S]Tan>T^$Zzo*2Acc'AdipoA`An}Avu-E.l/Eve|EzzaIgl?Il/n.Ind&Oc]*O@Onzi=Ul*U$2BboT+di$UffoVet+Vi,2Ass>In~O)2C]Dar@D%eE!n.G$meLl&Lm#Lo!Lpo(L^v#LzaMaMe+M`n@Mo@Mpu.rMuS+n.Ttu-V#2A.!Avat+E#Ede!Emo(Esci+E+Ice I=,IsiIt>OceO=}Os++Uc?,Us}2Ci!Cu*Gi$Ll#Po/R#!R(!R_Sci$S de:DoI$L`+Meri$Nie/N$(Nz&T#Van^Vve)3Bu|C[n'Ci(Cli$Col*C! D%#Fin{FormeG$Leg&Lfi$Lir'L+M[zaNot#Nt)Pos{Rapa+Riv&RogaScri|Ser Sider'Sume!Tersi_Vo 3Amet)Cemb!Ed)Fe(Ffu(Geri!Gi+,Luv'Nam>N=nziPin P*`Po*Rad&ReRo|RupoSag'Sc! Sf&Sge*Spos S+nzaSu`$ToVa$Vel Vide!Vor#5B*I}MoSaU(0An#B,`Es(I)O^_Oz'U*0Dem>Du)Erg?FasiO.}Tr&Zi`1A^.I*goI(d'O},Pu!0U#!0Ar'BaBo(EdeEmi+Ige!Met>OeOsi_Ran.0Ago$AmeAnimeAudi!CaEmp'Erc{Ib{Ig[.Is.!I OfagoOrt#O(Pan(P!s(S[zaSoTe(Tim&Ton?T)(Ult&0Il>N>Rus]To0ClideoRopa0A(Id[zaIt#Olu Viva:Bbr~Cc[daChi)L]Migl?Na,Nfa-NgoN+s`ReRfal/Ri$(R`]Sc?S (Sul*T%&ToVo*(3Bb!Co/DeG#LpaLt)Mmi=Nde!Nome$Rm[ R)R^,Ssu-S^_T+U@3AbaDuc?FaGur#LoNanzaNest-Ni!O!S},S>Ume2A]Cacc?Co(Der#Gl'La+Lc*!Lgo!Nd[.Net>N?N+=Rb{Rchet+Res+Rm~R='RoR.zzaRz&Sf#S(2A}s(A=Assi$A.l*Eccet+E=+Es]IgoOlli$OndeUga,Ut+2Ci/+Cs?Gg[.LmiT Ud'ZeboZzel/3CoLa^=L(Mel*Mm#NeN{!N='No^poRgo2Epar@Iacc'Isa0Al*LdaNep)Oc&Oiel*Or$OveR#RoAmmoAndeAtt&A_(Az?E}EggeIfoIll'O*RaR>Roge$2IeLude!0Bal*Bevu Boc]Bu MaO.siP~1IdeLandaOn>Rig#Ror&0Ol#O poTer>Titu Tr%e0Al?Er&:::Bb)Birin C}Cer#Cri`Cu=D@veGoMpoNcet+N.r=R@(RgaRingeSt-T[zaTi$TtugaVag=Vo)3Ga,Gge)MboN.zzaNzaOGl?G<.G)Iol~LafedeLg-@Lin.(Lsa$L Lumo!NaNc?N@r/Ngi&Nifes N=)Nov-NsardaN^deNubr'PpaR#=Rci!Ret+RmoRsup'Sche-Ssa?S^$Te-s(Tr>/T Ce=.DesimoDit&GaLassaLisLod?NingeNoN(/Rcur'R[daR*Schi$SeSse!S *Tal*To@T.!3Agol&CaCel'Che,C)boDol*E,Gl'!La$Li.MosaNe-,NiNo!Ri$R^l*Sce/SsivaS Sur&TezzaTig&T-T.n.4Emon>0Del*Dif~Du*Ga$G'LeLos(Nas.)N]Ndi=Ne+r'Ni,No $N(3Cch?NfaTi@5Bi,Ci_DoMeMi=Rd>R`,RvegeseSt-$T&Tiz?Ttur$Vel/5C,oL/Me)O_Tri!Vo/Z?,:Si0Bedi!BligoElis]L'O*So, 0Cas'B-EgaIss'<0Do(E!IceNi_)O!_,Ta1Er#In'IgiDel/D)Ri.RolisiTo2AceboAn&As`A+$E=r'2ChezzaDe)(DismoEs?Ggi&L[+Ligo$Ll%eLmoni.Lpet+L(Lt)=Lve!M%eMo@)N.Po*(Rfi@Ro(Rpo-R!R++SaSi^_Sses(Stul#Tass'Te!2AnzoAssiAt~Eclu(Ed~Efis(Egi#Elie_Eme!E$t&Epar#Es[zaE.s Eval(I`IncipeIv#Ob,`Ocu-Odur!OfumoOge|OlungaOmessaO$meOpos+O)gaO.(OvaUd[.Ug=Ur{0Iche1Bbl>D~Gil#G$LceL{Lsan.Nt&PazzoPil/Ro:99Ad)Al]saAsiE!/O+:C]l D@pp'D~,Dun#Ff~GazzoG'*Dur!Fas&F,s(For`Fug'G&Gett#Ghel*Lass#Lev#MaT)_Un'Bus Cc?CoDagg'De!D{!G{Ll'Mant>Mpe!Nz'Sol&SpoTan.Ton@Tu/Vesc'5BizzoBr~GaLli$Mi:B#Bbi&Bot#Go`Las(Ldatu-Lgem`Liv&LmoEtt)HedaHie=IarpaI[zaInde!IppoI)ppoI_*Ler&Odel/Olp{Ompar Onfor Opri!Or+Os(Mul#Nfon?Ngo*Nist)NoN.siNu(idePar'S`S ,Tu#2It+Ogatu-Ove$0Arr{Emor#En^ E-l@IlzoOnt&Ott#Uss#0Elli!Erv#O@0BbalzoBr'C]r(C?,Da,Ffi|G$Ld#L[M`NdaNe|Nnife)Pi!Ppe(P-Rge!Rpas(Rri(R(R.gg'R_l#Spi)S+T^,0AdaAl/Arge!A /Av[ Azzo/EcieEdi!EgRappoReg#Ridu*Rozz&Ru|Ucc&UfoUp[@0B[t)C](Do!Gger{GoL+$On&PerboPpor Rgel#R)g#Ssur)Tu-0Ag&EdeseEgl'El&Enu Ez?IluppoIs+Izze-Ol+Uot&:Bac]Bul#Cci&Citur$LeLis`$MpoVer=Vo/+Zza3CaCn>Lefo$Me-r'MpoMu N@Pog-foRagg'RoTan'To*Tuban.Z'Zzo<5Cc&L,r&L Mbo/MoNfoNsil/Paz'Po*g?PpaRbaRn&R)L,t+Lo)(Lut&L_/Mpa+Ng&N{(NoN+gg'Nve-Po!Ra$Rc#R?n.S}3Det+DovaDu Ge+,I]*Lc)Li=Llu LoceN#Ndemm?N RaceRba,Rgog=Rif~RoRru}Rt~,Sc~Ssil*S+,Te-$Tri=Tus 3Andan.B-n.C[daChingoCi=nzaDim&Gil?G< Go!LeL/$MiniNc{!O/Pe-Rgo/Ro*goRu,n S](S'5Cche)Fo*LuPpa","0x5c1362d88fd4cf614a96f3234941d29f7d37c08c5292fde03bf62c2db6ff7620")}static wordlist(){return null==i&&(i=new o),i}}t.LangIt=o},19642:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangJa=void 0;const n=r(98336),i=r(42120),o=r(51208),a=["AQRASRAGBAGUAIRAHBAghAURAdBAdcAnoAMEAFBAFCBKFBQRBSFBCXBCDBCHBGFBEQBpBBpQBIkBHNBeOBgFBVCBhBBhNBmOBmRBiHBiFBUFBZDBvFBsXBkFBlcBjYBwDBMBBTBBTRBWBBWXXaQXaRXQWXSRXCFXYBXpHXOQXHRXhRXuRXmXXbRXlXXwDXTRXrCXWQXWGaBWaKcaYgasFadQalmaMBacAKaRKKBKKXKKjKQRKDRKCYKCRKIDKeVKHcKlXKjHKrYNAHNBWNaRNKcNIBNIONmXNsXNdXNnBNMBNRBNrXNWDNWMNFOQABQAHQBrQXBQXFQaRQKXQKDQKOQKFQNBQNDQQgQCXQCDQGBQGDQGdQYXQpBQpQQpHQLXQHuQgBQhBQhCQuFQmXQiDQUFQZDQsFQdRQkHQbRQlOQlmQPDQjDQwXQMBQMDQcFQTBQTHQrDDXQDNFDGBDGQDGRDpFDhFDmXDZXDbRDMYDRdDTRDrXSAhSBCSBrSGQSEQSHBSVRShYShkSyQSuFSiBSdcSoESocSlmSMBSFBSFKSFNSFdSFcCByCaRCKcCSBCSRCCrCGbCEHCYXCpBCpQCIBCIHCeNCgBCgFCVECVcCmkCmwCZXCZFCdRClOClmClFCjDCjdCnXCwBCwXCcRCFQCFjGXhGNhGDEGDMGCDGCHGIFGgBGVXGVEGVRGmXGsXGdYGoSGbRGnXGwXGwDGWRGFNGFLGFOGFdGFkEABEBDEBFEXOEaBEKSENBENDEYXEIgEIkEgBEgQEgHEhFEudEuFEiBEiHEiFEZDEvBEsXEsFEdXEdREkFEbBEbRElFEPCEfkEFNYAEYAhYBNYQdYDXYSRYCEYYoYgQYgRYuRYmCYZTYdBYbEYlXYjQYRbYWRpKXpQopQnpSFpCXpIBpISphNpdBpdRpbRpcZpFBpFNpFDpFopFrLADLBuLXQLXcLaFLCXLEhLpBLpFLHXLeVLhILdHLdRLoDLbRLrXIABIBQIBCIBsIBoIBMIBRIXaIaRIKYIKRINBINuICDIGBIIDIIkIgRIxFIyQIiHIdRIbYIbRIlHIwRIMYIcRIRVITRIFBIFNIFQOABOAFOBQOaFONBONMOQFOSFOCDOGBOEQOpBOLXOIBOIFOgQOgFOyQOycOmXOsXOdIOkHOMEOMkOWWHBNHXNHXWHNXHDuHDRHSuHSRHHoHhkHmRHdRHkQHlcHlRHwBHWcgAEgAggAkgBNgBQgBEgXOgYcgLXgHjgyQgiBgsFgdagMYgWSgFQgFEVBTVXEVKBVKNVKDVKYVKRVNBVNYVDBVDxVSBVSRVCjVGNVLXVIFVhBVhcVsXVdRVbRVlRhBYhKYhDYhGShxWhmNhdahdkhbRhjohMXhTRxAXxXSxKBxNBxEQxeNxeQxhXxsFxdbxlHxjcxFBxFNxFQxFOxFoyNYyYoybcyMYuBQuBRuBruDMuCouHBudQukkuoBulVuMXuFEmCYmCRmpRmeDmiMmjdmTFmFQiADiBOiaRiKRiNBiNRiSFiGkiGFiERipRiLFiIFihYibHijBijEiMXiWBiFBiFCUBQUXFUaRUNDUNcUNRUNFUDBUSHUCDUGBUGFUEqULNULoUIRUeEUeYUgBUhFUuRUiFUsXUdFUkHUbBUjSUjYUwXUMDUcHURdUTBUrBUrXUrQZAFZXZZaRZKFZNBZQFZCXZGBZYdZpBZLDZIFZHXZHNZeQZVRZVFZmXZiBZvFZdFZkFZbHZbFZwXZcCZcRZRBvBQvBGvBLvBWvCovMYsAFsBDsaRsKFsNFsDrsSHsSFsCXsCRsEBsEHsEfspBsLBsLDsIgsIRseGsbRsFBsFQsFSdNBdSRdCVdGHdYDdHcdVbdySduDdsXdlRdwXdWYdWcdWRkBMkXOkaRkNIkNFkSFkCFkYBkpRkeNkgBkhVkmXksFklVkMBkWDkFNoBNoaQoaFoNBoNXoNaoNEoSRoEroYXoYCoYbopRopFomXojkowXorFbBEbEIbdBbjYlaRlDElMXlFDjKjjSRjGBjYBjYkjpRjLXjIBjOFjeVjbRjwBnXQnSHnpFnLXnINnMBnTRwXBwXNwXYwNFwQFwSBwGFwLXwLDweNwgBwuHwjDwnXMBXMpFMIBMeNMTHcaQcNBcDHcSFcCXcpBcLXcLDcgFcuFcnXcwXccDcTQcrFTQErXNrCHrpFrgFrbFrTHrFcWNYWNbWEHWMXWTR","ABGHABIJAEAVAYJQALZJAIaRAHNXAHdcAHbRAZJMAZJRAZTRAdVJAklmAbcNAjdRAMnRAMWYAWpRAWgRAFgBAFhBAFdcBNJBBNJDBQKBBQhcBQlmBDEJBYJkBYJTBpNBBpJFBIJBBIJDBIcABOKXBOEJBOVJBOiJBOZJBepBBeLXBeIFBegBBgGJBVJXBuocBiJRBUJQBlXVBlITBwNFBMYVBcqXBTlmBWNFBWiJBWnRBFGHBFwXXKGJXNJBXNZJXDTTXSHSXSVRXSlHXCJDXGQJXEhXXYQJXYbRXOfXXeNcXVJFXhQJXhEJXdTRXjdXXMhBXcQTXRGBXTEBXTnQXFCXXFOFXFgFaBaFaBNJaBCJaBpBaBwXaNJKaNJDaQIBaDpRaEPDaHMFamDJalEJaMZJaFaFaFNBaFQJaFLDaFVHKBCYKBEBKBHDKXaFKXGdKXEJKXpHKXIBKXZDKXwXKKwLKNacKNYJKNJoKNWcKDGdKDTRKChXKGaRKGhBKGbRKEBTKEaRKEPTKLMDKLWRKOHDKVJcKdBcKlIBKlOPKFSBKFEPKFpFNBNJNJBQNBGHNBEPNBHXNBgFNBVXNBZDNBsXNBwXNNaRNNJDNNJENNJkNDCJNDVDNGJRNJiDNZJNNsCJNJFNNFSBNFCXNFEPNFLXNFIFQJBFQCaRQJEQQLJDQLJFQIaRQOqXQHaFQHHQQVJXQVJDQhNJQmEIQZJFQsJXQJrFQWbRDJABDBYJDXNFDXCXDXLXDXZDDXsJDQqXDSJFDJCXDEPkDEqXDYmQDpSJDOCkDOGQDHEIDVJDDuDuDWEBDJFgSBNDSBSFSBGHSBIBSBTQSKVYSJQNSJQiSJCXSEqXSJYVSIiJSOMYSHAHSHaQSeCFSepQSegBSHdHSHrFShSJSJuHSJUFSkNRSrSrSWEBSFaHSJFQSFCXSFGDSFYXSFODSFgBSFVXSFhBSFxFSFkFSFbBSFMFCADdCJXBCXaFCXKFCXNFCXCXCXGBCXEJCXYBCXLDCXIBCXOPCXHXCXgBCXhBCXiBCXlDCXcHCJNBCJNFCDCJCDGBCDVXCDhBCDiDCDJdCCmNCpJFCIaRCOqXCHCHCHZJCViJCuCuCmddCJiFCdNBCdHhClEJCnUJCreSCWlgCWTRCFBFCFNBCFYBCFVFCFhFCFdSCFTBCFWDGBNBGBQFGJBCGBEqGBpBGBgQGNBEGNJYGNkOGNJRGDUFGJpQGHaBGJeNGJeEGVBlGVKjGiJDGvJHGsVJGkEBGMIJGWjNGFBFGFCXGFGBGFYXGFpBGFMFEASJEAWpEJNFECJVEIXSEIQJEOqXEOcFEeNcEHEJEHlFEJgFEhlmEmDJEmZJEiMBEUqXEoSREPBFEPXFEPKFEPSFEPEFEPpFEPLXEPIBEJPdEPcFEPTBEJnXEqlHEMpREFCXEFODEFcFYASJYJAFYBaBYBVXYXpFYDhBYCJBYJGFYYbRYeNcYJeVYiIJYZJcYvJgYvJRYJsXYsJFYMYMYreVpBNHpBEJpBwXpQxFpYEJpeNDpJeDpeSFpeCHpHUJpHbBpHcHpmUJpiiJpUJrpsJuplITpFaBpFQqpFGBpFEfpFYBpFpBpFLJpFIDpFgBpFVXpFyQpFuFpFlFpFjDpFnXpFwXpJFMpFTBLXCJLXEFLXhFLXUJLXbFLalmLNJBLSJQLCLCLGJBLLDJLHaFLeNFLeSHLeCXLepFLhaRLZsJLsJDLsJrLocaLlLlLMdbLFNBLFSBLFEHLFkFIBBFIBXFIBaQIBKXIBSFIBpHIBLXIBgBIBhBIBuHIBmXIBiFIBZXIBvFIBbFIBjQIBwXIBWFIKTRIQUJIDGFICjQIYSRIINXIJeCIVaRImEkIZJFIvJRIsJXIdCJIJoRIbBQIjYBIcqXITFVIreVIFKFIFSFIFCJIFGFIFLDIFIBIJFOIFgBIFVXIJFhIFxFIFmXIFdHIFbBIJFrIJFWOBGBOQfXOOKjOUqXOfXBOqXEOcqXORVJOFIBOFlDHBIOHXiFHNTRHCJXHIaRHHJDHHEJHVbRHZJYHbIBHRsJHRkDHWlmgBKFgBSBgBCDgBGHgBpBgBIBgBVJgBuBgBvFgKDTgQVXgDUJgGSJgOqXgmUMgZIJgTUJgWIEgFBFgFNBgFDJgFSFgFGBgFYXgJFOgFgQgFVXgFhBgFbHgJFWVJABVQKcVDgFVOfXVeDFVhaRVmGdViJYVMaRVFNHhBNDhBCXhBEqhBpFhBLXhNJBhSJRheVXhhKEhxlmhZIJhdBQhkIJhbMNhMUJhMZJxNJgxQUJxDEkxDdFxSJRxplmxeSBxeCXxeGFxeYXxepQxegBxWVcxFEQxFLXxFIBxFgBxFxDxFZtxFdcxFbBxFwXyDJXyDlcuASJuDJpuDIBuCpJuGSJuIJFueEFuZIJusJXudWEuoIBuWGJuFBcuFKEuFNFuFQFuFDJuFGJuFVJuFUtuFdHuFTBmBYJmNJYmQhkmLJDmLJomIdXmiJYmvJRmsJRmklmmMBymMuCmclmmcnQiJABiJBNiJBDiBSFiBCJiBEFiBYBiBpFiBLXiBTHiJNciDEfiCZJiECJiJEqiOkHiHKFieNDiHJQieQcieDHieSFieCXieGFieEFieIHiegFihUJixNoioNXiFaBiFKFiFNDiFEPiFYXitFOitFHiFgBiFVEiFmXiFitiFbBiFMFiFrFUCXQUIoQUIJcUHQJUeCEUHwXUUJDUUqXUdWcUcqXUrnQUFNDUFSHUFCFUFEfUFLXUtFOZBXOZXSBZXpFZXVXZEQJZEJkZpDJZOqXZeNHZeCDZUqXZFBQZFEHZFLXvBAFvBKFvBCXvBEPvBpHvBIDvBgFvBuHvQNJvFNFvFGBvFIBvJFcsXCDsXLXsXsXsXlFsXcHsQqXsJQFsEqXseIFsFEHsFjDdBxOdNpRdNJRdEJbdpJRdhZJdnSJdrjNdFNJdFQHdFhNkNJDkYaRkHNRkHSRkVbRkuMRkjSJkcqDoSJFoEiJoYZJoOfXohEBoMGQocqXbBAFbBXFbBaFbBNDbBGBbBLXbBTBbBWDbGJYbIJHbFQqbFpQlDgQlOrFlVJRjGEBjZJRnXvJnXbBnEfHnOPDngJRnxfXnUJWwXEJwNpJwDpBwEfXwrEBMDCJMDGHMDIJMLJDcQGDcQpHcqXccqNFcqCXcFCJRBSBRBGBRBEJRBpQTBNFTBQJTBpBTBVXTFABTFSBTFCFTFGBTFMDrXCJrXLDrDNJrEfHrFQJrFitWNjdWNTR","AKLJMANOPFASNJIAEJWXAYJNRAIIbRAIcdaAeEfDAgidRAdjNYAMYEJAMIbRAFNJBAFpJFBBIJYBDZJFBSiJhBGdEBBEJfXBEJqXBEJWRBpaUJBLXrXBIYJMBOcfXBeEfFBestXBjNJRBcDJOBFEqXXNvJRXDMBhXCJNYXOAWpXONJWXHDEBXeIaRXhYJDXZJSJXMDJOXcASJXFVJXaBQqXaBZJFasXdQaFSJQaFEfXaFpJHaFOqXKBNSRKXvJBKQJhXKEJQJKEJGFKINJBKIJjNKgJNSKVElmKVhEBKiJGFKlBgJKjnUJKwsJYKMFIJKFNJDKFIJFKFOfXNJBSFNJBCXNBpJFNJBvQNJBMBNJLJXNJOqXNJeCXNJeGFNdsJCNbTKFNwXUJQNFEPQDiJcQDMSJQSFpBQGMQJQJeOcQyCJEQUJEBQJFBrQFEJqDXDJFDJXpBDJXIMDGiJhDIJGRDJeYcDHrDJDVXgFDkAWpDkIgRDjDEqDMvJRDJFNFDJFIBSKclmSJQOFSJQVHSJQjDSJGJBSJGJFSECJoSHEJqSJHTBSJVJDSViJYSZJNBSJsJDSFSJFSFEfXSJFLXCBUJVCJXSBCJXpBCXVJXCJXsXCJXdFCJNJHCLIJgCHiJFCVNJMChCJhCUHEJCsJTRCJdYcCoQJCCFEfXCFIJgCFUJxCFstFGJBaQGJBIDGQJqXGYJNRGJHKFGeQqDGHEJFGJeLXGHIiJGHdBlGUJEBGkIJTGFQPDGJFEqEAGegEJIJBEJVJXEhQJTEiJNcEJZJFEJoEqEjDEqEPDsXEPGJBEPOqXEPeQFEfDiDEJfEFEfepQEfMiJEqXNBEqDIDEqeSFEqVJXEMvJRYXNJDYXEJHYKVJcYYJEBYJeEcYJUqXYFpJFYFstXpAZJMpBSJFpNBNFpeQPDpHLJDpHIJFpHgJFpeitFpHZJFpJFADpFSJFpJFCJpFOqXpFitBpJFZJLXIJFLIJgRLVNJWLVHJMLwNpJLFGJBLFLJDLFOqXLJFUJIBDJXIBGJBIJBYQIJBIBIBOqXIBcqDIEGJFILNJTIIJEBIOiJhIJeNBIJeIBIhiJIIWoTRIJFAHIJFpBIJFuHIFUtFIJFTHOSBYJOEcqXOHEJqOvBpFOkVJrObBVJOncqDOcNJkHhNJRHuHJuHdMhBgBUqXgBsJXgONJBgHNJDgHHJQgJeitgHsJXgJyNagyDJBgZJDrgsVJQgkEJNgkjSJgJFAHgFCJDgFZtMVJXNFVXQfXVJXDJVXoQJVQVJQVDEfXVDvJHVEqNFVeQfXVHpJFVHxfXVVJSRVVmaRVlIJOhCXVJhHjYkhxCJVhWVUJhWiJcxBNJIxeEqDxfXBFxcFEPxFSJFxFYJXyBDQJydaUJyFOPDuYCJYuLvJRuHLJXuZJLDuFOPDuFZJHuFcqXmKHJdmCQJcmOsVJiJAGFitLCFieOfXiestXiZJMEikNJQirXzFiFQqXiFIJFiFZJFiFvtFUHpJFUteIcUteOcUVCJkUhdHcUbEJEUJqXQUMNJhURjYkUFitFZDGJHZJIxDZJVJXZJFDJZJFpQvBNJBvBSJFvJxBrseQqDsVFVJdFLJDkEJNBkmNJYkFLJDoQJOPoGsJRoEAHBoEJfFbBQqDbBZJHbFVJXlFIJBjYIrXjeitcjjCEBjWMNBwXQfXwXOaFwDsJXwCJTRwrCZJMDNJQcDDJFcqDOPRYiJFTBsJXTQIJBTFEfXTFLJDrXEJFrEJXMrFZJFWEJdEWYTlm","ABCDEFACNJTRAMBDJdAcNJVXBLNJEBXSIdWRXErNJkXYDJMBXZJCJaXMNJaYKKVJKcKDEJqXKDcNJhKVJrNYKbgJVXKFVJSBNBYBwDNJeQfXNJeEqXNhGJWENJFiJRQlIJbEQJfXxDQqXcfXQFNDEJQFwXUJDYcnUJDJIBgQDIUJTRDJFEqDSJQSJFSJQIJFSOPeZtSJFZJHCJXQfXCTDEqFGJBSJFGJBOfXGJBcqXGJHNJDGJRLiJEJfXEqEJFEJPEFpBEJYJBZJFYBwXUJYiJMEBYJZJyTYTONJXpQMFXFpeGIDdpJFstXpJFcPDLBVSJRLHQJqXLJFZJFIJBNJDIJBUqXIBkFDJIJEJPTIYJGWRIJeQPDIJeEfHIJFsJXOqGDSFHXEJqXgJCsJCgGQJqXgdQYJEgFMFNBgJFcqDVJwXUJVJFZJchIgJCCxOEJqXxOwXUJyDJBVRuscisciJBiJBieUtqXiJFDJkiFsJXQUGEZJcUJFsJXZtXIrXZDZJDrZJFNJDZJFstXvJFQqXvJFCJEsJXQJqkhkNGBbDJdTRbYJMEBlDwXUJMEFiJFcfXNJDRcNJWMTBLJXC","BraFUtHBFSJFdbNBLJXVJQoYJNEBSJBEJfHSJHwXUJCJdAZJMGjaFVJXEJPNJBlEJfFiJFpFbFEJqIJBVJCrIBdHiJhOPFChvJVJZJNJWxGFNIFLueIBQJqUHEJfUFstOZJDrlXEASJRlXVJXSFwVJNJWD","QJEJNNJDQJEJIBSFQJEJxegBQJEJfHEPSJBmXEJFSJCDEJqXLXNJFQqXIcQsFNJFIFEJqXUJgFsJXIJBUJEJfHNFvJxEqXNJnXUJFQqD","IJBEJqXZJ"];let s=null;function u(e){return(0,i.hexlify)((0,i.toUtf8Bytes)(e))}function c(e){return(0,i.toUtf8String)(new Uint8Array(e))}function l(){if(null!==s)return s;const e=[],t={};function r(e){let r="";for(let n=0;nt?1:0})),"0xe3818de38284e3818f"===u(e[442])&&"0xe3818de38283e3818f"===u(e[443])){const t=e[442];e[442]=e[443],e[443]=t}if("0xcb36b09e6baa935787fd762ce65e80b0c6a8dabdfbc3a7f86ac0e2c4fd111600"!==(0,n.id)(e.join("\n")+"\n"))throw new Error("BIP39 Wordlist for ja (Japanese) FAILED");return s=e,e}let f=null;class h extends o.Wordlist{constructor(){super("ja")}getWord(e){const t=l();return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangKo=void 0;const n=r(98336),i=r(42120),o=r(51208),a=["OYAa","ATAZoATBl3ATCTrATCl8ATDloATGg3ATHT8ATJT8ATJl3ATLlvATLn4ATMT8ATMX8ATMboATMgoAToLbAToMTATrHgATvHnAT3AnAT3JbAT3MTAT8DbAT8JTAT8LmAT8MYAT8MbAT#LnAUHT8AUHZvAUJXrAUJX8AULnrAXJnvAXLUoAXLgvAXMn6AXRg3AXrMbAX3JTAX3QbAYLn3AZLgvAZrSUAZvAcAZ8AaAZ8AbAZ8AnAZ8HnAZ8LgAZ8MYAZ8MgAZ8OnAaAboAaDTrAaFTrAaJTrAaJboAaLVoAaMXvAaOl8AaSeoAbAUoAbAg8AbAl4AbGnrAbMT8AbMXrAbMn4AbQb8AbSV8AbvRlAb8AUAb8AnAb8HgAb8JTAb8NTAb8RbAcGboAcLnvAcMT8AcMX8AcSToAcrAaAcrFnAc8AbAc8MgAfGgrAfHboAfJnvAfLV8AfLkoAfMT8AfMnoAfQb8AfScrAfSgrAgAZ8AgFl3AgGX8AgHZvAgHgrAgJXoAgJX8AgJboAgLZoAgLn4AgOX8AgoATAgoAnAgoCUAgoJgAgoLXAgoMYAgoSeAgrDUAgrJTAhrFnAhrLjAhrQgAjAgoAjJnrAkMX8AkOnoAlCTvAlCV8AlClvAlFg4AlFl6AlFn3AloSnAlrAXAlrAfAlrFUAlrFbAlrGgAlrOXAlvKnAlvMTAl3AbAl3MnAnATrAnAcrAnCZ3AnCl8AnDg8AnFboAnFl3AnHX4AnHbrAnHgrAnIl3AnJgvAnLXoAnLX4AnLbrAnLgrAnLhrAnMXoAnMgrAnOn3AnSbrAnSeoAnvLnAn3OnCTGgvCTSlvCTvAUCTvKnCTvNTCT3CZCT3GUCT3MTCT8HnCUCZrCULf8CULnvCU3HnCU3JUCY6NUCbDb8CbFZoCbLnrCboOTCboScCbrFnCbvLnCb8AgCb8HgCb$LnCkLfoClBn3CloDUDTHT8DTLl3DTSU8DTrAaDTrLXDTrLjDTrOYDTrOgDTvFXDTvFnDT3HUDT3LfDUCT9DUDT4DUFVoDUFV8DUFkoDUGgrDUJnrDULl8DUMT8DUMXrDUMX4DUMg8DUOUoDUOgvDUOg8DUSToDUSZ8DbDXoDbDgoDbGT8DbJn3DbLg3DbLn4DbMXrDbMg8DbOToDboJXGTClvGTDT8GTFZrGTLVoGTLlvGTLl3GTMg8GTOTvGTSlrGToCUGTrDgGTrJYGTrScGTtLnGTvAnGTvQgGUCZrGUDTvGUFZoGUHXrGULnvGUMT8GUoMgGXoLnGXrMXGXrMnGXvFnGYLnvGZOnvGZvOnGZ8LaGZ8LmGbAl3GbDYvGbDlrGbHX3GbJl4GbLV8GbLn3GbMn4GboJTGboRfGbvFUGb3GUGb4JnGgDX3GgFl$GgJlrGgLX6GgLZoGgLf8GgOXoGgrAgGgrJXGgrMYGgrScGgvATGgvOYGnAgoGnJgvGnLZoGnLg3GnLnrGnQn8GnSbrGnrMgHTClvHTDToHTFT3HTQT8HToJTHToJgHTrDUHTrMnHTvFYHTvRfHT8MnHT8SUHUAZ8HUBb4HUDTvHUoMYHXFl6HXJX6HXQlrHXrAUHXrMnHXrSbHXvFYHXvKXHX3LjHX3MeHYvQlHZrScHZvDbHbAcrHbFT3HbFl3HbJT8HbLTrHbMT8HbMXrHbMbrHbQb8HbSX3HboDbHboJTHbrFUHbrHgHbrJTHb8JTHb8MnHb8QgHgAlrHgDT3HgGgrHgHgrHgJTrHgJT8HgLX@HgLnrHgMT8HgMX8HgMboHgOnrHgQToHgRg3HgoHgHgrCbHgrFnHgrLVHgvAcHgvAfHnAloHnCTrHnCnvHnGTrHnGZ8HnGnvHnJT8HnLf8HnLkvHnMg8HnRTrITvFUITvFnJTAXrJTCV8JTFT3JTFT8JTFn4JTGgvJTHT8JTJT8JTJXvJTJl3JTJnvJTLX4JTLf8JTLhvJTMT8JTMXrJTMnrJTObrJTQT8JTSlvJT8DUJT8FkJT8MTJT8OXJT8OgJT8QUJT8RfJUHZoJXFT4JXFlrJXGZ8JXGnrJXLV8JXLgvJXMXoJXMX3JXNboJXPlvJXoJTJXoLkJXrAXJXrHUJXrJgJXvJTJXvOnJX4KnJYAl3JYJT8JYLhvJYQToJYrQXJY6NUJbAl3JbCZrJbDloJbGT8JbGgrJbJXvJbJboJbLf8JbLhrJbLl3JbMnvJbRg8JbSZ8JboDbJbrCZJbrSUJb3KnJb8LnJfRn8JgAXrJgCZrJgDTrJgGZrJgGZ8JgHToJgJT8JgJXoJgJgvJgLX4JgLZ3JgLZ8JgLn4JgMgrJgMn4JgOgvJgPX6JgRnvJgSToJgoCZJgoJbJgoMYJgrJXJgrJgJgrLjJg6MTJlCn3JlGgvJlJl8Jl4AnJl8FnJl8HgJnAToJnATrJnAbvJnDUoJnGnrJnJXrJnJXvJnLhvJnLnrJnLnvJnMToJnMT8JnMXvJnMX3JnMg8JnMlrJnMn4JnOX8JnST4JnSX3JnoAgJnoAnJnoJTJnoObJnrAbJnrAkJnrHnJnrJTJnrJYJnrOYJnrScJnvCUJnvFaJnvJgJnvJnJnvOYJnvQUJnvRUJn3FnJn3JTKnFl3KnLT6LTDlvLTMnoLTOn3LTRl3LTSb4LTSlrLToAnLToJgLTrAULTrAcLTrCULTrHgLTrMgLT3JnLULnrLUMX8LUoJgLVATrLVDTrLVLb8LVoJgLV8MgLV8RTLXDg3LXFlrLXrCnLXrLXLX3GTLX4GgLX4OYLZAXrLZAcrLZAgrLZAhrLZDXyLZDlrLZFbrLZFl3LZJX6LZJX8LZLc8LZLnrLZSU8LZoJTLZoJnLZrAgLZrAnLZrJYLZrLULZrMgLZrSkLZvAnLZvGULZvJeLZvOTLZ3FZLZ4JXLZ8STLZ8ScLaAT3LaAl3LaHT8LaJTrLaJT8LaJXrLaJgvLaJl4LaLVoLaMXrLaMXvLaMX8LbClvLbFToLbHlrLbJn4LbLZ3LbLhvLbMXrLbMnoLbvSULcLnrLc8HnLc8MTLdrMnLeAgoLeOgvLeOn3LfAl3LfLnvLfMl3LfOX8Lf8AnLf8JXLf8LXLgJTrLgJXrLgJl8LgMX8LgRZrLhCToLhrAbLhrFULhrJXLhvJYLjHTrLjHX4LjJX8LjLhrLjSX3LjSZ4LkFX4LkGZ8LkGgvLkJTrLkMXoLkSToLkSU8LkSZ8LkoOYLl3FfLl3MgLmAZrLmCbrLmGgrLmHboLmJnoLmJn3LmLfoLmLhrLmSToLnAX6LnAb6LnCZ3LnCb3LnDTvLnDb8LnFl3LnGnrLnHZvLnHgvLnITvLnJT8LnJX8LnJlvLnLf8LnLg6LnLhvLnLnoLnMXrLnMg8LnQlvLnSbrLnrAgLnrAnLnrDbLnrFkLnrJdLnrMULnrOYLnrSTLnvAnLnvDULnvHgLnvOYLnvOnLn3GgLn4DULn4JTLn4JnMTAZoMTAloMTDb8MTFT8MTJnoMTJnrMTLZrMTLhrMTLkvMTMX8MTRTrMToATMTrDnMTrOnMT3JnMT4MnMT8FUMT8FaMT8FlMT8GTMT8GbMT8GnMT8HnMT8JTMT8JbMT8OTMUCl8MUJTrMUJU8MUMX8MURTrMUSToMXAX6MXAb6MXCZoMXFXrMXHXrMXLgvMXOgoMXrAUMXrAnMXrHgMXrJYMXrJnMXrMTMXrMgMXrOYMXrSZMXrSgMXvDUMXvOTMX3JgMX3OTMX4JnMX8DbMX8FnMX8HbMX8HgMX8HnMX8LbMX8MnMX8OnMYAb8MYGboMYHTvMYHX4MYLTrMYLnvMYMToMYOgvMYRg3MYSTrMbAToMbAXrMbAl3MbAn8MbGZ8MbJT8MbJXrMbMXvMbMX8MbMnoMbrMUMb8AfMb8FbMb8FkMcJXoMeLnrMgFl3MgGTvMgGXoMgGgrMgGnrMgHT8MgHZrMgJnoMgLnrMgLnvMgMT8MgQUoMgrHnMgvAnMg8HgMg8JYMg8LfMloJnMl8ATMl8AXMl8JYMnAToMnAT4MnAZ8MnAl3MnAl4MnCl8MnHT8MnHg8MnJnoMnLZoMnLhrMnMXoMnMX3MnMnrMnOgvMnrFbMnrFfMnrFnMnrNTMnvJXNTMl8OTCT3OTFV8OTFn3OTHZvOTJXrOTOl3OT3ATOT3JUOT3LZOT3LeOT3MbOT8ATOT8AbOT8AgOT8MbOUCXvOUMX3OXHXvOXLl3OXrMUOXvDbOX6NUOX8JbOYFZoOYLbrOYLkoOYMg8OYSX3ObHTrObHT4ObJgrObLhrObMX3ObOX8Ob8FnOeAlrOeJT8OeJXrOeJnrOeLToOeMb8OgJXoOgLXoOgMnrOgOXrOgOloOgoAgOgoJbOgoMYOgoSTOg8AbOjLX4OjMnoOjSV8OnLVoOnrAgOn3DUPXQlrPXvFXPbvFTPdAT3PlFn3PnvFbQTLn4QToAgQToMTQULV8QURg8QUoJnQXCXvQbFbrQb8AaQb8AcQb8FbQb8MYQb8ScQeAlrQeLhrQjAn3QlFXoQloJgQloSnRTLnvRTrGURTrJTRUJZrRUoJlRUrQnRZrLmRZrMnRZrSnRZ8ATRZ8JbRZ8ScRbMT8RbST3RfGZrRfMX8RfMgrRfSZrRnAbrRnGT8RnvJgRnvLfRnvMTRn8AaSTClvSTJgrSTOXrSTRg3STRnvSToAcSToAfSToAnSToHnSToLjSToMTSTrAaSTrEUST3BYST8AgST8LmSUAZvSUAgrSUDT4SUDT8SUGgvSUJXoSUJXvSULTrSU8JTSU8LjSV8AnSV8JgSXFToSXLf8SYvAnSZrDUSZrMUSZrMnSZ8HgSZ8JTSZ8JgSZ8MYSZ8QUSaQUoSbCT3SbHToSbQYvSbSl4SboJnSbvFbSb8HbSb8JgSb8OTScGZrScHgrScJTvScMT8ScSToScoHbScrMTScvAnSeAZrSeAcrSeHboSeJUoSeLhrSeMT8SeMXrSe6JgSgHTrSkJnoSkLnvSk8CUSlFl3SlrSnSl8GnSmAboSmGT8SmJU8","ATLnDlATrAZoATrJX4ATrMT8ATrMX4ATrRTrATvDl8ATvJUoATvMl8AT3AToAT3MX8AT8CT3AT8DT8AT8HZrAT8HgoAUAgFnAUCTFnAXoMX8AXrAT8AXrGgvAXrJXvAXrOgoAXvLl3AZvAgoAZvFbrAZvJXoAZvJl8AZvJn3AZvMX8AZvSbrAZ8FZoAZ8LZ8AZ8MU8AZ8OTvAZ8SV8AZ8SX3AbAgFZAboJnoAbvGboAb8ATrAb8AZoAb8AgrAb8Al4Ab8Db8Ab8JnoAb8LX4Ab8LZrAb8LhrAb8MT8Ab8OUoAb8Qb8Ab8ST8AcrAUoAcrAc8AcrCZ3AcrFT3AcrFZrAcrJl4AcrJn3AcrMX3AcrOTvAc8AZ8Ac8MT8AfAcJXAgoFn4AgoGgvAgoGnrAgoLc8AgoMXoAgrLnrAkrSZ8AlFXCTAloHboAlrHbrAlrLhrAlrLkoAl3CZrAl3LUoAl3LZrAnrAl4AnrMT8An3HT4BT3IToBX4MnvBb!Ln$CTGXMnCToLZ4CTrHT8CT3JTrCT3RZrCT#GTvCU6GgvCU8Db8CU8GZrCU8HT8CboLl3CbrGgrCbrMU8Cb8DT3Cb8GnrCb8LX4Cb8MT8Cb8ObrCgrGgvCgrKX4Cl8FZoDTrAbvDTrDboDTrGT6DTrJgrDTrMX3DTrRZrDTrRg8DTvAVvDTvFZoDT3DT8DT3Ln3DT4HZrDT4MT8DT8AlrDT8MT8DUAkGbDUDbJnDYLnQlDbDUOYDbMTAnDbMXSnDboAT3DboFn4DboLnvDj6JTrGTCgFTGTGgFnGTJTMnGTLnPlGToJT8GTrCT3GTrLVoGTrLnvGTrMX3GTrMboGTvKl3GZClFnGZrDT3GZ8DTrGZ8FZ8GZ8MXvGZ8On8GZ8ST3GbCnQXGbMbFnGboFboGboJg3GboMXoGb3JTvGb3JboGb3Mn6Gb3Qb8GgDXLjGgMnAUGgrDloGgrHX4GgrSToGgvAXrGgvAZvGgvFbrGgvLl3GgvMnvGnDnLXGnrATrGnrMboGnuLl3HTATMnHTAgCnHTCTCTHTrGTvHTrHTvHTrJX8HTrLl8HTrMT8HTrMgoHTrOTrHTuOn3HTvAZrHTvDTvHTvGboHTvJU8HTvLl3HTvMXrHTvQb4HT4GT6HT4JT8HT4Jb#HT8Al3HT8GZrHT8GgrHT8HX4HT8Jb8HT8JnoHT8LTrHT8LgvHT8SToHT8SV8HUoJUoHUoJX8HUoLnrHXrLZoHXvAl3HX3LnrHX4FkvHX4LhrHX4MXoHX4OnoHZrAZ8HZrDb8HZrGZ8HZrJnrHZvGZ8HZvLnvHZ8JnvHZ8LhrHbCXJlHbMTAnHboJl4HbpLl3HbrJX8HbrLnrHbrMnvHbvRYrHgoSTrHgrFV8HgrGZ8HgrJXoHgrRnvHgvBb!HgvGTrHgvHX4HgvHn!HgvLTrHgvSU8HnDnLbHnFbJbHnvDn8Hn6GgvHn!BTvJTCTLnJTQgFnJTrAnvJTrLX4JTrOUoJTvFn3JTvLnrJTvNToJT3AgoJT3Jn4JT3LhvJT3ObrJT8AcrJT8Al3JT8JT8JT8JnoJT8LX4JT8LnrJT8MX3JT8Rg3JT8Sc8JUoBTvJU8AToJU8GZ8JU8GgvJU8JTrJU8JXrJU8JnrJU8LnvJU8ScvJXHnJlJXrGgvJXrJU8JXrLhrJXrMT8JXrMXrJXrQUoJXvCTvJXvGZ8JXvGgrJXvQT8JX8Ab8JX8DT8JX8GZ8JX8HZvJX8LnrJX8MT8JX8MXoJX8MnvJX8ST3JYGnCTJbAkGbJbCTAnJbLTAcJboDT3JboLb6JbrAnvJbrCn3JbrDl8JbrGboJbrIZoJbrJnvJbrMnvJbrQb4Jb8RZrJeAbAnJgJnFbJgScAnJgrATrJgvHZ8JgvMn4JlJlFbJlLiQXJlLjOnJlRbOlJlvNXoJlvRl3Jl4AcrJl8AUoJl8MnrJnFnMlJnHgGbJnoDT8JnoFV8JnoGgvJnoIT8JnoQToJnoRg3JnrCZ3JnrGgrJnrHTvJnrLf8JnrOX8JnvAT3JnvFZoJnvGT8JnvJl4JnvMT8JnvMX8JnvOXrJnvPX6JnvSX3JnvSZrJn3MT8Jn3MX8Jn3RTrLTATKnLTJnLTLTMXKnLTRTQlLToGb8LTrAZ8LTrCZ8LTrDb8LTrHT8LT3PX6LT4FZoLT$CTvLT$GgrLUvHX3LVoATrLVoAgoLVoJboLVoMX3LVoRg3LV8CZ3LV8FZoLV8GTvLXrDXoLXrFbrLXvAgvLXvFlrLXvLl3LXvRn6LX4Mb8LX8GT8LYCXMnLYrMnrLZoSTvLZrAZvLZrAloLZrFToLZrJXvLZrJboLZrJl4LZrLnrLZrMT8LZrOgvLZrRnvLZrST4LZvMX8LZvSlvLZ8AgoLZ8CT3LZ8JT8LZ8LV8LZ8LZoLZ8Lg8LZ8SV8LZ8SbrLZ$HT8LZ$Mn4La6CTvLbFbMnLbRYFTLbSnFZLboJT8LbrAT9LbrGb3LbrQb8LcrJX8LcrMXrLerHTvLerJbrLerNboLgrDb8LgrGZ8LgrHTrLgrMXrLgrSU8LgvJTrLgvLl3Lg6Ll3LhrLnrLhrMT8LhvAl4LiLnQXLkoAgrLkoJT8LkoJn4LlrSU8Ll3FZoLl3HTrLl3JX8Ll3JnoLl3LToLmLeFbLnDUFbLnLVAnLnrATrLnrAZoLnrAb8LnrAlrLnrGgvLnrJU8LnrLZrLnrLhrLnrMb8LnrOXrLnrSZ8LnvAb4LnvDTrLnvDl8LnvHTrLnvHbrLnvJT8LnvJU8LnvJbrLnvLhvLnvMX8LnvMb8LnvNnoLnvSU8Ln3Al3Ln4FZoLn4GT6Ln4JgvLn4LhrLn4MT8Ln4SToMToCZrMToJX8MToLX4MToLf8MToRg3MTrEloMTvGb6MT3BTrMT3Lb6MT8AcrMT8AgrMT8GZrMT8JnoMT8LnrMT8MX3MUOUAnMXAbFnMXoAloMXoJX8MXoLf8MXoLl8MXrAb8MXrDTvMXrGT8MXrGgrMXrHTrMXrLf8MXrMU8MXrOXvMXrQb8MXvGT8MXvHTrMXvLVoMX3AX3MX3Jn3MX3LhrMX3MX3MX4AlrMX4OboMX8GTvMX8GZrMX8GgrMX8JT8MX8JX8MX8LhrMX8MT8MYDUFbMYMgDbMbGnFfMbvLX4MbvLl3Mb8Mb8Mb8ST4MgGXCnMg8ATrMg8AgoMg8CZrMg8DTrMg8DboMg8HTrMg8JgrMg8LT8MloJXoMl8AhrMl8JT8MnLgAUMnoJXrMnoLX4MnoLhrMnoMT8MnrAl4MnrDb8MnrOTvMnrOgvMnrQb8MnrSU8MnvGgrMnvHZ8Mn3MToMn4DTrMn4LTrMn4Mg8NnBXAnOTFTFnOToAToOTrGgvOTrJX8OT3JXoOT6MTrOT8GgrOT8HTpOT8MToOUoHT8OUoJT8OUoLn3OXrAgoOXrDg8OXrMT8OXvSToOX6CTvOX8CZrOX8OgrOb6HgvOb8AToOb8MT8OcvLZ8OgvAlrOgvHTvOgvJTrOgvJnrOgvLZrOgvLn4OgvMT8OgvRTrOg8AZoOg8DbvOnrOXoOnvJn4OnvLhvOnvRTrOn3GgoOn3JnvOn6JbvOn8OTrPTGYFTPbBnFnPbGnDnPgDYQTPlrAnvPlrETvPlrLnvPlrMXvPlvFX4QTMTAnQTrJU8QYCnJlQYJlQlQbGTQbQb8JnrQb8LZoQb8LnvQb8MT8Qb8Ml8Qb8ST4QloAl4QloHZvQloJX8QloMn8QnJZOlRTrAZvRTrDTrRTvJn4RTvLhvRT4Jb8RZrAZrRZ8AkrRZ8JU8RZ8LV8RZ8LnvRbJlQXRg3GboRg3MnvRg8AZ8Rg8JboRg8Jl4RnLTCbRnvFl3RnvQb8SToAl4SToCZrSToFZoSToHXrSToJU8SToJgvSToJl4SToLhrSToMX3STrAlvSTrCT9STrCgrSTrGgrSTrHXrSTrHboSTrJnoSTrNboSTvLnrST4AZoST8Ab8ST8JT8SUoJn3SU6HZ#SU6JTvSU8Db8SU8HboSU8LgrSV8JT8SZrAcrSZrAl3SZrJT8SZrJnvSZrMT8SZvLUoSZ4FZoSZ8JnoSZ8RZrScoLnrScoMT8ScoMX8ScrAT4ScrAZ8ScrLZ8ScrLkvScvDb8ScvLf8ScvNToSgrFZrShvKnrSloHUoSloLnrSlrMXoSl8HgrSmrJUoSn3BX6","ATFlOn3ATLgrDYAT4MTAnAT8LTMnAYJnRTrAbGgJnrAbLV8LnAbvNTAnAeFbLg3AgOYMXoAlQbFboAnDboAfAnJgoJTBToDgAnBUJbAl3BboDUAnCTDlvLnCTFTrSnCYoQTLnDTwAbAnDUDTrSnDUHgHgrDX8LXFnDbJXAcrETvLTLnGTFTQbrGTMnGToGT3DUFbGUJlPX3GbQg8LnGboJbFnGb3GgAYGgAg8ScGgMbAXrGgvAbAnGnJTLnvGnvATFgHTDT6ATHTrDlJnHYLnMn8HZrSbJTHZ8LTFnHbFTJUoHgSeMT8HgrLjAnHgvAbAnHlFUrDlHnDgvAnHnHTFT3HnQTGnrJTAaMXvJTGbCn3JTOgrAnJXvAXMnJbMg8SnJbMnRg3Jb8LTMnJnAl3OnJnGYrQlJnJlQY3LTDlCn3LTJjLg3LTLgvFXLTMg3GTLV8HUOgLXFZLg3LXNXrMnLX8QXFnLX9AlMYLYLXPXrLZAbJU8LZDUJU8LZMXrSnLZ$AgFnLaPXrDULbFYrMnLbMn8LXLboJgJgLeFbLg3LgLZrSnLgOYAgoLhrRnJlLkCTrSnLkOnLhrLnFX%AYLnFZoJXLnHTvJbLnLloAbMTATLf8MTHgJn3MTMXrAXMT3MTFnMUITvFnMXFX%AYMXMXvFbMXrFTDbMYAcMX3MbLf8SnMb8JbFnMgMXrMTMgvAXFnMgvGgCmMnAloSnMnFnJTrOXvMXSnOX8HTMnObJT8ScObLZFl3ObMXCZoPTLgrQXPUFnoQXPU3RXJlPX3RkQXPbrJXQlPlrJbFnQUAhrDbQXGnCXvQYLnHlvQbLfLnvRTOgvJbRXJYrQlRYLnrQlRbLnrQlRlFT8JlRlFnrQXSTClCn3STHTrAnSTLZQlrSTMnGTrSToHgGbSTrGTDnSTvGXCnST3HgFbSU3HXAXSbAnJn3SbFT8LnScLfLnv","AT3JgJX8AT8FZoSnAT8JgFV8AT8LhrDbAZ8JT8DbAb8GgLhrAb8SkLnvAe8MT8SnAlMYJXLVAl3GYDTvAl3LfLnvBUDTvLl3CTOn3HTrCT3DUGgrCU8MT8AbCbFTrJUoCgrDb8MTDTLV8JX8DTLnLXQlDT8LZrSnDUQb8FZ8DUST4JnvDb8ScOUoDj6GbJl4GTLfCYMlGToAXvFnGboAXvLnGgAcrJn3GgvFnSToGnLf8JnvGn#HTDToHTLnFXJlHTvATFToHTvHTDToHTvMTAgoHT3STClvHT4AlFl6HT8HTDToHUoDgJTrHUoScMX3HbRZrMXoHboJg8LTHgDb8JTrHgMToLf8HgvLnLnoHnHn3HT4Hn6MgvAnJTJU8ScvJT3AaQT8JT8HTrAnJXrRg8AnJbAloMXoJbrATFToJbvMnoSnJgDb6GgvJgDb8MXoJgSX3JU8JguATFToJlPYLnQlJlQkDnLbJlQlFYJlJl8Lf8OTJnCTFnLbJnLTHXMnJnLXGXCnJnoFfRg3JnrMYRg3Jn3HgFl3KT8Dg8LnLTRlFnPTLTvPbLbvLVoSbrCZLXMY6HT3LXNU7DlrLXNXDTATLX8DX8LnLZDb8JU8LZMnoLhrLZSToJU8LZrLaLnrLZvJn3SnLZ8LhrSnLaJnoMT8LbFlrHTvLbrFTLnrLbvATLlvLb6OTFn3LcLnJZOlLeAT6Mn4LeJT3ObrLg6LXFlrLhrJg8LnLhvDlPX4LhvLfLnvLj6JTFT3LnFbrMXoLnQluCTvLnrQXCY6LnvLfLnvLnvMgLnvLnvSeLf8MTMbrJn3MT3JgST3MT8AnATrMT8LULnrMUMToCZrMUScvLf8MXoDT8SnMX6ATFToMX8AXMT8MX8FkMT8MX8HTrDUMX8ScoSnMYJT6CTvMgAcrMXoMg8SToAfMlvAXLg3MnFl3AnvOT3AnFl3OUoATHT8OU3RnLXrOXrOXrSnObPbvFn6Og8HgrSnOg8OX8DbPTvAgoJgPU3RYLnrPXrDnJZrPb8CTGgvPlrLTDlvPlvFUJnoQUvFXrQlQeMnoAl3QlrQlrSnRTFTrJUoSTDlLiLXSTFg6HT3STJgoMn4STrFTJTrSTrLZFl3ST4FnMXoSUrDlHUoScvHTvSnSfLkvMXo","AUoAcrMXoAZ8HboAg8AbOg6ATFgAg8AloMXoAl3AT8JTrAl8MX8MXoCT3SToJU8Cl8Db8MXoDT8HgrATrDboOT8MXoGTOTrATMnGT8LhrAZ8GnvFnGnQXHToGgvAcrHTvAXvLl3HbrAZoMXoHgBlFXLg3HgMnFXrSnHgrSb8JUoHn6HT8LgvITvATrJUoJUoLZrRnvJU8HT8Jb8JXvFX8QT8JXvLToJTrJYrQnGnQXJgrJnoATrJnoJU8ScvJnvMnvMXoLTCTLgrJXLTJlRTvQlLbRnJlQYvLbrMb8LnvLbvFn3RnoLdCVSTGZrLeSTvGXCnLg3MnoLn3MToLlrETvMT8SToAl3MbrDU6GTvMb8LX4LhrPlrLXGXCnSToLf8Rg3STrDb8LTrSTvLTHXMnSb3RYLnMnSgOg6ATFg","HUDlGnrQXrJTrHgLnrAcJYMb8DULc8LTvFgGnCk3Mg8JbAnLX4QYvFYHnMXrRUoJnGnvFnRlvFTJlQnoSTrBXHXrLYSUJgLfoMT8Se8DTrHbDb","AbDl8SToJU8An3RbAb8ST8DUSTrGnrAgoLbFU6Db8LTrMg8AaHT8Jb8ObDl8SToJU8Pb3RlvFYoJl"];let s=null;function u(){if(null!=s)return s;const e=[];a.forEach(((t,r)=>{r+=4;for(let o=0;o=40?n=n+168-40:n>=19&&(n=n+97-19),(0,i.toUtf8String)(new Uint8Array([225,132+(n>>6),128+(63&n)])));e.push(a)}var n})),e.sort();if("0xf9eddeace9c5d3da9c93cf7d3cd38f6a13ed3affb933259ae865714e8a3ae71a"!==(0,n.id)(e.join("\n")+"\n"))throw new Error("BIP39 Wordlist for ko (Korean) FAILED");return s=e,e}let c=null;class l extends o.Wordlist{constructor(){super("ko")}getWord(e){const t=u();return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangPt=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("pt","0arad!ototealirertainrasoent hoandoaR#riareha!aroele'oronul0Aca%AixoAl A%rDuz'El]Er$IsmoO$ Rum S-&T(i&TigoVo[=0F&.Il#P' S?S* So&/Sun$Tr&0Ac#Adu+Al/A[f E End(Er_EuIng'Ir?IvoOl{oRac Revi=RizU&Um0Di$rM-.R>o+TismoT|@Tu 0Ali An%Ar@Ent&Es,I?Is Ul,1Ila1Ar E=Ei%Ulejo:B BosaC&]uCh `C@GagemI+c>~/Se#S)n%Ta)Te=rTidaTomTuc Unil]3B(IjoIr^IsebolLd!eLezaLgaLisc Ndi$Ng&aNz(RimbauRl*d>_Sou_XigaZ(_3CoCu=En&Foc&Furc G|naLhe%Mest[Mo$rOlog@OmboOsf(aPol Rr-$Scoi$Sne$SpoSsex$TolaZ _2Ind#OcoOque 2A$BagemC#CejoChec]Ico.L^LetimL]LoMb{oNdeNecoNi)Rb~h>d>e&R+c]V*oXe?2AncoAsaAvezaEuIgaIl/Inc OaOchu+Onze O$Uxo2C]DismoF LeRacoScaS$Z*a:Bimb Rn{oRpe%R['>)zRv&/SacoScaSeb[S%loS~oT a)Tiv UleUs?U%l V&oV(na3BolaDil]G}]Lebr L~ Nou+N,N%ioRc Rr#R%'oRvejaTimV^2Aco)Al{aAm#Ap^ArmeAticeAveEfeEg^E'oEqueIco%If[In`oOc&/Ov(UmboU.Uva0CatrizCl}eD!eD['aEn%Gcui$Rurg@T 2A[zaE_Ic OneUbe2A=Ag'Ba@B($rBr C^El/Ent_E,Gum`oIb'IfaIo%L L{aLh(Lid'Lme@L}oLunaM<=Mb* M-.MitivaMov(MplexoMumNc]N=rNec.Nfu,Ng` Nhec(Njug Nsum'Nt+$Nvi%Op( P{oPi?PoQue%lRagemRdi&Rne)R}h>p|&R[ioR%joRuj>voSs-oS%laT}e%U_UveVilZ*]2A%+AvoEcheE=rEmeErEspoI^Im*&Io~oIseItic Os)UaUz{o2B+m SafioSbo.Sc<,S-/Sfi#Sgas%Sigu&SlizeSmam SovaSpesaS)queSvi T&h T-$rT} Tri$UsaV(Vi=Vot#Z-a3Ag+maAle$Da)Fu,Gi.Lat#Lu-%M*u'Nast@Nh{oOceseRe$Sc[)Sf ceSp oSque%Ssip S)n%T?UrnoV(,Vi,rV~g Z(5Br?L|i=M?M*#NativoNz`>m-%Rs&SagemUr#U$r2EnagemIbleOg @2El EndeE$PloQues><%Vi=,:1Lod'O Olog@0Ific It&Uc#1Ei$Etiv 3E.1Ab| Eg(Ei$rEncoEv?Im* Ogi 0B goBol#Br~/Buti=EndaErg'Is,rPat@P-/P*#Polg P[goPurr Ul?0CaixeC-#Ch-%C}t_Deus Doss Faix Fei%FimGaj#G-/Glob Gom#G+x Gu@Jo La.Qu<$Raiz Rol#Rug SaioSe^S*oSop#T<$Te#Tid!eT|.Tr^T~/V(g Vi#Volv(XameX($Xof[Xu$1Id(me0Uip 0E$Gui=Ra)VaVil]0Bopeu0Acu Ap| AsivoEntu&Id-%Olu'1Ag(oAl Am* A$Aus$Ces,Ci.Clam Ecu.EmploIb'Ig-%On( Pof>p>tu+T@T|V|i)X*aZ-da3Ch#Ijo^I+n%L*oM**oNdaNoR>i#RrugemRv(S%j T&Ud&3ApoB_seC Ch{oGur#L{aL/LmeLtr RmezaSg^Ssu+TaV`aX?Xo2AcidezAm*goAn`aEch^O+Utu Uxo2C&C*/Foc GoGue%IceLg#Lhe$Rj Rmig>noR%ScoSsa2Aga)AldaAngoAscoA%rnoE'aEn%E.IezaI,Itu+On]Ustr U%'a2G'L+faSodu$S$TaTil/Ve)Z`a3L#Le@LoM^M(Mi=N(o,NgivaNi&NomaN_Ologi>?Rm* S,S$r3Nas)Nc*o2Aci&IcoseOb&Orio,2ElaIabaLfeLpe Rdu+Rje)R_S$,T{aV(n 2AcejoAdu&Afi%Al]AmpoAn^Atui$Ave$AxaEgoElh EveIloIs&/I.@Os,O%scoUd#Unhi=U)2AcheA+niAx*imEr[ I Inc/Is#LaLo,Ru:Bi.Rm}@S%V(3C.eRd Res@Si.3A$B(n D+.EnaNoPismoPnosePo%ca5JeLofo%MemNes$Nr#Rm}&Sped 5M|#:Te2E@O,2N|#RejaUdimR_SmimToV&iZida3Jum9An*]Elh^G?I>n&Rr Vem5BaDeuDocaIzLg?L/R#Ris)RoS)::B edaB|&C[C)n%Dril/G )GoaJeMb(M-.M* MpejoNchePid P,R{>gu+S<]St_T(&Ti=VfimRgemR*/Rmi)Ro$RquiseR[coR%loRujoSco%Sm|+SsagemStig Tag&T(noT*&Tu.Xil 3D&]DidaDusaGaf}eIgaLc/Sc~ SeuSic&:Ci}&D?JaMo_R*>r#Sc(TivaTu[zaV&]Veg Vio3Bl*aB~o,GativaGoci Gri$Rvo,TaUr&VascaVo{o3N N/TidezV` 5B[zaI%IvaMe M*&Rdes%R% T Tici TurnoV`oVil/Vo5Bl#DezM(&Pci&Tr'Vem:0Cec#Edec(JetivoRig#Scu_S%t+T(Tur 0Id-%Io,Orr(Ulis)Up#2Eg<%EnsivaEr-daIc*aUsc#0Iva4Ar@Eo,H Iv{a0B_Ele%Is,It'0D~#E_,Tem1Ci}&Er?On-%OrtunoOs$1ArBi.DemD*&Fci&Rd&RedeRtidaSmoSs#S%lTam T-%T* T_noUl^Us 3C~i D& Dest[D@t+D+G^I$r&IxeLeLicplexoRsi<>%nceRucaSc#SquisaS,aTisc 3AdaC#Ed!eGm-$Last+Lh#Lo.M-)Nc`NguimN]No%N.On{oPocaQue%ResRue)Sc S$laTg-$Rje)Tur Ud!eXof}eZ}&3C C~ DaD-$Di#Do,Du$rGm-$G[=Gun=IvaLe$LvagemM<&M-%N?N/rNsu&Nt#P #Rei>*g>+RvoTemb_T|3GiloLhue)Lic}eMetr@Mpat@M~ N&Nc(oNg~ NopseN$ni>-eRiTu#5B(fis)Rp[s>[&Rt'Sp'oS%n$:B`aBle%Bu^C/G `aLh(LoLvezMdioRef>j>+xaTuagemUr*oXativoXis)3Atr&C(Ci=Cl#Dio,IaIm Lef}eLh#Mp(oN-%N,rN.Rm&RnoRr-oSeSou+St#ToXtu+Xugo3A+G`aJoloMbr MidezNgi=N%'oRagemT~ 5Al]C]L( LiceM^Mil/N`Ntu+Pe%R>ci=RneioRqueRr!>$S.UcaUp{aX*a2Ab&/Acej Adu$rAfeg Aje$AmaAnc ApoAs{oAt?Av E*oEm(Epid EvoIagemIboIcicloId-%Ilog@Ind!eIploItur Iunf&Oc Ombe)OvaUnfoUque2B~ CquesaT` T|i&:7V 3Bigo0HaId!eIf|me3Olog@SoTigaUbu0A=InaUfru':C*aDi G o,I=,LaL-%Lid!eLo[sN)gemQu{oRe)Rr(Sc~ Sil]S,u+Z Zio3A=D Ge.Ic~ L{oLhiceLu=Nce=rNdav&N( Nt[Rb&Rd!eRe?Rg}h>m`/RnizRs R%n%SpaSti=T|i&3Adu$AgemAj Atu+Br?D{aDr @ElaGaG-%Gi G| L ejoNcoNhe)NilOle)R!>tudeSi.S$Tr&V{oZ*/5A=rArG&L<%LeibolL)gemLumo,Nt!e5L$Vuz`a::D[zRope3QueRe.Rife3Ng ::Ng#Rp 3BuL?9Mb Olog@5Mbi=","0x2219000926df7b50d8aa0a3d495826b988287df4657fbd100e6fe596c8f737ac")}static wordlist(){return null==i&&(i=new o),i}}t.LangPt=o},64065:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangZh=void 0;const n=r(98336),i=r(42120),o=r(51208),a="}aE#4A=Yv&co#4N#6G=cJ&SM#66|/Z#4t&kn~46#4K~4q%b9=IR#7l,mB#7W_X2*dl}Uo~7s}Uf&Iw#9c&cw~6O&H6&wx&IG%v5=IQ~8a&Pv#47$PR&50%Ko&QM&3l#5f,D9#4L|/H&tQ;v0~6n]nN>2),128+c.indexOf(a[3*n+1]),128+c.indexOf(a[3*n+2])];if("zh_tw"===e){for(let e=o%4;e<3;e++)s[e]=c.indexOf("FAZDC6BALcLZCA+GBARCW8wNCcDDZ8LVFBOqqDUiou+M42TFAyERXFb7EjhP+vmBFpFrUpfDV2F7eB+eCltCHJFWLFCED+pWTojEIHFXc3aFn4F68zqjEuKidS1QBVPDEhE7NA4mhMF7oThD49ot3FgtzHFCK0acW1x8DH1EmLoIlrWFBLE+y5+NA3Cx65wJHTaEZVaK1mWAmPGxgYCdxwOjTDIt/faOEhTl1vqNsKtJCOhJWuio2g07KLZEQsFBUpNtwEByBgxFslFheFbiEPvi61msDvApxCzB6rBCzox7joYA5UdDc+Cb4FSgIabpXFAj3bjkmFAxCZE+mD/SFf/0ELecYCt3nLoxC6WEZf2tKDB4oZvrEmqFkKk7BwILA7gtYBpsTq//D4jD0F0wEB9pyQ1BD5Ba0oYHDI+sbDFhvrHXdDHfgFEIJLi5r8qercNFBgFLC4bo5ERJtamWBDFy73KCEb6M8VpmEt330ygCTK58EIIFkYgF84gtGA9Uyh3m68iVrFbWFbcbqiCYHZ9J1jeRPbL8yswhMiDbhEhdNoSwFbZrLT740ABEqgCkO8J1BLd1VhKKR4sD1yUo0z+FF59Mvg71CFbyEhbHSFBKEIKyoQNgQppq9T0KAqePu0ZFGrXOHdKJqkoTFhYvpDNyuuznrN84thJbsCoO6Cu6Xlvntvy0QYuAExQEYtTUBf3CoCqwgGFZ4u1HJFzDVwEy3cjcpV4QvsPaBC3rCGyCF23o4K3pp2gberGgFEJEHo4nHICtyKH2ZqyxhN05KBBJIQlKh/Oujv/DH32VrlqFdIFC7Fz9Ct4kaqFME0UETLprnN9kfy+kFmtQBB0+5CFu0N9Ij8l/VvJDh2oq3hT6EzjTHKFN7ZjZwoTsAZ4Exsko6Fpa6WC+sduz8jyrLpegTv2h1EBeYpLpm2czQW0KoCcS0bCVXCmuWJDBjN1nQNLdF58SFJ0h7i3pC3oEOKy/FjBklL70XvBEEIWp2yZ04xObzAWDDJG7f+DbqBEA7LyiR95j7MDVdDViz2RE5vWlBMv5e4+VfhP3aXNPhvLSynb9O2x4uFBV+3jqu6d5pCG28/sETByvmu/+IJ0L3wb4rj9DNOLBF6XPIODr4L19U9RRofAG6Nxydi8Bki8BhGJbBAJKzbJxkZSlF9Q2Cu8oKqggB9hBArwLLqEBWEtFowy8XK8bEyw9snT+BeyFk1ZCSrdmgfEwFePTgCjELBEnIbjaDDPJm36rG9pztcEzT8dGk23SBhXBB1H4z+OWze0ooFzz8pDBYFvp9j9tvFByf9y4EFdVnz026CGR5qMr7fxMHN8UUdlyJAzlTBDRC28k+L4FB8078ljyD91tUj1ocnTs8vdEf7znbzm+GIjEZnoZE5rnLL700Xc7yHfz05nWxy03vBB9YGHYOWxgMQGBCR24CVYNE1hpfKxN0zKnfJDmmMgMmBWqNbjfSyFCBWSCGCgR8yFXiHyEj+VtD1FB3FpC1zI0kFbzifiKTLm9yq5zFmur+q8FHqjoOBWsBPiDbnCC2ErunV6cJ6TygXFYHYp7MKN9RUlSIS8/xBAGYLzeqUnBF4QbsTuUkUqGs6CaiDWKWjQK9EJkjpkTmNCPYXL"[r++])+(0==e?228:128)}t.push((0,i.toUtf8String)(new Uint8Array(s)))}if((0,n.id)(t.join("\n")+"\n")!==u[e])throw new Error(`BIP39 Wordlist for ${e} (Chinese) FAILED`);return s[e]=t,t}const f={};class h extends o.Wordlist{constructor(e){super("zh_"+e)}getWord(e){const t=l(this.locale);return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WordlistOwl=void 0;const n=r(98336),i=r(42120),o=r(82629),a=r(51208);class s extends a.Wordlist{#r;#Ot;constructor(e,t,r){super(e),this.#r=t,this.#Ot=r,this.#Rt=null}get _data(){return this.#r}_decodeWords(){return(0,o.decodeOwl)(this.#r)}#Rt;#Ct(){if(null==this.#Rt){const e=this._decodeWords();if((0,n.id)(e.join("\n")+"\n")!==this.#Ot)throw new Error(`BIP39 Wordlist for ${this.locale} FAILED`);this.#Rt=e}return this.#Rt}getWord(e){const t=this.#Ct();return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WordlistOwlA=void 0;const n=r(21978),i=r(84603);class o extends n.WordlistOwl{#Bt;constructor(e,t,r,n){super(e,t,n),this.#Bt=r}get _accent(){return this.#Bt}_decodeWords(){return(0,i.decodeOwlA)(this._data,this._accent)}}t.WordlistOwlA=o},51208:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Wordlist=void 0;const n=r(42120);t.Wordlist=class{locale;constructor(e){(0,n.defineProperties)(this,{locale:e})}split(e){return e.toLowerCase().split(/\s+/g)}join(e){return e.join(" ")}}},84311:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wordlists=void 0;const n=r(8838),i=r(10847),o=r(19321),a=r(42036),s=r(19642),u=r(86150),c=r(24555),l=r(58982),f=r(64065);t.wordlists={cz:n.LangCz.wordlist(),en:i.LangEn.wordlist(),es:o.LangEs.wordlist(),fr:a.LangFr.wordlist(),it:c.LangIt.wordlist(),pt:l.LangPt.wordlist(),ja:s.LangJa.wordlist(),ko:u.LangKo.wordlist(),zh_cn:f.LangZh.wordlist("cn"),zh_tw:f.LangZh.wordlist("tw")}},44946:e=>{"use strict";e.exports=JSON.parse('{"aes-128-ecb":{"cipher":"AES","key":128,"iv":0,"mode":"ECB","type":"block"},"aes-192-ecb":{"cipher":"AES","key":192,"iv":0,"mode":"ECB","type":"block"},"aes-256-ecb":{"cipher":"AES","key":256,"iv":0,"mode":"ECB","type":"block"},"aes-128-cbc":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes-192-cbc":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes-256-cbc":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes128":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes192":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes256":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes-128-cfb":{"cipher":"AES","key":128,"iv":16,"mode":"CFB","type":"stream"},"aes-192-cfb":{"cipher":"AES","key":192,"iv":16,"mode":"CFB","type":"stream"},"aes-256-cfb":{"cipher":"AES","key":256,"iv":16,"mode":"CFB","type":"stream"},"aes-128-cfb8":{"cipher":"AES","key":128,"iv":16,"mode":"CFB8","type":"stream"},"aes-192-cfb8":{"cipher":"AES","key":192,"iv":16,"mode":"CFB8","type":"stream"},"aes-256-cfb8":{"cipher":"AES","key":256,"iv":16,"mode":"CFB8","type":"stream"},"aes-128-cfb1":{"cipher":"AES","key":128,"iv":16,"mode":"CFB1","type":"stream"},"aes-192-cfb1":{"cipher":"AES","key":192,"iv":16,"mode":"CFB1","type":"stream"},"aes-256-cfb1":{"cipher":"AES","key":256,"iv":16,"mode":"CFB1","type":"stream"},"aes-128-ofb":{"cipher":"AES","key":128,"iv":16,"mode":"OFB","type":"stream"},"aes-192-ofb":{"cipher":"AES","key":192,"iv":16,"mode":"OFB","type":"stream"},"aes-256-ofb":{"cipher":"AES","key":256,"iv":16,"mode":"OFB","type":"stream"},"aes-128-ctr":{"cipher":"AES","key":128,"iv":16,"mode":"CTR","type":"stream"},"aes-192-ctr":{"cipher":"AES","key":192,"iv":16,"mode":"CTR","type":"stream"},"aes-256-ctr":{"cipher":"AES","key":256,"iv":16,"mode":"CTR","type":"stream"},"aes-128-gcm":{"cipher":"AES","key":128,"iv":12,"mode":"GCM","type":"auth"},"aes-192-gcm":{"cipher":"AES","key":192,"iv":12,"mode":"GCM","type":"auth"},"aes-256-gcm":{"cipher":"AES","key":256,"iv":12,"mode":"GCM","type":"auth"}}')},75207:e=>{"use strict";e.exports=JSON.parse('{"sha224WithRSAEncryption":{"sign":"rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"RSA-SHA224":{"sign":"ecdsa/rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"sha256WithRSAEncryption":{"sign":"rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"RSA-SHA256":{"sign":"ecdsa/rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"sha384WithRSAEncryption":{"sign":"rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"RSA-SHA384":{"sign":"ecdsa/rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"sha512WithRSAEncryption":{"sign":"rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA512":{"sign":"ecdsa/rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA1":{"sign":"rsa","hash":"sha1","id":"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{"sign":"ecdsa","hash":"sha1","id":""},"sha256":{"sign":"ecdsa","hash":"sha256","id":""},"sha224":{"sign":"ecdsa","hash":"sha224","id":""},"sha384":{"sign":"ecdsa","hash":"sha384","id":""},"sha512":{"sign":"ecdsa","hash":"sha512","id":""},"DSA-SHA":{"sign":"dsa","hash":"sha1","id":""},"DSA-SHA1":{"sign":"dsa","hash":"sha1","id":""},"DSA":{"sign":"dsa","hash":"sha1","id":""},"DSA-WITH-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-WITH-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-WITH-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-WITH-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-RIPEMD160":{"sign":"dsa","hash":"rmd160","id":""},"ripemd160WithRSA":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"RSA-RIPEMD160":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"md5WithRSAEncryption":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"},"RSA-MD5":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"}}')},1308:e=>{"use strict";e.exports=JSON.parse('{"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}')},29799:e=>{"use strict";e.exports=JSON.parse('{"modp1":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},"modp2":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},"modp5":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},"modp14":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},"modp15":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},"modp16":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},"modp17":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},"modp18":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}')},84064:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"assertionExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"}],"name":"createAssertion","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"deleteAssertion","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertion","outputs":[{"components":[{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"}],"internalType":"struct AssertionStructs.Assertion","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionChunksNumber","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionSize","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionTriplesNumber","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},64776:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"AssetExpired","type":"error"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"CommitPhaseOngoing","type":"error"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"CommitPhaseSucceeded","type":"error"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"FirstEpochHasAlreadyEnded","type":"error"},{"inputs":[{"internalType":"address","name":"assetStorage","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"NoPendingUpdate","type":"error"},{"inputs":[{"internalType":"address","name":"assetStorage","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"latestStateIndex","type":"uint256"}],"name":"PendingUpdateFinalization","type":"error"},{"inputs":[{"internalType":"address","name":"assetStorage","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"latestState","type":"bytes32"}],"name":"UpdateIsNotFinalized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"returnedTokenAmount","type":"uint96"}],"name":"AssetBurnt","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"bytes32","name":"state","type":"bytes32"}],"name":"AssetMinted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"AssetPaymentIncreased","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"stateIndex","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"returnedTokenAmount","type":"uint96"}],"name":"AssetStateUpdateCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"stateIndex","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"AssetStateUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"AssetStoringPeriodExtended","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"AssetUpdatePaymentIncreased","type":"event"},{"inputs":[],"name":"assertionContract","outputs":[{"internalType":"contract Assertion","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burnAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"cancelAssetStateUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"clearOldCommitsMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contentAssetStorage","outputs":[{"internalType":"contract ContentAssetStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"bool","name":"immutable_","type":"bool"}],"internalType":"struct ContentAssetStructs.AssetInputArgs","name":"args","type":"tuple"}],"name":"createAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"bool","name":"immutable_","type":"bool"}],"name":"createAssetWithVariables","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"extendAssetStoringPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"hashingProxy","outputs":[{"internalType":"contract HashingProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"increaseAssetTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"increaseAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"parametersStorage","outputs":[{"internalType":"contract ParametersStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"serviceAgreementStorageProxy","outputs":[{"internalType":"contract ServiceAgreementStorageProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"serviceAgreementV1","outputs":[{"internalType":"contract ServiceAgreementV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_flag","type":"bool"}],"name":"setOldMetadataClearingFlag","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unfinalizedStateStorage","outputs":[{"internalType":"contract UnfinalizedStateStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"updateAssetState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},44664:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assetAssertionId","type":"bytes32"}],"name":"assertionExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"deleteAssertionIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deleteAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"generateTokenId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getAssertionIdByIndex","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getAssertionIds","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getAssertionIdsLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint256","name":"assertionIndex","type":"uint256"}],"name":"getAssertionIssuer","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getAsset","outputs":[{"components":[{"internalType":"bool","name":"immutable_","type":"bool"},{"internalType":"bytes32[]","name":"assertionIds","type":"bytes32[]"}],"internalType":"struct ContentAssetStructs.Asset","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getLatestAssertionId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"isMutable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"issuers","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"pushAssertionId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"address","name":"issuer","type":"address"}],"name":"setAssertionIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bool","name":"immutable_","type":"bool"}],"name":"setMutability","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},67448:e=>{"use strict";e.exports=JSON.parse('[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"AssetStorageChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"ContractChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"NewAssetStorage","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"NewContract","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"getAllAssetStorages","outputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"internalType":"struct UnorderedNamedContractDynamicSetLib.Contract[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllContracts","outputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"internalType":"struct UnorderedNamedContractDynamicSetLib.Contract[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"assetStorageName","type":"string"}],"name":"getAssetStorageAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"contractName","type":"string"}],"name":"getContractAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"assetStorageAddress","type":"address"}],"name":"isAssetStorage","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"assetStorageName","type":"string"}],"name":"isAssetStorage","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"selectedContractAddress","type":"address"}],"name":"isContract","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"contractName","type":"string"}],"name":"isContract","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"assetStorageName","type":"string"},{"internalType":"address","name":"assetStorageAddress","type":"address"}],"name":"setAssetStorageAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"address","name":"newContractAddress","type":"address"}],"name":"setContractAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},11926:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"paranetKnowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"paranetTokenId","type":"uint256"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"KnowledgeAssetIsAPartOfOtherParanet","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetDoesntExist","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetHasAlreadyBeenRegistered","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetServiceDoesntExist","type":"error"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"paranetServiceId","type":"bytes32"}],"name":"ParanetServiceHasAlreadyBeenAdded","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetServiceHasAlreadyBeenRegistered","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"indexed":false,"internalType":"uint256","name":"knowledgeAssetTokenId","type":"uint256"}],"name":"KnowledgeAssetSubmittedToParanet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"string","name":"poolType","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"indexed":false,"internalType":"struct ParanetStructs.IncentivesPool","name":"incentivesPool","type":"tuple"}],"name":"ParanetIncetivesPoolDeployed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"newParanetName","type":"string"},{"indexed":false,"internalType":"string","name":"newParanetDescription","type":"string"}],"name":"ParanetMetadataUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"paranetName","type":"string"},{"indexed":false,"internalType":"string","name":"paranetDescription","type":"string"}],"name":"ParanetRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"indexed":false,"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"}],"name":"ParanetServiceAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"newParanetServiceName","type":"string"},{"indexed":false,"internalType":"string","name":"newParanetServiceDescription","type":"string"},{"indexed":false,"internalType":"address[]","name":"newParanetServiceAddresses","type":"address[]"}],"name":"ParanetServiceMetadataUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"paranetServiceName","type":"string"},{"indexed":false,"internalType":"string","name":"paranetServiceDescription","type":"string"},{"indexed":false,"internalType":"address[]","name":"paranetServiceAddresses","type":"address[]"}],"name":"ParanetServiceRegistered","type":"event"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"internalType":"struct ParanetStructs.UniversalAssetLocator[]","name":"services","type":"tuple[]"}],"name":"addParanetServices","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contentAsset","outputs":[{"internalType":"contract ContentAssetV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contentAssetStorage","outputs":[{"internalType":"contract ContentAssetStorageV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hashingProxy","outputs":[{"internalType":"contract HashingProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"bool","name":"immutable_","type":"bool"}],"internalType":"struct ContentAssetStructs.AssetInputArgs","name":"knowledgeAssetArgs","type":"tuple"}],"name":"mintKnowledgeAsset","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"paranetKnowledgeAssetsRegistry","outputs":[{"internalType":"contract ParanetKnowledgeAssetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetKnowledgeMinersRegistry","outputs":[{"internalType":"contract ParanetKnowledgeMinersRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetServicesRegistry","outputs":[{"internalType":"contract ParanetServicesRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"processUpdatedKnowledgeAssetStatesMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"string","name":"paranetName","type":"string"},{"internalType":"string","name":"paranetDescription","type":"string"}],"name":"registerParanet","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"internalType":"string","name":"paranetServiceName","type":"string"},{"internalType":"string","name":"paranetServiceDescription","type":"string"},{"internalType":"address[]","name":"paranetServiceAddresses","type":"address[]"}],"name":"registerParanetService","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"serviceAgreementStorageProxy","outputs":[{"internalType":"contract ServiceAgreementStorageProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_status","type":"bool"}],"name":"setStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"status","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"knowledgeAssetTokenId","type":"uint256"}],"name":"submitKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"string","name":"paranetName","type":"string"},{"internalType":"string","name":"paranetDescription","type":"string"}],"name":"updateParanetMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"internalType":"string","name":"paranetServiceName","type":"string"},{"internalType":"string","name":"paranetServiceDescription","type":"string"},{"internalType":"address[]","name":"paranetServiceAddresses","type":"address[]"}],"name":"updateParanetServiceMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},12936:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"poolType","type":"string"},{"internalType":"address","name":"poolAddress","type":"address"}],"name":"ParanetIncentivesPoolAlreadyExists","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"string","name":"poolType","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"indexed":false,"internalType":"struct ParanetStructs.IncentivesPool","name":"incentivesPool","type":"tuple"}],"name":"ParanetIncetivesPoolDeployed","type":"event"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"uint256","name":"tracToNeuroEmissionMultiplier","type":"uint256"},{"internalType":"uint16","name":"paranetOperatorRewardPercentage","type":"uint16"},{"internalType":"uint16","name":"paranetIncentivizationProposalVotersRewardPercentage","type":"uint16"}],"name":"deployNeuroIncentivesPool","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_status","type":"bool"}],"name":"setStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"status","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},88767:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"addedCumulativeAwardedNeuro","type":"uint256"}],"name":"addCumulativeAwardedNeuro","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"addedTracSpent","type":"uint96"}],"name":"addCumulativeTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"addSubmittedKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint96","name":"addedTracSpent","type":"uint96"}],"name":"addTotalTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"addedUnrewardedTracSpent","type":"uint96"}],"name":"addUnrewardedTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"addUpdatingKnowledgeAssetState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"},{"internalType":"uint96","name":"addedUpdateTokenAmount","type":"uint96"}],"name":"addUpdatingKnowledgeAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"decrementTotalSubmittedKnowledgeAssetsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"deleteKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getCumulativeAwardedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getCumulativeTracSpent","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"getKnowledgeMinerMetadata","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"totalTracSpent","type":"uint96"},{"internalType":"uint256","name":"totalSubmittedKnowledgeAssetsCount","type":"uint256"}],"internalType":"struct ParanetStructs.KnowledgeMinerMetadata","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getSubmittedKnowledgeAssets","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"getSubmittedKnowledgeAssets","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"getTotalSubmittedKnowledgeAssetsCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"getTotalTracSpent","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getUnrewardedTracSpent","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"getUpdatingKnowledgeAssetStates","outputs":[{"components":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"internalType":"struct ParanetStructs.UpdatingKnowledgeAssetState[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getUpdatingKnowledgeAssetStates","outputs":[{"components":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"internalType":"struct ParanetStructs.UpdatingKnowledgeAssetState[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"incrementTotalSubmittedKnowledgeAssetsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"knowledgeMinerExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"registerKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"removeSubmittedKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"}],"name":"removeUpdatingKnowledgeAssetState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"cumulativeAwardedNeuro","type":"uint256"}],"name":"setCumulativeAwardedNeuro","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"cumulativeTracSpent","type":"uint96"}],"name":"setCumulativeTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint256","name":"totalSubmittedKnowledgeAssetsCount","type":"uint256"}],"name":"setTotalSubmittedKnowledgeAssetsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint96","name":"totalTracSpent","type":"uint96"}],"name":"setTotalTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"unrewardedTracSpent","type":"uint96"}],"name":"setUnrewardedTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"setUpdatingKnowledgeAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"subtractedCumulativeAwardedNeuro","type":"uint256"}],"name":"subCumulativeAwardedNeuro","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"subtractedTracSpent","type":"uint96"}],"name":"subCumulativeTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint96","name":"subtractedTracSpent","type":"uint96"}],"name":"subTotalTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"subtractedUnrewardedTracSpent","type":"uint96"}],"name":"subUnrewardedTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"},{"internalType":"uint96","name":"subtractedUpdateTokenAmount","type":"uint96"}],"name":"subUpdatingKnowledgeAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},64004:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"},{"internalType":"address","name":"paranetsRegistryAddress","type":"address"},{"internalType":"address","name":"knowledgeMinersRegistryAddress","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"tracToNeuroEmissionMultiplier","type":"uint256"},{"internalType":"uint16","name":"paranetOperatorRewardPercentage_","type":"uint16"},{"internalType":"uint16","name":"paranetIncentivizationProposalVotersRewardPercentage_","type":"uint16"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"currentCumulativeWeight","type":"uint96"},{"internalType":"uint96","name":"targetCumulativeWeight","type":"uint96"}],"name":"InvalidCumulativeVotersWeight","type":"error"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"claimer","type":"address"}],"name":"NoRewardAvailable","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldMultiplier","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newMultiplier","type":"uint256"}],"name":"NeuroEmissionMultiplierUpdateFinalized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldMultiplier","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newMultiplier","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"NeuroEmissionMultiplierUpdateInitiated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"NeuroRewardDeposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"voter","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ParanetIncentivizationProposalVoterRewardClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"miner","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ParanetKnowledgeMinerRewardClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ParanetOperatorRewardClaimed","type":"event"},{"inputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"}],"internalType":"struct ParanetStructs.ParanetIncentivizationProposalVoterInput[]","name":"voters_","type":"tuple[]"}],"name":"addVoters","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimIncentivizationProposalVoterReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimKnowledgeMinerReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimParanetOperatorReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"claimedMinerRewards","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"claimedMinerRewardsIndexes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"claimedOperatorRewards","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"claimedOperatorRewardsIndexes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cumulativeVotersWeight","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"finalizeNeuroEmissionMultiplierUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getAllRewardedMiners","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivesPoolClaimedRewardsProfile[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllRewardedOperators","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivesPoolClaimedRewardsProfile[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableAllKnowledgeMinersRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableAllProposalVotersRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableKnowledgeMinerRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableParanetOperatorRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableProposalVoterRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"getEffectiveNeuroEmissionMultiplier","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNeuroBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNeuroEmissionMultipliers","outputs":[{"components":[{"internalType":"uint256","name":"multiplier","type":"uint256"},{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"bool","name":"finalized","type":"bool"}],"internalType":"struct ParanetStructs.NeuroEmissionMultiplier[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalAllKnowledgeMinersIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalAllProposalVotersIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalKnowledgeMinerIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalParanetOperatorIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalProposalVoterIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"voterAddress","type":"address"}],"name":"getVoter","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivizationProposalVoter","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getVoters","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivizationProposalVoter[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getVotersCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"newMultiplier","type":"uint256"}],"name":"initiateNeuroEmissionMultiplierUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"isKnowledgeMiner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"isParanetOperator","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"isProposalVoter","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"minerAddress","type":"address"}],"name":"minerClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"neuroEmissionMultiplierUpdateDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"neuroEmissionMultipliers","outputs":[{"internalType":"uint256","name":"multiplier","type":"uint256"},{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"bool","name":"finalized","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"operatorAddress","type":"address"}],"name":"operatorClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetIncentivizationProposalVotersRewardPercentage","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetKnowledgeMinersRegistry","outputs":[{"internalType":"contract ParanetKnowledgeMinersRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetOperatorRewardPercentage","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"parentParanetId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"limit","type":"uint256"}],"name":"removeVoters","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalMinersClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalNeuroReceived","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalOperatorsClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalVotersClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newRegistrar","type":"address"}],"name":"transferVotersRegistrarRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newDelay","type":"uint256"}],"name":"updateNeuroEmissionMultiplierUpdateDelay","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"voterAddress","type":"address"}],"name":"voterClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"voters","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"votersIndexes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"votersRegistrar","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]')},50575:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"addedKnowledgeValue","type":"uint96"}],"name":"addCumulativeKnowledgeValue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"addKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeMinerAddress","type":"address"}],"name":"addKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"serviceId","type":"bytes32"}],"name":"addService","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"deleteParanet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getAllIncentivesPools","outputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"internalType":"struct UnorderedNamedContractDynamicSetStructs.Contract[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getCumulativeKnowledgeValue","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getDescription","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"}],"name":"getIncentivesPoolAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeAssets","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeAssetsCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"},{"internalType":"uint256","name":"limit","type":"uint256"}],"name":"getKnowledgeAssetsStartingFromKnowledgeAssetId","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"offset","type":"uint256"},{"internalType":"uint256","name":"limit","type":"uint256"}],"name":"getKnowledgeAssetsWithPagination","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeMiners","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeMinersCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getName","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getParanetKnowledgeAssetLocator","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getParanetMetadata","outputs":[{"components":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"description","type":"string"},{"internalType":"uint96","name":"cumulativeKnowledgeValue","type":"uint96"}],"internalType":"struct ParanetStructs.ParanetMetadata","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getServices","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getServicesCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"hasIncentivesPoolByAddress","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"}],"name":"hasIncentivesPoolByType","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"isKnowledgeAssetRegistered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeMinerAddress","type":"address"}],"name":"isKnowledgeMinerRegistered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"serviceId","type":"bytes32"}],"name":"isServiceImplemented","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"paranetExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"paranetName","type":"string"},{"internalType":"string","name":"paranetDescription","type":"string"}],"name":"registerParanet","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"removeIncentivesPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"}],"name":"removeIncentivesPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"removeKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeMinerAddress","type":"address"}],"name":"removeKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"serviceId","type":"bytes32"}],"name":"removeService","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"cumulativeKnowledgeValue","type":"uint96"}],"name":"setCumulativeKnowledgeValue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"description","type":"string"}],"name":"setDescription","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"setIncentivesPoolAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"name_","type":"string"}],"name":"setName","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"subtractedKnowledgeValue","type":"uint96"}],"name":"subCumulativeKnowledgeValue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"updateIncentivesPoolAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},26758:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"agreementV1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"agreementV1StorageAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"agreementV1U1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"agreementV1U1StorageAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"commitSubmissionExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"commitV1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"commitV1U1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"name":"createV1CommitSubmissionObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint128","name":"epochLength","type":"uint128"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"uint8","name":"proofWindowOffsetPerc","type":"uint8"}],"name":"createV1ServiceAgreementObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"name":"createV1U1CommitSubmissionObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint128","name":"epochLength","type":"uint128"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"uint8","name":"proofWindowOffsetPerc","type":"uint8"}],"name":"createV1U1ServiceAgreementObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"decrementAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"decrementCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"deleteAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"deleteCommitSubmissionsObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"deleteCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"deleteServiceAgreementObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"deleteServiceAgreementV1Object","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"deleteServiceAgreementV1U1Object","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"stateId","type":"bytes32"}],"name":"deleteUpdateCommitsDeadline","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementData","outputs":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint128","name":"epochLength","type":"uint128"},{"internalType":"uint96[2]","name":"tokens","type":"uint96[2]"},{"internalType":"uint8[2]","name":"scoreFunctionIdAndProofWindowOffsetPerc","type":"uint8[2]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementEpochLength","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementEpochsNumber","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementProofWindowOffsetPerc","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getAgreementRewardedNodesNumber","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementScoreFunctionId","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementTokenAmount","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementUpdateTokenAmount","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmission","outputs":[{"components":[{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"internalType":"struct ServiceAgreementStructsV1.CommitSubmission","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionIdentityId","outputs":[{"internalType":"uint72","name":"","type":"uint72"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionNextIdentityId","outputs":[{"internalType":"uint72","name":"","type":"uint72"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionPrevIdentityId","outputs":[{"internalType":"uint72","name":"","type":"uint72"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionScore","outputs":[{"internalType":"uint40","name":"","type":"uint40"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"getCommitsCount","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"stateId","type":"bytes32"}],"name":"getUpdateCommitsDeadline","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getV1AgreementEpochSubmissionHead","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"uint256","name":"stateIndex","type":"uint256"}],"name":"getV1U1AgreementEpochSubmissionHead","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"incrementAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"incrementCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"migrateV1ServiceAgreement","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"serviceAgreementExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint128","name":"epochLength","type":"uint128"}],"name":"setAgreementEpochLength","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"}],"name":"setAgreementEpochsNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint8","name":"proofWindowOffsetPerc","type":"uint8"}],"name":"setAgreementProofWindowOffsetPerc","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"uint32","name":"rewardedNodesNumber","type":"uint32"}],"name":"setAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint8","name":"newScoreFunctionId","type":"uint8"}],"name":"setAgreementScoreFunctionId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint256","name":"startTime","type":"uint256"}],"name":"setAgreementStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"setAgreementTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"setAgreementUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"identityId","type":"uint72"}],"name":"setCommitSubmissionIdentityId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"}],"name":"setCommitSubmissionNextIdentityId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"}],"name":"setCommitSubmissionPrevIdentityId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint40","name":"score","type":"uint40"}],"name":"setCommitSubmissionScore","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"},{"internalType":"uint8","name":"epochStateCommitsCount","type":"uint8"}],"name":"setCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"stateId","type":"bytes32"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"setUpdateCommitsDeadline","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"bytes32","name":"headCommitId","type":"bytes32"}],"name":"setV1AgreementEpochSubmissionHead","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"uint256","name":"stateIndex","type":"uint256"},{"internalType":"bytes32","name":"headCommitId","type":"bytes32"}],"name":"setV1U1AgreementEpochSubmissionHead","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"storageV1","outputs":[{"internalType":"contract ServiceAgreementStorageV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"storageV1U1","outputs":[{"internalType":"contract ServiceAgreementStorageV1U1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"transferAgreementTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"transferV1AgreementTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"transferV1U1AgreementTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},60082:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ScoreError","type":"error"},{"inputs":[{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"}],"name":"ScoreFunctionDoesntExist","type":"error"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"TooLowAllowance","type":"error"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"TooLowBalance","type":"error"},{"inputs":[],"name":"ZeroEpochsNumber","type":"error"},{"inputs":[],"name":"ZeroTokenAmount","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"keyword","type":"bytes"},{"indexed":false,"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"indexed":false,"internalType":"uint256","name":"startTime","type":"uint256"},{"indexed":false,"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"indexed":false,"internalType":"uint128","name":"epochLength","type":"uint128"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"ServiceAgreementV1Created","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"indexed":false,"internalType":"uint16","name":"epochsNumber","type":"uint16"}],"name":"ServiceAgreementV1Extended","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"ServiceAgreementV1RewardRaised","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"ServiceAgreementV1Terminated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"indexed":false,"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"ServiceAgreementV1UpdateRewardRaised","type":"event"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"addTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"addUpdateTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"commitManagerV1","outputs":[{"internalType":"contract CommitManagerV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"commitManagerV1U1","outputs":[{"internalType":"contract CommitManagerV1U1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"assetCreator","type":"address"},{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"keyword","type":"bytes"},{"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"}],"internalType":"struct ServiceAgreementStructsV1.ServiceAgreementInputArgs","name":"args","type":"tuple"}],"name":"createServiceAgreement","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"extendStoringPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getChallenge","outputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint256","name":"challenge","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getTopCommitSubmissions","outputs":[{"components":[{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"internalType":"struct ServiceAgreementStructsV1.CommitSubmission[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hashingProxy","outputs":[{"internalType":"contract HashingProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"isCommitWindowOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"isProofWindowOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"parametersStorage","outputs":[{"internalType":"contract ParametersStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proofManagerV1","outputs":[{"internalType":"contract ProofManagerV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proofManagerV1U1","outputs":[{"internalType":"contract ProofManagerV1U1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"scoringProxy","outputs":[{"internalType":"contract ScoringProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"keyword","type":"bytes"},{"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"internalType":"bytes32","name":"chunkHash","type":"bytes32"}],"internalType":"struct ServiceAgreementStructsV1.ProofInputArgs","name":"args","type":"tuple"}],"name":"sendProof","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"serviceAgreementStorageProxy","outputs":[{"internalType":"contract ServiceAgreementStorageProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_status","type":"bool"}],"name":"setStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"status","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"keyword","type":"bytes"},{"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"internalType":"struct ServiceAgreementStructsV1.CommitInputArgs","name":"args","type":"tuple"}],"name":"submitCommit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"terminateAgreement","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"tokenContract","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},65177:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"string","name":"tokenName","type":"string"},{"internalType":"string","name":"tokenSymbol","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"minter","type":"address"}],"name":"setupRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]')},74066:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deleteIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deleteUnfinalizedState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getIssuer","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getUnfinalizedState","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"hasPendingUpdate","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"issuer","type":"address"}],"name":"setIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"state","type":"bytes32"}],"name":"setUnfinalizedState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},18597:e=>{"use strict";e.exports={i8:"6.5.4"}},22562:e=>{"use strict";e.exports=JSON.parse('{"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}')}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={id:n,loaded:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.loaded=!0,o.exports}r.amdO={},r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var n=r(46010);DKG=n})(); \ No newline at end of file +var DKG;(()=>{var e={16381:e=>{const t={PUBLIC:"public",PRIVATE:"private",ALL:"all"},r={N_QUADS:"n-quads",JSON_LD:"json-ld"},n={LATEST:"LATEST",FINALIZED:"LATEST_FINALIZED"},i={PUBLIC_KG:"PUBLIC_KG",LOCAL_KG:"LOCAL_KG"},o={CURRENT:"CURRENT",HISTORICAL:"HISTORICAL"},a={ENVIRONMENT:"mainnet",PORT:8900,FREQUENCY:5,MAX_NUMBER_OF_RETRIES:5,HASH_FUNCTION_ID:1,IMMUTABLE:!1,VALIDATE:!0,OUTPUT_FORMAT:r.JSON_LD,STATE:n.LATEST,CONTENT_TYPE:t.PUBLIC,GRAPH_LOCATION:i.LOCAL_KG,GRAPH_STATE:o.CURRENT,HANDLE_NOT_MINED_ERROR:!1,SIMULATE_TXS:!1,FORCE_REPLACE_TXS:!1,GAS_LIMIT_MULTIPLIER:1},s="high",u=["low","med",s,"all"];e.exports={MAX_FILE_SIZE:2621440,DID_PREFIX:"did:dkg",PRIVATE_ASSERTION_PREDICATE:"https://ontology.origintrail.io/dkg/1.0#privateAssertionID",ZERO_ADDRESS:"0x0000000000000000000000000000000000000000",BLOCKCHAINS:{development:{"hardhat1:31337":{rpc:"http://localhost:8545",hubContract:"0x5FbDB2315678afecb367f032d93F642f64180aa3"},"hardhat2:31337":{rpc:"http://localhost:9545",hubContract:"0x5FbDB2315678afecb367f032d93F642f64180aa3"},"otp:2043":{rpc:"http://parachain-alphanet-02.origin-trail.network:9933",hubContract:"0x7585a99C5C150a08f5CDeFD16465C6De8D41EbbD"}},devnet:{"otp:2160":{rpc:"https://lofar-tm-rpc.origin-trail.network",hubContract:"0x833048F6e6BEa78E0AAdedeCd2Dc2231dda443FB"},"gnosis:10200":{rpc:"https://rpc.chiadochain.net",hubContract:"0xD2bA102A0b11944d00180eE8136208ccF87bC39A",gasPriceOracleLink:"https://blockscout.chiadochain.net/api/v1/gas-price-oracle"},"base:84532":{hubContract:"0x6C861Cb69300C34DfeF674F7C00E734e840C29C0",rpc:"https://sepolia.base.org"}},testnet:{"otp:20430":{rpc:"https://lofar-testnet.origin-trail.network",hubContract:"0xBbfF7Ea6b2Addc1f38A0798329e12C08f03750A6"},"gnosis:10200":{rpc:"https://rpc.chiadochain.net",hubContract:"0xC06210312C9217A0EdF67453618F5eB96668679A",gasPriceOracleLink:"https://blockscout.chiadochain.net/api/v1/gas-price-oracle"},"base:84532":{hubContract:"0x144eDa5cbf8926327cb2cceef168A121F0E4A299",rpc:"https://sepolia.base.org"}},mainnet:{"otp:2043":{rpc:"https://astrosat-parachain-rpc.origin-trail.network",hubContract:"0x5fA7916c48Fe6D5F1738d12Ad234b78c90B4cAdA"},"gnosis:100":{rpc:"https://rpc.gnosischain.com/",hubContract:"0xbEF14fc04F870c2dD65c13Df4faB6ba01A9c746b",gasPriceOracleLink:"https://api.gnosisscan.io/api?module=proxy&action=eth_gasPrice"},"base:8453":{hubContract:"0xaBfcf2ad1718828E7D3ec20435b0d0b5EAfbDf2c",rpc:"https://mainnet.base.org"}}},BLOCKCHAINS_RENAME_PAIRS:{hardhat1:"hardhat1:31337",hardhat2:"hardhat2:31337","otp::devnet":"otp:2160","otp::testnet":"otp:20430","otp::mainnet":"otp:2043"},MAX_BLOCKCHAIN_CALL_RETRIES:3,TRANSACTION_RETRY_ERRORS:["transaction was not mined","already known","replacement transaction underpriced"],WEBSOCKET_PROVIDER_OPTIONS:{reconnect:{auto:!0,delay:1e3,maxAttempts:3},clientConfig:{keepalive:!0,keepaliveInterval:3e4}},OPERATIONS:{PUBLISH:"publish",GET:"get",UPDATE:"update",LOCAL_STORE:"local-store",QUERY:"query"},OPERATION_STATUSES:{PENDING:"PENDING",COMPLETED:"COMPLETED",FAILED:"FAILED"},ASSERTION_STATES:{LATEST:"latest",LATEST_FINALIZED:"latest_finalized"},CONTENT_TYPES:t,GET_OUTPUT_FORMATS:r,INCENTIVE_TYPE:{NEUROWEB:"Neuroweb"},ASSET_STATES:n,STORE_TYPES:{TRIPLE:"TRIPLE",PENDING:"PENDING"},GRAPH_LOCATIONS:i,GRAPH_STATES:o,OT_NODE_TRIPLE_STORE_REPOSITORIES:{PUBLIC_CURRENT:"publicCurrent",PUBLIC_HISTORY:"publicHistory",PRIVATE_CURRENT:"privateCurrent",PRIVATE_HISTORY:"privateHistory"},QUERY_TYPES:{CONSTRUCT:"CONSTRUCT",SELECT:"SELECT"},OPERATIONS_STEP_STATUS:{INCREASE_ALLOWANCE_COMPLETED:"INCREASE_ALLOWANCE_COMPLETED",CREATE_ASSET_COMPLETED:"CREATE_ASSET_COMPLETED",NETWORK_PUBLISH_COMPLETED:"NETWORK_PUBLISH_COMPLETED"},DEFAULT_GET_LOCAL_STORE_RESULT_FREQUENCY:.5,DEFAULT_PROXIMITY_SCORE_FUNCTIONS_PAIR_IDS:{development:{"hardhat1:31337":2,"hardhat2:31337":2,"otp:2043":2},devnet:{"otp:2160":2,"gnosis:10200":2,"base:84532":2},testnet:{"otp:20430":2,"gnosis:10200":2,"base:84532":2},mainnet:{"otp:2043":2,"gnosis:100":2,"base:8453":2}},DEFAULT_PARAMETERS:a,DEFAULT_GAS_PRICE:{GNOSIS:"20",OTP:"1"},LOW_BID_SUGGESTION:"low",MED_BID_SUGGESTION:"med",HIGH_BID_SUGGESTION:s,ALL_BID_SUGGESTION:"all",BID_SUGGESTION_RANGE_ENUM:u}},46010:(e,t,r)=>{const n=r(87128),i=r(65160),o=r(18538),a=r(2432),s=r(46792),u=r(83826),c=r(82689),l=r(76371);e.exports=class{constructor(e){const t=new l(e).getServices();this.assertion=new n(t),this.asset=new i(t),this.blockchain=new o(t),this.node=new u(t),this.graph=new a(t),this.network=new s(t),this.paranet=new c(t)}}},87128:(e,t,r)=>{const{assertionMetadata:n,calculateRoot:i,formatGraph:o}=r(50953);e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.inputService=e.inputService}async formatGraph(e){return o(e)}async getPublicAssertionId(e){const t=await o(e);return i(t.public)}async getSizeInBytes(e){const t=await o(e);return n.getAssertionSizeInBytes(t.public)}async getTriplesNumber(e){const t=await o(e);return n.getAssertionTriplesNumber(t.public)}async getChunksNumber(e){const t=await o(e);return n.getAssertionChunksNumber(t.public)}}},65160:(e,t,r)=>{const{assertionMetadata:n,calculateRoot:i,formatGraph:o}=r(50953),{ethers:a,ZeroHash:s}=r(59237),{deriveUAL:u,getOperationStatusObject:c,resolveUAL:l,toNQuads:f,toJSONLD:h,sleepForMilliseconds:d}=r(95200),{ASSET_STATES:p,CONTENT_TYPES:m,OPERATIONS:y,OPERATIONS_STEP_STATUS:g,GET_OUTPUT_FORMATS:b,OPERATION_STATUSES:v,DEFAULT_GET_LOCAL_STORE_RESULT_FREQUENCY:w,PRIVATE_ASSERTION_PREDICATE:A,STORE_TYPES:S,QUERY_TYPES:k,OT_NODE_TRIPLE_STORE_REPOSITORIES:E,ZERO_ADDRESS:_}=r(16381),M=r(54209);e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.validationService=e.validationService,this.blockchainService=e.blockchainService,this.inputService=e.inputService}async isValidUAL(e,t={}){if("string"!=typeof e||""===e.trim())throw new Error("UAL must be a non-empty string.");const r=this.inputService.getBlockchain(t);this.validationService.validateIsValidUAL(r);const n=e.split("/");if(3!==n.length)throw new Error("UAL format is incorrect.");const i=n[0].split(":");if(3!==i.length&&4!==i.length)throw new Error("Prefix format in UAL is incorrect.");if("did"!==i[0])throw new Error(`Invalid DID prefix. Expected: 'did'. Received: '${i[0]}'.`);if("dkg"!==i[1])throw new Error(`Invalid DKG prefix. Expected: 'dkg'. Received: '${i[1]}'.`);if(i[2]!==r.name.split(":")[0])throw new Error(`Invalid blockchain name in the UAL prefix. Expected: '${r.name.split(":")[0]}'. Received: '${i[2]}'.`);if(4===i.length){const e=await this.blockchainService.getChainId(r);if(Number(i[3])!==e)throw new Error(`Chain ID in UAL does not match the blockchain. Expected: '${e}'. Received: '${i[3]}'.`)}const o=await this.blockchainService.getContractAddress("ContentAssetStorage",r);if(n[1].toLowerCase()!==o.toLowerCase())throw new Error(`Contract address in UAL does not match. Expected: '${o}'. Received: '${n[1]}'.`);try{const e=await this.blockchainService.getAssetOwner(n[2],r);if(!e||e===_)throw new Error("Token does not exist or has no owner.");return!0}catch(e){throw new Error(`Error fetching asset owner: ${e.message}`)}}async setAllowance(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateSetAllowance(r);const n=await this.blockchainService.getContractAddress("ServiceAgreementV1",r),i=e-BigInt(await this.blockchainService.callContractFunction("Token","allowance",[r.publicKey,n],r));let o;return i>0?o=await this.blockchainService.executeContractFunction("Token","increaseAllowance",[n,i],r):i<0&&(o=await this.blockchainService.executeContractFunction("Token","decreaseAllowance",[n,-i],r)),o?{transactionHash:o.transactionHash,status:o.status}:{status:"Skipped: Allowance is already equal to the requested amount."}}async increaseAllowance(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateIncreaseAllowance(r);const n=await this.blockchainService.getContractAddress("ServiceAgreementV1",r),i=await this.blockchainService.executeContractFunction("Token","increaseAllowance",[n,e],r);return{transactionHash:i.transactionHash,status:i.status}}async decreaseAllowance(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateDecreaseAllowance(r);const n=await this.blockchainService.getContractAddress("ServiceAgreementV1",r),i=await this.blockchainService.callContractFunction("Token","allowance",[r.publicKey,n],r),o=await this.blockchainService.executeContractFunction("Token","decreaseAllowance",[n,BigInt(e)>BigInt(i)?i:e],r);return{transactionHash:o.transactionHash,status:o.status}}async getCurrentAllowance(e={}){const t=this.inputService.getBlockchain(e),r=await this.blockchainService.getContractAddress("ServiceAgreementV1",t),n=await this.blockchainService.callContractFunction("Token","allowance",[t.publicKey,r],t);return BigInt(n)}async create(e,t={},r=M){this.validationService.validateObjectType(e);let a={};e.public||e.private?a=e:a.public=e;const{blockchain:s,endpoint:f,port:h,maxNumberOfRetries:d,frequency:p,epochsNum:m,hashFunctionId:b,scoreFunctionId:A,immutable:k,tokenAmount:E,authToken:_,paranetUAL:T}=this.inputService.getAssetCreateArguments(t);this.validationService.validateAssetCreate(a,s,f,h,d,p,m,b,A,k,E,_,T);const{public:x,private:P}=await o(a),I=n.getAssertionSizeInBytes(x);this.validationService.validateAssertionSizeInBytes(I+(void 0===P?0:n.getAssertionSizeInBytes(P)));const O=i(x),R=await this.blockchainService.getContractAddress("ContentAssetStorage",s),C=E??await this.nodeApiService.getBidSuggestion(f,h,_,s.name,m,I,R,O,b);let B;if(null==T)B=await this.blockchainService.createAsset({publicAssertionId:O,assertionSize:I,triplesNumber:n.getAssertionTriplesNumber(x),chunksNumber:n.getAssertionChunksNumber(x),epochsNum:m,tokenAmount:C,scoreFunctionId:A??1,immutable_:k},null,null,s,r);else{const{contract:e,tokenId:t}=l(T);B=await this.blockchainService.createAsset({publicAssertionId:O,assertionSize:I,triplesNumber:n.getAssertionTriplesNumber(x),chunksNumber:n.getAssertionChunksNumber(x),epochsNum:m,tokenAmount:C,scoreFunctionId:A??1,immutable_:k},e,t,s,r)}const N={blockchain:s.name,contract:R,tokenId:B},L=[{...N,assertionId:O,assertion:x,storeType:S.TRIPLE}];P?.length&&L.push({...N,assertionId:i(P),assertion:P,storeType:S.TRIPLE});const U=u(s.name,R,B);let F=await this.nodeApiService.publish(f,h,_,O,x,s.name,R,B,b),D=await this.nodeApiService.getOperationResult(f,h,_,y.PUBLISH,d,p,F);return D.status===v.FAILED?{UAL:U,assertionId:O,operation:c(D,F)}:(F=await this.nodeApiService.localStore(f,h,_,L),D=await this.nodeApiService.getOperationResult(f,h,_,y.LOCAL_STORE,d,w,F),r.afterHook({status:g.CREATE_ASSET_COMPLETED,data:{operationId:F,operationResult:D}}),{UAL:U,publicAssertionId:O,operation:c(D,F)})}async get(e,t={}){const{blockchain:r,endpoint:n,port:o,maxNumberOfRetries:a,frequency:u,state:d,contentType:g,validate:v,outputFormat:w,authToken:S,hashFunctionId:_}=this.inputService.getAssetGetArguments(t);this.validationService.validateAssetGet(e,r,n,o,a,u,d,g,_,v,w,S);const{tokenId:M}=l(e);let T,x=!1;if(d===p.LATEST){const e=await this.blockchainService.getUnfinalizedState(M,r);null!=e&&e!==s&&(T=e,x=!1)}let P=[];const I=Object.values(p).includes(d);if(!T)if(P=await this.blockchainService.getAssertionIds(M,r),I)T=P[P.length-1],x=!0;else if("number"==typeof d){if(d>=P.length)throw new Error("State index is out of range.");T=P[d],d===P.length-1&&(x=!0)}else if(P.includes(d))T=d,d===P[P.length-1]&&(x=!0);else{if(!/^0x[a-fA-F0-9]{64}$/.test(d))throw new Error("Incorrect state option.");{const e=await this.blockchainService.getUnfinalizedState(M,r);if(null==e||e===s||d!==e)throw new Error("Given state hash isn't a part of the Knowledge Asset.");T=e,x=!1}}const O=await this.nodeApiService.get(n,o,S,e,I?d:T,_),R=await this.nodeApiService.getOperationResult(n,o,S,y.GET,a,u,O);if(!R.data.assertion)return"FAILED"!==R.status&&(R.data={errorType:"DKG_CLIENT_ERROR",errorMessage:"Unable to find assertion on the network!"},R.status="FAILED"),{operation:{publicGet:c(R,O)}};const C=R.data.assertion;!0===v&&i(C)!==T&&(R.data={errorType:"DKG_CLIENT_ERROR",errorMessage:"Calculated root hashes don't match!"});let B={operation:{}};if(g!==m.PRIVATE){let e=C;try{e=w!==b.N_QUADS?await h(C.join("\n")):C.join("\n")}catch(e){R.data={errorType:"DKG_CLIENT_ERROR",errorMessage:e.message}}g===m.PUBLIC?B={...B,assertion:e,assertionId:T}:B.public={assertion:e,assertionId:T},B.operation.publicGet=c(R,O)}if(g!==m.PUBLIC){const e=C.filter((e=>e.includes(A))),t=e.length>0?e[0]:null;let r,s={};if(t){const e=t.match(/"(.*?)"/)[1];let l,d;if(R?.data?.privateAssertion?.length)l=R.data.privateAssertion;else{const t=`\n CONSTRUCT { ?s ?p ?o }\n WHERE {\n {\n GRAPH \n {\n ?s ?p ?o .\n }\n }\n }`;r=await this.nodeApiService.query(n,o,S,t,k.CONSTRUCT,x?E.PRIVATE_CURRENT:E.PRIVATE_HISTORY),s=await this.nodeApiService.getOperationResult(n,o,S,y.QUERY,a,u,r);const i=s.data;l=await f(i,"application/n-quads")}l.length&&!0===v&&i(l)!==e&&(s.data={errorType:"DKG_CLIENT_ERROR",errorMessage:"Calculated root hashes don't match!"});try{d=w!==b.N_QUADS?await h(l.join("\n")):l.join("\n")}catch(e){s.data={errorType:"DKG_CLIENT_ERROR",errorMessage:e.message}}g===m.PRIVATE?B={...B,assertion:d,assertionId:e}:B.private={assertion:d,assertionId:e},r&&(B.operation.queryPrivate=c(s,r))}}return B}async update(e,t,r={}){this.validationService.validateObjectType(t);const a=t,{blockchain:s,endpoint:u,port:f,maxNumberOfRetries:h,frequency:d,hashFunctionId:p,scoreFunctionId:m,tokenAmount:g,authToken:b}=this.inputService.getAssetUpdateArguments(r);this.validationService.validateAssetUpdate(a,s,u,f,h,d,p,m,g,b);const{tokenId:A}=l(e),{public:k,private:E}=await o(a),_=n.getAssertionSizeInBytes(k);this.validationService.validateAssertionSizeInBytes(_+(void 0===E?0:n.getAssertionSizeInBytes(E)));const M=i(k),T=await this.blockchainService.getContractAddress("ContentAssetStorage",s);let x;x=null!=g?g:await this._getUpdateBidSuggestion(e,s,u,f,b,M,_,p),await this.blockchainService.updateAsset(A,M,_,n.getAssertionTriplesNumber(k),n.getAssertionChunksNumber(k),x,s);const P={blockchain:s.name,contract:T,tokenId:A},I=[{...P,assertionId:M,assertion:k,storeType:S.PENDING}];E?.length&&I.push({...P,assertionId:i(E),assertion:E,storeType:S.PENDING});let O=await this.nodeApiService.localStore(u,f,b,I),R=await this.nodeApiService.getOperationResult(u,f,b,y.LOCAL_STORE,h,w,O);return R.status===v.FAILED?{UAL:e,assertionId:M,operation:c(R,O)}:(O=await this.nodeApiService.update(u,f,b,M,k,s.name,T,A,p),R=await this.nodeApiService.getOperationResult(u,f,b,y.UPDATE,h,d,O),{UAL:e,publicAssertionId:M,operation:c(R,O)})}async waitFinalization(e,t={}){const r=this.inputService.getBlockchain(t),n=this.inputService.getFrequency(t),i=this.inputService.getMaxNumberOfRetries(t);this.validationService.validateWaitAssetUpdateFinalization(e,r,n,i);const{tokenId:o}=l(e),a={status:v.PENDING};let s=!0,u=0;do{if(u>i){a.data={...a.data,data:{errorType:"DKG_CLIENT_ERROR",errorMessage:"Unable to get results. Max number of retries reached."}};break}u+=1,await d(1e3*n),s=await this.blockchainService.hasPendingUpdate(o,r)}while(s);return a.status=s?v.PENDING:v.COMPLETED,{UAL:e,operation:c({data:a.data,status:a.status},null)}}async cancelUpdate(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetUpdateCancel(e,r);const{tokenId:n}=l(e);return await this.blockchainService.cancelAssetUpdate(n,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async transfer(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateAssetTransfer(e,t,n);const{tokenId:i}=l(e);await this.blockchainService.transferAsset(i,t,n);return{UAL:e,owner:await this.blockchainService.getAssetOwner(i,n),operation:c({status:"COMPLETED"},null)}}async getOwner(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetGetOwner(e,r);const{tokenId:n}=l(e);return{UAL:e,owner:await this.blockchainService.getAssetOwner(n,r),operation:c({data:{},status:"COMPLETED"},null)}}async getStateIssuer(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateAssetGetStateIssuer(e,t,n);const{tokenId:i}=l(e),o=await this.blockchainService.getAssertionIdByIndex(i,t,n);return{UAL:e,issuer:await this.blockchainService.getAssertionIssuer(i,o,t,n),state:o,operation:c({data:{},status:"COMPLETED"},null)}}async getLatestStateIssuer(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetGetLatestStateIssuer(e,r);const{tokenId:n}=l(e),i=await this.blockchainService.getAssertionIds(n,r),o=i.length-1,a=i[o];return{UAL:e,issuer:await this.blockchainService.getAssertionIssuer(n,a,o,r),latestState:a,operation:c({data:{},status:"COMPLETED"},null)}}async getStates(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetGetStates(e,r);const{tokenId:n}=l(e);return{UAL:e,states:await this.blockchainService.getAssertionIds(n,r),operation:c({data:{},status:"COMPLETED"},null)}}async burn(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateAssetBurn(e,r);const{tokenId:n}=l(e);return await this.blockchainService.burnAsset(n,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async extendStoringPeriod(e,t,r={}){const n=this.inputService.getBlockchain(r),i=this.inputService.getTokenAmount(r);this.validationService.validateExtendAssetStoringPeriod(e,t,i,n);const{tokenId:o,contract:a}=l(e);let s;if(null!=i)s=i;else{const e=this.inputService.getEndpoint(r),i=this.inputService.getPort(r),u=this.inputService.getAuthToken(r),c=this.inputService.getHashFunctionId(r),l=await this.blockchainService.getLatestAssertionId(o,n),f=await this.blockchainService.getAssertionSize(l,n);s=await this.nodeApiService.getBidSuggestion(e,i,u,n.name,t,f,a,l,c)}return await this.blockchainService.extendAssetStoringPeriod(o,t,s,n),{UAL:e,operation:c({status:"COMPLETED"},null)}}async addTokens(e,t={}){const r=this.inputService.getBlockchain(t),n=this.inputService.getTokenAmount(t);this.validationService.validateAddTokens(e,n,r);const{tokenId:i}=l(e);let o;if(null!=n)o=n;else{const n=this.inputService.getEndpoint(t),a=this.inputService.getPort(t),s=this.inputService.getAuthToken(t),u=this.inputService.getHashFunctionId(t),c=await this.blockchainService.getLatestAssertionId(i,r),l=await this.blockchainService.getAssertionSize(c,r);if(o=await this._getUpdateBidSuggestion(e,r,n,a,s,c,l,u),o<=0)throw new Error("Token amount is bigger than default suggested amount, please specify exact tokenAmount if you still want to add more tokens!")}return await this.blockchainService.addTokens(i,o,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async addUpdateTokens(e,t={}){const r=this.inputService.getBlockchain(t),n=this.inputService.getTokenAmount(t);this.validationService.validateAddTokens(e,n,r);const{tokenId:i}=l(e);let o;if(null!=n)o=n;else{const n=this.inputService.getEndpoint(t),a=this.inputService.getPort(t),s=this.inputService.getAuthToken(t),u=this.inputService.getHashFunctionId(t),c=await this.blockchainService.getUnfinalizedState(i,r),l=await this.blockchainService.getAssertionSize(c,r);if(o=await this._getUpdateBidSuggestion(e,r,n,a,s,c,l,u),o<=0)throw new Error("Token amount is bigger than default suggested amount, please specify exact tokenAmount if you still want to add more tokens!")}return await this.blockchainService.addUpdateTokens(i,o,r),{UAL:e,operation:c({status:"COMPLETED"},null)}}async _getUpdateBidSuggestion(e,t,r,n,i,o,s,u){const{contract:c,tokenId:f}=l(e),h=await this.blockchainService.getAssertionIdByIndex(f,0,t),d=a.solidityPacked(["address","bytes32"],[c,h]),p=a.sha256(a.solidityPacked(["address","uint256","bytes"],[c,f,d])),m=await this.blockchainService.getAgreementData(p,t),y=await this.blockchainService.getBlockchainTimestamp(t),g=Math.floor((y-m.startTime)/m.epochLength),b=m.epochsNumber-g,v=await this.nodeApiService.getBidSuggestion(r,n,i,t.name,b,s,c,o,u),w=BigInt(v)-(BigInt(m.tokenAmount)+BigInt(m.updateTokenAmount??0));return w>0?w:0}async submitToParanet(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateSubmitToParanet(e,t,n);const{contract:i,tokenId:o}=l(e),{contract:a,tokenId:s}=l(t);return await this.blockchainService.submitToParanet({paranetContract:a,paranetTokenId:s,contract:i,tokenId:o},n),{UAL:e,operation:c({status:"COMPLETED"},null)}}}},18538:e=>{e.exports=class{constructor(e){this.blockchainService=e.blockchainService,this.inputService=e.inputService}async getChainId(e={}){const t=this.inputService.getBlockchain(e);return this.blockchainService.getChainId(t)}async getGasPrice(e={}){const t=this.inputService.getBlockchain(e);return this.blockchainService.getGasPrice(t)}async getWalletBalances(e={}){const t=this.inputService.getBlockchain(e);return this.blockchainService.getWalletBalances(t)}}},2432:(e,t,r)=>{const{OPERATIONS:n}=r(16381),{deriveRepository:i}=r(95200);e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.validationService=e.validationService,this.inputService=e.inputService}async query(e,t,r={}){const{graphLocation:o,graphState:a,endpoint:s,port:u,maxNumberOfRetries:c,frequency:l,authToken:f}=this.inputService.getQueryArguments(r);this.validationService.validateGraphQuery(e,t,o,a,s,u,c,l,f);const h=i(o,a),d=await this.nodeApiService.query(s,u,f,e,t,h);return this.nodeApiService.getOperationResult(s,u,f,n.QUERY,c,l,d)}}},46792:e=>{e.exports=class{constructor(e){this.inputService=e.inputService,this.blockchainService=e.blockchainService,this.nodeApiService=e.nodeApiService}async getBidSuggestion(e,t,r={}){const{blockchain:n,endpoint:i,port:o,epochsNum:a,hashFunctionId:s,authToken:u,bidSuggestionRange:c}=this.inputService.getBidSuggestionArguments(r),l=await this.blockchainService.getContractAddress("ContentAssetStorage",n),f=await this.nodeApiService.getBidSuggestion(i,o,u,n.name,a,t,l,e,s,c);return"string"==typeof f?BigInt(f):f}}},83826:e=>{e.exports=class{constructor(e){this.nodeApiService=e.nodeApiService,this.inputService=e.inputService}async info(e={}){const t=this.inputService.getEndpoint(e),r=this.inputService.getPort(e),n=this.inputService.getAuthToken(e);return(await this.nodeApiService.info(t,r,n)).data}}},82689:(e,t,r)=>{const{ethers:n}=r(59237),{resolveUAL:i}=r(95200),{INCENTIVE_TYPE:o}=r(16381);e.exports=class{constructor(e){this.blockchainService=e.blockchainService,this.inputService=e.inputService,this.nodeApiService=e.nodeApiService,this.validationService=e.validationService}async create(e,t={}){const{blockchain:r,paranetName:n,paranetDescription:o}=this.inputService.getParanetCreateArguments(t);this.validationService.validateParanetCreate(e,r,n,o);const{contract:a,tokenId:s}=i(e);return await this.blockchainService.registerParanet({contract:a,tokenId:s,paranetName:n,paranetDescription:o},r),{paranetUAL:e}}async deployIncentivesContract(e,t,r={}){const{blockchain:a,tracToNeuroEmissionMultiplier:s,operatorRewardPercentage:u,incentivizationProposalVotersRewardPercentage:c}=this.inputService.getParanetDeployIncentivesContractArguments(r);if(this.validationService.validateDeployIncentivesContract(e,a,s,u,c),t===o.NEUROWEB){const{contract:t,tokenId:r}=i(e);await this.blockchainService.deployNeuroIncentivesPool({contract:t,tokenId:r,tracToNeuroEmissionMultiplier:s,operatorRewardPercentage:u,incentivizationProposalVotersRewardPercentage:c},a);const o=n.keccak256(n.solidityPacked(["address","uint256"],[t,r]));return{paranetUAL:e,incentivesPoolContractAddress:await this.blockchainService.getNeuroIncentivesPoolAddress(o,a)}}throw Error(`Unsupported incentive type: ${t}.`)}async createService(e,t={}){const{blockchain:r,paranetServiceName:n,paranetServiceDescription:o,paranetServiceAddresses:a}=this.inputService.getParanetCreateServiceArguments(t);this.validationService.validateParanetCreateServiceArguments(e,n,o,a,r);const{contract:s,tokenId:u}=i(e);return await this.blockchainService.registerParanetService({contract:s,tokenId:u,paranetServiceName:n,paranetServiceDescription:o,paranetServiceAddresses:a},r),{serviceUAL:e}}async addServices(e,t,r={}){const n=this.inputService.getBlockchain(r);this.validationService.validateParanetAddServicesArguments(e,t,n);const{contract:o,tokenId:a}=i(e),s=[];for(const e of t){const{contract:t,tokenId:r}=i(e);s.push([t,r])}return await this.blockchainService.addParanetServices({contract:o,tokenId:a,processedServicesArray:s},n),{paranetUAL:e,paranetServiceUALs:t}}async claimMinerReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.claimKnowledgeMinerReward(s,r);return{transactionHash:u.transactionHash,status:u.status}}async claimVoterReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.claimVoterReward(s,r);return{transactionHash:u.transactionHash,status:u.status}}async claimOperatorReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.claimOperatorReward(s,r);return{transactionHash:u.transactionHash,status:u.status}}async getClaimableMinerReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableKnowledgeMinerReward(s,r)}async getClaimableAllMinersReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableAllKnowledgeMinersReward(s,r)}async getClaimableVoterReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableVoterReward(s,r)}async getClaimableAllVotersReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableAllVotersReward(s,r)}async getClaimableOperatorReward(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a]));return await this.blockchainService.getClaimableOperatorReward(s,r)}async updateClaimableRewards(e,t={}){const r=this.inputService.getBlockchain(t);this.validationService.validateParanetRewardArguments(e,r);const{contract:o,tokenId:a}=i(e),s=n.keccak256(n.solidityPacked(["address","uint256"],[o,a])),u=await this.blockchainService.getUpdatingKnowledgeAssetStates({miner:r.publicKey,paranetId:s},r);if(u.length>0){const e=await this.blockchainService.updateClaimableRewards({contract:o,tokenId:a,start:0,end:u.length},r);return{transactionHash:e.transactionHash,status:e.status}}return{status:"No updated knowledge assets."}}async isKnowledgeMiner(e,t={}){let{blockchain:r,roleAddress:o}=this.inputService.getParanetRoleCheckArguments(t);null==o&&(o=r.publicKey),this.validationService.validateParanetRoleCheckArguments(o,e,r);const{contract:a,tokenId:s}=i(e),u=n.keccak256(n.solidityPacked(["address","uint256"],[a,s]));return await this.blockchainService.isParanetKnowledgeMiner(o,u,r)}async isParanetOperator(e,t={}){let{blockchain:r,roleAddress:o}=this.inputService.getParanetRoleCheckArguments(t);null==o&&(o=r.publicKey),this.validationService.validateParanetRoleCheckArguments(o,e,r);const{contract:a,tokenId:s}=i(e),u=n.keccak256(n.solidityPacked(["address","uint256"],[a,s]));return await this.blockchainService.isParanetOperator(o,u,r)}async isProposalVoter(e,t={}){let{blockchain:r,roleAddress:o}=this.inputService.getParanetRoleCheckArguments(t);null==o&&(o=r.publicKey),this.validationService.validateParanetRoleCheckArguments(o,e,r);const{contract:a,tokenId:s}=i(e),u=n.keccak256(n.solidityPacked(["address","uint256"],[a,s]));return await this.blockchainService.isParanetProposalVoter(o,u,r)}}},48709:function(e){"use strict";!function(t){function r(e){return parseInt(e)===e}function n(e){if(!r(e.length))return!1;for(var t=0;t255)return!1;return!0}function i(e,t){if(e.buffer&&ArrayBuffer.isView(e)&&"Uint8Array"===e.name)return t&&(e=e.slice?e.slice():Array.prototype.slice.call(e)),e;if(Array.isArray(e)){if(!n(e))throw new Error("Array contains invalid value: "+e);return new Uint8Array(e)}if(r(e.length)&&n(e))return new Uint8Array(e);throw new Error("unsupported array-like object")}function o(e){return new Uint8Array(e)}function a(e,t,r,n,i){null==n&&null==i||(e=e.slice?e.slice(n,i):Array.prototype.slice.call(e,n,i)),t.set(e,r)}var s,u={toBytes:function(e){var t=[],r=0;for(e=encodeURI(e);r191&&n<224?(t.push(String.fromCharCode((31&n)<<6|63&e[r+1])),r+=2):(t.push(String.fromCharCode((15&n)<<12|(63&e[r+1])<<6|63&e[r+2])),r+=3)}return t.join("")}},c=(s="0123456789abcdef",{toBytes:function(e){for(var t=[],r=0;r>4]+s[15&n])}return t.join("")}}),l={16:10,24:12,32:14},f=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],h=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],d=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],p=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],m=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],y=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],g=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],b=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],v=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],w=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],A=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],S=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],k=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],E=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],_=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function M(e){for(var t=[],r=0;r>2,this._Ke[r][t%4]=o[t],this._Kd[e-r][t%4]=o[t];for(var a,s=0,u=i;u>16&255]<<24^h[a>>8&255]<<16^h[255&a]<<8^h[a>>24&255]^f[s]<<24,s+=1,8!=i)for(t=1;t>8&255]<<8^h[a>>16&255]<<16^h[a>>24&255]<<24;for(t=i/2+1;t>2,d=u%4,this._Ke[c][d]=o[t],this._Kd[e-c][d]=o[t++],u++}for(var c=1;c>24&255]^k[a>>16&255]^E[a>>8&255]^_[255&a]},T.prototype.encrypt=function(e){if(16!=e.length)throw new Error("invalid plaintext size (must be 16 bytes)");for(var t=this._Ke.length-1,r=[0,0,0,0],n=M(e),i=0;i<4;i++)n[i]^=this._Ke[0][i];for(var a=1;a>24&255]^m[n[(i+1)%4]>>16&255]^y[n[(i+2)%4]>>8&255]^g[255&n[(i+3)%4]]^this._Ke[a][i];n=r.slice()}var s,u=o(16);for(i=0;i<4;i++)s=this._Ke[t][i],u[4*i]=255&(h[n[i]>>24&255]^s>>24),u[4*i+1]=255&(h[n[(i+1)%4]>>16&255]^s>>16),u[4*i+2]=255&(h[n[(i+2)%4]>>8&255]^s>>8),u[4*i+3]=255&(h[255&n[(i+3)%4]]^s);return u},T.prototype.decrypt=function(e){if(16!=e.length)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var t=this._Kd.length-1,r=[0,0,0,0],n=M(e),i=0;i<4;i++)n[i]^=this._Kd[0][i];for(var a=1;a>24&255]^v[n[(i+3)%4]>>16&255]^w[n[(i+2)%4]>>8&255]^A[255&n[(i+1)%4]]^this._Kd[a][i];n=r.slice()}var s,u=o(16);for(i=0;i<4;i++)s=this._Kd[t][i],u[4*i]=255&(d[n[i]>>24&255]^s>>24),u[4*i+1]=255&(d[n[(i+3)%4]>>16&255]^s>>16),u[4*i+2]=255&(d[n[(i+2)%4]>>8&255]^s>>8),u[4*i+3]=255&(d[255&n[(i+1)%4]]^s);return u};var x=function(e){if(!(this instanceof x))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new T(e)};x.prototype.encrypt=function(e){if((e=i(e)).length%16!=0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var t=o(e.length),r=o(16),n=0;n=0;--t)this._counter[t]=e%256,e>>=8},R.prototype.setBytes=function(e){if(16!=(e=i(e,!0)).length)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=e},R.prototype.increment=function(){for(var e=15;e>=0;e--){if(255!==this._counter[e]){this._counter[e]++;break}this._counter[e]=0}};var C=function(e,t){if(!(this instanceof C))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",t instanceof R||(t=new R(t)),this._counter=t,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new T(e)};C.prototype.encrypt=function(e){for(var t=i(e,!0),r=0;r16)throw new Error("PKCS#7 padding byte out of range");for(var r=e.length-t,n=0;n{"use strict";function r(e){if(!Number.isSafeInteger(e)||e<0)throw new Error(`Wrong positive integer: ${e}`)}function n(e){if("boolean"!=typeof e)throw new Error(`Expected boolean, not ${e}`)}function i(e,...t){if(!(e instanceof Uint8Array))throw new TypeError("Expected Uint8Array");if(t.length>0&&!t.includes(e.length))throw new TypeError(`Expected Uint8Array of length ${t}, not of length=${e.length}`)}function o(e){if("function"!=typeof e||"function"!=typeof e.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");r(e.outputLen),r(e.blockLen)}function a(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function s(e,t){i(e);const r=t.outputLen;if(e.length{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SHA2=void 0;const n=r(27320),i=r(98089);class o extends i.Hash{constructor(e,t,r,n){super(),this.blockLen=e,this.outputLen=t,this.padOffset=r,this.isLE=n,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(e),this.view=(0,i.createView)(this.buffer)}update(e){n.default.exists(this);const{view:t,buffer:r,blockLen:o}=this,a=(e=(0,i.toBytes)(e)).length;for(let n=0;no-s&&(this.process(r,0),s=0);for(let e=s;e>i&o),s=Number(r&o),u=n?4:0,c=n?0:4;e.setUint32(t+u,a,n),e.setUint32(t+c,s,n)}(r,o-8,BigInt(8*this.length),a),this.process(r,0);const u=(0,i.createView)(e);this.get().forEach(((e,t)=>u.setUint32(4*t,e,a)))}digest(){const{buffer:e,outputLen:t}=this;this.digestInto(e);const r=e.slice(0,t);return this.destroy(),r}_cloneInto(e){e||(e=new this.constructor),e.set(...this.get());const{blockLen:t,buffer:r,length:n,finished:i,destroyed:o,pos:a}=this;return e.length=n,e.pos=a,e.finished=i,e.destroyed=o,n%t&&e.buffer.set(r),e}}t.SHA2=o},6873:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.add=t.toBig=t.split=t.fromBig=void 0;const r=BigInt(2**32-1),n=BigInt(32);function i(e,t=!1){return t?{h:Number(e&r),l:Number(e>>n&r)}:{h:0|Number(e>>n&r),l:0|Number(e&r)}}function o(e,t=!1){let r=new Uint32Array(e.length),n=new Uint32Array(e.length);for(let o=0;oBigInt(e>>>0)<>>0);function a(e,t,r,n){const i=(t>>>0)+(n>>>0);return{h:e+r+(i/2**32|0)|0,l:0|i}}t.add=a;const s={fromBig:i,split:o,toBig:t.toBig,shrSH:(e,t,r)=>e>>>r,shrSL:(e,t,r)=>e<<32-r|t>>>r,rotrSH:(e,t,r)=>e>>>r|t<<32-r,rotrSL:(e,t,r)=>e<<32-r|t>>>r,rotrBH:(e,t,r)=>e<<64-r|t>>>r-32,rotrBL:(e,t,r)=>e>>>r-32|t<<64-r,rotr32H:(e,t)=>t,rotr32L:(e,t)=>e,rotlSH:(e,t,r)=>e<>>32-r,rotlSL:(e,t,r)=>t<>>32-r,rotlBH:(e,t,r)=>t<>>64-r,rotlBL:(e,t,r)=>e<>>64-r,add:a,add3L:(e,t,r)=>(e>>>0)+(t>>>0)+(r>>>0),add3H:(e,t,r,n)=>t+r+n+(e/2**32|0)|0,add4L:(e,t,r,n)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0),add4H:(e,t,r,n,i)=>t+r+n+i+(e/2**32|0)|0,add5H:(e,t,r,n,i,o)=>t+r+n+i+o+(e/2**32|0)|0,add5L:(e,t,r,n,i)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0)+(i>>>0)};t.default=s},64421:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.crypto=void 0,t.crypto={node:void 0,web:"object"==typeof self&&"crypto"in self?self.crypto:void 0}},79569:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hmac=void 0;const n=r(27320),i=r(98089);class o extends i.Hash{constructor(e,t){super(),this.finished=!1,this.destroyed=!1,n.default.hash(e);const r=(0,i.toBytes)(t);if(this.iHash=e.create(),!(this.iHash instanceof i.Hash))throw new TypeError("Expected instance of class which extends utils.Hash");const o=this.blockLen=this.iHash.blockLen;this.outputLen=this.iHash.outputLen;const a=new Uint8Array(o);a.set(r.length>this.iHash.blockLen?e.create().update(r).digest():r);for(let e=0;enew o(e,t).update(r).digest(),t.hmac.create=(e,t)=>new o(e,t)},29023:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pbkdf2Async=t.pbkdf2=void 0;const n=r(27320),i=r(79569),o=r(98089);function a(e,t,r,a){n.default.hash(e);const s=(0,o.checkOpts)({dkLen:32,asyncTick:10},a),{c:u,dkLen:c,asyncTick:l}=s;if(n.default.number(u),n.default.number(c),n.default.number(l),u<1)throw new Error("PBKDF2: iterations (c) should be >= 1");const f=(0,o.toBytes)(t),h=(0,o.toBytes)(r),d=new Uint8Array(c),p=i.hmac.create(e,f),m=p._cloneInto().update(h);return{c:u,dkLen:c,asyncTick:l,DK:d,PRF:p,PRFSalt:m}}function s(e,t,r,n,i){return e.destroy(),t.destroy(),n&&n.destroy(),i.fill(0),r}t.pbkdf2=function(e,t,r,n){const{c:i,dkLen:u,DK:c,PRF:l,PRFSalt:f}=a(e,t,r,n);let h;const d=new Uint8Array(4),p=(0,o.createView)(d),m=new Uint8Array(l.outputLen);for(let e=1,t=0;t{f._cloneInto(d).update(y).digestInto(y);for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ripemd160=t.RIPEMD160=void 0;const n=r(27505),i=r(98089),o=new Uint8Array([7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8]),a=Uint8Array.from({length:16},((e,t)=>t)),s=a.map((e=>(9*e+5)%16));let u=[a],c=[s];for(let e=0;e<4;e++)for(let t of[u,c])t.push(t[e].map((e=>o[e])));const l=[[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8],[12,13,11,15,6,9,9,7,12,15,11,13,7,8,7,7],[13,15,14,11,7,7,6,8,13,14,13,12,5,5,6,9],[14,11,12,14,8,6,5,5,15,12,15,14,9,9,8,6],[15,12,13,13,9,5,8,6,14,11,12,11,8,6,5,5]].map((e=>new Uint8Array(e))),f=u.map(((e,t)=>e.map((e=>l[t][e])))),h=c.map(((e,t)=>e.map((e=>l[t][e])))),d=new Uint32Array([0,1518500249,1859775393,2400959708,2840853838]),p=new Uint32Array([1352829926,1548603684,1836072691,2053994217,0]),m=(e,t)=>e<>>32-t;function y(e,t,r,n){return 0===e?t^r^n:1===e?t&r|~t&n:2===e?(t|~r)^n:3===e?t&n|r&~n:t^(r|~n)}const g=new Uint32Array(16);class b extends n.SHA2{constructor(){super(64,20,8,!0),this.h0=1732584193,this.h1=-271733879,this.h2=-1732584194,this.h3=271733878,this.h4=-1009589776}get(){const{h0:e,h1:t,h2:r,h3:n,h4:i}=this;return[e,t,r,n,i]}set(e,t,r,n,i){this.h0=0|e,this.h1=0|t,this.h2=0|r,this.h3=0|n,this.h4=0|i}process(e,t){for(let r=0;r<16;r++,t+=4)g[r]=e.getUint32(t,!0);let r=0|this.h0,n=r,i=0|this.h1,o=i,a=0|this.h2,s=a,l=0|this.h3,b=l,v=0|this.h4,w=v;for(let e=0;e<5;e++){const t=4-e,A=d[e],S=p[e],k=u[e],E=c[e],_=f[e],M=h[e];for(let t=0;t<16;t++){const n=m(r+y(e,i,a,l)+g[k[t]]+A,_[t])+v|0;r=v,v=l,l=0|m(a,10),a=i,i=n}for(let e=0;e<16;e++){const r=m(n+y(t,o,s,b)+g[E[e]]+S,M[e])+w|0;n=w,w=b,b=0|m(s,10),s=o,o=r}}this.set(this.h1+a+b|0,this.h2+l+w|0,this.h3+v+n|0,this.h4+r+o|0,this.h0+i+s|0)}roundClean(){g.fill(0)}destroy(){this.destroyed=!0,this.buffer.fill(0),this.set(0,0,0,0,0)}}t.RIPEMD160=b,t.ripemd160=(0,i.wrapConstructor)((()=>new b))},69514:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.scryptAsync=t.scrypt=void 0;const n=r(27320),i=r(23061),o=r(29023),a=r(98089),s=(e,t)=>e<>>32-t;function u(e,t,r,n,i,o){let a=e[t++]^r[n++],u=e[t++]^r[n++],c=e[t++]^r[n++],l=e[t++]^r[n++],f=e[t++]^r[n++],h=e[t++]^r[n++],d=e[t++]^r[n++],p=e[t++]^r[n++],m=e[t++]^r[n++],y=e[t++]^r[n++],g=e[t++]^r[n++],b=e[t++]^r[n++],v=e[t++]^r[n++],w=e[t++]^r[n++],A=e[t++]^r[n++],S=e[t++]^r[n++],k=a,E=u,_=c,M=l,T=f,x=h,P=d,I=p,O=m,R=y,C=g,B=b,N=v,L=w,U=A,F=S;for(let e=0;e<8;e+=2)T^=s(k+N|0,7),O^=s(T+k|0,9),N^=s(O+T|0,13),k^=s(N+O|0,18),R^=s(x+E|0,7),L^=s(R+x|0,9),E^=s(L+R|0,13),x^=s(E+L|0,18),U^=s(C+P|0,7),_^=s(U+C|0,9),P^=s(_+U|0,13),C^=s(P+_|0,18),M^=s(F+B|0,7),I^=s(M+F|0,9),B^=s(I+M|0,13),F^=s(B+I|0,18),E^=s(k+M|0,7),_^=s(E+k|0,9),M^=s(_+E|0,13),k^=s(M+_|0,18),P^=s(x+T|0,7),I^=s(P+x|0,9),T^=s(I+P|0,13),x^=s(T+I|0,18),B^=s(C+R|0,7),O^=s(B+C|0,9),R^=s(O+B|0,13),C^=s(R+O|0,18),N^=s(F+U|0,7),L^=s(N+F|0,9),U^=s(L+N|0,13),F^=s(U+L|0,18);i[o++]=a+k|0,i[o++]=u+E|0,i[o++]=c+_|0,i[o++]=l+M|0,i[o++]=f+T|0,i[o++]=h+x|0,i[o++]=d+P|0,i[o++]=p+I|0,i[o++]=m+O|0,i[o++]=y+R|0,i[o++]=g+C|0,i[o++]=b+B|0,i[o++]=v+N|0,i[o++]=w+L|0,i[o++]=A+U|0,i[o++]=S+F|0}function c(e,t,r,n,i){let o=n+0,a=n+16*i;for(let n=0;n<16;n++)r[a+n]=e[t+16*(2*i-1)+n];for(let n=0;n0&&(a+=16),u(r,o,e,t+=16,r,a)}function l(e,t,r){const s=(0,a.checkOpts)({dkLen:32,asyncTick:10,maxmem:1073742848},r),{N:u,r:c,p:l,dkLen:f,asyncTick:h,maxmem:d,onProgress:p}=s;if(n.default.number(u),n.default.number(c),n.default.number(l),n.default.number(f),n.default.number(h),n.default.number(d),void 0!==p&&"function"!=typeof p)throw new Error("progressCb should be function");const m=128*c,y=m/4;if(u<=1||0!=(u&u-1)||u>=2**(m/8)||u>2**32)throw new Error("Scrypt: N must be larger than 1, a power of 2, less than 2^(128 * r / 8) and less than 2^32");if(l<0||l>137438953440/m)throw new Error("Scrypt: p must be a positive integer less than or equal to ((2^32 - 1) * 32) / (128 * r)");if(f<0||f>137438953440)throw new Error("Scrypt: dkLen should be positive integer less than or equal to (2^32 - 1) * 32");const g=m*(u+l);if(g>d)throw new Error(`Scrypt: parameters too large, ${g} (128 * r * (N + p)) > ${d} (maxmem)`);const b=(0,o.pbkdf2)(i.sha256,e,t,{c:1,dkLen:m*l}),v=(0,a.u32)(b),w=(0,a.u32)(new Uint8Array(m*u)),A=(0,a.u32)(new Uint8Array(m));let S=()=>{};if(p){const e=2*u*l,t=Math.max(Math.floor(e/1e4),1);let r=0;S=()=>{r++,!p||r%t&&r!==e||p(r/e)}}return{N:u,r:c,p:l,dkLen:f,blockSize32:y,V:w,B32:v,B:b,tmp:A,blockMixCb:S,asyncTick:h}}function f(e,t,r,n,a){const s=(0,o.pbkdf2)(i.sha256,e,r,{c:1,dkLen:t});return r.fill(0),n.fill(0),a.fill(0),s}t.scrypt=function(e,t,r){const{N:n,r:i,p:o,dkLen:a,blockSize32:s,V:u,B32:h,B:d,tmp:p,blockMixCb:m}=l(e,t,r);for(let e=0;e{c(h,r,h,r+=u,i),y()})),c(h,(n-1)*u,d,t,i),y(),await(0,a.asyncLoop)(n,g,(e=>{const r=d[t+u-16]%n;for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha256=void 0;const n=r(27505),i=r(98089),o=(e,t,r)=>e&t^e&r^t&r,a=new Uint32Array([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]),s=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),u=new Uint32Array(64);class c extends n.SHA2{constructor(){super(64,32,8,!1),this.A=0|s[0],this.B=0|s[1],this.C=0|s[2],this.D=0|s[3],this.E=0|s[4],this.F=0|s[5],this.G=0|s[6],this.H=0|s[7]}get(){const{A:e,B:t,C:r,D:n,E:i,F:o,G:a,H:s}=this;return[e,t,r,n,i,o,a,s]}set(e,t,r,n,i,o,a,s){this.A=0|e,this.B=0|t,this.C=0|r,this.D=0|n,this.E=0|i,this.F=0|o,this.G=0|a,this.H=0|s}process(e,t){for(let r=0;r<16;r++,t+=4)u[r]=e.getUint32(t,!1);for(let e=16;e<64;e++){const t=u[e-15],r=u[e-2],n=(0,i.rotr)(t,7)^(0,i.rotr)(t,18)^t>>>3,o=(0,i.rotr)(r,17)^(0,i.rotr)(r,19)^r>>>10;u[e]=o+u[e-7]+n+u[e-16]|0}let{A:r,B:n,C:s,D:c,E:l,F:f,G:h,H:d}=this;for(let e=0;e<64;e++){const t=d+((0,i.rotr)(l,6)^(0,i.rotr)(l,11)^(0,i.rotr)(l,25))+((p=l)&f^~p&h)+a[e]+u[e]|0,m=((0,i.rotr)(r,2)^(0,i.rotr)(r,13)^(0,i.rotr)(r,22))+o(r,n,s)|0;d=h,h=f,f=l,l=c+t|0,c=s,s=n,n=r,r=t+m|0}var p;r=r+this.A|0,n=n+this.B|0,s=s+this.C|0,c=c+this.D|0,l=l+this.E|0,f=f+this.F|0,h=h+this.G|0,d=d+this.H|0,this.set(r,n,s,c,l,f,h,d)}roundClean(){u.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}t.sha256=(0,i.wrapConstructor)((()=>new c))},85426:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.shake256=t.shake128=t.keccak_512=t.keccak_384=t.keccak_256=t.keccak_224=t.sha3_512=t.sha3_384=t.sha3_256=t.sha3_224=t.Keccak=t.keccakP=void 0;const n=r(27320),i=r(6873),o=r(98089),[a,s,u]=[[],[],[]],c=BigInt(0),l=BigInt(1),f=BigInt(2),h=BigInt(7),d=BigInt(256),p=BigInt(113);for(let e=0,t=l,r=1,n=0;e<24;e++){[r,n]=[n,(2*r+3*n)%5],a.push(2*(5*n+r)),s.push((e+1)*(e+2)/2%64);let i=c;for(let e=0;e<7;e++)t=(t<>h)*p)%d,t&f&&(i^=l<<(l<r>32?i.default.rotlBH(e,t,r):i.default.rotlSH(e,t,r),b=(e,t,r)=>r>32?i.default.rotlBL(e,t,r):i.default.rotlSL(e,t,r);function v(e,t=24){const r=new Uint32Array(10);for(let n=24-t;n<24;n++){for(let t=0;t<10;t++)r[t]=e[t]^e[t+10]^e[t+20]^e[t+30]^e[t+40];for(let t=0;t<10;t+=2){const n=(t+8)%10,i=(t+2)%10,o=r[i],a=r[i+1],s=g(o,a,1)^r[n],u=b(o,a,1)^r[n+1];for(let r=0;r<50;r+=10)e[t+r]^=s,e[t+r+1]^=u}let t=e[2],i=e[3];for(let r=0;r<24;r++){const n=s[r],o=g(t,i,n),u=b(t,i,n),c=a[r];t=e[c],i=e[c+1],e[c]=o,e[c+1]=u}for(let t=0;t<50;t+=10){for(let n=0;n<10;n++)r[n]=e[t+n];for(let n=0;n<10;n++)e[t+n]^=~r[(n+2)%10]&r[(n+4)%10]}e[0]^=m[n],e[1]^=y[n]}r.fill(0)}t.keccakP=v;class w extends o.Hash{constructor(e,t,r,i=!1,a=24){if(super(),this.blockLen=e,this.suffix=t,this.outputLen=r,this.enableXOF=i,this.rounds=a,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,n.default.number(r),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=(0,o.u32)(this.state)}keccak(){v(this.state32,this.rounds),this.posOut=0,this.pos=0}update(e){n.default.exists(this);const{blockLen:t,state:r}=this,i=(e=(0,o.toBytes)(e)).length;for(let n=0;n=r&&this.keccak();const o=Math.min(r-this.posOut,i-n);e.set(t.subarray(this.posOut,this.posOut+o),n),this.posOut+=o,n+=o}return e}xofInto(e){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return n.default.number(e),this.xofInto(new Uint8Array(e))}digestInto(e){if(n.default.output(e,this),this.finished)throw new Error("digest() was already called");return this.writeInto(e),this.destroy(),e}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(e){const{blockLen:t,suffix:r,outputLen:n,rounds:i,enableXOF:o}=this;return e||(e=new w(t,r,n,o,i)),e.state32.set(this.state32),e.pos=this.pos,e.posOut=this.posOut,e.finished=this.finished,e.rounds=i,e.suffix=r,e.outputLen=n,e.enableXOF=o,e.destroyed=this.destroyed,e}}t.Keccak=w;const A=(e,t,r)=>(0,o.wrapConstructor)((()=>new w(t,e,r)));t.sha3_224=A(6,144,28),t.sha3_256=A(6,136,32),t.sha3_384=A(6,104,48),t.sha3_512=A(6,72,64),t.keccak_224=A(1,144,28),t.keccak_256=A(1,136,32),t.keccak_384=A(1,104,48),t.keccak_512=A(1,72,64);const S=(e,t,r)=>(0,o.wrapConstructorWithOpts)(((n={})=>new w(t,e,void 0===n.dkLen?r:n.dkLen,!0)));t.shake128=S(31,168,16),t.shake256=S(31,136,32)},98089:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.randomBytes=t.wrapConstructorWithOpts=t.wrapConstructor=t.checkOpts=t.Hash=t.concatBytes=t.toBytes=t.utf8ToBytes=t.asyncLoop=t.nextTick=t.hexToBytes=t.bytesToHex=t.isLE=t.rotr=t.createView=t.u32=t.u8=void 0;const n=r(64421);t.u8=e=>new Uint8Array(e.buffer,e.byteOffset,e.byteLength);t.u32=e=>new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4));t.createView=e=>new DataView(e.buffer,e.byteOffset,e.byteLength);if(t.rotr=(e,t)=>e<<32-t|e>>>t,t.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],!t.isLE)throw new Error("Non little-endian hardware is not supported");const i=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0")));t.bytesToHex=function(e){if(!(e instanceof Uint8Array))throw new Error("Uint8Array expected");let t="";for(let r=0;r{},t.asyncLoop=async function(e,r,n){let i=Date.now();for(let o=0;o=0&&ee instanceof Uint8Array)))throw new Error("Uint8Array list expected");if(1===e.length)return e[0];const t=e.reduce(((e,t)=>e+t.length),0),r=new Uint8Array(t);for(let t=0,n=0;te().update(a(t)).digest(),r=e();return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=()=>e(),t},t.wrapConstructorWithOpts=function(e){const t=(t,r)=>e(r).update(a(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t},t.randomBytes=function(e=32){if(n.crypto.web)return n.crypto.web.getRandomValues(new Uint8Array(e));if(n.crypto.node)return new Uint8Array(n.crypto.node.randomBytes(e).buffer);throw new Error("The environment doesn't have randomBytes function")}},79656:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utils=t.schnorr=t.verify=t.signSync=t.sign=t.getSharedSecret=t.recoverPublicKey=t.getPublicKey=t.Signature=t.Point=t.CURVE=void 0;const n=r(69159),i=BigInt(0),o=BigInt(1),a=BigInt(2),s=BigInt(3),u=BigInt(8),c=Object.freeze({a:i,b:BigInt(7),P:BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),n:BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),h:o,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee")});t.CURVE=c;const l=(e,t)=>(e+t/a)/t,f={beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar(e){const{n:t}=c,r=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),n=-o*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),i=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),a=r,s=BigInt("0x100000000000000000000000000000000"),u=l(a*e,t),f=l(-n*e,t);let h=U(e-u*r-f*i,t),d=U(-u*n-f*a,t);const p=h>s,m=d>s;if(p&&(h=t-h),m&&(d=t-d),h>s||d>s)throw new Error("splitScalarEndo: Endomorphism failed, k="+e);return{k1neg:p,k1:h,k2neg:m,k2:d}}},h=32,d=32;function p(e){const{a:t,b:r}=c,n=U(e*e),i=U(n*e);return U(i+t*e+r)}const m=c.a===i;class y extends Error{constructor(e){super(e)}}function g(e){if(!(e instanceof b))throw new TypeError("JacobianPoint expected")}class b{constructor(e,t,r){this.x=e,this.y=t,this.z=r}static fromAffine(e){if(!(e instanceof A))throw new TypeError("JacobianPoint#fromAffine: expected Point");return e.equals(A.ZERO)?b.ZERO:new b(e.x,e.y,o)}static toAffineBatch(e){const t=function(e,t=c.P){const r=new Array(e.length),n=D(e.reduce(((e,n,o)=>n===i?e:(r[o]=e,U(e*n,t))),o),t);return e.reduceRight(((e,n,o)=>n===i?e:(r[o]=U(e*r[o],t),U(e*n,t))),n),r}(e.map((e=>e.z)));return e.map(((e,r)=>e.toAffine(t[r])))}static normalizeZ(e){return b.toAffineBatch(e).map(b.fromAffine)}equals(e){g(e);const{x:t,y:r,z:n}=this,{x:i,y:o,z:a}=e,s=U(n*n),u=U(a*a),c=U(t*u),l=U(i*s),f=U(U(r*a)*u),h=U(U(o*n)*s);return c===l&&f===h}negate(){return new b(this.x,U(-this.y),this.z)}double(){const{x:e,y:t,z:r}=this,n=U(e*e),i=U(t*t),o=U(i*i),c=e+i,l=U(a*(U(c*c)-n-o)),f=U(s*n),h=U(f*f),d=U(h-a*l),p=U(f*(l-d)-u*o),m=U(a*t*r);return new b(d,p,m)}add(e){g(e);const{x:t,y:r,z:n}=this,{x:o,y:s,z:u}=e;if(o===i||s===i)return this;if(t===i||r===i)return e;const c=U(n*n),l=U(u*u),f=U(t*l),h=U(o*c),d=U(U(r*u)*l),p=U(U(s*n)*c),m=U(h-f),y=U(p-d);if(m===i)return y===i?this.double():b.ZERO;const v=U(m*m),w=U(m*v),A=U(f*v),S=U(y*y-w-a*A),k=U(y*(A-S)-d*w),E=U(n*u*m);return new b(S,k,E)}subtract(e){return this.add(e.negate())}multiplyUnsafe(e){const t=b.ZERO;if("bigint"==typeof e&&e===i)return t;let r=L(e);if(r===o)return this;if(!m){let e=t,n=this;for(;r>i;)r&o&&(e=e.add(n)),n=n.double(),r>>=o;return e}let{k1neg:n,k1:a,k2neg:s,k2:u}=f.splitScalar(r),c=t,l=t,h=this;for(;a>i||u>i;)a&o&&(c=c.add(h)),u&o&&(l=l.add(h)),h=h.double(),a>>=o,u>>=o;return n&&(c=c.negate()),s&&(l=l.negate()),l=new b(U(l.x*f.beta),l.y,l.z),c.add(l)}precomputeWindow(e){const t=m?128/e+1:256/e+1,r=[];let n=this,i=n;for(let o=0;o>=f,s>u&&(s-=l,e+=o);const h=r,d=r+Math.abs(s)-1,p=t%2!=0,m=s<0;0===s?a=a.add(v(p,n[h])):i=i.add(v(m,n[d]))}return{p:i,f:a}}multiply(e,t){let r,n,i=L(e);if(m){const{k1neg:e,k1:o,k2neg:a,k2:s}=f.splitScalar(i);let{p:u,f:c}=this.wNAF(o,t),{p:l,f:h}=this.wNAF(s,t);u=v(e,u),l=v(a,l),l=new b(U(l.x*f.beta),l.y,l.z),r=u.add(l),n=c.add(h)}else{const{p:e,f:o}=this.wNAF(i,t);r=e,n=o}return b.normalizeZ([r,n])[0]}toAffine(e){const{x:t,y:r,z:n}=this,i=this.equals(b.ZERO);null==e&&(e=i?u:D(n));const a=e,s=U(a*a),c=U(s*a),l=U(t*s),f=U(r*c),h=U(n*a);if(i)return A.ZERO;if(h!==o)throw new Error("invZ was invalid");return new A(l,f)}}function v(e,t){const r=t.negate();return e?r:t}b.BASE=new b(c.Gx,c.Gy,o),b.ZERO=new b(i,o,i);const w=new WeakMap;class A{constructor(e,t){this.x=e,this.y=t}_setWindowSize(e){this._WINDOW_SIZE=e,w.delete(this)}hasEvenY(){return this.y%a===i}static fromCompressedHex(e){const t=32===e.length,r=B(t?e:e.subarray(1));if(!q(r))throw new Error("Point is not on curve");let n=function(e){const{P:t}=c,r=BigInt(6),n=BigInt(11),i=BigInt(22),o=BigInt(23),u=BigInt(44),l=BigInt(88),f=e*e*e%t,h=f*f*e%t,d=F(h,s)*h%t,p=F(d,s)*h%t,m=F(p,a)*f%t,y=F(m,n)*m%t,g=F(y,i)*y%t,b=F(g,u)*g%t,v=F(b,l)*b%t,w=F(v,u)*g%t,A=F(w,s)*h%t,S=F(A,o)*y%t,k=F(S,r)*f%t,E=F(k,a);if(E*E%t!==e)throw new Error("Cannot find square root");return E}(p(r));const i=(n&o)===o;if(t)i&&(n=U(-n));else{1==(1&e[0])!==i&&(n=U(-n))}const u=new A(r,n);return u.assertValidity(),u}static fromUncompressedHex(e){const t=B(e.subarray(1,33)),r=B(e.subarray(33,65)),n=new A(t,r);return n.assertValidity(),n}static fromHex(e){const t=N(e),r=t.length,n=t[0];if(r===h)return this.fromCompressedHex(t);if(33===r&&(2===n||3===n))return this.fromCompressedHex(t);if(65===r&&4===n)return this.fromUncompressedHex(t);throw new Error(`Point.fromHex: received invalid point. Expected 32-33 compressed bytes or 65 uncompressed bytes, not ${r}`)}static fromPrivateKey(e){return A.BASE.multiply(V(e))}static fromSignature(e,t,r){const{r:n,s:i}=Q(t);if(![0,1,2,3].includes(r))throw new Error("Cannot recover: invalid recovery bit");const o=j(N(e)),{n:a}=c,s=2===r||3===r?n+a:n,u=D(s,a),l=U(-o*u,a),f=U(i*u,a),h=1&r?"03":"02",d=A.fromHex(h+P(s)),p=A.BASE.multiplyAndAddUnsafe(d,l,f);if(!p)throw new Error("Cannot recover signature: point at infinify");return p.assertValidity(),p}toRawBytes(e=!1){return C(this.toHex(e))}toHex(e=!1){const t=P(this.x);if(e){return`${this.hasEvenY()?"02":"03"}${t}`}return`04${t}${P(this.y)}`}toHexX(){return this.toHex(!0).slice(2)}toRawX(){return this.toRawBytes(!0).slice(1)}assertValidity(){const e="Point is not on elliptic curve",{x:t,y:r}=this;if(!q(t)||!q(r))throw new Error(e);const n=U(r*r);if(U(n-p(t))!==i)throw new Error(e)}equals(e){return this.x===e.x&&this.y===e.y}negate(){return new A(this.x,U(-this.y))}double(){return b.fromAffine(this).double().toAffine()}add(e){return b.fromAffine(this).add(b.fromAffine(e)).toAffine()}subtract(e){return this.add(e.negate())}multiply(e){return b.fromAffine(this).multiply(e,this).toAffine()}multiplyAndAddUnsafe(e,t,r){const n=b.fromAffine(this),a=t===i||t===o||this!==A.BASE?n.multiplyUnsafe(t):n.multiply(t),s=b.fromAffine(e).multiplyUnsafe(r),u=a.add(s);return u.equals(b.ZERO)?void 0:u.toAffine()}}function S(e){return Number.parseInt(e[0],16)>=8?"00"+e:e}function k(e){if(e.length<2||2!==e[0])throw new Error(`Invalid signature integer tag: ${T(e)}`);const t=e[1],r=e.subarray(2,t+2);if(!t||r.length!==t)throw new Error("Invalid signature integer: wrong length");if(0===r[0]&&r[1]<=127)throw new Error("Invalid signature integer: trailing length");return{data:B(r),left:e.subarray(t+2)}}t.Point=A,A.BASE=new A(c.Gx,c.Gy),A.ZERO=new A(i,i);class E{constructor(e,t){this.r=e,this.s=t,this.assertValidity()}static fromCompact(e){const t=e instanceof Uint8Array,r="Signature.fromCompact";if("string"!=typeof e&&!t)throw new TypeError(`${r}: Expected string or Uint8Array`);const n=t?T(e):e;if(128!==n.length)throw new Error(`${r}: Expected 64-byte hex`);return new E(R(n.slice(0,64)),R(n.slice(64,128)))}static fromDER(e){const t=e instanceof Uint8Array;if("string"!=typeof e&&!t)throw new TypeError("Signature.fromDER: Expected string or Uint8Array");const{r,s:n}=function(e){if(e.length<2||48!=e[0])throw new Error(`Invalid signature tag: ${T(e)}`);if(e[1]!==e.length-2)throw new Error("Invalid signature: incorrect length");const{data:t,left:r}=k(e.subarray(2)),{data:n,left:i}=k(r);if(i.length)throw new Error(`Invalid signature: left bytes after parsing: ${T(i)}`);return{r:t,s:n}}(t?e:C(e));return new E(r,n)}static fromHex(e){return this.fromDER(e)}assertValidity(){const{r:e,s:t}=this;if(!G(e))throw new Error("Invalid Signature: r must be 0 < r < n");if(!G(t))throw new Error("Invalid Signature: s must be 0 < s < n")}hasHighS(){const e=c.n>>o;return this.s>e}normalizeS(){return this.hasHighS()?new E(this.r,U(-this.s,c.n)):this}toDERRawBytes(){return C(this.toDERHex())}toDERHex(){const e=S(O(this.s)),t=S(O(this.r)),r=e.length/2,n=t.length/2,i=O(r),o=O(n);return`30${O(n+r+4)}02${o}${t}02${i}${e}`}toRawBytes(){return this.toDERRawBytes()}toHex(){return this.toDERHex()}toCompactRawBytes(){return C(this.toCompactHex())}toCompactHex(){return P(this.r)+P(this.s)}}function _(...e){if(!e.every((e=>e instanceof Uint8Array)))throw new Error("Uint8Array list expected");if(1===e.length)return e[0];const t=e.reduce(((e,t)=>e+t.length),0),r=new Uint8Array(t);for(let t=0,n=0;tt.toString(16).padStart(2,"0")));function T(e){if(!(e instanceof Uint8Array))throw new Error("Expected Uint8Array");let t="";for(let r=0;r0)return BigInt(e);if("bigint"==typeof e&&G(e))return e;throw new TypeError("Expected valid private scalar: 0 < scalar < curve.n")}function U(e,t=c.P){const r=e%t;return r>=i?r:t+r}function F(e,t){const{P:r}=c;let n=e;for(;t-- >i;)n*=n,n%=r;return n}function D(e,t=c.P){if(e===i||t<=i)throw new Error(`invert: expected positive integers, got n=${e} mod=${t}`);let r=U(e,t),n=t,a=i,s=o,u=o,l=i;for(;r!==i;){const e=n/r,t=n%r,i=a-u*e,o=s-l*e;n=r,r=t,a=u,s=l,u=i,l=o}if(n!==o)throw new Error("invert: does not exist");return U(a,t)}function j(e,t=!1){const r=function(e){const t=8*e.length-256,r=B(e);return t>0?r>>BigInt(t):r}(e);if(t)return r;const{n}=c;return r>=n?r-n:r}let H,J;class z{constructor(e,t){if(this.hashLen=e,this.qByteLen=t,"number"!=typeof e||e<2)throw new Error("hashLen must be a number");if("number"!=typeof t||t<2)throw new Error("qByteLen must be a number");this.v=new Uint8Array(e).fill(1),this.k=new Uint8Array(e).fill(0),this.counter=0}hmac(...e){return t.utils.hmacSha256(this.k,...e)}hmacSync(...e){return J(this.k,...e)}checkSync(){if("function"!=typeof J)throw new y("hmacSha256Sync needs to be set")}incr(){if(this.counter>=1e3)throw new Error("Tried 1,000 k values for sign(), all were invalid");this.counter+=1}async reseed(e=new Uint8Array){this.k=await this.hmac(this.v,Uint8Array.from([0]),e),this.v=await this.hmac(this.v),0!==e.length&&(this.k=await this.hmac(this.v,Uint8Array.from([1]),e),this.v=await this.hmac(this.v))}reseedSync(e=new Uint8Array){this.checkSync(),this.k=this.hmacSync(this.v,Uint8Array.from([0]),e),this.v=this.hmacSync(this.v),0!==e.length&&(this.k=this.hmacSync(this.v,Uint8Array.from([1]),e),this.v=this.hmacSync(this.v))}async generate(){this.incr();let e=0;const t=[];for(;e0)t=BigInt(e);else if("string"==typeof e){if(64!==e.length)throw new Error("Expected 32 bytes of private key");t=R(e)}else{if(!(e instanceof Uint8Array))throw new TypeError("Expected valid private key");if(e.length!==d)throw new Error("Expected 32 bytes of private key");t=B(e)}if(!G(t))throw new Error("Expected private key: 0 < key < n");return t}function X(e){return e instanceof A?(e.assertValidity(),e):A.fromHex(e)}function Q(e){if(e instanceof E)return e.assertValidity(),e;try{return E.fromDER(e)}catch(t){return E.fromCompact(e)}}function W(e){const t=e instanceof Uint8Array,r="string"==typeof e,n=(t||r)&&e.length;return t?33===n||65===n:r?66===n||130===n:e instanceof A}function Z(e){return B(e.length>h?e.slice(0,h):e)}function Y(e){const t=Z(e),r=U(t,c.n);return $(r{if((e=N(e)).length<40||e.length>1024)throw new Error("Expected valid bytes of private key as per FIPS 186");return I(U(B(e),c.n-o)+o)},randomBytes:(e=32)=>{if(le.web)return le.web.getRandomValues(new Uint8Array(e));if(le.node){const{randomBytes:t}=le.node;return Uint8Array.from(t(e))}throw new Error("The environment doesn't have randomBytes function")},randomPrivateKey:()=>t.utils.hashToPrivateKey(t.utils.randomBytes(40)),precompute(e=8,t=A.BASE){const r=t===A.BASE?t:new A(t.x,t.y);return r._setWindowSize(e),r.multiply(s),r},sha256:async(...e)=>{if(le.web){const t=await le.web.subtle.digest("SHA-256",_(...e));return new Uint8Array(t)}if(le.node){const{createHash:t}=le.node,r=t("sha256");return e.forEach((e=>r.update(e))),Uint8Array.from(r.digest())}throw new Error("The environment doesn't have sha256 function")},hmacSha256:async(e,...t)=>{if(le.web){const r=await le.web.subtle.importKey("raw",e,{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),n=_(...t),i=await le.web.subtle.sign("HMAC",r,n);return new Uint8Array(i)}if(le.node){const{createHmac:r}=le.node,n=r("sha256",e);return t.forEach((e=>n.update(e))),Uint8Array.from(n.digest())}throw new Error("The environment doesn't have hmac-sha256 function")},sha256Sync:void 0,hmacSha256Sync:void 0,taggedHash:async(e,...r)=>{let n=he[e];if(void 0===n){const r=await t.utils.sha256(Uint8Array.from(e,(e=>e.charCodeAt(0))));n=_(r,r),he[e]=n}return t.utils.sha256(n,...r)},taggedHashSync:(e,...t)=>{if("function"!=typeof H)throw new y("sha256Sync is undefined, you need to set it");let r=he[e];if(void 0===r){const t=H(Uint8Array.from(e,(e=>e.charCodeAt(0))));r=_(t,t),he[e]=r}return H(r,...t)},_JacobianPoint:b},Object.defineProperties(t.utils,{sha256Sync:{configurable:!1,get:()=>H,set(e){H||(H=e)}},hmacSha256Sync:{configurable:!1,get:()=>J,set(e){J||(J=e)}}})},39809:(e,t,r)=>{"use strict";const n=t;n.bignum=r(4590),n.define=r(22500).define,n.base=r(71979),n.constants=r(36826),n.decoders=r(78307),n.encoders=r(56579)},22500:(e,t,r)=>{"use strict";const n=r(56579),i=r(78307),o=r(35717);function a(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}t.define=function(e,t){return new a(e,t)},a.prototype._createNamed=function(e){const t=this.name;function r(e){this._initNamed(e,t)}return o(r,e),r.prototype._initNamed=function(t,r){e.call(this,t,r)},new r(this)},a.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(i[e])),this.decoders[e]},a.prototype.decode=function(e,t,r){return this._getDecoder(t).decode(e,r)},a.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(n[e])),this.encoders[e]},a.prototype.encode=function(e,t,r){return this._getEncoder(t).encode(e,r)}},36625:(e,t,r)=>{"use strict";const n=r(35717),i=r(98465).b,o=r(2399).Buffer;function a(e,t){i.call(this,t),o.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function s(e,t){if(Array.isArray(e))this.length=0,this.value=e.map((function(e){return s.isEncoderBuffer(e)||(e=new s(e,t)),this.length+=e.length,e}),this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=o.byteLength(e);else{if(!o.isBuffer(e))return t.error("Unsupported type: "+typeof e);this.value=e,this.length=e.length}}n(a,i),t.C=a,a.isDecoderBuffer=function(e){if(e instanceof a)return!0;return"object"==typeof e&&o.isBuffer(e.base)&&"DecoderBuffer"===e.constructor.name&&"number"==typeof e.offset&&"number"==typeof e.length&&"function"==typeof e.save&&"function"==typeof e.restore&&"function"==typeof e.isEmpty&&"function"==typeof e.readUInt8&&"function"==typeof e.skip&&"function"==typeof e.raw},a.prototype.save=function(){return{offset:this.offset,reporter:i.prototype.save.call(this)}},a.prototype.restore=function(e){const t=new a(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,i.prototype.restore.call(this,e.reporter),t},a.prototype.isEmpty=function(){return this.offset===this.length},a.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},a.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");const r=new a(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+e,this.offset+=e,r},a.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},t.R=s,s.isEncoderBuffer=function(e){if(e instanceof s)return!0;return"object"==typeof e&&"EncoderBuffer"===e.constructor.name&&"number"==typeof e.length&&"function"==typeof e.join},s.prototype.join=function(e,t){return e||(e=o.alloc(this.length)),t||(t=0),0===this.length||(Array.isArray(this.value)?this.value.forEach((function(r){r.join(e,t),t+=r.length})):("number"==typeof this.value?e[t]=this.value:"string"==typeof this.value?e.write(this.value,t):o.isBuffer(this.value)&&this.value.copy(e,t),t+=this.length)),e}},71979:(e,t,r)=>{"use strict";const n=t;n.Reporter=r(98465).b,n.DecoderBuffer=r(36625).C,n.EncoderBuffer=r(36625).R,n.Node=r(41949)},41949:(e,t,r)=>{"use strict";const n=r(98465).b,i=r(36625).R,o=r(36625).C,a=r(79746),s=["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"],u=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(s);function c(e,t,r){const n={};this._baseState=n,n.name=r,n.enc=e,n.parent=t||null,n.children=null,n.tag=null,n.args=null,n.reverseArgs=null,n.choice=null,n.optional=!1,n.any=!1,n.obj=!1,n.use=null,n.useDecoder=null,n.key=null,n.default=null,n.explicit=null,n.implicit=null,n.contains=null,n.parent||(n.children=[],this._wrap())}e.exports=c;const l=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];c.prototype.clone=function(){const e=this._baseState,t={};l.forEach((function(r){t[r]=e[r]}));const r=new this.constructor(t.parent);return r._baseState=t,r},c.prototype._wrap=function(){const e=this._baseState;u.forEach((function(t){this[t]=function(){const r=new this.constructor(this);return e.children.push(r),r[t].apply(r,arguments)}}),this)},c.prototype._init=function(e){const t=this._baseState;a(null===t.parent),e.call(this),t.children=t.children.filter((function(e){return e._baseState.parent===this}),this),a.equal(t.children.length,1,"Root node can have only one child")},c.prototype._useArgs=function(e){const t=this._baseState,r=e.filter((function(e){return e instanceof this.constructor}),this);e=e.filter((function(e){return!(e instanceof this.constructor)}),this),0!==r.length&&(a(null===t.children),t.children=r,r.forEach((function(e){e._baseState.parent=this}),this)),0!==e.length&&(a(null===t.args),t.args=e,t.reverseArgs=e.map((function(e){if("object"!=typeof e||e.constructor!==Object)return e;const t={};return Object.keys(e).forEach((function(r){r==(0|r)&&(r|=0);const n=e[r];t[n]=r})),t})))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach((function(e){c.prototype[e]=function(){const t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}})),s.forEach((function(e){c.prototype[e]=function(){const t=this._baseState,r=Array.prototype.slice.call(arguments);return a(null===t.tag),t.tag=e,this._useArgs(r),this}})),c.prototype.use=function(e){a(e);const t=this._baseState;return a(null===t.use),t.use=e,this},c.prototype.optional=function(){return this._baseState.optional=!0,this},c.prototype.def=function(e){const t=this._baseState;return a(null===t.default),t.default=e,t.optional=!0,this},c.prototype.explicit=function(e){const t=this._baseState;return a(null===t.explicit&&null===t.implicit),t.explicit=e,this},c.prototype.implicit=function(e){const t=this._baseState;return a(null===t.explicit&&null===t.implicit),t.implicit=e,this},c.prototype.obj=function(){const e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},c.prototype.key=function(e){const t=this._baseState;return a(null===t.key),t.key=e,this},c.prototype.any=function(){return this._baseState.any=!0,this},c.prototype.choice=function(e){const t=this._baseState;return a(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map((function(t){return e[t]}))),this},c.prototype.contains=function(e){const t=this._baseState;return a(null===t.use),t.contains=e,this},c.prototype._decode=function(e,t){const r=this._baseState;if(null===r.parent)return e.wrapResult(r.children[0]._decode(e,t));let n,i=r.default,a=!0,s=null;if(null!==r.key&&(s=e.enterKey(r.key)),r.optional){let n=null;if(null!==r.explicit?n=r.explicit:null!==r.implicit?n=r.implicit:null!==r.tag&&(n=r.tag),null!==n||r.any){if(a=this._peekTag(e,n,r.any),e.isError(a))return a}else{const n=e.save();try{null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),a=!0}catch(e){a=!1}e.restore(n)}}if(r.obj&&a&&(n=e.enterObject()),a){if(null!==r.explicit){const t=this._decodeTag(e,r.explicit);if(e.isError(t))return t;e=t}const n=e.offset;if(null===r.use&&null===r.choice){let t;r.any&&(t=e.save());const n=this._decodeTag(e,null!==r.implicit?r.implicit:r.tag,r.any);if(e.isError(n))return n;r.any?i=e.raw(t):e=n}if(t&&t.track&&null!==r.tag&&t.track(e.path(),n,e.length,"tagged"),t&&t.track&&null!==r.tag&&t.track(e.path(),e.offset,e.length,"content"),r.any||(i=null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t)),e.isError(i))return i;if(r.any||null!==r.choice||null===r.children||r.children.forEach((function(r){r._decode(e,t)})),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){const n=new o(i);i=this._getUse(r.contains,e._reporterState.obj)._decode(n,t)}}return r.obj&&a&&(i=e.leaveObject(n)),null===r.key||null===i&&!0!==a?null!==s&&e.exitKey(s):e.leaveKey(s,r.key,i),i},c.prototype._decodeGeneric=function(e,t,r){const n=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,n.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&n.args?this._decodeObjid(t,n.args[0],n.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,n.args&&n.args[0],r):null!==n.use?this._getUse(n.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},c.prototype._getUse=function(e,t){const r=this._baseState;return r.useDecoder=this._use(e,t),a(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},c.prototype._decodeChoice=function(e,t){const r=this._baseState;let n=null,i=!1;return Object.keys(r.choice).some((function(o){const a=e.save(),s=r.choice[o];try{const r=s._decode(e,t);if(e.isError(r))return!1;n={type:o,value:r},i=!0}catch(t){return e.restore(a),!1}return!0}),this),i?n:e.error("Choice not matched")},c.prototype._createEncoderBuffer=function(e){return new i(e,this.reporter)},c.prototype._encode=function(e,t,r){const n=this._baseState;if(null!==n.default&&n.default===e)return;const i=this._encodeValue(e,t,r);return void 0===i||this._skipDefault(i,t,r)?void 0:i},c.prototype._encodeValue=function(e,t,r){const i=this._baseState;if(null===i.parent)return i.children[0]._encode(e,t||new n);let o=null;if(this.reporter=t,i.optional&&void 0===e){if(null===i.default)return;e=i.default}let a=null,s=!1;if(i.any)o=this._createEncoderBuffer(e);else if(i.choice)o=this._encodeChoice(e,t);else if(i.contains)a=this._getUse(i.contains,r)._encode(e,t),s=!0;else if(i.children)a=i.children.map((function(r){if("null_"===r._baseState.tag)return r._encode(null,t,e);if(null===r._baseState.key)return t.error("Child should have a key");const n=t.enterKey(r._baseState.key);if("object"!=typeof e)return t.error("Child expected, but input is not object");const i=r._encode(e[r._baseState.key],t,e);return t.leaveKey(n),i}),this).filter((function(e){return e})),a=this._createEncoderBuffer(a);else if("seqof"===i.tag||"setof"===i.tag){if(!i.args||1!==i.args.length)return t.error("Too many args for : "+i.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");const r=this.clone();r._baseState.implicit=null,a=this._createEncoderBuffer(e.map((function(r){const n=this._baseState;return this._getUse(n.args[0],e)._encode(r,t)}),r))}else null!==i.use?o=this._getUse(i.use,r)._encode(e,t):(a=this._encodePrimitive(i.tag,e),s=!0);if(!i.any&&null===i.choice){const e=null!==i.implicit?i.implicit:i.tag,r=null===i.implicit?"universal":"context";null===e?null===i.use&&t.error("Tag could be omitted only for .use()"):null===i.use&&(o=this._encodeComposite(e,s,r,a))}return null!==i.explicit&&(o=this._encodeComposite(i.explicit,!1,"context",o)),o},c.prototype._encodeChoice=function(e,t){const r=this._baseState,n=r.choice[e.type];return n||a(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),n._encode(e.value,t)},c.prototype._encodePrimitive=function(e,t){const r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},c.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},c.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(e)}},98465:(e,t,r)=>{"use strict";const n=r(35717);function i(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function o(e,t){this.path=e,this.rethrow(t)}t.b=i,i.prototype.isError=function(e){return e instanceof o},i.prototype.save=function(){const e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},i.prototype.restore=function(e){const t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},i.prototype.enterKey=function(e){return this._reporterState.path.push(e)},i.prototype.exitKey=function(e){const t=this._reporterState;t.path=t.path.slice(0,e-1)},i.prototype.leaveKey=function(e,t,r){const n=this._reporterState;this.exitKey(e),null!==n.obj&&(n.obj[t]=r)},i.prototype.path=function(){return this._reporterState.path.join("/")},i.prototype.enterObject=function(){const e=this._reporterState,t=e.obj;return e.obj={},t},i.prototype.leaveObject=function(e){const t=this._reporterState,r=t.obj;return t.obj=e,r},i.prototype.error=function(e){let t;const r=this._reporterState,n=e instanceof o;if(t=n?e:new o(r.path.map((function(e){return"["+JSON.stringify(e)+"]"})).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},i.prototype.wrapResult=function(e){const t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},n(o,Error),o.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,o),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},70160:(e,t)=>{"use strict";function r(e){const t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);const n=e[r];t[n]=r})),t}t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=r(t.tagClass),t.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"},t.tagByName=r(t.tag)},36826:(e,t,r)=>{"use strict";const n=t;n._reverse=function(e){const t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);const n=e[r];t[n]=r})),t},n.der=r(70160)},41671:(e,t,r)=>{"use strict";const n=r(35717),i=r(4590),o=r(36625).C,a=r(41949),s=r(70160);function u(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new c,this.tree._init(e.body)}function c(e){a.call(this,"der",e)}function l(e,t){let r=e.readUInt8(t);if(e.isError(r))return r;const n=s.tagClass[r>>6],i=0==(32&r);if(31==(31&r)){let n=r;for(r=0;128==(128&n);){if(n=e.readUInt8(t),e.isError(n))return n;r<<=7,r|=127&n}}else r&=31;return{cls:n,primitive:i,tag:r,tagStr:s.tag[r]}}function f(e,t,r){let n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&128===n)return null;if(0==(128&n))return n;const i=127&n;if(i>4)return e.error("length octect is too long");n=0;for(let t=0;t{"use strict";const n=t;n.der=r(41671),n.pem=r(59631)},59631:(e,t,r)=>{"use strict";const n=r(35717),i=r(2399).Buffer,o=r(41671);function a(e){o.call(this,e),this.enc="pem"}n(a,o),e.exports=a,a.prototype.decode=function(e,t){const r=e.toString().split(/[\r\n]+/g),n=t.label.toUpperCase(),a=/^-----(BEGIN|END) ([^-]+)-----$/;let s=-1,u=-1;for(let e=0;e{"use strict";const n=r(35717),i=r(2399).Buffer,o=r(41949),a=r(70160);function s(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){o.call(this,"der",e)}function c(e){return e<10?"0"+e:e}e.exports=s,s.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},n(u,o),u.prototype._encodeComposite=function(e,t,r,n){const o=function(e,t,r,n){let i;"seqof"===e?e="seq":"setof"===e&&(e="set");if(a.tagByName.hasOwnProperty(e))i=a.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return n.error("Unknown tag: "+e);i=e}if(i>=31)return n.error("Multi-octet tag encoding unsupported");t||(i|=32);return i|=a.tagClassByName[r||"universal"]<<6,i}(e,t,r,this.reporter);if(n.length<128){const e=i.alloc(2);return e[0]=o,e[1]=n.length,this._createEncoderBuffer([e,n])}let s=1;for(let e=n.length;e>=256;e>>=8)s++;const u=i.alloc(2+s);u[0]=o,u[1]=128|s;for(let e=1+s,t=n.length;t>0;e--,t>>=8)u[e]=255&t;return this._createEncoderBuffer([u,n])},u.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){const t=i.alloc(2*e.length);for(let r=0;r=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}let n=0;for(let t=0;t=128;r>>=7)n++}const o=i.alloc(n);let a=o.length-1;for(let t=e.length-1;t>=0;t--){let r=e[t];for(o[a--]=127&r;(r>>=7)>0;)o[a--]=128|127&r}return this._createEncoderBuffer(o)},u.prototype._encodeTime=function(e,t){let r;const n=new Date(e);return"gentime"===t?r=[c(n.getUTCFullYear()),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[c(n.getUTCFullYear()%100),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},u.prototype._encodeNull=function(){return this._createEncoderBuffer("")},u.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!i.isBuffer(e)){const t=e.toArray();!e.sign&&128&t[0]&&t.unshift(0),e=i.from(t)}if(i.isBuffer(e)){let t=e.length;0===e.length&&t++;const r=i.alloc(t);return e.copy(r),0===e.length&&(r[0]=0),this._createEncoderBuffer(r)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);let r=1;for(let t=e;t>=256;t>>=8)r++;const n=new Array(r);for(let t=n.length-1;t>=0;t--)n[t]=255&e,e>>=8;return 128&n[0]&&n.unshift(0),this._createEncoderBuffer(i.from(n))},u.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},u.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},u.prototype._skipDefault=function(e,t,r){const n=this._baseState;let i;if(null===n.default)return!1;const o=e.join();if(void 0===n.defaultBuffer&&(n.defaultBuffer=this._encodeValue(n.default,t,r).join()),o.length!==n.defaultBuffer.length)return!1;for(i=0;i{"use strict";const n=t;n.der=r(66984),n.pem=r(2883)},2883:(e,t,r)=>{"use strict";const n=r(35717),i=r(66984);function o(e){i.call(this,e),this.enc="pem"}n(o,i),e.exports=o,o.prototype.encode=function(e,t){const r=i.prototype.encode.call(this,e).toString("base64"),n=["-----BEGIN "+t.label+"-----"];for(let e=0;e=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},44583:(e,t,r)=>{const n=r(36805);e.exports=async function(e,t){const r={algorithm:"URDNA2015",format:"application/n-quads"};t&&(r.inputFormat=t);const i=(await n.canonize(e,r)).split("\n").filter((e=>""!==e));if(i&&0===i.length)throw Error("File format is corrupted, no n-quads are extracted.");return i}},66302:e=>{e.exports={getAssertionSizeInBytes:function(e){const t=JSON.stringify(e);return(new TextEncoder).encode(t).length},getAssertionTriplesNumber:function(e){return e.length},getAssertionChunksNumber:function(e){return e.length}}},6025:(e,t,r)=>{const n=r(54099),{MerkleTree:i}=r(2162),o=r(25651);e.exports=function(e){e.sort();const t=e.map(((e,t)=>o(n.utils.solidityPack(["bytes32","uint256"],[o(e),t]))));return`0x${new i(t,o,{sortPairs:!0}).getRoot().toString("hex")}`}},75386:e=>{e.exports="https://ontology.origintrail.io/dkg/1.0#privateAssertionID"},94263:(e,t,r)=>{const n=r(54099),{MerkleTree:i}=r(2162),o=r(25651);e.exports=function(e,t){e.sort();const r=e.map(((e,t)=>o(n.utils.solidityPack(["bytes32","uint256"],[o(e),t])))),a=new i(r,o,{sortPairs:!0});return{leaf:o(e[t]),proof:a.getHexProof(r[t])}}},58735:(e,t,r)=>{const n=r(44583),i=r(6025),o=r(75386);function a(e){return 0===Object.keys(e).length&&e.constructor===Object}e.exports=async function(e){let t;e.private&&!a(e.private)&&(t=await n(e.private));const r={"@graph":[e.public&&!a(e.public)?e.public:null,e.private&&!a(e.private)?{[o]:t?i(t):null}:null]},s={public:await n(r)};return t&&(s.private=t),s}},50953:(e,t,r)=>{const n=r(66302),i=r(6025),o=r(44583),a=r(58735),s=r(94263),u=r(88459),c=r(25651);e.exports={calculateRoot:i,formatAssertion:o,formatGraph:a,getMerkleProof:s,peerId2Hash:u,keccak256:c,assertionMetadata:n}},25651:(e,t,r)=>{const n=r(54099);e.exports=function(e){let t=e;return n.utils.isBytesLike(e)||(t=n.utils.toUtf8Bytes(e)),n.utils.keccak256(t)}},54099:(e,t,r)=>{"use strict";r.r(t),r.d(t,{BaseContract:()=>Bn,BigNumber:()=>X,Contract:()=>Nn,ContractFactory:()=>Ln,FixedNumber:()=>Vn,Signer:()=>lr,VoidSigner:()=>fr,Wallet:()=>Eo,Wordlist:()=>Ei,constants:()=>i,errors:()=>y,ethers:()=>u,getDefaultProvider:()=>vu,logger:()=>Qu,providers:()=>o,utils:()=>s,version:()=>Xu,wordlists:()=>xi});var n={};r.r(n),r.d(n,{decode:()=>Te,encode:()=>Ee});var i={};r.r(i),r.d(i,{AddressZero:()=>To,EtherSymbol:()=>Po,HashZero:()=>xo,MaxInt256:()=>yt,MaxUint256:()=>pt,MinInt256:()=>mt,NegativeOne:()=>ct,One:()=>ft,Two:()=>ht,WeiPerEther:()=>dt,Zero:()=>lt});var o={};r.r(o),r.d(o,{AlchemyProvider:()=>_s,AlchemyWebSocketProvider:()=>Es,AnkrProvider:()=>Ps,BaseProvider:()=>$a,CloudflareProvider:()=>Rs,EtherscanProvider:()=>js,FallbackProvider:()=>ru,Formatter:()=>_a,InfuraProvider:()=>su,InfuraWebSocketProvider:()=>au,IpcProvider:()=>nu,JsonRpcBatchProvider:()=>uu,JsonRpcProvider:()=>hs,JsonRpcSigner:()=>cs,NodesmithProvider:()=>lu,PocketProvider:()=>du,Provider:()=>or,Resolver:()=>Wa,StaticJsonRpcProvider:()=>ws,UrlJsonRpcProvider:()=>As,Web3Provider:()=>gu,WebSocketProvider:()=>gs,getDefaultProvider:()=>vu,getNetwork:()=>Uo,isCommunityResourcable:()=>Ma,isCommunityResource:()=>Ta,showThrottleMessage:()=>Pa});var a={};r.r(a),r.d(a,{decode:()=>Fo,encode:()=>Do});var s={};r.r(s),r.d(s,{AbiCoder:()=>Kt,ConstructorFragment:()=>Nt,ErrorFragment:()=>Ft,EventFragment:()=>Ot,FormatTypes:()=>Mt,Fragment:()=>It,FunctionFragment:()=>Lt,HDNode:()=>Di,Indexed:()=>Yt,Interface:()=>tr,LogDescription:()=>Qt,Logger:()=>b,ParamType:()=>xt,RLP:()=>n,SigningKey:()=>$r,SupportedAlgorithm:()=>yi,TransactionDescription:()=>Wt,TransactionTypes:()=>nn,UnicodeNormalizationForm:()=>je,Utf8ErrorFuncs:()=>ze,Utf8ErrorReason:()=>He,_TypedDataEncoder:()=>di,_fetchData:()=>ba,_toEscapedUtf8String:()=>Ve,accessListify:()=>dn,arrayify:()=>_,base58:()=>mi,base64:()=>a,checkProperties:()=>ie,checkResultErrors:()=>de,commify:()=>zu,computeAddress:()=>cn,computeHmac:()=>Ai,computePublicKey:()=>tn,concat:()=>M,deepCopy:()=>ce,defaultAbiCoder:()=>Vt,defaultPath:()=>Fi,defineReadOnly:()=>te,dnsEncode:()=>fa,entropyToMnemonic:()=>Ji,fetchJson:()=>va,formatBytes32String:()=>Du,formatEther:()=>Ku,formatUnits:()=>Gu,getAccountPath:()=>Gi,getAddress:()=>Be,getContractAddress:()=>Ue,getCreate2Address:()=>Fe,getIcapAddress:()=>Le,getJsonWalletAddress:()=>vo,getStatic:()=>re,hashMessage:()=>Wn,hexConcat:()=>B,hexDataLength:()=>R,hexDataSlice:()=>C,hexStripZeros:()=>L,hexValue:()=>N,hexZeroPad:()=>U,hexlify:()=>O,id:()=>Ze,isAddress:()=>Ne,isBytes:()=>E,isBytesLike:()=>S,isHexString:()=>P,isValidMnemonic:()=>zi,isValidName:()=>ca,joinSignature:()=>D,keccak256:()=>ve,mnemonicToEntropy:()=>Hi,mnemonicToSeed:()=>ji,namehash:()=>la,nameprep:()=>Fu,parseBytes32String:()=>ju,parseEther:()=>Vu,parseTransaction:()=>vn,parseUnits:()=>qu,poll:()=>wa,randomBytes:()=>Xi,recoverAddress:()=>ln,recoverPublicKey:()=>en,resolveProperties:()=>ne,ripemd160:()=>bi,serializeTransaction:()=>gn,sha256:()=>vi,sha512:()=>wi,shallowCopy:()=>oe,shuffled:()=>Hs,solidityKeccak256:()=>Mu,solidityPack:()=>_u,soliditySha256:()=>Tu,splitSignature:()=>F,stripZeros:()=>T,toUtf8Bytes:()=>qe,toUtf8CodePoints:()=>We,toUtf8String:()=>Qe,verifyMessage:()=>_o,verifyTypedData:()=>Mo,zeroPad:()=>x});var u={};r.r(u),r.d(u,{BaseContract:()=>Bn,BigNumber:()=>X,Contract:()=>Nn,ContractFactory:()=>Ln,FixedNumber:()=>Vn,Signer:()=>lr,VoidSigner:()=>fr,Wallet:()=>Eo,Wordlist:()=>Ei,constants:()=>i,errors:()=>y,getDefaultProvider:()=>vu,logger:()=>Qu,providers:()=>o,utils:()=>s,version:()=>Xu,wordlists:()=>xi});let c=!1,l=!1;const f={debug:1,default:2,info:2,warning:3,error:4,off:5};let h=f.default,d=null;const p=function(){try{const e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((t=>{try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(e){return e.message}return null}();var m,y;!function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(m||(m={})),function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED",e.ACTION_REJECTED="ACTION_REJECTED"}(y||(y={}));const g="0123456789abcdef";class b{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,t){const r=e.toLowerCase();null==f[r]&&this.throwArgumentError("invalid log level name","logLevel",e),h>f[r]||console.log.apply(console,t)}debug(...e){this._log(b.levels.DEBUG,e)}info(...e){this._log(b.levels.INFO,e)}warn(...e){this._log(b.levels.WARNING,e)}makeError(e,t,r){if(l)return this.makeError("censored error",t,{});t||(t=b.errors.UNKNOWN_ERROR),r||(r={});const n=[];Object.keys(r).forEach((e=>{const t=r[e];try{if(t instanceof Uint8Array){let r="";for(let e=0;e>4],r+=g[15&t[e]];n.push(e+"=Uint8Array(0x"+r+")")}else n.push(e+"="+JSON.stringify(t))}catch(t){n.push(e+"="+JSON.stringify(r[e].toString()))}})),n.push(`code=${t}`),n.push(`version=${this.version}`);const i=e;let o="";switch(t){case y.NUMERIC_FAULT:{o="NUMERIC_FAULT";const t=e;switch(t){case"overflow":case"underflow":case"division-by-zero":o+="-"+t;break;case"negative-power":case"negative-width":o+="-unsupported";break;case"unbound-bitwise-result":o+="-unbound-result"}break}case y.CALL_EXCEPTION:case y.INSUFFICIENT_FUNDS:case y.MISSING_NEW:case y.NONCE_EXPIRED:case y.REPLACEMENT_UNDERPRICED:case y.TRANSACTION_REPLACED:case y.UNPREDICTABLE_GAS_LIMIT:o=t}o&&(e+=" [ See: https://links.ethers.org/v5-errors-"+o+" ]"),n.length&&(e+=" ("+n.join(", ")+")");const a=new Error(e);return a.reason=i,a.code=t,Object.keys(r).forEach((function(e){a[e]=r[e]})),a}throwError(e,t,r){throw this.makeError(e,t,r)}throwArgumentError(e,t,r){return this.throwError(e,b.errors.INVALID_ARGUMENT,{argument:t,value:r})}assert(e,t,r,n){e||this.throwError(t,r,n)}assertArgument(e,t,r,n){e||this.throwArgumentError(t,r,n)}checkNormalize(e){null==e&&(e="platform missing String.prototype.normalize"),p&&this.throwError("platform missing String.prototype.normalize",b.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:p})}checkSafeUint53(e,t){"number"==typeof e&&(null==t&&(t="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(t,b.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(t,b.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,t,r){r=r?": "+r:"",et&&this.throwError("too many arguments"+r,b.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:t})}checkNew(e,t){e!==Object&&null!=e||this.throwError("missing new",b.errors.MISSING_NEW,{name:t.name})}checkAbstract(e,t){e===t?this.throwError("cannot instantiate abstract class "+JSON.stringify(t.name)+" directly; use a sub-class",b.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):e!==Object&&null!=e||this.throwError("missing new",b.errors.MISSING_NEW,{name:t.name})}static globalLogger(){return d||(d=new b("logger/5.7.0")),d}static setCensorship(e,t){if(!e&&t&&this.globalLogger().throwError("cannot permanently disable censorship",b.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),c){if(!e)return;this.globalLogger().throwError("error censorship permanent",b.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}l=!!e,c=!!t}static setLogLevel(e){const t=f[e.toLowerCase()];null!=t?h=t:b.globalLogger().warn("invalid log level - "+e)}static from(e){return new b(e)}}b.errors=y,b.levels=m;const v=new b("bytes/5.7.0");function w(e){return!!e.toHexString}function A(e){return e.slice||(e.slice=function(){const t=Array.prototype.slice.call(arguments);return A(new Uint8Array(Array.prototype.slice.apply(e,t)))}),e}function S(e){return P(e)&&!(e.length%2)||E(e)}function k(e){return"number"==typeof e&&e==e&&e%1==0}function E(e){if(null==e)return!1;if(e.constructor===Uint8Array)return!0;if("string"==typeof e)return!1;if(!k(e.length)||e.length<0)return!1;for(let t=0;t=256)return!1}return!0}function _(e,t){if(t||(t={}),"number"==typeof e){v.checkSafeUint53(e,"invalid arrayify value");const t=[];for(;e;)t.unshift(255&e),e=parseInt(String(e/256));return 0===t.length&&t.push(0),A(new Uint8Array(t))}if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),w(e)&&(e=e.toHexString()),P(e)){let r=e.substring(2);r.length%2&&("left"===t.hexPad?r="0"+r:"right"===t.hexPad?r+="0":v.throwArgumentError("hex data is odd-length","value",e));const n=[];for(let e=0;e_(e))),r=t.reduce(((e,t)=>e+t.length),0),n=new Uint8Array(r);return t.reduce(((e,t)=>(n.set(t,e),e+t.length)),0),A(n)}function T(e){let t=_(e);if(0===t.length)return t;let r=0;for(;rt&&v.throwArgumentError("value out of range","value",arguments[0]);const r=new Uint8Array(t);return r.set(e,t-e.length),A(r)}function P(e,t){return!("string"!=typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&(!t||e.length===2+2*t)}const I="0123456789abcdef";function O(e,t){if(t||(t={}),"number"==typeof e){v.checkSafeUint53(e,"invalid hexlify value");let t="";for(;e;)t=I[15&e]+t,e=Math.floor(e/16);return t.length?(t.length%2&&(t="0"+t),"0x"+t):"0x00"}if("bigint"==typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),w(e))return e.toHexString();if(P(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":v.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(E(e)){let t="0x";for(let r=0;r>4]+I[15&n]}return t}return v.throwArgumentError("invalid hexlify value","value",e)}function R(e){if("string"!=typeof e)e=O(e);else if(!P(e)||e.length%2)return null;return(e.length-2)/2}function C(e,t,r){return"string"!=typeof e?e=O(e):(!P(e)||e.length%2)&&v.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)}function B(e){let t="0x";return e.forEach((e=>{t+=O(e).substring(2)})),t}function N(e){const t=L(O(e,{hexPad:"left"}));return"0x"===t?"0x0":t}function L(e){"string"!=typeof e&&(e=O(e)),P(e)||v.throwArgumentError("invalid hex string","value",e),e=e.substring(2);let t=0;for(;t2*t+2&&v.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function F(e){const t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(S(e)){let r=_(e);64===r.length?(t.v=27+(r[32]>>7),r[32]&=127,t.r=O(r.slice(0,32)),t.s=O(r.slice(32,64))):65===r.length?(t.r=O(r.slice(0,32)),t.s=O(r.slice(32,64)),t.v=r[64]):v.throwArgumentError("invalid signature string","signature",e),t.v<27&&(0===t.v||1===t.v?t.v+=27:v.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=O(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){const r=x(_(t._vs),32);t._vs=O(r);const n=r[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=n:t.recoveryParam!==n&&v.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),r[0]&=127;const i=O(r);null==t.s?t.s=i:t.s!==i&&v.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?v.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{const r=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==r&&v.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&P(t.r)?t.r=U(t.r,32):v.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&P(t.s)?t.s=U(t.s,32):v.throwArgumentError("signature missing or invalid s","signature",e);const r=_(t.s);r[0]>=128&&v.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(r[0]|=128);const n=O(r);t._vs&&(P(t._vs)||v.throwArgumentError("signature invalid _vs","signature",e),t._vs=U(t._vs,32)),null==t._vs?t._vs=n:t._vs!==n&&v.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t.yParityAndS=t._vs,t.compact=t.r+t.yParityAndS.substring(2),t}function D(e){return O(M([(e=F(e)).r,e.s,e.recoveryParam?"0x1c":"0x1b"]))}var j=r(13550),H=r.n(j);const J="bignumber/5.7.0";var z=H().BN;const G=new b(J),q={},K=9007199254740991;let V=!1;class X{constructor(e,t){e!==q&&G.throwError("cannot call constructor directly; use BigNumber.from",b.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=t,this._isBigNumber=!0,Object.freeze(this)}fromTwos(e){return W(Z(this).fromTwos(e))}toTwos(e){return W(Z(this).toTwos(e))}abs(){return"-"===this._hex[0]?X.from(this._hex.substring(1)):this}add(e){return W(Z(this).add(Z(e)))}sub(e){return W(Z(this).sub(Z(e)))}div(e){return X.from(e).isZero()&&Y("division-by-zero","div"),W(Z(this).div(Z(e)))}mul(e){return W(Z(this).mul(Z(e)))}mod(e){const t=Z(e);return t.isNeg()&&Y("division-by-zero","mod"),W(Z(this).umod(t))}pow(e){const t=Z(e);return t.isNeg()&&Y("negative-power","pow"),W(Z(this).pow(t))}and(e){const t=Z(e);return(this.isNegative()||t.isNeg())&&Y("unbound-bitwise-result","and"),W(Z(this).and(t))}or(e){const t=Z(e);return(this.isNegative()||t.isNeg())&&Y("unbound-bitwise-result","or"),W(Z(this).or(t))}xor(e){const t=Z(e);return(this.isNegative()||t.isNeg())&&Y("unbound-bitwise-result","xor"),W(Z(this).xor(t))}mask(e){return(this.isNegative()||e<0)&&Y("negative-width","mask"),W(Z(this).maskn(e))}shl(e){return(this.isNegative()||e<0)&&Y("negative-width","shl"),W(Z(this).shln(e))}shr(e){return(this.isNegative()||e<0)&&Y("negative-width","shr"),W(Z(this).shrn(e))}eq(e){return Z(this).eq(Z(e))}lt(e){return Z(this).lt(Z(e))}lte(e){return Z(this).lte(Z(e))}gt(e){return Z(this).gt(Z(e))}gte(e){return Z(this).gte(Z(e))}isNegative(){return"-"===this._hex[0]}isZero(){return Z(this).isZero()}toNumber(){try{return Z(this).toNumber()}catch(e){Y("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch(e){}return G.throwError("this platform does not support BigInt",b.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(10===arguments[0]?V||(V=!0,G.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?G.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",b.errors.UNEXPECTED_ARGUMENT,{}):G.throwError("BigNumber.toString does not accept parameters",b.errors.UNEXPECTED_ARGUMENT,{})),Z(this).toString(10)}toHexString(){return this._hex}toJSON(e){return{type:"BigNumber",hex:this.toHexString()}}static from(e){if(e instanceof X)return e;if("string"==typeof e)return e.match(/^-?0x[0-9a-f]+$/i)?new X(q,Q(e)):e.match(/^-?[0-9]+$/)?new X(q,Q(new z(e))):G.throwArgumentError("invalid BigNumber string","value",e);if("number"==typeof e)return e%1&&Y("underflow","BigNumber.from",e),(e>=K||e<=-K)&&Y("overflow","BigNumber.from",e),X.from(String(e));const t=e;if("bigint"==typeof t)return X.from(t.toString());if(E(t))return X.from(O(t));if(t)if(t.toHexString){const e=t.toHexString();if("string"==typeof e)return X.from(e)}else{let e=t._hex;if(null==e&&"BigNumber"===t.type&&(e=t.hex),"string"==typeof e&&(P(e)||"-"===e[0]&&P(e.substring(1))))return X.from(e)}return G.throwArgumentError("invalid BigNumber value","value",e)}static isBigNumber(e){return!(!e||!e._isBigNumber)}}function Q(e){if("string"!=typeof e)return Q(e.toString(16));if("-"===e[0])return"-"===(e=e.substring(1))[0]&&G.throwArgumentError("invalid hex","value",e),"0x00"===(e=Q(e))?e:"-"+e;if("0x"!==e.substring(0,2)&&(e="0x"+e),"0x"===e)return"0x00";for(e.length%2&&(e="0x0"+e.substring(2));e.length>4&&"0x00"===e.substring(0,4);)e="0x"+e.substring(4);return e}function W(e){return X.from(Q(e))}function Z(e){const t=X.from(e).toHexString();return"-"===t[0]?new z("-"+t.substring(3),16):new z(t.substring(2),16)}function Y(e,t,r){const n={fault:e,operation:t};return null!=r&&(n.value=r),G.throwError(e,b.errors.NUMERIC_FAULT,n)}var $=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ee=new b("properties/5.7.0");function te(e,t,r){Object.defineProperty(e,t,{enumerable:!0,value:r,writable:!1})}function re(e,t){for(let r=0;r<32;r++){if(e[t])return e[t];if(!e.prototype||"object"!=typeof e.prototype)break;e=Object.getPrototypeOf(e.prototype).constructor}return null}function ne(e){return $(this,void 0,void 0,(function*(){const t=Object.keys(e).map((t=>{const r=e[t];return Promise.resolve(r).then((e=>({key:t,value:e})))}));return(yield Promise.all(t)).reduce(((e,t)=>(e[t.key]=t.value,e)),{})}))}function ie(e,t){e&&"object"==typeof e||ee.throwArgumentError("invalid object","object",e),Object.keys(e).forEach((r=>{t[r]||ee.throwArgumentError("invalid object key - "+r,"transaction:"+r,e)}))}function oe(e){const t={};for(const r in e)t[r]=e[r];return t}const ae={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function se(e){if(null==e||ae[typeof e])return!0;if(Array.isArray(e)||"object"==typeof e){if(!Object.isFrozen(e))return!1;const t=Object.keys(e);for(let r=0;rce(e))));if("object"==typeof e){const t={};for(const r in e){const n=e[r];void 0!==n&&te(t,r,ce(n))}return t}return ee.throwArgumentError("Cannot deepCopy "+typeof e,"object",e)}function ce(e){return ue(e)}class le{constructor(e){for(const t in e)this[t]=ce(e[t])}}const fe="abi/5.7.0",he=new b(fe);function de(e){const t=[],r=function(e,n){if(Array.isArray(n))for(let i in n){const o=e.slice();o.push(i);try{r(o,n[i])}catch(e){t.push({path:o,error:e})}}};return r([],e),t}class pe{constructor(e,t,r,n){this.name=e,this.type=t,this.localName=r,this.dynamic=n}_throwError(e,t){he.throwArgumentError(e,this.localName,t)}}class me{constructor(e){te(this,"wordSize",e||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(e)}get data(){return B(this._data)}get length(){return this._dataLength}_writeData(e){return this._data.push(e),this._dataLength+=e.length,e.length}appendWriter(e){return this._writeData(M(e._data))}writeBytes(e){let t=_(e);const r=t.length%this.wordSize;return r&&(t=M([t,this._padding.slice(r)])),this._writeData(t)}_getValue(e){let t=_(X.from(e));return t.length>this.wordSize&&he.throwError("value out-of-bounds",b.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=M([this._padding.slice(t.length%this.wordSize),t])),t}writeValue(e){return this._writeData(this._getValue(e))}writeUpdatableValue(){const e=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,t=>{this._data[e]=this._getValue(t)}}}class ye{constructor(e,t,r,n){te(this,"_data",_(e)),te(this,"wordSize",t||32),te(this,"_coerceFunc",r),te(this,"allowLoose",n),this._offset=0}get data(){return O(this._data)}get consumed(){return this._offset}static coerce(e,t){let r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}coerce(e,t){return this._coerceFunc?this._coerceFunc(e,t):ye.coerce(e,t)}_peekBytes(e,t,r){let n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:he.throwError("data out-of-bounds",b.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}subReader(e){return new ye(this._data.slice(this._offset+e),this.wordSize,this._coerceFunc,this.allowLoose)}readBytes(e,t){let r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}readValue(){return X.from(this.readBytes(this.wordSize))}}var ge=r(91094),be=r.n(ge);function ve(e){return"0x"+be().keccak_256(_(e))}const we=new b("rlp/5.7.0");function Ae(e){const t=[];for(;e;)t.unshift(255&e),e>>=8;return t}function Se(e,t,r){let n=0;for(let i=0;it+1+n&&we.throwError("child data too short",b.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:i}}function Me(e,t){if(0===e.length&&we.throwError("data too short",b.errors.BUFFER_OVERRUN,{}),e[t]>=248){const r=e[t]-247;t+1+r>e.length&&we.throwError("data short segment too short",b.errors.BUFFER_OVERRUN,{});const n=Se(e,t+1,r);return t+1+r+n>e.length&&we.throwError("data long segment too short",b.errors.BUFFER_OVERRUN,{}),_e(e,t,t+1+r,r+n)}if(e[t]>=192){const r=e[t]-192;return t+1+r>e.length&&we.throwError("data array too short",b.errors.BUFFER_OVERRUN,{}),_e(e,t,t+1,r)}if(e[t]>=184){const r=e[t]-183;t+1+r>e.length&&we.throwError("data array too short",b.errors.BUFFER_OVERRUN,{});const n=Se(e,t+1,r);t+1+r+n>e.length&&we.throwError("data array too short",b.errors.BUFFER_OVERRUN,{});return{consumed:1+r+n,result:O(e.slice(t+1+r,t+1+r+n))}}if(e[t]>=128){const r=e[t]-128;t+1+r>e.length&&we.throwError("data too short",b.errors.BUFFER_OVERRUN,{});return{consumed:1+r,result:O(e.slice(t+1,t+1+r))}}return{consumed:1,result:O(e[t])}}function Te(e){const t=_(e),r=Me(t,0);return r.consumed!==t.length&&we.throwArgumentError("invalid rlp data","data",e),r.result}const xe=new b("address/5.7.0");function Pe(e){P(e,20)||xe.throwArgumentError("invalid address","address",e);const t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40);for(let e=0;e<40;e++)r[e]=t[e].charCodeAt(0);const n=_(ve(r));for(let e=0;e<40;e+=2)n[e>>1]>>4>=8&&(t[e]=t[e].toUpperCase()),(15&n[e>>1])>=8&&(t[e+1]=t[e+1].toUpperCase());return"0x"+t.join("")}const Ie={};for(let e=0;e<10;e++)Ie[String(e)]=String(e);for(let e=0;e<26;e++)Ie[String.fromCharCode(65+e)]=String(10+e);const Oe=Math.floor((Re=9007199254740991,Math.log10?Math.log10(Re):Math.log(Re)/Math.LN10));var Re;function Ce(e){let t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((e=>Ie[e])).join("");for(;t.length>=Oe;){let e=t.substring(0,Oe);t=parseInt(e,10)%97+t.substring(e.length)}let r=String(98-parseInt(t,10)%97);for(;r.length<2;)r="0"+r;return r}function Be(e){let t=null;if("string"!=typeof e&&xe.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=Pe(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&xe.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==Ce(e)&&xe.throwArgumentError("bad icap checksum","address",e),r=e.substring(4),t=new z(r,36).toString(16);t.length<40;)t="0"+t;t=Pe("0x"+t)}else xe.throwArgumentError("invalid address","address",e);var r;return t}function Ne(e){try{return Be(e),!0}catch(e){}return!1}function Le(e){let t=(r=Be(e).substring(2),new z(r,16).toString(36)).toUpperCase();for(var r;t.length<30;)t="0"+t;return"XE"+Ce("XE00"+t)+t}function Ue(e){let t=null;try{t=Be(e.from)}catch(t){xe.throwArgumentError("missing from address","transaction",e)}return Be(C(ve(Ee([t,T(_(X.from(e.nonce).toHexString()))])),12))}function Fe(e,t,r){return 32!==R(t)&&xe.throwArgumentError("salt must be 32 bytes","salt",t),32!==R(r)&&xe.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),Be(C(ve(M(["0xff",Be(e),t,r])),12))}const De=new b("strings/5.7.0");var je,He;function Je(e,t,r,n,i){if(e===He.BAD_PREFIX||e===He.UNEXPECTED_CONTINUE){let e=0;for(let n=t+1;n>6==2;n++)e++;return e}return e===He.OVERRUN?r.length-t-1:0}!function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(je||(je={})),function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(He||(He={}));const ze=Object.freeze({error:function(e,t,r,n,i){return De.throwArgumentError(`invalid codepoint at offset ${t}; ${e}`,"bytes",r)},ignore:Je,replace:function(e,t,r,n,i){return e===He.OVERLONG?(n.push(i),0):(n.push(65533),Je(e,t,r))}});function Ge(e,t){null==t&&(t=ze.error),e=_(e);const r=[];let n=0;for(;n>7==0){r.push(i);continue}let o=null,a=null;if(192==(224&i))o=1,a=127;else if(224==(240&i))o=2,a=2047;else{if(240!=(248&i)){n+=t(128==(192&i)?He.UNEXPECTED_CONTINUE:He.BAD_PREFIX,n-1,e,r);continue}o=3,a=65535}if(n-1+o>=e.length){n+=t(He.OVERRUN,n-1,e,r);continue}let s=i&(1<<8-o-1)-1;for(let i=0;i1114111?n+=t(He.OUT_OF_RANGE,n-1-o,e,r,s):s>=55296&&s<=57343?n+=t(He.UTF16_SURROGATE,n-1-o,e,r,s):s<=a?n+=t(He.OVERLONG,n-1-o,e,r,s):r.push(s))}return r}function qe(e,t=je.current){t!=je.current&&(De.checkNormalize(),e=e.normalize(t));let r=[];for(let t=0;t>6|192),r.push(63&n|128);else if(55296==(64512&n)){t++;const i=e.charCodeAt(t);if(t>=e.length||56320!=(64512&i))throw new Error("invalid utf-8 string");const o=65536+((1023&n)<<10)+(1023&i);r.push(o>>18|240),r.push(o>>12&63|128),r.push(o>>6&63|128),r.push(63&o|128)}else r.push(n>>12|224),r.push(n>>6&63|128),r.push(63&n|128)}return _(r)}function Ke(e){const t="0000"+e.toString(16);return"\\u"+t.substring(t.length-4)}function Ve(e,t){return'"'+Ge(e,t).map((e=>{if(e<256){switch(e){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(e>=32&&e<127)return String.fromCharCode(e)}return e<=65535?Ke(e):Ke(55296+((e-=65536)>>10&1023))+Ke(56320+(1023&e))})).join("")+'"'}function Xe(e){return e.map((e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e))))).join("")}function Qe(e,t){return Xe(Ge(e,t))}function We(e,t=je.current){return Ge(qe(e,t))}function Ze(e){return ve(qe(e))}class Ye extends pe{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,t){try{t=Be(t)}catch(e){this._throwError(e.message,t)}return e.writeValue(t)}decode(e){return Be(U(e.readValue().toHexString(),20))}}class $e extends pe{constructor(e){super(e.name,e.type,void 0,e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,t){return this.coder.encode(e,t)}decode(e){return this.coder.decode(e)}}const et=new b(fe);function tt(e,t,r){let n=null;if(Array.isArray(r))n=r;else if(r&&"object"==typeof r){let e={};n=t.map((t=>{const n=t.localName;return n||et.throwError("cannot encode object for signature with missing names",b.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]&&et.throwError("cannot encode object for signature with duplicate names",b.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]=!0,r[n]}))}else et.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&et.throwArgumentError("types/value length mismatch","tuple",r);let i=new me(e.wordSize),o=new me(e.wordSize),a=[];t.forEach(((e,t)=>{let r=n[t];if(e.dynamic){let t=o.length;e.encode(o,r);let n=i.writeUpdatableValue();a.push((e=>{n(e+t)}))}else e.encode(i,r)})),a.forEach((e=>{e(i.length)}));let s=e.appendWriter(i);return s+=e.appendWriter(o),s}function rt(e,t){let r=[],n=e.subReader(0);t.forEach((t=>{let i=null;if(t.dynamic){let r=e.readValue(),o=n.subReader(r.toNumber());try{i=t.decode(o)}catch(e){if(e.code===b.errors.BUFFER_OVERRUN)throw e;i=e,i.baseType=t.name,i.name=t.localName,i.type=t.type}}else try{i=t.decode(e)}catch(e){if(e.code===b.errors.BUFFER_OVERRUN)throw e;i=e,i.baseType=t.name,i.name=t.localName,i.type=t.type}null!=i&&r.push(i)}));const i=t.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach(((e,t)=>{let n=e.localName;if(!n||1!==i[n])return;if("length"===n&&(n="_length"),null!=r[n])return;const o=r[t];o instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:()=>{throw o}}):r[n]=o}));for(let e=0;e{throw t}})}return Object.freeze(r)}class nt extends pe{constructor(e,t,r){super("array",e.type+"["+(t>=0?t:"")+"]",r,-1===t||e.dynamic),this.coder=e,this.length=t}defaultValue(){const e=this.coder.defaultValue(),t=[];for(let r=0;re._data.length&&et.throwError("insufficient data length",b.errors.BUFFER_OVERRUN,{length:e._data.length,count:t}));let r=[];for(let e=0;e{e.dynamic&&(r=!0),n.push(e.type)}));super("tuple","tuple("+n.join(",")+")",t,r),this.coders=e}defaultValue(){const e=[];this.coders.forEach((t=>{e.push(t.defaultValue())}));const t=this.coders.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach(((r,n)=>{let i=r.localName;i&&1===t[i]&&("length"===i&&(i="_length"),null==e[i]&&(e[i]=e[n]))})),Object.freeze(e)}encode(e,t){return tt(e,this.coders,t)}decode(e){return e.coerce(this.name,rt(e,this.coders))}}const wt=new b(fe),At={};let St={calldata:!0,memory:!0,storage:!0},kt={calldata:!0,memory:!0};function Et(e,t){if("bytes"===e||"string"===e){if(St[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&kt[t])return!0;return(St[t]||"payable"===t)&&wt.throwArgumentError("invalid modifier","name",t),!1}function _t(e,t){for(let r in t)te(e,r,t[r])}const Mt=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),Tt=new RegExp(/^(.*)\[([0-9]*)\]$/);class xt{constructor(e,t){e!==At&&wt.throwError("use fromString",b.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),_t(this,t);let r=this.type.match(Tt);_t(this,r?{arrayLength:parseInt(r[2]||"-1"),arrayChildren:xt.fromObject({type:r[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json){let t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((t=>JSON.parse(t.format(e))))),JSON.stringify(t)}let t="";return"array"===this.baseType?(t+=this.arrayChildren.format(e),t+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==Mt.sighash&&(t+=this.type),t+="("+this.components.map((t=>t.format(e))).join(e===Mt.full?", ":",")+")"):t+=this.type,e!==Mt.sighash&&(!0===this.indexed&&(t+=" indexed"),e===Mt.full&&this.name&&(t+=" "+this.name)),t}static from(e,t){return"string"==typeof e?xt.fromString(e,t):xt.fromObject(e)}static fromObject(e){return xt.isParamType(e)?e:new xt(At,{name:e.name||null,type:Dt(e.type),indexed:null==e.indexed?null:!!e.indexed,components:e.components?e.components.map(xt.fromObject):null})}static fromString(e,t){return r=function(e,t){let r=e;function n(t){wt.throwArgumentError(`unexpected character at position ${t}`,"param",e)}function i(e){let r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");let o={type:"",name:"",state:{allowType:!0}},a=o;for(let r=0;rxt.fromString(e,t)))}class It{constructor(e,t){e!==At&&wt.throwError("use a static from method",b.errors.UNSUPPORTED_OPERATION,{operation:"new Fragment()"}),_t(this,t),this._isFragment=!0,Object.freeze(this)}static from(e){return It.isFragment(e)?e:"string"==typeof e?It.fromString(e):It.fromObject(e)}static fromObject(e){if(It.isFragment(e))return e;switch(e.type){case"function":return Lt.fromObject(e);case"event":return Ot.fromObject(e);case"constructor":return Nt.fromObject(e);case"error":return Ft.fromObject(e);case"fallback":case"receive":return null}return wt.throwArgumentError("invalid fragment object","value",e)}static fromString(e){return"event"===(e=(e=(e=e.replace(/\s/g," ")).replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," ")).trim()).split(" ")[0]?Ot.fromString(e.substring(5).trim()):"function"===e.split(" ")[0]?Lt.fromString(e.substring(8).trim()):"constructor"===e.split("(")[0].trim()?Nt.fromString(e.trim()):"error"===e.split(" ")[0]?Ft.fromString(e.substring(5).trim()):wt.throwArgumentError("unsupported fragment","value",e)}static isFragment(e){return!(!e||!e._isFragment)}}class Ot extends It{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Mt.sighash&&(t+="event "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ",e!==Mt.sighash&&this.anonymous&&(t+="anonymous "),t.trim()}static from(e){return"string"==typeof e?Ot.fromString(e):Ot.fromObject(e)}static fromObject(e){if(Ot.isEventFragment(e))return e;"event"!==e.type&&wt.throwArgumentError("invalid event object","value",e);const t={name:Ht(e.name),anonymous:e.anonymous,inputs:e.inputs?e.inputs.map(xt.fromObject):[],type:"event"};return new Ot(At,t)}static fromString(e){let t=e.match(Jt);t||wt.throwArgumentError("invalid event string","value",e);let r=!1;return t[3].split(" ").forEach((e=>{switch(e.trim()){case"anonymous":r=!0;break;case"":break;default:wt.warn("unknown modifier: "+e)}})),Ot.fromObject({name:t[1].trim(),anonymous:r,inputs:Pt(t[2],!0),type:"event"})}static isEventFragment(e){return e&&e._isFragment&&"event"===e.type}}function Rt(e,t){t.gas=null;let r=e.split("@");return 1!==r.length?(r.length>2&&wt.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||wt.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=X.from(r[1]),r[0]):e}function Ct(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((e=>{switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function Bt(e){let t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&wt.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&wt.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||wt.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&wt.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&wt.throwArgumentError("unable to determine stateMutability","value",e),t}class Nt extends It{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});e===Mt.sighash&&wt.throwError("cannot format a constructor for sighash",b.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});let t="constructor("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}static from(e){return"string"==typeof e?Nt.fromString(e):Nt.fromObject(e)}static fromObject(e){if(Nt.isConstructorFragment(e))return e;"constructor"!==e.type&&wt.throwArgumentError("invalid constructor object","value",e);let t=Bt(e);t.constant&&wt.throwArgumentError("constructor cannot be constant","value",e);const r={name:null,type:e.type,inputs:e.inputs?e.inputs.map(xt.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?X.from(e.gas):null};return new Nt(At,r)}static fromString(e){let t={type:"constructor"},r=(e=Rt(e,t)).match(Jt);return r&&"constructor"===r[1].trim()||wt.throwArgumentError("invalid constructor string","value",e),t.inputs=Pt(r[2].trim(),!1),Ct(r[3].trim(),t),Nt.fromObject(t)}static isConstructorFragment(e){return e&&e._isFragment&&"constructor"===e.type}}class Lt extends Nt{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e)))),outputs:this.outputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Mt.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ",e!==Mt.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((t=>t.format(e))).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}static from(e){return"string"==typeof e?Lt.fromString(e):Lt.fromObject(e)}static fromObject(e){if(Lt.isFunctionFragment(e))return e;"function"!==e.type&&wt.throwArgumentError("invalid function object","value",e);let t=Bt(e);const r={type:e.type,name:Ht(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(xt.fromObject):[],outputs:e.outputs?e.outputs.map(xt.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?X.from(e.gas):null};return new Lt(At,r)}static fromString(e){let t={type:"function"},r=(e=Rt(e,t)).split(" returns ");r.length>2&&wt.throwArgumentError("invalid function string","value",e);let n=r[0].match(Jt);if(n||wt.throwArgumentError("invalid function signature","value",e),t.name=n[1].trim(),t.name&&Ht(t.name),t.inputs=Pt(n[2],!1),Ct(n[3].trim(),t),r.length>1){let n=r[1].match(Jt);""==n[1].trim()&&""==n[3].trim()||wt.throwArgumentError("unexpected tokens","value",e),t.outputs=Pt(n[2],!1)}else t.outputs=[];return Lt.fromObject(t)}static isFunctionFragment(e){return e&&e._isFragment&&"function"===e.type}}function Ut(e){const t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||wt.throwArgumentError(`cannot specify user defined ${t} error`,"fragment",e),e}class Ft extends It{format(e){if(e||(e=Mt.sighash),Mt[e]||wt.throwArgumentError("invalid format type","format",e),e===Mt.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Mt.sighash&&(t+="error "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Mt.full?", ":",")+") ",t.trim()}static from(e){return"string"==typeof e?Ft.fromString(e):Ft.fromObject(e)}static fromObject(e){if(Ft.isErrorFragment(e))return e;"error"!==e.type&&wt.throwArgumentError("invalid error object","value",e);const t={type:e.type,name:Ht(e.name),inputs:e.inputs?e.inputs.map(xt.fromObject):[]};return Ut(new Ft(At,t))}static fromString(e){let t={type:"error"},r=e.match(Jt);return r||wt.throwArgumentError("invalid error signature","value",e),t.name=r[1].trim(),t.name&&Ht(t.name),t.inputs=Pt(r[2],!1),Ut(Ft.fromObject(t))}static isErrorFragment(e){return e&&e._isFragment&&"error"===e.type}}function Dt(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}const jt=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function Ht(e){return e&&e.match(jt)||wt.throwArgumentError(`invalid identifier "${e}"`,"value",e),e}const Jt=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");const zt=new b(fe),Gt=new RegExp(/^bytes([0-9]*)$/),qt=new RegExp(/^(u?int)([0-9]*)$/);class Kt{constructor(e){te(this,"coerceFunc",e||null)}_getCoder(e){switch(e.baseType){case"address":return new Ye(e.name);case"bool":return new it(e.name);case"string":return new bt(e.name);case"bytes":return new at(e.name);case"array":return new nt(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new vt((e.components||[]).map((e=>this._getCoder(e))),e.name);case"":return new ut(e.name)}let t=e.type.match(qt);if(t){let r=parseInt(t[2]||"256");return(0===r||r>256||r%8!=0)&&zt.throwArgumentError("invalid "+t[1]+" bit length","param",e),new gt(r/8,"int"===t[1],e.name)}if(t=e.type.match(Gt),t){let r=parseInt(t[1]);return(0===r||r>32)&&zt.throwArgumentError("invalid bytes length","param",e),new st(r,e.name)}return zt.throwArgumentError("invalid type","type",e.type)}_getWordSize(){return 32}_getReader(e,t){return new ye(e,this._getWordSize(),this.coerceFunc,t)}_getWriter(){return new me(this._getWordSize())}getDefaultValue(e){const t=e.map((e=>this._getCoder(xt.from(e))));return new vt(t,"_").defaultValue()}encode(e,t){e.length!==t.length&&zt.throwError("types/values length mismatch",b.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});const r=e.map((e=>this._getCoder(xt.from(e)))),n=new vt(r,"_"),i=this._getWriter();return n.encode(i,t),i.data}decode(e,t,r){const n=e.map((e=>this._getCoder(xt.from(e))));return new vt(n,"_").decode(this._getReader(_(t),r))}}const Vt=new Kt,Xt=new b(fe);class Qt extends le{}class Wt extends le{}class Zt extends le{}class Yt extends le{static isIndexed(e){return!(!e||!e._isIndexed)}}const $t={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function er(e,t){const r=new Error(`deferred error during ABI decoding triggered accessing ${e}`);return r.error=t,r}class tr{constructor(e){let t=[];t="string"==typeof e?JSON.parse(e):e,te(this,"fragments",t.map((e=>It.from(e))).filter((e=>null!=e))),te(this,"_abiCoder",re(new.target,"getAbiCoder")()),te(this,"functions",{}),te(this,"errors",{}),te(this,"events",{}),te(this,"structs",{}),this.fragments.forEach((e=>{let t=null;switch(e.type){case"constructor":return this.deploy?void Xt.warn("duplicate definition - constructor"):void te(this,"deploy",e);case"function":t=this.functions;break;case"event":t=this.events;break;case"error":t=this.errors;break;default:return}let r=e.format();t[r]?Xt.warn("duplicate definition - "+r):t[r]=e})),this.deploy||te(this,"deploy",Nt.from({payable:!1,type:"constructor"})),te(this,"_isInterface",!0)}format(e){e||(e=Mt.full),e===Mt.sighash&&Xt.throwArgumentError("interface does not support formatting sighash","format",e);const t=this.fragments.map((t=>t.format(e)));return e===Mt.json?JSON.stringify(t.map((e=>JSON.parse(e)))):t}static getAbiCoder(){return Vt}static getAddress(e){return Be(e)}static getSighash(e){return C(Ze(e.format()),0,4)}static getEventTopic(e){return Ze(e.format())}getFunction(e){if(P(e)){for(const t in this.functions)if(e===this.getSighash(t))return this.functions[t];Xt.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.functions).filter((e=>e.split("(")[0]===t));return 0===r.length?Xt.throwArgumentError("no matching function","name",t):r.length>1&&Xt.throwArgumentError("multiple matching functions","name",t),this.functions[r[0]]}const t=this.functions[Lt.fromString(e).format()];return t||Xt.throwArgumentError("no matching function","signature",e),t}getEvent(e){if(P(e)){const t=e.toLowerCase();for(const e in this.events)if(t===this.getEventTopic(e))return this.events[e];Xt.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.events).filter((e=>e.split("(")[0]===t));return 0===r.length?Xt.throwArgumentError("no matching event","name",t):r.length>1&&Xt.throwArgumentError("multiple matching events","name",t),this.events[r[0]]}const t=this.events[Ot.fromString(e).format()];return t||Xt.throwArgumentError("no matching event","signature",e),t}getError(e){if(P(e)){const t=re(this.constructor,"getSighash");for(const r in this.errors){if(e===t(this.errors[r]))return this.errors[r]}Xt.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.errors).filter((e=>e.split("(")[0]===t));return 0===r.length?Xt.throwArgumentError("no matching error","name",t):r.length>1&&Xt.throwArgumentError("multiple matching errors","name",t),this.errors[r[0]]}const t=this.errors[Lt.fromString(e).format()];return t||Xt.throwArgumentError("no matching error","signature",e),t}getSighash(e){if("string"==typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(e){throw t}}return re(this.constructor,"getSighash")(e)}getEventTopic(e){return"string"==typeof e&&(e=this.getEvent(e)),re(this.constructor,"getEventTopic")(e)}_decodeParams(e,t){return this._abiCoder.decode(e,t)}_encodeParams(e,t){return this._abiCoder.encode(e,t)}encodeDeploy(e){return this._encodeParams(this.deploy.inputs,e||[])}decodeErrorResult(e,t){"string"==typeof e&&(e=this.getError(e));const r=_(t);return O(r.slice(0,4))!==this.getSighash(e)&&Xt.throwArgumentError(`data signature does not match error ${e.name}.`,"data",O(r)),this._decodeParams(e.inputs,r.slice(4))}encodeErrorResult(e,t){return"string"==typeof e&&(e=this.getError(e)),O(M([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionData(e,t){"string"==typeof e&&(e=this.getFunction(e));const r=_(t);return O(r.slice(0,4))!==this.getSighash(e)&&Xt.throwArgumentError(`data signature does not match function ${e.name}.`,"data",O(r)),this._decodeParams(e.inputs,r.slice(4))}encodeFunctionData(e,t){return"string"==typeof e&&(e=this.getFunction(e)),O(M([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionResult(e,t){"string"==typeof e&&(e=this.getFunction(e));let r=_(t),n=null,i="",o=null,a=null,s=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(e){}break;case 4:{const e=O(r.slice(0,4)),t=$t[e];if(t)o=this._abiCoder.decode(t.inputs,r.slice(4)),a=t.name,s=t.signature,t.reason&&(n=o[0]),"Error"===a?i=`; VM Exception while processing transaction: reverted with reason string ${JSON.stringify(o[0])}`:"Panic"===a&&(i=`; VM Exception while processing transaction: reverted with panic code ${o[0]}`);else try{const t=this.getError(e);o=this._abiCoder.decode(t.inputs,r.slice(4)),a=t.name,s=t.format()}catch(e){}break}}return Xt.throwError("call revert exception"+i,b.errors.CALL_EXCEPTION,{method:e.format(),data:O(t),errorArgs:o,errorName:a,errorSignature:s,reason:n})}encodeFunctionResult(e,t){return"string"==typeof e&&(e=this.getFunction(e)),O(this._abiCoder.encode(e.outputs,t||[]))}encodeFilterTopics(e,t){"string"==typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&Xt.throwError("too many arguments for "+e.format(),b.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});let r=[];e.anonymous||r.push(this.getEventTopic(e));const n=(e,t)=>"string"===e.type?Ze(t):"bytes"===e.type?ve(O(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=X.from(t).toHexString()),"address"===e.type&&this._abiCoder.encode(["address"],[t]),U(O(t),32));for(t.forEach(((t,i)=>{let o=e.inputs[i];o.indexed?null==t?r.push(null):"array"===o.baseType||"tuple"===o.baseType?Xt.throwArgumentError("filtering with tuples or arrays not supported","contract."+o.name,t):Array.isArray(t)?r.push(t.map((e=>n(o,e)))):r.push(n(o,t)):null!=t&&Xt.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+o.name,t)}));r.length&&null===r[r.length-1];)r.pop();return r}encodeEventLog(e,t){"string"==typeof e&&(e=this.getEvent(e));const r=[],n=[],i=[];return e.anonymous||r.push(this.getEventTopic(e)),t.length!==e.inputs.length&&Xt.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach(((e,o)=>{const a=t[o];if(e.indexed)if("string"===e.type)r.push(Ze(a));else if("bytes"===e.type)r.push(ve(a));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");r.push(this._abiCoder.encode([e.type],[a]))}else n.push(e),i.push(a)})),{data:this._abiCoder.encode(n,i),topics:r}}decodeEventLog(e,t,r){if("string"==typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){let t=this.getEventTopic(e);P(r[0],32)&&r[0].toLowerCase()===t||Xt.throwError("fragment/topic mismatch",b.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:t,value:r[0]}),r=r.slice(1)}let n=[],i=[],o=[];e.inputs.forEach(((e,t)=>{e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(n.push(xt.fromObject({type:"bytes32",name:e.name})),o.push(!0)):(n.push(e),o.push(!1)):(i.push(e),o.push(!1))}));let a=null!=r?this._abiCoder.decode(n,M(r)):null,s=this._abiCoder.decode(i,t,!0),u=[],c=0,l=0;e.inputs.forEach(((e,t)=>{if(e.indexed)if(null==a)u[t]=new Yt({_isIndexed:!0,hash:null});else if(o[t])u[t]=new Yt({_isIndexed:!0,hash:a[l++]});else try{u[t]=a[l++]}catch(e){u[t]=e}else try{u[t]=s[c++]}catch(e){u[t]=e}if(e.name&&null==u[e.name]){const r=u[t];r instanceof Error?Object.defineProperty(u,e.name,{enumerable:!0,get:()=>{throw er(`property ${JSON.stringify(e.name)}`,r)}}):u[e.name]=r}}));for(let e=0;e{throw er(`index ${e}`,t)}})}return Object.freeze(u)}parseTransaction(e){let t=this.getFunction(e.data.substring(0,10).toLowerCase());return t?new Wt({args:this._abiCoder.decode(t.inputs,"0x"+e.data.substring(10)),functionFragment:t,name:t.name,signature:t.format(),sighash:this.getSighash(t),value:X.from(e.value||"0")}):null}parseLog(e){let t=this.getEvent(e.topics[0]);return!t||t.anonymous?null:new Qt({eventFragment:t,name:t.name,signature:t.format(),topic:this.getEventTopic(t),args:this.decodeEventLog(t,e.data,e.topics)})}parseError(e){const t=O(e);let r=this.getError(t.substring(0,10).toLowerCase());return r?new Zt({args:this._abiCoder.decode(r.inputs,"0x"+t.substring(10)),errorFragment:r,name:r.name,signature:r.format(),sighash:this.getSighash(r)}):null}static isInterface(e){return!(!e||!e._isInterface)}}var rr=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const nr=new b("abstract-provider/5.7.0");class ir extends le{static isForkEvent(e){return!(!e||!e._isForkEvent)}}class or{constructor(){nr.checkAbstract(new.target,or),te(this,"_isProvider",!0)}getFeeData(){return rr(this,void 0,void 0,(function*(){const{block:e,gasPrice:t}=yield ne({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch((e=>null))});let r=null,n=null,i=null;return e&&e.baseFeePerGas&&(r=e.baseFeePerGas,i=X.from("1500000000"),n=e.baseFeePerGas.mul(2).add(i)),{lastBaseFeePerGas:r,maxFeePerGas:n,maxPriorityFeePerGas:i,gasPrice:t}}))}addListener(e,t){return this.on(e,t)}removeListener(e,t){return this.off(e,t)}static isProvider(e){return!(!e||!e._isProvider)}}var ar=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const sr=new b("abstract-signer/5.7.0"),ur=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],cr=[b.errors.INSUFFICIENT_FUNDS,b.errors.NONCE_EXPIRED,b.errors.REPLACEMENT_UNDERPRICED];class lr{constructor(){sr.checkAbstract(new.target,lr),te(this,"_isSigner",!0)}getBalance(e){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),e)}))}getTransactionCount(e){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),e)}))}estimateGas(e){return ar(this,void 0,void 0,(function*(){this._checkProvider("estimateGas");const t=yield ne(this.checkTransaction(e));return yield this.provider.estimateGas(t)}))}call(e,t){return ar(this,void 0,void 0,(function*(){this._checkProvider("call");const r=yield ne(this.checkTransaction(e));return yield this.provider.call(r,t)}))}sendTransaction(e){return ar(this,void 0,void 0,(function*(){this._checkProvider("sendTransaction");const t=yield this.populateTransaction(e),r=yield this.signTransaction(t);return yield this.provider.sendTransaction(r)}))}getChainId(){return ar(this,void 0,void 0,(function*(){this._checkProvider("getChainId");return(yield this.provider.getNetwork()).chainId}))}getGasPrice(){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()}))}getFeeData(){return ar(this,void 0,void 0,(function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()}))}resolveName(e){return ar(this,void 0,void 0,(function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(e)}))}checkTransaction(e){for(const t in e)-1===ur.indexOf(t)&&sr.throwArgumentError("invalid transaction key: "+t,"transaction",e);const t=oe(e);return null==t.from?t.from=this.getAddress():t.from=Promise.all([Promise.resolve(t.from),this.getAddress()]).then((t=>(t[0].toLowerCase()!==t[1].toLowerCase()&&sr.throwArgumentError("from address mismatch","transaction",e),t[0]))),t}populateTransaction(e){return ar(this,void 0,void 0,(function*(){const t=yield ne(this.checkTransaction(e));null!=t.to&&(t.to=Promise.resolve(t.to).then((e=>ar(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.resolveName(e);return null==t&&sr.throwArgumentError("provided ENS name resolves to null","tx.to",e),t})))),t.to.catch((e=>{})));const r=null!=t.maxFeePerGas||null!=t.maxPriorityFeePerGas;if(null==t.gasPrice||2!==t.type&&!r?0!==t.type&&1!==t.type||!r||sr.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",e):sr.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",e),2!==t.type&&null!=t.type||null==t.maxFeePerGas||null==t.maxPriorityFeePerGas)if(0===t.type||1===t.type)null==t.gasPrice&&(t.gasPrice=this.getGasPrice());else{const e=yield this.getFeeData();if(null==t.type)if(null!=e.maxFeePerGas&&null!=e.maxPriorityFeePerGas)if(t.type=2,null!=t.gasPrice){const e=t.gasPrice;delete t.gasPrice,t.maxFeePerGas=e,t.maxPriorityFeePerGas=e}else null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas);else null!=e.gasPrice?(r&&sr.throwError("network does not support EIP-1559",b.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),null==t.gasPrice&&(t.gasPrice=e.gasPrice),t.type=0):sr.throwError("failed to get consistent fee data",b.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"});else 2===t.type&&(null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas))}else t.type=2;return null==t.nonce&&(t.nonce=this.getTransactionCount("pending")),null==t.gasLimit&&(t.gasLimit=this.estimateGas(t).catch((e=>{if(cr.indexOf(e.code)>=0)throw e;return sr.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,tx:t})}))),null==t.chainId?t.chainId=this.getChainId():t.chainId=Promise.all([Promise.resolve(t.chainId),this.getChainId()]).then((t=>(0!==t[1]&&t[0]!==t[1]&&sr.throwArgumentError("chainId address mismatch","transaction",e),t[0]))),yield ne(t)}))}_checkProvider(e){this.provider||sr.throwError("missing provider",b.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}static isSigner(e){return!(!e||!e._isSigner)}}class fr extends lr{constructor(e,t){super(),te(this,"address",e),te(this,"provider",t||null)}getAddress(){return Promise.resolve(this.address)}_fail(e,t){return Promise.resolve().then((()=>{sr.throwError(e,b.errors.UNSUPPORTED_OPERATION,{operation:t})}))}signMessage(e){return this._fail("VoidSigner cannot sign messages","signMessage")}signTransaction(e){return this._fail("VoidSigner cannot sign transactions","signTransaction")}_signTypedData(e,t,r){return this._fail("VoidSigner cannot sign typed data","signTypedData")}connect(e){return new fr(this.address,e)}}var hr=r(33715),dr=r.n(hr);"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==r.g?r.g:"undefined"!=typeof self&&self;function pr(e,t,r){return r={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&r.path)}},e(r,r.exports),r.exports}var mr=yr;function yr(e,t){if(!e)throw new Error(t||"Assertion failed")}yr.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var gr=pr((function(e,t){var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}})),br=pr((function(e,t){var r=t;r.assert=mr,r.toArray=gr.toArray,r.zero2=gr.zero2,r.toHex=gr.toHex,r.encode=gr.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!==(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!==(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"==typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new(H())(e,"hex","le")}})),vr=br.getNAF,wr=br.getJSF,Ar=br.assert;function Sr(e,t){this.type=e,this.p=new(H())(t.p,16),this.red=t.prime?H().red(t.prime):H().mont(this.p),this.zero=new(H())(0).toRed(this.red),this.one=new(H())(1).toRed(this.red),this.two=new(H())(2).toRed(this.red),this.n=t.n&&new(H())(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var kr=Sr;function Er(e,t){this.curve=e,this.type=t,this.precomputed=null}Sr.prototype.point=function(){throw new Error("Not implemented")},Sr.prototype.validate=function(){throw new Error("Not implemented")},Sr.prototype._fixedNafMul=function(e,t){Ar(e.precomputed);var r=e._getDoubles(),n=vr(t,1,this._bitLength),i=(1<=o;u--)a=(a<<1)+n[u];s.push(a)}for(var c=this.jpoint(null,null,null),l=this.jpoint(null,null,null),f=i;f>0;f--){for(o=0;o=0;s--){for(var u=0;s>=0&&0===o[s];s--)u++;if(s>=0&&u++,a=a.dblp(u),s<0)break;var c=o[s];Ar(0!==c),a="affine"===e.type?c>0?a.mixedAdd(i[c-1>>1]):a.mixedAdd(i[-c-1>>1].neg()):c>0?a.add(i[c-1>>1]):a.add(i[-c-1>>1].neg())}return"affine"===e.type?a.toP():a},Sr.prototype._wnafMulAdd=function(e,t,r,n,i){var o,a,s,u=this._wnafT1,c=this._wnafT2,l=this._wnafT3,f=0;for(o=0;o=1;o-=2){var d=o-1,p=o;if(1===u[d]&&1===u[p]){var m=[t[d],null,null,t[p]];0===t[d].y.cmp(t[p].y)?(m[1]=t[d].add(t[p]),m[2]=t[d].toJ().mixedAdd(t[p].neg())):0===t[d].y.cmp(t[p].y.redNeg())?(m[1]=t[d].toJ().mixedAdd(t[p]),m[2]=t[d].add(t[p].neg())):(m[1]=t[d].toJ().mixedAdd(t[p]),m[2]=t[d].toJ().mixedAdd(t[p].neg()));var y=[-3,-1,-5,-7,0,7,5,1,3],g=wr(r[d],r[p]);for(f=Math.max(g[0].length,f),l[d]=new Array(f),l[p]=new Array(f),a=0;a=0;o--){for(var S=0;o>=0;){var k=!0;for(a=0;a=0&&S++,w=w.dblp(S),o<0)break;for(a=0;a0?s=c[a][E-1>>1]:E<0&&(s=c[a][-E-1>>1].neg()),w="affine"===s.type?w.mixedAdd(s):w.add(s))}}for(o=0;o=Math.ceil((e.bitLength()+1)/t.step)},Er.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i=0&&(o=t,a=r),n.negative&&(n=n.neg(),i=i.neg()),o.negative&&(o=o.neg(),a=a.neg()),[{a:n,b:i},{a:o,b:a}]},Tr.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},Tr.prototype.pointFromX=function(e,t){(e=new(H())(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},Tr.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},Tr.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},Pr.prototype.isInfinity=function(){return this.inf},Pr.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},Pr.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},Pr.prototype.getX=function(){return this.x.fromRed()},Pr.prototype.getY=function(){return this.y.fromRed()},Pr.prototype.mul=function(e){return e=new(H())(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},Pr.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},Pr.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},Pr.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},Pr.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},Pr.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},_r(Ir,kr.BasePoint),Tr.prototype.jpoint=function(e,t,r){return new Ir(this,e,t,r)},Ir.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},Ir.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},Ir.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},Ir.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},Ir.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},Ir.prototype.inspect=function(){return this.isInfinity()?"":""},Ir.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var Or=pr((function(e,t){var r=t;r.base=kr,r.short=xr,r.mont=null,r.edwards=null})),Rr=pr((function(e,t){var r,n=t,i=br.assert;function o(e){"short"===e.type?this.curve=new Or.short(e):"edwards"===e.type?this.curve=new Or.edwards(e):this.curve=new Or.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,i(this.g.validate(),"Invalid curve"),i(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function a(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new o(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=o,a("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:dr().sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),a("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:dr().sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),a("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:dr().sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),a("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:dr().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"]}),a("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:dr().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"]}),a("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:dr().sha256,gRed:!1,g:["9"]}),a("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:dr().sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(e){r=void 0}a("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:dr().sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function Cr(e){if(!(this instanceof Cr))return new Cr(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=gr.toArray(e.entropy,e.entropyEnc||"hex"),r=gr.toArray(e.nonce,e.nonceEnc||"hex"),n=gr.toArray(e.pers,e.persEnc||"hex");mr(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var Br=Cr;Cr.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},Cr.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=gr.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length"};var Fr=br.assert;function Dr(e,t){if(e instanceof Dr)return e;this._importDER(e,t)||(Fr(e.r&&e.s,"Signature without r or s"),this.r=new(H())(e.r,16),this.s=new(H())(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var jr=Dr;function Hr(){this.place=0}function Jr(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function zr(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}Dr.prototype._importDER=function(e,t){e=br.toArray(e,t);var r=new Hr;if(48!==e[r.place++])return!1;var n=Jr(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var i=Jr(e,r);if(!1===i)return!1;var o=e.slice(r.place,i+r.place);if(r.place+=i,2!==e[r.place++])return!1;var a=Jr(e,r);if(!1===a)return!1;if(e.length!==a+r.place)return!1;var s=e.slice(r.place,a+r.place);if(0===o[0]){if(!(128&o[1]))return!1;o=o.slice(1)}if(0===s[0]){if(!(128&s[1]))return!1;s=s.slice(1)}return this.r=new(H())(o),this.s=new(H())(s),this.recoveryParam=null,!0},Dr.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=zr(t),r=zr(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];Gr(n,t.length),(n=n.concat(t)).push(2),Gr(n,r.length);var i=n.concat(r),o=[48];return Gr(o,i.length),o=o.concat(i),br.encode(o,e)};var qr=function(){throw new Error("unsupported")},Kr=br.assert;function Vr(e){if(!(this instanceof Vr))return new Vr(e);"string"==typeof e&&(Kr(Object.prototype.hasOwnProperty.call(Rr,e),"Unknown curve "+e),e=Rr[e]),e instanceof Rr.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var Xr=Vr;Vr.prototype.keyPair=function(e){return new Ur(this,e)},Vr.prototype.keyFromPrivate=function(e,t){return Ur.fromPrivate(this,e,t)},Vr.prototype.keyFromPublic=function(e,t){return Ur.fromPublic(this,e,t)},Vr.prototype.genKeyPair=function(e){e||(e={});for(var t=new Br({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||qr(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new(H())(2));;){var i=new(H())(t.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},Vr.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},Vr.prototype.sign=function(e,t,r,n){"object"==typeof r&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new(H())(e,16));for(var i=this.n.byteLength(),o=t.getPrivate().toArray("be",i),a=e.toArray("be",i),s=new Br({hash:this.hash,entropy:o,nonce:a,pers:n.pers,persEnc:n.persEnc||"utf8"}),u=this.n.sub(new(H())(1)),c=0;;c++){var l=n.k?n.k(c):new(H())(s.generate(this.n.byteLength()));if(!((l=this._truncateToN(l,!0)).cmpn(1)<=0||l.cmp(u)>=0)){var f=this.g.mul(l);if(!f.isInfinity()){var h=f.getX(),d=h.umod(this.n);if(0!==d.cmpn(0)){var p=l.invm(this.n).mul(d.mul(t.getPrivate()).iadd(e));if(0!==(p=p.umod(this.n)).cmpn(0)){var m=(f.getY().isOdd()?1:0)|(0!==h.cmp(d)?2:0);return n.canonical&&p.cmp(this.nh)>0&&(p=this.n.sub(p),m^=1),new jr({r:d,s:p,recoveryParam:m})}}}}}},Vr.prototype.verify=function(e,t,r,n){e=this._truncateToN(new(H())(e,16)),r=this.keyFromPublic(r,n);var i=(t=new jr(t,"hex")).r,o=t.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var a,s=o.invm(this.n),u=s.mul(e).umod(this.n),c=s.mul(i).umod(this.n);return this.curve._maxwellTrick?!(a=this.g.jmulAdd(u,r.getPublic(),c)).isInfinity()&&a.eqXToP(i):!(a=this.g.mulAdd(u,r.getPublic(),c)).isInfinity()&&0===a.getX().umod(this.n).cmp(i)},Vr.prototype.recoverPubKey=function(e,t,r,n){Kr((3&r)===r,"The recovery param is more than two bits"),t=new jr(t,n);var i=this.n,o=new(H())(e),a=t.r,s=t.s,u=1&r,c=r>>1;if(a.cmp(this.curve.p.umod(this.curve.n))>=0&&c)throw new Error("Unable to find sencond key candinate");a=c?this.curve.pointFromX(a.add(this.curve.n),u):this.curve.pointFromX(a,u);var l=t.r.invm(i),f=i.sub(o).mul(l).umod(i),h=s.mul(l).umod(i);return this.g.mulAdd(f,a,h)},Vr.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new jr(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")};var Qr=pr((function(e,t){var r=t;r.version="6.5.4",r.utils=br,r.rand=function(){throw new Error("unsupported")},r.curve=Or,r.curves=Rr,r.ec=Xr,r.eddsa=null})).ec;const Wr=new b("signing-key/5.7.0");let Zr=null;function Yr(){return Zr||(Zr=new Qr("secp256k1")),Zr}class $r{constructor(e){te(this,"curve","secp256k1"),te(this,"privateKey",O(e)),32!==R(this.privateKey)&&Wr.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");const t=Yr().keyFromPrivate(_(this.privateKey));te(this,"publicKey","0x"+t.getPublic(!1,"hex")),te(this,"compressedPublicKey","0x"+t.getPublic(!0,"hex")),te(this,"_isSigningKey",!0)}_addPoint(e){const t=Yr().keyFromPublic(_(this.publicKey)),r=Yr().keyFromPublic(_(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}signDigest(e){const t=Yr().keyFromPrivate(_(this.privateKey)),r=_(e);32!==r.length&&Wr.throwArgumentError("bad digest length","digest",e);const n=t.sign(r,{canonical:!0});return F({recoveryParam:n.recoveryParam,r:U("0x"+n.r.toString(16),32),s:U("0x"+n.s.toString(16),32)})}computeSharedSecret(e){const t=Yr().keyFromPrivate(_(this.privateKey)),r=Yr().keyFromPublic(_(tn(e)));return U("0x"+t.derive(r.getPublic()).toString(16),32)}static isSigningKey(e){return!(!e||!e._isSigningKey)}}function en(e,t){const r=F(t),n={r:_(r.r),s:_(r.s)};return"0x"+Yr().recoverPubKey(_(e),n,r.recoveryParam).encode("hex",!1)}function tn(e,t){const r=_(e);if(32===r.length){const e=new $r(r);return t?"0x"+Yr().keyFromPrivate(r).getPublic(!0,"hex"):e.publicKey}return 33===r.length?t?O(r):"0x"+Yr().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+Yr().keyFromPublic(r).getPublic(!0,"hex"):O(r):Wr.throwArgumentError("invalid public or private key","key","[REDACTED]")}const rn=new b("transactions/5.7.0");var nn;function on(e){return"0x"===e?null:Be(e)}function an(e){return"0x"===e?lt:X.from(e)}!function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(nn||(nn={}));const sn=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],un={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function cn(e){return Be(C(ve(C(tn(e),1)),12))}function ln(e,t){return cn(en(_(e),t))}function fn(e,t){const r=T(X.from(e).toHexString());return r.length>32&&rn.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function hn(e,t){return{address:Be(e),storageKeys:(t||[]).map(((t,r)=>(32!==R(t)&&rn.throwArgumentError("invalid access list storageKey",`accessList[${e}:${r}]`,t),t.toLowerCase())))}}function dn(e){if(Array.isArray(e))return e.map(((e,t)=>Array.isArray(e)?(e.length>2&&rn.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${t}]`,e),hn(e[0],e[1])):hn(e.address,e.storageKeys)));const t=Object.keys(e).map((t=>{const r=e[t].reduce(((e,t)=>(e[t]=!0,e)),{});return hn(t,Object.keys(r).sort())}));return t.sort(((e,t)=>e.address.localeCompare(t.address))),t}function pn(e){return dn(e).map((e=>[e.address,e.storageKeys]))}function mn(e,t){if(null!=e.gasPrice){const t=X.from(e.gasPrice),r=X.from(e.maxFeePerGas||0);t.eq(r)||rn.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:t,maxFeePerGas:r})}const r=[fn(e.chainId||0,"chainId"),fn(e.nonce||0,"nonce"),fn(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),fn(e.maxFeePerGas||0,"maxFeePerGas"),fn(e.gasLimit||0,"gasLimit"),null!=e.to?Be(e.to):"0x",fn(e.value||0,"value"),e.data||"0x",pn(e.accessList||[])];if(t){const e=F(t);r.push(fn(e.recoveryParam,"recoveryParam")),r.push(T(e.r)),r.push(T(e.s))}return B(["0x02",Ee(r)])}function yn(e,t){const r=[fn(e.chainId||0,"chainId"),fn(e.nonce||0,"nonce"),fn(e.gasPrice||0,"gasPrice"),fn(e.gasLimit||0,"gasLimit"),null!=e.to?Be(e.to):"0x",fn(e.value||0,"value"),e.data||"0x",pn(e.accessList||[])];if(t){const e=F(t);r.push(fn(e.recoveryParam,"recoveryParam")),r.push(T(e.r)),r.push(T(e.s))}return B(["0x01",Ee(r)])}function gn(e,t){if(null==e.type||0===e.type)return null!=e.accessList&&rn.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",e),function(e,t){ie(e,un);const r=[];sn.forEach((function(t){let n=e[t.name]||[];const i={};t.numeric&&(i.hexPad="left"),n=_(O(n,i)),t.length&&n.length!==t.length&&n.length>0&&rn.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),t.maxLength&&(n=T(n),n.length>t.maxLength&&rn.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n)),r.push(O(n))}));let n=0;if(null!=e.chainId?(n=e.chainId,"number"!=typeof n&&rn.throwArgumentError("invalid transaction.chainId","transaction",e)):t&&!S(t)&&t.v>28&&(n=Math.floor((t.v-35)/2)),0!==n&&(r.push(O(n)),r.push("0x"),r.push("0x")),!t)return Ee(r);const i=F(t);let o=27+i.recoveryParam;return 0!==n?(r.pop(),r.pop(),r.pop(),o+=2*n+8,i.v>28&&i.v!==o&&rn.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t)):i.v!==o&&rn.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t),r.push(O(o)),r.push(T(_(i.r))),r.push(T(_(i.s))),Ee(r)}(e,t);switch(e.type){case 1:return yn(e,t);case 2:return mn(e,t)}return rn.throwError(`unsupported transaction type: ${e.type}`,b.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:e.type})}function bn(e,t,r){try{const r=an(t[0]).toNumber();if(0!==r&&1!==r)throw new Error("bad recid");e.v=r}catch(e){rn.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=U(t[1],32),e.s=U(t[2],32);try{const t=ve(r(e));e.from=ln(t,{r:e.r,s:e.s,recoveryParam:e.v})}catch(e){}}function vn(e){const t=_(e);if(t[0]>127)return function(e){const t=Te(e);9!==t.length&&6!==t.length&&rn.throwArgumentError("invalid raw transaction","rawTransaction",e);const r={nonce:an(t[0]).toNumber(),gasPrice:an(t[1]),gasLimit:an(t[2]),to:on(t[3]),value:an(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=X.from(t[6]).toNumber()}catch(e){return r}if(r.r=U(t[7],32),r.s=U(t[8],32),X.from(r.r).isZero()&&X.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);let n=r.v-27;const i=t.slice(0,6);0!==r.chainId&&(i.push(O(r.chainId)),i.push("0x"),i.push("0x"),n-=2*r.chainId+8);const o=ve(Ee(i));try{r.from=ln(o,{r:O(r.r),s:O(r.s),recoveryParam:n})}catch(e){}r.hash=ve(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){const t=Te(e.slice(1));8!==t.length&&11!==t.length&&rn.throwArgumentError("invalid component count for transaction type: 1","payload",O(e));const r={type:1,chainId:an(t[0]).toNumber(),nonce:an(t[1]).toNumber(),gasPrice:an(t[2]),gasLimit:an(t[3]),to:on(t[4]),value:an(t[5]),data:t[6],accessList:dn(t[7])};return 8===t.length||(r.hash=ve(e),bn(r,t.slice(8),yn)),r}(t);case 2:return function(e){const t=Te(e.slice(1));9!==t.length&&12!==t.length&&rn.throwArgumentError("invalid component count for transaction type: 2","payload",O(e));const r=an(t[2]),n=an(t[3]),i={type:2,chainId:an(t[0]).toNumber(),nonce:an(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:an(t[4]),to:on(t[5]),value:an(t[6]),data:t[7],accessList:dn(t[8])};return 9===t.length||(i.hash=ve(e),bn(i,t.slice(9),mn)),i}(t)}return rn.throwError(`unsupported transaction type: ${t[0]}`,b.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})}var wn=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const An=new b("contracts/5.7.0"),Sn={chainId:!0,data:!0,from:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0,customData:!0,ccipReadEnabled:!0};function kn(e,t){return wn(this,void 0,void 0,(function*(){const r=yield t;"string"!=typeof r&&An.throwArgumentError("invalid address or ENS name","name",r);try{return Be(r)}catch(e){}e||An.throwError("a provider or signer is needed to resolve ENS names",b.errors.UNSUPPORTED_OPERATION,{operation:"resolveName"});const n=yield e.resolveName(r);return null==n&&An.throwArgumentError("resolver or addr is not configured for ENS name","name",r),n}))}function En(e,t,r){return wn(this,void 0,void 0,(function*(){return Array.isArray(r)?yield Promise.all(r.map(((r,n)=>En(e,Array.isArray(t)?t[n]:t[r.name],r)))):"address"===r.type?yield kn(e,t):"tuple"===r.type?yield En(e,t,r.components):"array"===r.baseType?Array.isArray(t)?yield Promise.all(t.map((t=>En(e,t,r.arrayChildren)))):Promise.reject(An.makeError("invalid value for array",b.errors.INVALID_ARGUMENT,{argument:"value",value:t})):t}))}function _n(e,t,r){return wn(this,void 0,void 0,(function*(){let n={};r.length===t.inputs.length+1&&"object"==typeof r[r.length-1]&&(n=oe(r.pop())),An.checkArgumentCount(r.length,t.inputs.length,"passed to contract"),e.signer?n.from?n.from=ne({override:kn(e.signer,n.from),signer:e.signer.getAddress()}).then((e=>wn(this,void 0,void 0,(function*(){return Be(e.signer)!==e.override&&An.throwError("Contract with a Signer cannot override from",b.errors.UNSUPPORTED_OPERATION,{operation:"overrides.from"}),e.override})))):n.from=e.signer.getAddress():n.from&&(n.from=kn(e.provider,n.from));const i=yield ne({args:En(e.signer||e.provider,r,t.inputs),address:e.resolvedAddress,overrides:ne(n)||{}}),o=e.interface.encodeFunctionData(t,i.args),a={data:o,to:i.address},s=i.overrides;if(null!=s.nonce&&(a.nonce=X.from(s.nonce).toNumber()),null!=s.gasLimit&&(a.gasLimit=X.from(s.gasLimit)),null!=s.gasPrice&&(a.gasPrice=X.from(s.gasPrice)),null!=s.maxFeePerGas&&(a.maxFeePerGas=X.from(s.maxFeePerGas)),null!=s.maxPriorityFeePerGas&&(a.maxPriorityFeePerGas=X.from(s.maxPriorityFeePerGas)),null!=s.from&&(a.from=s.from),null!=s.type&&(a.type=s.type),null!=s.accessList&&(a.accessList=dn(s.accessList)),null==a.gasLimit&&null!=t.gas){let e=21e3;const r=_(o);for(let t=0;tnull!=n[e]));return u.length&&An.throwError(`cannot override ${u.map((e=>JSON.stringify(e))).join(",")}`,b.errors.UNSUPPORTED_OPERATION,{operation:"overrides",overrides:u}),a}))}function Mn(e,t){const r=t.wait.bind(t);t.wait=t=>r(t).then((t=>(t.events=t.logs.map((r=>{let n=ce(r),i=null;try{i=e.interface.parseLog(r)}catch(e){}return i&&(n.args=i.args,n.decode=(t,r)=>e.interface.decodeEventLog(i.eventFragment,t,r),n.event=i.name,n.eventSignature=i.signature),n.removeListener=()=>e.provider,n.getBlock=()=>e.provider.getBlock(t.blockHash),n.getTransaction=()=>e.provider.getTransaction(t.transactionHash),n.getTransactionReceipt=()=>Promise.resolve(t),n})),t)))}function Tn(e,t,r){const n=e.signer||e.provider;return function(...i){return wn(this,void 0,void 0,(function*(){let o;if(i.length===t.inputs.length+1&&"object"==typeof i[i.length-1]){const e=oe(i.pop());null!=e.blockTag&&(o=yield e.blockTag),delete e.blockTag,i.push(e)}null!=e.deployTransaction&&(yield e._deployed(o));const a=yield _n(e,t,i),s=yield n.call(a,o);try{let n=e.interface.decodeFunctionResult(t,s);return r&&1===t.outputs.length&&(n=n[0]),n}catch(t){throw t.code===b.errors.CALL_EXCEPTION&&(t.address=e.address,t.args=i,t.transaction=a),t}}))}}function xn(e,t,r){return t.constant?Tn(e,t,r):function(e,t){return function(...r){return wn(this,void 0,void 0,(function*(){e.signer||An.throwError("sending a transaction requires a signer",b.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction"}),null!=e.deployTransaction&&(yield e._deployed());const n=yield _n(e,t,r),i=yield e.signer.sendTransaction(n);return Mn(e,i),i}))}}(e,t)}function Pn(e){return!e.address||null!=e.topics&&0!==e.topics.length?(e.address||"*")+"@"+(e.topics?e.topics.map((e=>Array.isArray(e)?e.join("|"):e)).join(":"):""):"*"}class In{constructor(e,t){te(this,"tag",e),te(this,"filter",t),this._listeners=[]}addListener(e,t){this._listeners.push({listener:e,once:t})}removeListener(e){let t=!1;this._listeners=this._listeners.filter((r=>!(!t&&r.listener===e)||(t=!0,!1)))}removeAllListeners(){this._listeners=[]}listeners(){return this._listeners.map((e=>e.listener))}listenerCount(){return this._listeners.length}run(e){const t=this.listenerCount();return this._listeners=this._listeners.filter((t=>{const r=e.slice();return setTimeout((()=>{t.listener.apply(this,r)}),0),!t.once})),t}prepareEvent(e){}getEmit(e){return[e]}}class On extends In{constructor(){super("error",null)}}class Rn extends In{constructor(e,t,r,n){const i={address:e};let o=t.getEventTopic(r);n?(o!==n[0]&&An.throwArgumentError("topic mismatch","topics",n),i.topics=n.slice()):i.topics=[o],super(Pn(i),i),te(this,"address",e),te(this,"interface",t),te(this,"fragment",r)}prepareEvent(e){super.prepareEvent(e),e.event=this.fragment.name,e.eventSignature=this.fragment.format(),e.decode=(e,t)=>this.interface.decodeEventLog(this.fragment,e,t);try{e.args=this.interface.decodeEventLog(this.fragment,e.data,e.topics)}catch(t){e.args=null,e.decodeError=t}}getEmit(e){const t=de(e.args);if(t.length)throw t[0].error;const r=(e.args||[]).slice();return r.push(e),r}}class Cn extends In{constructor(e,t){super("*",{address:e}),te(this,"address",e),te(this,"interface",t)}prepareEvent(e){super.prepareEvent(e);try{const t=this.interface.parseLog(e);e.event=t.name,e.eventSignature=t.signature,e.decode=(e,r)=>this.interface.decodeEventLog(t.eventFragment,e,r),e.args=t.args}catch(e){}}}class Bn{constructor(e,t,r){te(this,"interface",re(new.target,"getInterface")(t)),null==r?(te(this,"provider",null),te(this,"signer",null)):lr.isSigner(r)?(te(this,"provider",r.provider||null),te(this,"signer",r)):or.isProvider(r)?(te(this,"provider",r),te(this,"signer",null)):An.throwArgumentError("invalid signer or provider","signerOrProvider",r),te(this,"callStatic",{}),te(this,"estimateGas",{}),te(this,"functions",{}),te(this,"populateTransaction",{}),te(this,"filters",{});{const e={};Object.keys(this.interface.events).forEach((t=>{const r=this.interface.events[t];te(this.filters,t,((...e)=>({address:this.address,topics:this.interface.encodeFilterTopics(r,e)}))),e[r.name]||(e[r.name]=[]),e[r.name].push(t)})),Object.keys(e).forEach((t=>{const r=e[t];1===r.length?te(this.filters,t,this.filters[r[0]]):An.warn(`Duplicate definition of ${t} (${r.join(", ")})`)}))}if(te(this,"_runningEvents",{}),te(this,"_wrappedEmits",{}),null==e&&An.throwArgumentError("invalid contract address or ENS name","addressOrName",e),te(this,"address",e),this.provider)te(this,"resolvedAddress",kn(this.provider,e));else try{te(this,"resolvedAddress",Promise.resolve(Be(e)))}catch(e){An.throwError("provider is required to use ENS name as contract address",b.errors.UNSUPPORTED_OPERATION,{operation:"new Contract"})}this.resolvedAddress.catch((e=>{}));const n={},i={};Object.keys(this.interface.functions).forEach((e=>{const t=this.interface.functions[e];if(i[e])An.warn(`Duplicate ABI entry for ${JSON.stringify(e)}`);else{i[e]=!0;{const r=t.name;n[`%${r}`]||(n[`%${r}`]=[]),n[`%${r}`].push(e)}null==this[e]&&te(this,e,xn(this,t,!0)),null==this.functions[e]&&te(this.functions,e,xn(this,t,!1)),null==this.callStatic[e]&&te(this.callStatic,e,Tn(this,t,!0)),null==this.populateTransaction[e]&&te(this.populateTransaction,e,function(e,t){return function(...r){return _n(e,t,r)}}(this,t)),null==this.estimateGas[e]&&te(this.estimateGas,e,function(e,t){const r=e.signer||e.provider;return function(...n){return wn(this,void 0,void 0,(function*(){r||An.throwError("estimate require a provider or signer",b.errors.UNSUPPORTED_OPERATION,{operation:"estimateGas"});const i=yield _n(e,t,n);return yield r.estimateGas(i)}))}}(this,t))}})),Object.keys(n).forEach((e=>{const t=n[e];if(t.length>1)return;e=e.substring(1);const r=t[0];try{null==this[e]&&te(this,e,this[r])}catch(e){}null==this.functions[e]&&te(this.functions,e,this.functions[r]),null==this.callStatic[e]&&te(this.callStatic,e,this.callStatic[r]),null==this.populateTransaction[e]&&te(this.populateTransaction,e,this.populateTransaction[r]),null==this.estimateGas[e]&&te(this.estimateGas,e,this.estimateGas[r])}))}static getContractAddress(e){return Ue(e)}static getInterface(e){return tr.isInterface(e)?e:new tr(e)}deployed(){return this._deployed()}_deployed(e){return this._deployedPromise||(this.deployTransaction?this._deployedPromise=this.deployTransaction.wait().then((()=>this)):this._deployedPromise=this.provider.getCode(this.address,e).then((e=>("0x"===e&&An.throwError("contract not deployed",b.errors.UNSUPPORTED_OPERATION,{contractAddress:this.address,operation:"getDeployed"}),this)))),this._deployedPromise}fallback(e){this.signer||An.throwError("sending a transactions require a signer",b.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction(fallback)"});const t=oe(e||{});return["from","to"].forEach((function(e){null!=t[e]&&An.throwError("cannot override "+e,b.errors.UNSUPPORTED_OPERATION,{operation:e})})),t.to=this.resolvedAddress,this.deployed().then((()=>this.signer.sendTransaction(t)))}connect(e){"string"==typeof e&&(e=new fr(e,this.provider));const t=new this.constructor(this.address,this.interface,e);return this.deployTransaction&&te(t,"deployTransaction",this.deployTransaction),t}attach(e){return new this.constructor(e,this.interface,this.signer||this.provider)}static isIndexed(e){return Yt.isIndexed(e)}_normalizeRunningEvent(e){return this._runningEvents[e.tag]?this._runningEvents[e.tag]:e}_getRunningEvent(e){if("string"==typeof e){if("error"===e)return this._normalizeRunningEvent(new On);if("event"===e)return this._normalizeRunningEvent(new In("event",null));if("*"===e)return this._normalizeRunningEvent(new Cn(this.address,this.interface));const t=this.interface.getEvent(e);return this._normalizeRunningEvent(new Rn(this.address,this.interface,t))}if(e.topics&&e.topics.length>0){try{const t=e.topics[0];if("string"!=typeof t)throw new Error("invalid topic");const r=this.interface.getEvent(t);return this._normalizeRunningEvent(new Rn(this.address,this.interface,r,e.topics))}catch(e){}const t={address:this.address,topics:e.topics};return this._normalizeRunningEvent(new In(Pn(t),t))}return this._normalizeRunningEvent(new Cn(this.address,this.interface))}_checkRunningEvents(e){if(0===e.listenerCount()){delete this._runningEvents[e.tag];const t=this._wrappedEmits[e.tag];t&&e.filter&&(this.provider.off(e.filter,t),delete this._wrappedEmits[e.tag])}}_wrapEvent(e,t,r){const n=ce(t);return n.removeListener=()=>{r&&(e.removeListener(r),this._checkRunningEvents(e))},n.getBlock=()=>this.provider.getBlock(t.blockHash),n.getTransaction=()=>this.provider.getTransaction(t.transactionHash),n.getTransactionReceipt=()=>this.provider.getTransactionReceipt(t.transactionHash),e.prepareEvent(n),n}_addEventListener(e,t,r){if(this.provider||An.throwError("events require a provider or a signer with a provider",b.errors.UNSUPPORTED_OPERATION,{operation:"once"}),e.addListener(t,r),this._runningEvents[e.tag]=e,!this._wrappedEmits[e.tag]){const r=r=>{let n=this._wrapEvent(e,r,t);if(null==n.decodeError)try{const t=e.getEmit(n);this.emit(e.filter,...t)}catch(e){n.decodeError=e.error}null!=e.filter&&this.emit("event",n),null!=n.decodeError&&this.emit("error",n.decodeError,n)};this._wrappedEmits[e.tag]=r,null!=e.filter&&this.provider.on(e.filter,r)}}queryFilter(e,t,r){const n=this._getRunningEvent(e),i=oe(n.filter);return"string"==typeof t&&P(t,32)?(null!=r&&An.throwArgumentError("cannot specify toBlock with blockhash","toBlock",r),i.blockHash=t):(i.fromBlock=null!=t?t:0,i.toBlock=null!=r?r:"latest"),this.provider.getLogs(i).then((e=>e.map((e=>this._wrapEvent(n,e,null)))))}on(e,t){return this._addEventListener(this._getRunningEvent(e),t,!1),this}once(e,t){return this._addEventListener(this._getRunningEvent(e),t,!0),this}emit(e,...t){if(!this.provider)return!1;const r=this._getRunningEvent(e),n=r.run(t)>0;return this._checkRunningEvents(r),n}listenerCount(e){return this.provider?null==e?Object.keys(this._runningEvents).reduce(((e,t)=>e+this._runningEvents[t].listenerCount()),0):this._getRunningEvent(e).listenerCount():0}listeners(e){if(!this.provider)return[];if(null==e){const e=[];for(let t in this._runningEvents)this._runningEvents[t].listeners().forEach((t=>{e.push(t)}));return e}return this._getRunningEvent(e).listeners()}removeAllListeners(e){if(!this.provider)return this;if(null==e){for(const e in this._runningEvents){const t=this._runningEvents[e];t.removeAllListeners(),this._checkRunningEvents(t)}return this}const t=this._getRunningEvent(e);return t.removeAllListeners(),this._checkRunningEvents(t),this}off(e,t){if(!this.provider)return this;const r=this._getRunningEvent(e);return r.removeListener(t),this._checkRunningEvents(r),this}removeListener(e,t){return this.off(e,t)}}class Nn extends Bn{}class Ln{constructor(e,t,r){let n=null;n="string"==typeof t?t:E(t)?O(t):t&&"string"==typeof t.object?t.object:"!","0x"!==n.substring(0,2)&&(n="0x"+n),(!P(n)||n.length%2)&&An.throwArgumentError("invalid bytecode","bytecode",t),r&&!lr.isSigner(r)&&An.throwArgumentError("invalid signer","signer",r),te(this,"bytecode",n),te(this,"interface",re(new.target,"getInterface")(e)),te(this,"signer",r||null)}getDeployTransaction(...e){let t={};if(e.length===this.interface.deploy.inputs.length+1&&"object"==typeof e[e.length-1]){t=oe(e.pop());for(const e in t)if(!Sn[e])throw new Error("unknown transaction override "+e)}if(["data","from","to"].forEach((e=>{null!=t[e]&&An.throwError("cannot override "+e,b.errors.UNSUPPORTED_OPERATION,{operation:e})})),t.value){X.from(t.value).isZero()||this.interface.deploy.payable||An.throwError("non-payable constructor cannot override value",b.errors.UNSUPPORTED_OPERATION,{operation:"overrides.value",value:t.value})}return An.checkArgumentCount(e.length,this.interface.deploy.inputs.length," in Contract constructor"),t.data=O(M([this.bytecode,this.interface.encodeDeploy(e)])),t}deploy(...e){return wn(this,void 0,void 0,(function*(){let t={};e.length===this.interface.deploy.inputs.length+1&&(t=e.pop()),An.checkArgumentCount(e.length,this.interface.deploy.inputs.length," in Contract constructor");const r=yield En(this.signer,e,this.interface.deploy.inputs);r.push(t);const n=this.getDeployTransaction(...r),i=yield this.signer.sendTransaction(n),o=re(this.constructor,"getContractAddress")(i),a=re(this.constructor,"getContract")(o,this.interface,this.signer);return Mn(a,i),te(a,"deployTransaction",i),a}))}attach(e){return this.constructor.getContract(e,this.interface,this.signer)}connect(e){return new this.constructor(this.interface,this.bytecode,e)}static fromSolidity(e,t){null==e&&An.throwError("missing compiler output",b.errors.MISSING_ARGUMENT,{argument:"compilerOutput"}),"string"==typeof e&&(e=JSON.parse(e));const r=e.abi;let n=null;return e.bytecode?n=e.bytecode:e.evm&&e.evm.bytecode&&(n=e.evm.bytecode),new this(r,n,t)}static getInterface(e){return Nn.getInterface(e)}static getContractAddress(e){return Ue(e)}static getContract(e,t,r){return new Nn(e,t,r)}}const Un=new b(J),Fn={},Dn=X.from(0),jn=X.from(-1);function Hn(e,t,r,n){const i={fault:t,operation:r};return void 0!==n&&(i.value=n),Un.throwError(e,b.errors.NUMERIC_FAULT,i)}let Jn="0";for(;Jn.length<256;)Jn+=Jn;function zn(e){if("number"!=typeof e)try{e=X.from(e).toNumber()}catch(e){}return"number"==typeof e&&e>=0&&e<=256&&!(e%1)?"1"+Jn.substring(0,e):Un.throwArgumentError("invalid decimal size","decimals",e)}function Gn(e,t){null==t&&(t=0);const r=zn(t),n=(e=X.from(e)).lt(Dn);n&&(e=e.mul(jn));let i=e.mod(r).toString();for(;i.length2&&Un.throwArgumentError("too many decimal points","value",e);let o=i[0],a=i[1];for(o||(o="0"),a||(a="0");"0"===a[a.length-1];)a=a.substring(0,a.length-1);for(a.length>r.length-1&&Hn("fractional component exceeds decimals","underflow","parseFixed"),""===a&&(a="0");a.lengthnull==e[t]?n:(typeof e[t]!==r&&Un.throwArgumentError("invalid fixed format ("+t+" not "+r+")","format."+t,e[t]),e[t]);t=i("signed","boolean",t),r=i("width","number",r),n=i("decimals","number",n)}return r%8&&Un.throwArgumentError("invalid fixed format width (not byte aligned)","format.width",r),n>80&&Un.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",n),new Kn(Fn,t,r,n)}}class Vn{constructor(e,t,r,n){e!==Fn&&Un.throwError("cannot use FixedNumber constructor; use FixedNumber.from",b.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=n,this._hex=t,this._value=r,this._isFixedNumber=!0,Object.freeze(this)}_checkFormat(e){this.format.name!==e.format.name&&Un.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}addUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.add(r),this.format.decimals,this.format)}subUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.sub(r),this.format.decimals,this.format)}mulUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.mul(r).div(this.format._multiplier),this.format.decimals,this.format)}divUnsafe(e){this._checkFormat(e);const t=qn(this._value,this.format.decimals),r=qn(e._value,e.format.decimals);return Vn.fromValue(t.mul(this.format._multiplier).div(r),this.format.decimals,this.format)}floor(){const e=this.toString().split(".");1===e.length&&e.push("0");let t=Vn.from(e[0],this.format);const r=!e[1].match(/^(0*)$/);return this.isNegative()&&r&&(t=t.subUnsafe(Xn.toFormat(t.format))),t}ceiling(){const e=this.toString().split(".");1===e.length&&e.push("0");let t=Vn.from(e[0],this.format);const r=!e[1].match(/^(0*)$/);return!this.isNegative()&&r&&(t=t.addUnsafe(Xn.toFormat(t.format))),t}round(e){null==e&&(e=0);const t=this.toString().split(".");if(1===t.length&&t.push("0"),(e<0||e>80||e%1)&&Un.throwArgumentError("invalid decimal count","decimals",e),t[1].length<=e)return this;const r=Vn.from("1"+Jn.substring(0,e),this.format),n=Qn.toFormat(this.format);return this.mulUnsafe(r).addUnsafe(n).floor().divUnsafe(r)}isZero(){return"0.0"===this._value||"0"===this._value}isNegative(){return"-"===this._value[0]}toString(){return this._value}toHexString(e){if(null==e)return this._hex;e%8&&Un.throwArgumentError("invalid byte width","width",e);return U(X.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString(),e/8)}toUnsafeFloat(){return parseFloat(this.toString())}toFormat(e){return Vn.fromString(this._value,e)}static fromValue(e,t,r){return null!=r||null==t||function(e){return null!=e&&(X.isBigNumber(e)||"number"==typeof e&&e%1==0||"string"==typeof e&&!!e.match(/^-?[0-9]+$/)||P(e)||"bigint"==typeof e||E(e))}(t)||(r=t,t=null),null==t&&(t=0),null==r&&(r="fixed"),Vn.fromString(Gn(e,t),Kn.from(r))}static fromString(e,t){null==t&&(t="fixed");const r=Kn.from(t),n=qn(e,r.decimals);!r.signed&&n.lt(Dn)&&Hn("unsigned value cannot be negative","overflow","value",e);let i=null;r.signed?i=n.toTwos(r.width).toHexString():(i=n.toHexString(),i=U(i,r.width/8));const o=Gn(n,r.decimals);return new Vn(Fn,i,o,r)}static fromBytes(e,t){null==t&&(t="fixed");const r=Kn.from(t);if(_(e).length>r.width/8)throw new Error("overflow");let n=X.from(e);r.signed&&(n=n.fromTwos(r.width));const i=n.toTwos((r.signed?0:1)+r.width).toHexString(),o=Gn(n,r.decimals);return new Vn(Fn,i,o,r)}static from(e,t){if("string"==typeof e)return Vn.fromString(e,t);if(E(e))return Vn.fromBytes(e,t);try{return Vn.fromValue(e,0,t)}catch(e){if(e.code!==b.errors.INVALID_ARGUMENT)throw e}return Un.throwArgumentError("invalid FixedNumber value","value",e)}static isFixedNumber(e){return!(!e||!e._isFixedNumber)}}const Xn=Vn.from(1),Qn=Vn.from("0.5");function Wn(e){return"string"==typeof e&&(e=qe(e)),ve(M([qe("Ethereum Signed Message:\n"),qe(String(e.length)),e]))}const Zn="hash/5.7.0";var Yn=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const $n=new b(Zn),ei=new Uint8Array(32);ei.fill(0);const ti=X.from(-1),ri=X.from(0),ni=X.from(1),ii=X.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");const oi=U(ni.toHexString(),32),ai=U(ri.toHexString(),32),si={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},ui=["name","version","chainId","verifyingContract","salt"];function ci(e){return function(t){return"string"!=typeof t&&$n.throwArgumentError(`invalid domain value for ${JSON.stringify(e)}`,`domain.${e}`,t),t}}const li={name:ci("name"),version:ci("version"),chainId:function(e){try{return X.from(e).toString()}catch(e){}return $n.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",e)},verifyingContract:function(e){try{return Be(e).toLowerCase()}catch(e){}return $n.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){try{const t=_(e);if(32!==t.length)throw new Error("bad length");return O(t)}catch(e){}return $n.throwArgumentError('invalid domain value "salt"',"domain.salt",e)}};function fi(e){{const t=e.match(/^(u?)int(\d*)$/);if(t){const r=""===t[1],n=parseInt(t[2]||"256");(n%8!=0||n>256||t[2]&&t[2]!==String(n))&&$n.throwArgumentError("invalid numeric width","type",e);const i=ii.mask(r?n-1:n),o=r?i.add(ni).mul(ti):ri;return function(t){const r=X.from(t);return(r.lt(o)||r.gt(i))&&$n.throwArgumentError(`value out-of-bounds for ${e}`,"value",t),U(r.toTwos(256).toHexString(),32)}}}{const t=e.match(/^bytes(\d+)$/);if(t){const r=parseInt(t[1]);return(0===r||r>32||t[1]!==String(r))&&$n.throwArgumentError("invalid bytes width","type",e),function(t){return _(t).length!==r&&$n.throwArgumentError(`invalid length for ${e}`,"value",t),function(e){const t=_(e),r=t.length%32;return r?B([t,ei.slice(r)]):O(t)}(t)}}}switch(e){case"address":return function(e){return U(Be(e),32)};case"bool":return function(e){return e?oi:ai};case"bytes":return function(e){return ve(e)};case"string":return function(e){return Ze(e)}}return null}function hi(e,t){return`${e}(${t.map((({name:e,type:t})=>t+" "+e)).join(",")})`}class di{constructor(e){te(this,"types",Object.freeze(ce(e))),te(this,"_encoderCache",{}),te(this,"_types",{});const t={},r={},n={};Object.keys(e).forEach((e=>{t[e]={},r[e]=[],n[e]={}}));for(const n in e){const i={};e[n].forEach((o=>{i[o.name]&&$n.throwArgumentError(`duplicate variable name ${JSON.stringify(o.name)} in ${JSON.stringify(n)}`,"types",e),i[o.name]=!0;const a=o.type.match(/^([^\x5b]*)(\x5b|$)/)[1];a===n&&$n.throwArgumentError(`circular type reference to ${JSON.stringify(a)}`,"types",e);fi(a)||(r[a]||$n.throwArgumentError(`unknown type ${JSON.stringify(a)}`,"types",e),r[a].push(n),t[n][a]=!0)}))}const i=Object.keys(r).filter((e=>0===r[e].length));0===i.length?$n.throwArgumentError("missing primary type","types",e):i.length>1&&$n.throwArgumentError(`ambiguous primary types or unused types: ${i.map((e=>JSON.stringify(e))).join(", ")}`,"types",e),te(this,"primaryType",i[0]),function i(o,a){a[o]&&$n.throwArgumentError(`circular type reference to ${JSON.stringify(o)}`,"types",e),a[o]=!0,Object.keys(t[o]).forEach((e=>{r[e]&&(i(e,a),Object.keys(a).forEach((t=>{n[t][e]=!0})))})),delete a[o]}(this.primaryType,{});for(const t in n){const r=Object.keys(n[t]);r.sort(),this._types[t]=hi(t,e[t])+r.map((t=>hi(t,e[t]))).join("")}}getEncoder(e){let t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}_getEncoder(e){{const t=fi(e);if(t)return t}const t=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(t){const e=t[1],r=this.getEncoder(e),n=parseInt(t[3]);return t=>{n>=0&&t.length!==n&&$n.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t);let i=t.map(r);return this._types[e]&&(i=i.map(ve)),ve(B(i))}}const r=this.types[e];if(r){const t=Ze(this._types[e]);return e=>{const n=r.map((({name:t,type:r})=>{const n=this.getEncoder(r)(e[t]);return this._types[r]?ve(n):n}));return n.unshift(t),B(n)}}return $n.throwArgumentError(`unknown type: ${e}`,"type",e)}encodeType(e){const t=this._types[e];return t||$n.throwArgumentError(`unknown type: ${JSON.stringify(e)}`,"name",e),t}encodeData(e,t){return this.getEncoder(e)(t)}hashStruct(e,t){return ve(this.encodeData(e,t))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,t,r){if(fi(e))return r(e,t);const n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){const e=n[1],i=parseInt(n[3]);return i>=0&&t.length!==i&&$n.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((t=>this._visit(e,t,r)))}const i=this.types[e];return i?i.reduce(((e,{name:n,type:i})=>(e[n]=this._visit(i,t[n],r),e)),{}):$n.throwArgumentError(`unknown type: ${e}`,"type",e)}visit(e,t){return this._visit(this.primaryType,e,t)}static from(e){return new di(e)}static getPrimaryType(e){return di.from(e).primaryType}static hashStruct(e,t,r){return di.from(t).hashStruct(e,r)}static hashDomain(e){const t=[];for(const r in e){const n=si[r];n||$n.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(r)}`,"domain",e),t.push({name:r,type:n})}return t.sort(((e,t)=>ui.indexOf(e.name)-ui.indexOf(t.name))),di.hashStruct("EIP712Domain",{EIP712Domain:t},e)}static encode(e,t,r){return B(["0x1901",di.hashDomain(e),di.from(t).hash(r)])}static hash(e,t,r){return ve(di.encode(e,t,r))}static resolveNames(e,t,r,n){return Yn(this,void 0,void 0,(function*(){e=oe(e);const i={};e.verifyingContract&&!P(e.verifyingContract,20)&&(i[e.verifyingContract]="0x");const o=di.from(t);o.visit(r,((e,t)=>("address"!==e||P(t,20)||(i[t]="0x"),t)));for(const e in i)i[e]=yield n(e);return e.verifyingContract&&i[e.verifyingContract]&&(e.verifyingContract=i[e.verifyingContract]),r=o.visit(r,((e,t)=>"address"===e&&i[t]?i[t]:t)),{domain:e,value:r}}))}static getPayload(e,t,r){di.hashDomain(e);const n={},i=[];ui.forEach((t=>{const r=e[t];null!=r&&(n[t]=li[t](r),i.push({name:t,type:si[t]}))}));const o=di.from(t),a=oe(t);return a.EIP712Domain?$n.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",t):a.EIP712Domain=i,o.encode(r),{types:a,domain:n,primaryType:o.primaryType,message:o.visit(r,((e,t)=>{if(e.match(/^bytes(\d*)/))return O(_(t));if(e.match(/^u?int/))return X.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!=typeof t&&$n.throwArgumentError("invalid string","value",t),t}return $n.throwArgumentError("unsupported type","type",e)}))}}}class pi{constructor(e){te(this,"alphabet",e),te(this,"base",e.length),te(this,"_alphabetMap",{}),te(this,"_leader",e.charAt(0));for(let t=0;t0;)r.push(n%this.base),n=n/this.base|0}let n="";for(let e=0;0===t[e]&&e=0;--e)n+=this.alphabet[r[e]];return n}decode(e){if("string"!=typeof e)throw new TypeError("Expected String");let t=[];if(0===e.length)return new Uint8Array(t);t.push(0);for(let r=0;r>=8;for(;i>0;)t.push(255&i),i>>=8}for(let r=0;e[r]===this._leader&&r>24&255,u[t.length+1]=f>>16&255,u[t.length+2]=f>>8&255,u[t.length+3]=255&f;let h=_(Ai(i,e,u));o||(o=h.length,l=new Uint8Array(o),a=Math.ceil(n/o),c=n-(a-1)*o),l.set(h);for(let t=1;t=256)throw new Error("Depth too large!");return Ni(M([null!=this.privateKey?"0x0488ADE4":"0x0488B21E",O(this.depth),this.parentFingerprint,U(O(this.index),4),this.chainCode,null!=this.privateKey?M(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new Di(Ui,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(2147483647&e));const r=new Uint8Array(37);if(e&Ri){if(!this.privateKey)throw new Error("cannot derive child of neutered node");r.set(_(this.privateKey),1),t&&(t+="'")}else r.set(_(this.publicKey));for(let t=24;t>=0;t-=8)r[33+(t>>3)]=e>>24-t&255;const n=_(Ai(yi.sha512,this.chainCode,r)),i=n.slice(0,32),o=n.slice(32);let a=null,s=null;if(this.privateKey)a=Bi(X.from(i).add(this.privateKey).mod(Ii));else{s=new $r(O(i))._addPoint(this.publicKey)}let u=t;const c=this.mnemonic;return c&&(u=Object.freeze({phrase:c.phrase,path:t,locale:c.locale||"en"})),new Di(Ui,a,s,this.fingerprint,Bi(o),e,this.depth+1,u)}derivePath(e){const t=e.split("/");if(0===t.length||"m"===t[0]&&0!==this.depth)throw new Error("invalid path - "+e);"m"===t[0]&&t.shift();let r=this;for(let e=0;e=Ri)throw new Error("invalid path index - "+n);r=r._derive(Ri+e)}else{if(!n.match(/^[0-9]+$/))throw new Error("invalid path component - "+n);{const e=parseInt(n);if(e>=Ri)throw new Error("invalid path index - "+n);r=r._derive(e)}}}return r}static _fromSeed(e,t){const r=_(e);if(r.length<16||r.length>64)throw new Error("invalid seed");const n=_(Ai(yi.sha512,Oi,r));return new Di(Ui,Bi(n.slice(0,32)),null,"0x00000000",Bi(n.slice(32)),0,0,t)}static fromMnemonic(e,t,r){return e=Ji(Hi(e,r=Li(r)),r),Di._fromSeed(ji(e,t),{phrase:e,path:"m",locale:r.locale})}static fromSeed(e){return Di._fromSeed(e,null)}static fromExtendedKey(e){const t=mi.decode(e);82===t.length&&Ni(t.slice(0,78))===e||Pi.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");const r=t[4],n=O(t.slice(5,9)),i=parseInt(O(t.slice(9,13)).substring(2),16),o=O(t.slice(13,45)),a=t.slice(45,78);switch(O(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new Di(Ui,null,O(a),n,o,i,r,null);case"0x0488ade4":case"0x04358394 ":if(0!==a[0])break;return new Di(Ui,O(a.slice(1)),null,n,o,i,r,null)}return Pi.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}}function ji(e,t){t||(t="");const r=qe("mnemonic"+t,je.NFKD);return Si(qe(e,je.NFKD),r,2048,64,"sha512")}function Hi(e,t){t=Li(t),Pi.checkNormalize();const r=t.split(e);if(r.length%3!=0)throw new Error("invalid mnemonic");const n=_(new Uint8Array(Math.ceil(11*r.length/8)));let i=0;for(let e=0;e>3]|=1<<7-i%8),i++}const o=32*r.length/3,a=Ci(r.length/3);if((_(vi(n.slice(0,o/8)))[0]&a)!==(n[n.length-1]&a))throw new Error("invalid checksum");return O(n.slice(0,o/8))}function Ji(e,t){if(t=Li(t),(e=_(e)).length%4!=0||e.length<16||e.length>32)throw new Error("invalid entropy");const r=[0];let n=11;for(let t=0;t8?(r[r.length-1]<<=8,r[r.length-1]|=e[t],n-=8):(r[r.length-1]<<=n,r[r.length-1]|=e[t]>>8-n,r.push(e[t]&(1<<8-n)-1),n+=3);const i=e.length/4,o=_(vi(e))[0]&Ci(i);return r[r.length-1]<<=i,r[r.length-1]|=o>>8-i,t.join(r.map((e=>t.getWord(e))))}function zi(e,t){try{return Hi(e,t),!0}catch(e){}return!1}function Gi(e){return("number"!=typeof e||e<0||e>=Ri||e%1)&&Pi.throwArgumentError("invalid account index","index",e),`m/44'/60'/${e}'/0/0`}const qi=new b("random/5.7.0");const Ki=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r.g)return r.g;throw new Error("unable to locate global object")}();let Vi=Ki.crypto||Ki.msCrypto;function Xi(e){(e<=0||e>1024||e%1||e!=e)&&qi.throwArgumentError("invalid length","length",e);const t=new Uint8Array(e);return Vi.getRandomValues(t),_(t)}Vi&&Vi.getRandomValues||(qi.warn("WARNING: Missing strong random number source"),Vi={getRandomValues:function(e){return qi.throwError("no secure random source avaialble",b.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});var Qi=r(48709),Wi=r.n(Qi),Zi=r(17635),Yi=r.n(Zi);function $i(e){return"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),_(e)}function eo(e,t){for(e=String(e);e.lengtht)),te(this,"address",cn(this.publicKey)),this.address!==Be(e.address)&&ko.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),function(e){const t=e.mnemonic;return t&&t.phrase}(e)){const t=e.mnemonic;te(this,"_mnemonic",(()=>({phrase:t.phrase,path:t.path||Fi,locale:t.locale||"en"})));const r=this.mnemonic;cn(Di.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path).privateKey)!==this.address&&ko.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else te(this,"_mnemonic",(()=>null))}else{if($r.isSigningKey(e))"secp256k1"!==e.curve&&ko.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),te(this,"_signingKey",(()=>e));else{"string"==typeof e&&e.match(/^[0-9a-f]*$/i)&&64===e.length&&(e="0x"+e);const t=new $r(e);te(this,"_signingKey",(()=>t))}te(this,"_mnemonic",(()=>null)),te(this,"address",cn(this.publicKey))}var r;t&&!or.isProvider(t)&&ko.throwArgumentError("invalid provider","provider",t),te(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Eo(this,e)}signTransaction(e){return ne(e).then((t=>{null!=t.from&&(Be(t.from)!==this.address&&ko.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);const r=this._signingKey().signDigest(ve(gn(t)));return gn(t,r)}))}signMessage(e){return So(this,void 0,void 0,(function*(){return D(this._signingKey().signDigest(Wn(e)))}))}_signTypedData(e,t,r){return So(this,void 0,void 0,(function*(){const n=yield di.resolveNames(e,t,r,(e=>(null==this.provider&&ko.throwError("cannot resolve ENS names without a provider",b.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:e}),this.provider.resolveName(e))));return D(this._signingKey().signDigest(di.hash(n.domain,t,n.value)))}))}encrypt(e,t,r){if("function"!=typeof t||r||(r=t,t={}),r&&"function"!=typeof r)throw new Error("invalid callback");return t||(t={}),function(e,t,r,n){try{if(Be(e.address)!==cn(e.privateKey))throw new Error("address/privateKey mismatch");if(so(e)){const t=e.mnemonic;if(Di.fromMnemonic(t.phrase,null,t.locale).derivePath(t.path||Fi).privateKey!=e.privateKey)throw new Error("mnemonic mismatch")}}catch(e){return Promise.reject(e)}"function"!=typeof r||n||(n=r,r={}),r||(r={});const i=_(e.privateKey),o=to(t);let a=null,s=null,u=null;if(so(e)){const t=e.mnemonic;a=_(Hi(t.phrase,t.locale||"en")),s=t.path||Fi,u=t.locale||"en"}let c=r.client;c||(c="ethers.js");let l=null;l=r.salt?_(r.salt):Xi(32);let f=null;if(r.iv){if(f=_(r.iv),16!==f.length)throw new Error("invalid iv")}else f=Xi(16);let h=null;if(r.uuid){if(h=_(r.uuid),16!==h.length)throw new Error("invalid uuid")}else h=Xi(16);let d=1<<17,p=8,m=1;return r.scrypt&&(r.scrypt.N&&(d=r.scrypt.N),r.scrypt.r&&(p=r.scrypt.r),r.scrypt.p&&(m=r.scrypt.p)),Yi().scrypt(o,l,d,p,m,64,n).then((t=>{const r=(t=_(t)).slice(0,16),n=t.slice(16,32),o=t.slice(32,64),y=new(Wi().Counter)(f),g=_(new(Wi().ModeOfOperation.ctr)(r,y).encrypt(i)),b=ve(M([n,g])),v={address:e.address.substring(2).toLowerCase(),id:no(h),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:O(f).substring(2)},ciphertext:O(g).substring(2),kdf:"scrypt",kdfparams:{salt:O(l).substring(2),n:d,dklen:32,p:m,r:p},mac:b.substring(2)}};if(a){const e=Xi(16),t=new(Wi().Counter)(e),r=_(new(Wi().ModeOfOperation.ctr)(o,t).encrypt(a)),n=new Date,i=n.getUTCFullYear()+"-"+eo(n.getUTCMonth()+1,2)+"-"+eo(n.getUTCDate(),2)+"T"+eo(n.getUTCHours(),2)+"-"+eo(n.getUTCMinutes(),2)+"-"+eo(n.getUTCSeconds(),2)+".0Z";v["x-ethers"]={client:c,gethFilename:"UTC--"+i+"--"+v.address,mnemonicCounter:O(e).substring(2),mnemonicCiphertext:O(r).substring(2),path:s,locale:u,version:"0.1"}}return JSON.stringify(v)}))}(this,e,t,r)}static createRandom(e){let t=Xi(16);e||(e={}),e.extraEntropy&&(t=_(C(ve(M([t,e.extraEntropy])),0,16)));const r=Ji(t,e.locale);return Eo.fromMnemonic(r,e.path,e.locale)}static fromEncryptedJson(e,t,r){return wo(e,t,r).then((e=>new Eo(e)))}static fromEncryptedJsonSync(e,t){return new Eo(Ao(e,t))}static fromMnemonic(e,t,r){return t||(t=Fi),new Eo(Di.fromMnemonic(e,null,r).derivePath(t))}}function _o(e,t){return ln(Wn(e),t)}function Mo(e,t,r,n){return ln(di.hash(e,t,r),n)}const To="0x0000000000000000000000000000000000000000",xo="0x0000000000000000000000000000000000000000000000000000000000000000",Po="Ξ",Io=new b("networks/5.7.1");function Oo(e){const t=function(t,r){null==r&&(r={});const n=[];if(t.InfuraProvider&&"-"!==r.infura)try{n.push(new t.InfuraProvider(e,r.infura))}catch(e){}if(t.EtherscanProvider&&"-"!==r.etherscan)try{n.push(new t.EtherscanProvider(e,r.etherscan))}catch(e){}if(t.AlchemyProvider&&"-"!==r.alchemy)try{n.push(new t.AlchemyProvider(e,r.alchemy))}catch(e){}if(t.PocketProvider&&"-"!==r.pocket){const i=["goerli","ropsten","rinkeby","sepolia"];try{const o=new t.PocketProvider(e,r.pocket);o.network&&-1===i.indexOf(o.network.name)&&n.push(o)}catch(e){}}if(t.CloudflareProvider&&"-"!==r.cloudflare)try{n.push(new t.CloudflareProvider(e))}catch(e){}if(t.AnkrProvider&&"-"!==r.ankr)try{const i=["ropsten"],o=new t.AnkrProvider(e,r.ankr);o.network&&-1===i.indexOf(o.network.name)&&n.push(o)}catch(e){}if(0===n.length)return null;if(t.FallbackProvider){let i=1;return null!=r.quorum?i=r.quorum:"homestead"===e&&(i=2),new t.FallbackProvider(n,i)}return n[0]};return t.renetwork=function(e){return Oo(e)},t}function Ro(e,t){const r=function(r,n){return r.JsonRpcProvider?new r.JsonRpcProvider(e,t):null};return r.renetwork=function(t){return Ro(e,t)},r}const Co={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:Oo("homestead")},Bo={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:Oo("ropsten")},No={chainId:63,name:"classicMordor",_defaultProvider:Ro("https://www.ethercluster.com/mordor","classicMordor")},Lo={unspecified:{chainId:0,name:"unspecified"},homestead:Co,mainnet:Co,morden:{chainId:2,name:"morden"},ropsten:Bo,testnet:Bo,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:Oo("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:Oo("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:Oo("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:Oo("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Ro("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:No,classicTestnet:No,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Ro("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:Oo("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:Oo("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function Uo(e){if(null==e)return null;if("number"==typeof e){for(const t in Lo){const r=Lo[t];if(r.chainId===e)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:e,name:"unknown"}}if("string"==typeof e){const t=Lo[e];return null==t?null:{name:t.name,chainId:t.chainId,ensAddress:t.ensAddress,_defaultProvider:t._defaultProvider||null}}const t=Lo[e.name];if(!t)return"number"!=typeof e.chainId&&Io.throwArgumentError("invalid network chainId","network",e),e;0!==e.chainId&&e.chainId!==t.chainId&&Io.throwArgumentError("network chainId mismatch","network",e);let r=e._defaultProvider||null;var n;return null==r&&t._defaultProvider&&(r=(n=t._defaultProvider)&&"function"==typeof n.renetwork?t._defaultProvider.renetwork(e):t._defaultProvider),{name:e.name,chainId:t.chainId,ensAddress:e.ensAddress||t.ensAddress||null,_defaultProvider:r}}function Fo(e){e=atob(e);const t=[];for(let r=0;r0&&Array.isArray(e)?i(e,t-1):r.push(e)}))};return i(e,t),r}function Ho(e){return function(e){let t=0;return()=>e[t++]}(function(e){let t=0;function r(){return e[t++]<<8|e[t++]}let n=r(),i=1,o=[0,1];for(let e=1;e>--u&1}const f=Math.pow(2,31),h=f>>>1,d=h>>1,p=f-1;let m=0;for(let e=0;e<31;e++)m=m<<1|l();let y=[],g=0,b=f;for(;;){let e=Math.floor(((m-g+1)*i-1)/b),t=0,r=n;for(;r-t>1;){let n=t+r>>>1;e>>1|l(),a=a<<1^h,s=(s^h)<<1|h|1;g=a,b=1+s-a}let v=n-4;return y.map((t=>{switch(t-v){case 3:return v+65792+(e[s++]<<16|e[s++]<<8|e[s++]);case 2:return v+256+(e[s++]<<8|e[s++]);case 1:return v+e[s++];default:return t-1}}))}(e))}function Jo(e){return 1&e?~e>>1:e>>1}function zo(e,t){let r=Array(e);for(let n=0,i=-1;nt[e])):r}function Ko(e,t,r){let n=Array(e).fill(void 0).map((()=>[]));for(let i=0;in[t].push(e)));return n}function Vo(e,t){let r=1+t(),n=t(),i=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(r)}return t}(t);return jo(Ko(i.length,1+e,t).map(((e,t)=>{const o=e[0],a=e.slice(1);return Array(i[t]).fill(void 0).map(((e,t)=>{let i=t*n;return[o+t*r,a.map((e=>e+i))]}))})))}function Xo(e,t){return Ko(1+t(),1+e,t).map((e=>[e[0],e.slice(1)]))}const Qo=Ho(Fo("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA==")),Wo=new Set(qo(Qo)),Zo=new Set(qo(Qo)),Yo=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(Vo(r,e))}for(;;){let r=e()-1;if(r<0)break;t.push(Xo(r,e))}return function(e){const t={};for(let r=0;re-t));return function r(){let n=[];for(;;){let i=qo(e,t);if(0==i.length)break;n.push({set:new Set(i),node:r()})}n.sort(((e,t)=>t.set.size-e.set.size));let i=e(),o=i%3;i=i/3|0;let a=!!(1&i);return i>>=1,{branches:n,valid:o,fe0f:a,save:1==i,check:2==i}}()}(Qo);function ea(e){return We(e)}function ta(e){return e.filter((e=>65039!=e))}function ra(e){for(let t of e.split(".")){let e=ea(t);try{for(let t=e.lastIndexOf(95)-1;t>=0;t--)if(95!==e[t])throw new Error("underscore only allowed at start");if(e.length>=4&&e.every((e=>e<128))&&45===e[2]&&45===e[3])throw new Error("invalid label extension")}catch(e){throw new Error(`Invalid label "${t}": ${e.message}`)}}return e}function na(e){return ra(function(e,t){let r=ea(e).reverse(),n=[];for(;r.length;){let e=ia(r);if(e){n.push(...t(e));continue}let i=r.pop();if(Wo.has(i)){n.push(i);continue}if(Zo.has(i))continue;let o=Yo[i];if(!o)throw new Error(`Disallowed codepoint: 0x${i.toString(16).toUpperCase()}`);n.push(...o)}return ra((i=String.fromCodePoint(...n),i.normalize("NFC")));var i}(e,ta))}function ia(e,t){var r;let n,i,o=$o,a=[],s=e.length;for(t&&(t.length=0);s;){let u=e[--s];if(o=null===(r=o.branches.find((e=>e.set.has(u))))||void 0===r?void 0:r.node,!o)break;if(o.save)i=u;else if(o.check&&u===i)break;a.push(u),o.fe0f&&(a.push(65039),s>0&&65039==e[s-1]&&s--),o.valid&&(n=a.slice(),2==o.valid&&n.splice(1,1),t&&t.push(...e.slice(s).reverse()),e.length=s)}return n}const oa=new b(Zn),aa=new Uint8Array(32);function sa(e){if(0===e.length)throw new Error("invalid ENS name; empty component");return e}function ua(e){const t=qe(na(e)),r=[];if(0===e.length)return r;let n=0;for(let e=0;e=t.length)throw new Error("invalid ENS name; empty component");return r.push(sa(t.slice(n))),r}function ca(e){try{return 0!==ua(e).length}catch(e){}return!1}function la(e){"string"!=typeof e&&oa.throwArgumentError("invalid ENS name; not a string","name",e);let t=aa;const r=ua(e);for(;r.length;)t=ve(M([t,ve(r.pop())]));return O(t)}function fa(e){return O(M(ua(e).map((e=>{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"}aa.fill(0);var ha=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};function da(e,t){return ha(this,void 0,void 0,(function*(){null==t&&(t={});const r={method:t.method||"GET",headers:t.headers||{},body:t.body||void 0};if(!0!==t.skipFetchSetup&&(r.mode="cors",r.cache="no-cache",r.credentials="same-origin",r.redirect="follow",r.referrer="client"),null!=t.fetchOptions){const e=t.fetchOptions;e.mode&&(r.mode=e.mode),e.cache&&(r.cache=e.cache),e.credentials&&(r.credentials=e.credentials),e.redirect&&(r.redirect=e.redirect),e.referrer&&(r.referrer=e.referrer)}const n=yield fetch(e,r),i=yield n.arrayBuffer(),o={};return n.headers.forEach?n.headers.forEach(((e,t)=>{o[t.toLowerCase()]=e})):n.headers.keys().forEach((e=>{o[e.toLowerCase()]=n.headers.get(e)})),{headers:o,statusCode:n.status,statusMessage:n.statusText,body:_(new Uint8Array(i))}}))}var pa=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ma=new b("web/5.7.1");function ya(e){return new Promise((t=>{setTimeout(t,e)}))}function ga(e,t){if(null==e)return null;if("string"==typeof e)return e;if(S(e)){if(t&&("text"===t.split("/")[0]||"application/json"===t.split(";")[0].trim()))try{return Qe(e)}catch(e){}return O(e)}return e}function ba(e,t,r){const n="object"==typeof e&&null!=e.throttleLimit?e.throttleLimit:12;ma.assertArgument(n>0&&n%1==0,"invalid connection throttle limit","connection.throttleLimit",n);const i="object"==typeof e?e.throttleCallback:null,o="object"==typeof e&&"number"==typeof e.throttleSlotInterval?e.throttleSlotInterval:100;ma.assertArgument(o>0&&o%1==0,"invalid connection throttle slot interval","connection.throttleSlotInterval",o);const a="object"==typeof e&&!!e.errorPassThrough,s={};let u=null;const c={method:"GET"};let l=!1,f=12e4;if("string"==typeof e)u=e;else if("object"==typeof e){if(null!=e&&null!=e.url||ma.throwArgumentError("missing URL","connection.url",e),u=e.url,"number"==typeof e.timeout&&e.timeout>0&&(f=e.timeout),e.headers)for(const t in e.headers)s[t.toLowerCase()]={key:t,value:String(e.headers[t])},["if-none-match","if-modified-since"].indexOf(t.toLowerCase())>=0&&(l=!0);if(c.allowGzip=!!e.allowGzip,null!=e.user&&null!=e.password){"https:"!==u.substring(0,6)&&!0!==e.allowInsecureAuthentication&&ma.throwError("basic authentication requires a secure https url",b.errors.INVALID_ARGUMENT,{argument:"url",url:u,user:e.user,password:"[REDACTED]"});const t=e.user+":"+e.password;s.authorization={key:"Authorization",value:"Basic "+Do(qe(t))}}null!=e.skipFetchSetup&&(c.skipFetchSetup=!!e.skipFetchSetup),null!=e.fetchOptions&&(c.fetchOptions=oe(e.fetchOptions))}const h=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),d=u?u.match(h):null;if(d)try{const e={statusCode:200,statusMessage:"OK",headers:{"content-type":d[1]||"text/plain"},body:d[2]?Fo(d[3]):(p=d[3],qe(p.replace(/%([0-9a-f][0-9a-f])/gi,((e,t)=>String.fromCharCode(parseInt(t,16))))))};let t=e.body;return r&&(t=r(e.body,e)),Promise.resolve(t)}catch(e){ma.throwError("processing response error",b.errors.SERVER_ERROR,{body:ga(d[1],d[2]),error:e,requestBody:null,requestMethod:"GET",url:u})}var p;t&&(c.method="POST",c.body=t,null==s["content-type"]&&(s["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==s["content-length"]&&(s["content-length"]={key:"Content-Length",value:String(t.length)}));const m={};Object.keys(s).forEach((e=>{const t=s[e];m[t.key]=t.value})),c.headers=m;const y=function(){let e=null;return{promise:new Promise((function(t,r){f&&(e=setTimeout((()=>{null!=e&&(e=null,r(ma.makeError("timeout",b.errors.TIMEOUT,{requestBody:ga(c.body,m["content-type"]),requestMethod:c.method,timeout:f,url:u})))}),f))})),cancel:function(){null!=e&&(clearTimeout(e),e=null)}}}(),g=function(){return pa(this,void 0,void 0,(function*(){for(let e=0;e=300)&&(y.cancel(),ma.throwError("bad response",b.errors.SERVER_ERROR,{status:t.statusCode,headers:t.headers,body:ga(s,t.headers?t.headers["content-type"]:null),requestBody:ga(c.body,m["content-type"]),requestMethod:c.method,url:u})),r)try{const e=yield r(s,t);return y.cancel(),e}catch(r){if(r.throttleRetry&&e"content-type"===e.toLowerCase())).length||(r.headers=oe(r.headers),r.headers["content-type"]="application/json")}else r.headers={"content-type":"application/json"};e=r}return ba(e,n,((e,t)=>{let n=null;if(null!=e)try{n=JSON.parse(Qe(e))}catch(t){ma.throwError("invalid JSON",b.errors.SERVER_ERROR,{body:e,error:t})}return r&&(n=r(n,t)),n}))}function wa(e,t){return t||(t={}),null==(t=oe(t)).floor&&(t.floor=0),null==t.ceiling&&(t.ceiling=1e4),null==t.interval&&(t.interval=250),new Promise((function(r,n){let i=null,o=!1;const a=()=>!o&&(o=!0,i&&clearTimeout(i),!0);t.timeout&&(i=setTimeout((()=>{a()&&n(new Error("timeout"))}),t.timeout));const s=t.retryLimit;let u=0;!function i(){return e().then((function(e){if(void 0!==e)a()&&r(e);else if(t.oncePoll)t.oncePoll.once("poll",i);else if(t.onceBlock)t.onceBlock.once("block",i);else if(!o){if(u++,u>s)return void(a()&&n(new Error("retry limit reached")));let e=t.interval*parseInt(String(Math.random()*Math.pow(2,u)));et.ceiling&&(e=t.ceiling),setTimeout(i,e)}return null}),(function(e){a()&&n(e)}))}()}))}var Aa=r(92882),Sa=r.n(Aa);const ka="providers/5.7.2",Ea=new b(ka);class _a{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){const e={},t=this.address.bind(this),r=this.bigNumber.bind(this),n=this.blockTag.bind(this),i=this.data.bind(this),o=this.hash.bind(this),a=this.hex.bind(this),s=this.number.bind(this),u=this.type.bind(this);return e.transaction={hash:o,type:u,accessList:_a.allowNull(this.accessList.bind(this),null),blockHash:_a.allowNull(o,null),blockNumber:_a.allowNull(s,null),transactionIndex:_a.allowNull(s,null),confirmations:_a.allowNull(s,null),from:t,gasPrice:_a.allowNull(r),maxPriorityFeePerGas:_a.allowNull(r),maxFeePerGas:_a.allowNull(r),gasLimit:r,to:_a.allowNull(t,null),value:r,nonce:s,data:i,r:_a.allowNull(this.uint256),s:_a.allowNull(this.uint256),v:_a.allowNull(s),creates:_a.allowNull(t,null),raw:_a.allowNull(i)},e.transactionRequest={from:_a.allowNull(t),nonce:_a.allowNull(s),gasLimit:_a.allowNull(r),gasPrice:_a.allowNull(r),maxPriorityFeePerGas:_a.allowNull(r),maxFeePerGas:_a.allowNull(r),to:_a.allowNull(t),value:_a.allowNull(r),data:_a.allowNull((e=>this.data(e,!0))),type:_a.allowNull(s),accessList:_a.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:s,blockNumber:s,transactionHash:o,address:t,topics:_a.arrayOf(o),data:i,logIndex:s,blockHash:o},e.receipt={to:_a.allowNull(this.address,null),from:_a.allowNull(this.address,null),contractAddress:_a.allowNull(t,null),transactionIndex:s,root:_a.allowNull(a),gasUsed:r,logsBloom:_a.allowNull(i),blockHash:o,transactionHash:o,logs:_a.arrayOf(this.receiptLog.bind(this)),blockNumber:s,confirmations:_a.allowNull(s,null),cumulativeGasUsed:r,effectiveGasPrice:_a.allowNull(r),status:_a.allowNull(s),type:u},e.block={hash:_a.allowNull(o),parentHash:o,number:s,timestamp:s,nonce:_a.allowNull(a),difficulty:this.difficulty.bind(this),gasLimit:r,gasUsed:r,miner:_a.allowNull(t),extraData:i,transactions:_a.allowNull(_a.arrayOf(o)),baseFeePerGas:_a.allowNull(r)},e.blockWithTransactions=oe(e.block),e.blockWithTransactions.transactions=_a.allowNull(_a.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:_a.allowNull(n,void 0),toBlock:_a.allowNull(n,void 0),blockHash:_a.allowNull(o,void 0),address:_a.allowNull(t,void 0),topics:_a.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:_a.allowNull(s),blockHash:_a.allowNull(o),transactionIndex:s,removed:_a.allowNull(this.boolean.bind(this)),address:t,data:_a.allowFalsish(i,"0x"),topics:_a.arrayOf(o),transactionHash:o,logIndex:s},e}accessList(e){return dn(e||[])}number(e){return"0x"===e?0:X.from(e).toNumber()}type(e){return"0x"===e||null==e?0:X.from(e).toNumber()}bigNumber(e){return X.from(e)}boolean(e){if("boolean"==typeof e)return e;if("string"==typeof e){if("true"===(e=e.toLowerCase()))return!0;if("false"===e)return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return"string"==typeof e&&(t||"0x"===e.substring(0,2)||(e="0x"+e),P(e))?e.toLowerCase():Ea.throwArgumentError("invalid hash","value",e)}data(e,t){const r=this.hex(e,t);if(r.length%2!=0)throw new Error("invalid data; odd-length - "+e);return r}address(e){return Be(e)}callAddress(e){if(!P(e,32))return null;const t=Be(C(e,12));return t===To?null:t}contractAddress(e){return Ue(e)}blockTag(e){if(null==e)return"latest";if("earliest"===e)return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if("number"==typeof e||P(e))return N(e);throw new Error("invalid blockTag")}hash(e,t){const r=this.hex(e,t);return 32!==R(r)?Ea.throwArgumentError("invalid hash","value",e):r}difficulty(e){if(null==e)return null;const t=X.from(e);try{return t.toNumber()}catch(e){}return null}uint256(e){if(!P(e))throw new Error("invalid uint256");return U(e,32)}_block(e,t){null!=e.author&&null==e.miner&&(e.miner=e.author);const r=null!=e._difficulty?e._difficulty:e.difficulty,n=_a.check(t,e);return n._difficulty=null==r?null:X.from(r),n}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return _a.check(this.formats.transactionRequest,e)}transactionResponse(e){null!=e.gas&&null==e.gasLimit&&(e.gasLimit=e.gas),e.to&&X.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),null!=e.input&&null==e.data&&(e.data=e.input),null==e.to&&null==e.creates&&(e.creates=this.contractAddress(e)),1!==e.type&&2!==e.type||null!=e.accessList||(e.accessList=[]);const t=_a.check(this.formats.transaction,e);if(null!=e.chainId){let r=e.chainId;P(r)&&(r=X.from(r).toNumber()),t.chainId=r}else{let r=e.networkId;null==r&&null==t.v&&(r=e.chainId),P(r)&&(r=X.from(r).toNumber()),"number"!=typeof r&&null!=t.v&&(r=(t.v-35)/2,r<0&&(r=0),r=parseInt(r)),"number"!=typeof r&&(r=0),t.chainId=r}return t.blockHash&&"x"===t.blockHash.replace(/0/g,"")&&(t.blockHash=null),t}transaction(e){return vn(e)}receiptLog(e){return _a.check(this.formats.receiptLog,e)}receipt(e){const t=_a.check(this.formats.receipt,e);if(null!=t.root)if(t.root.length<=4){const e=X.from(t.root).toNumber();0===e||1===e?(null!=t.status&&t.status!==e&&Ea.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=e,delete t.root):Ea.throwArgumentError("invalid alt-root-status","value.root",t.root)}else 66!==t.root.length&&Ea.throwArgumentError("invalid root hash","value.root",t.root);return null!=t.status&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map((e=>this.topics(e))):null!=e?this.hash(e,!0):null}filter(e){return _a.check(this.formats.filter,e)}filterLog(e){return _a.check(this.formats.filterLog,e)}static check(e,t){const r={};for(const n in e)try{const i=e[n](t[n]);void 0!==i&&(r[n]=i)}catch(e){throw e.checkKey=n,e.checkValue=t[n],e}return r}static allowNull(e,t){return function(r){return null==r?t:e(r)}}static allowFalsish(e,t){return function(r){return r?e(r):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");const r=[];return t.forEach((function(t){r.push(e(t))})),r}}}function Ma(e){return e&&"function"==typeof e.isCommunityResource}function Ta(e){return Ma(e)&&e.isCommunityResource()}let xa=!1;function Pa(){xa||(xa=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var Ia=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const Oa=new b(ka);function Ra(e){return null==e?"null":(32!==R(e)&&Oa.throwArgumentError("invalid topic","topic",e),e.toLowerCase())}function Ca(e){for(e=e.slice();e.length>0&&null==e[e.length-1];)e.pop();return e.map((e=>{if(Array.isArray(e)){const t={};e.forEach((e=>{t[Ra(e)]=!0}));const r=Object.keys(t);return r.sort(),r.join("|")}return Ra(e)})).join("&")}function Ba(e){if("string"==typeof e){if(32===R(e=e.toLowerCase()))return"tx:"+e;if(-1===e.indexOf(":"))return e}else{if(Array.isArray(e))return"filter:*:"+Ca(e);if(ir.isForkEvent(e))throw Oa.warn("not implemented"),new Error("not implemented");if(e&&"object"==typeof e)return"filter:"+(e.address||"*")+":"+Ca(e.topics||[])}throw new Error("invalid event - "+e)}function Na(){return(new Date).getTime()}function La(e){return new Promise((t=>{setTimeout(t,e)}))}const Ua=["block","network","pending","poll"];class Fa{constructor(e,t,r){te(this,"tag",e),te(this,"listener",t),te(this,"once",r),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){const e=this.tag.split(":");return"tx"!==e[0]?null:e[1]}get filter(){const e=this.tag.split(":");if("filter"!==e[0])return null;const t=e[1],r=""===(n=e[2])?[]:n.split(/&/g).map((e=>{if(""===e)return[];const t=e.split("|").map((e=>"null"===e?null:e));return 1===t.length?t[0]:t}));var n;const i={};return r.length>0&&(i.topics=r),t&&"*"!==t&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||Ua.indexOf(this.tag)>=0}}const Da={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function ja(e){return U(X.from(e).toHexString(),32)}function Ha(e){return mi.encode(M([e,C(vi(vi(e)),0,4)]))}const Ja=new RegExp("^(ipfs)://(.*)$","i"),za=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Ja,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Ga(e,t){try{return Qe(qa(e,t))}catch(e){}return null}function qa(e,t){if("0x"===e)return null;const r=X.from(C(e,t,t+32)).toNumber(),n=X.from(C(e,r,r+32)).toNumber();return C(e,r+32,r+32+n)}function Ka(e){return e.match(/^ipfs:\/\/ipfs\//i)?e=e.substring(12):e.match(/^ipfs:\/\//i)?e=e.substring(7):Oa.throwArgumentError("unsupported IPFS format","link",e),`https://gateway.ipfs.io/ipfs/${e}`}function Va(e){const t=_(e);if(t.length>32)throw new Error("internal; should not happen");const r=new Uint8Array(32);return r.set(t,32-t.length),r}function Xa(e){if(e.length%32==0)return e;const t=new Uint8Array(32*Math.ceil(e.length/32));return t.set(e),t}function Qa(e){const t=[];let r=0;for(let n=0;nX.from(e).eq(1))).catch((e=>{if(e.code===b.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e}))),this._supportsEip2544}_fetch(e,t){return Ia(this,void 0,void 0,(function*(){const r={to:this.address,ccipReadEnabled:!0,data:B([e,la(this.name),t||"0x"])};let n=!1;(yield this.supportsWildcard())&&(n=!0,r.data=B(["0x9061b923",Qa([fa(this.name),r.data])]));try{let e=yield this.provider.call(r);return _(e).length%32==4&&Oa.throwError("resolver threw error",b.errors.CALL_EXCEPTION,{transaction:r,data:e}),n&&(e=qa(e,0)),e}catch(e){if(e.code===b.errors.CALL_EXCEPTION)return null;throw e}}))}_fetchBytes(e,t){return Ia(this,void 0,void 0,(function*(){const r=yield this._fetch(e,t);return null!=r?qa(r,0):null}))}_getAddress(e,t){const r=Da[String(e)];if(null==r&&Oa.throwError(`unsupported coin type: ${e}`,b.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),"eth"===r.ilk)return this.provider.formatter.address(t);const n=_(t);if(null!=r.p2pkh){const e=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Ha(M([[r.p2pkh],"0x"+e[2]]))}}if(null!=r.p2sh){const e=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Ha(M([[r.p2sh],"0x"+e[2]]))}}if(null!=r.prefix){const e=n[1];let t=n[0];if(0===t?20!==e&&32!==e&&(t=-1):t=-1,t>=0&&n.length===2+e&&e>=1&&e<=75){const e=Sa().toWords(n.slice(2));return e.unshift(t),Sa().encode(r.prefix,e)}}return null}getAddress(e){return Ia(this,void 0,void 0,(function*(){if(null==e&&(e=60),60===e)try{const e=yield this._fetch("0x3b3b57de");return"0x"===e||e===xo?null:this.provider.formatter.callAddress(e)}catch(e){if(e.code===b.errors.CALL_EXCEPTION)return null;throw e}const t=yield this._fetchBytes("0xf1cb7e06",ja(e));if(null==t||"0x"===t)return null;const r=this._getAddress(e,t);return null==r&&Oa.throwError("invalid or unsupported coin data",b.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),r}))}getAvatar(){return Ia(this,void 0,void 0,(function*(){const e=[{type:"name",content:this.name}];try{const t=yield this.getText("avatar");if(null==t)return null;for(let r=0;re[t]))}return Oa.throwError("invalid or unsupported content hash data",b.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})}))}getText(e){return Ia(this,void 0,void 0,(function*(){let t=qe(e);t=M([ja(64),ja(t.length),t]),t.length%32!=0&&(t=M([t,U("0x",32-e.length%32)]));const r=yield this._fetchBytes("0x59d1d43c",O(t));return null==r||"0x"===r?null:Qe(r)}))}}let Za=null,Ya=1;class $a extends or{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),te(this,"anyNetwork","any"===e),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch((e=>{})),this._ready().catch((e=>{}));else{const t=re(new.target,"getNetwork")(e);t?(te(this,"_network",t),this.emit("network",t,null)):Oa.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return Ia(this,void 0,void 0,(function*(){if(null==this._network){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch(e){}null==e&&(e=yield this.detectNetwork()),e||Oa.throwError("no network detected",b.errors.UNKNOWN_ERROR,{}),null==this._network&&(this.anyNetwork?this._network=e:te(this,"_network",e),this.emit("network",e,null))}return this._network}))}get ready(){return wa((()=>this._ready().then((e=>e),(e=>{if(e.code!==b.errors.NETWORK_ERROR||"noNetwork"!==e.event)throw e}))))}static getFormatter(){return null==Za&&(Za=new _a),Za}static getNetwork(e){return Uo(null==e?"homestead":e)}ccipReadFetch(e,t,r){return Ia(this,void 0,void 0,(function*(){if(this.disableCcipRead||0===r.length)return null;const n=e.to.toLowerCase(),i=t.toLowerCase(),o=[];for(let e=0;e=0?null:JSON.stringify({data:i,sender:n}),u=yield va({url:a,errorPassThrough:!0},s,((e,t)=>(e.status=t.statusCode,e)));if(u.data)return u.data;const c=u.message||"unknown error";if(u.status>=400&&u.status<500)return Oa.throwError(`response not found during CCIP fetch: ${c}`,b.errors.SERVER_ERROR,{url:t,errorMessage:c});o.push(c)}return Oa.throwError(`error encountered during CCIP fetch: ${o.map((e=>JSON.stringify(e))).join(", ")}`,b.errors.SERVER_ERROR,{urls:r,errorMessages:o})}))}_getInternalBlockNumber(e){return Ia(this,void 0,void 0,(function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){const t=this._internalBlockNumber;try{const r=yield t;if(Na()-r.respTime<=e)return r.blockNumber;break}catch(e){if(this._internalBlockNumber===t)break}}const t=Na(),r=ne({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then((e=>null),(e=>e))}).then((({blockNumber:e,networkError:n})=>{if(n)throw this._internalBlockNumber===r&&(this._internalBlockNumber=null),n;const i=Na();return(e=X.from(e).toNumber()){this._internalBlockNumber===r&&(this._internalBlockNumber=null)})),(yield r).blockNumber}))}poll(){return Ia(this,void 0,void 0,(function*(){const e=Ya++,t=[];let r=null;try{r=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(e){return void this.emit("error",e)}if(this._setFastBlockNumber(r),this.emit("poll",e,r),r!==this._lastBlockNumber){if(-2===this._emitted.block&&(this._emitted.block=r-1),Math.abs(this._emitted.block-r)>1e3)Oa.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${r})`),this.emit("error",Oa.makeError("network block skew detected",b.errors.NETWORK_ERROR,{blockNumber:r,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",r);else for(let e=this._emitted.block+1;e<=r;e++)this.emit("block",e);this._emitted.block!==r&&(this._emitted.block=r,Object.keys(this._emitted).forEach((e=>{if("block"===e)return;const t=this._emitted[e];"pending"!==t&&r-t>12&&delete this._emitted[e]}))),-2===this._lastBlockNumber&&(this._lastBlockNumber=r-1),this._events.forEach((e=>{switch(e.type){case"tx":{const r=e.hash;let n=this.getTransactionReceipt(r).then((e=>e&&null!=e.blockNumber?(this._emitted["t:"+r]=e.blockNumber,this.emit(r,e),null):null)).catch((e=>{this.emit("error",e)}));t.push(n);break}case"filter":if(!e._inflight){e._inflight=!0,-2===e._lastBlockNumber&&(e._lastBlockNumber=r-1);const n=e.filter;n.fromBlock=e._lastBlockNumber+1,n.toBlock=r;const i=n.toBlock-this._maxFilterBlockRange;i>n.fromBlock&&(n.fromBlock=i),n.fromBlock<0&&(n.fromBlock=0);const o=this.getLogs(n).then((t=>{e._inflight=!1,0!==t.length&&t.forEach((t=>{t.blockNumber>e._lastBlockNumber&&(e._lastBlockNumber=t.blockNumber),this._emitted["b:"+t.blockHash]=t.blockNumber,this._emitted["t:"+t.transactionHash]=t.blockNumber,this.emit(n,t)}))})).catch((t=>{this.emit("error",t),e._inflight=!1}));t.push(o)}}})),this._lastBlockNumber=r,Promise.all(t).then((()=>{this.emit("didPoll",e)})).catch((e=>{this.emit("error",e)}))}else this.emit("didPoll",e)}))}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return Ia(this,void 0,void 0,(function*(){return Oa.throwError("provider does not support network detection",b.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})}))}getNetwork(){return Ia(this,void 0,void 0,(function*(){const e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield La(0),this._network;const r=Oa.makeError("underlying network changed",b.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",r),r}return e}))}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then((e=>{this._setFastBlockNumber(e)}),(e=>{})),null!=this._fastBlockNumber?this._fastBlockNumber:-1}get polling(){return null!=this._poller}set polling(e){e&&!this._poller?(this._poller=setInterval((()=>{this.poll()}),this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout((()=>{this.poll(),this._bootstrapPoll=setTimeout((()=>{this._poller||this.poll(),this._bootstrapPoll=null}),this.pollingInterval)}),0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if("number"!=typeof e||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval((()=>{this.poll()}),this._pollingInterval))}_getFastBlockNumber(){const e=Na();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then((e=>((null==this._fastBlockNumber||e>this._fastBlockNumber)&&(this._fastBlockNumber=e),this._fastBlockNumber)))),this._fastBlockNumberPromise}_setFastBlockNumber(e){null!=this._fastBlockNumber&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,r){return Ia(this,void 0,void 0,(function*(){return this._waitForTransaction(e,null==t?1:t,r||0,null)}))}_waitForTransaction(e,t,r,n){return Ia(this,void 0,void 0,(function*(){const i=yield this.getTransactionReceipt(e);return(i?i.confirmations:0)>=t?i:new Promise(((i,o)=>{const a=[];let s=!1;const u=function(){return!!s||(s=!0,a.forEach((e=>{e()})),!1)},c=e=>{e.confirmations{this.removeListener(e,c)})),n){let r=n.startBlock,i=null;const c=a=>Ia(this,void 0,void 0,(function*(){s||(yield La(1e3),this.getTransactionCount(n.from).then((l=>Ia(this,void 0,void 0,(function*(){if(!s){if(l<=n.nonce)r=a;else{{const t=yield this.getTransaction(e);if(t&&null!=t.blockNumber)return}for(null==i&&(i=r-3,i{s||this.once("block",c)})))}));if(s)return;this.once("block",c),a.push((()=>{this.removeListener("block",c)}))}if("number"==typeof r&&r>0){const e=setTimeout((()=>{u()||o(Oa.makeError("timeout exceeded",b.errors.TIMEOUT,{timeout:r}))}),r);e.unref&&e.unref(),a.push((()=>{clearTimeout(e)}))}}))}))}getBlockNumber(){return Ia(this,void 0,void 0,(function*(){return this._getInternalBlockNumber(0)}))}getGasPrice(){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const e=yield this.perform("getGasPrice",{});try{return X.from(e)}catch(t){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}}))}getBalance(e,t){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getBalance",r);try{return X.from(n)}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getBalance",params:r,result:n,error:e})}}))}getTransactionCount(e,t){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getTransactionCount",r);try{return X.from(n).toNumber()}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getTransactionCount",params:r,result:n,error:e})}}))}getCode(e,t){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getCode",r);try{return O(n)}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getCode",params:r,result:n,error:e})}}))}getStorageAt(e,t,r){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const n=yield ne({address:this._getAddress(e),blockTag:this._getBlockTag(r),position:Promise.resolve(t).then((e=>N(e)))}),i=yield this.perform("getStorageAt",n);try{return O(i)}catch(e){return Oa.throwError("bad result from backend",b.errors.SERVER_ERROR,{method:"getStorageAt",params:n,result:i,error:e})}}))}_wrapTransaction(e,t,r){if(null!=t&&32!==R(t))throw new Error("invalid response - sendTransaction");const n=e;return null!=t&&e.hash!==t&&Oa.throwError("Transaction hash mismatch from Provider.sendTransaction.",b.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),n.wait=(t,n)=>Ia(this,void 0,void 0,(function*(){let i;null==t&&(t=1),null==n&&(n=0),0!==t&&null!=r&&(i={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:r});const o=yield this._waitForTransaction(e.hash,t,n,i);return null==o&&0===t?null:(this._emitted["t:"+e.hash]=o.blockNumber,0===o.status&&Oa.throwError("transaction failed",b.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:o}),o)})),n}sendTransaction(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Promise.resolve(e).then((e=>O(e))),r=this.formatter.transaction(e);null==r.confirmations&&(r.confirmations=0);const n=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{const e=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(r,e,n)}catch(e){throw e.transaction=r,e.transactionHash=r.hash,e}}))}_getTransactionRequest(e){return Ia(this,void 0,void 0,(function*(){const t=yield e,r={};return["from","to"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?this._getAddress(e):null)))})),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?X.from(e):null)))})),["type"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>null!=e?e:null)))})),t.accessList&&(r.accessList=this.formatter.accessList(t.accessList)),["data"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?O(e):null)))})),this.formatter.transactionRequest(yield ne(r))}))}_getFilter(e){return Ia(this,void 0,void 0,(function*(){e=yield e;const t={};return null!=e.address&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach((r=>{null!=e[r]&&(t[r]=e[r])})),["fromBlock","toBlock"].forEach((r=>{null!=e[r]&&(t[r]=this._getBlockTag(e[r]))})),this.formatter.filter(yield ne(t))}))}_call(e,t,r){return Ia(this,void 0,void 0,(function*(){r>=10&&Oa.throwError("CCIP read exceeded maximum redirections",b.errors.SERVER_ERROR,{redirects:r,transaction:e});const n=e.to,i=yield this.perform("call",{transaction:e,blockTag:t});if(r>=0&&"latest"===t&&null!=n&&"0x556f1830"===i.substring(0,10)&&R(i)%32==4)try{const o=C(i,4),a=C(o,0,32);X.from(a).eq(n)||Oa.throwError("CCIP Read sender did not match",b.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:i});const s=[],u=X.from(C(o,32,64)).toNumber(),c=X.from(C(o,u,u+32)).toNumber(),l=C(o,u+32);for(let t=0;tIa(this,void 0,void 0,(function*(){const e=yield this.perform("getBlock",n);if(null==e)return null!=n.blockHash&&null==this._emitted["b:"+n.blockHash]||null!=n.blockTag&&r>this._emitted.block?null:void 0;if(t){let t=null;for(let r=0;rthis._wrapTransaction(e))),r}return this.formatter.block(e)}))),{oncePoll:this})}))}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return wa((()=>Ia(this,void 0,void 0,(function*(){const r=yield this.perform("getTransaction",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;const n=this.formatter.transactionResponse(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return this._wrapTransaction(n)}))),{oncePoll:this})}))}getTransactionReceipt(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return wa((()=>Ia(this,void 0,void 0,(function*(){const r=yield this.perform("getTransactionReceipt",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;if(null==r.blockHash)return;const n=this.formatter.receipt(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return n}))),{oncePoll:this})}))}getLogs(e){return Ia(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield ne({filter:this._getFilter(e)}),r=yield this.perform("getLogs",t);return r.forEach((e=>{null==e.removed&&(e.removed=!1)})),_a.arrayOf(this.formatter.filterLog.bind(this.formatter))(r)}))}getEtherPrice(){return Ia(this,void 0,void 0,(function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})}))}_getBlockTag(e){return Ia(this,void 0,void 0,(function*(){if("number"==typeof(e=yield e)&&e<0){e%1&&Oa.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)}))}getResolver(e){return Ia(this,void 0,void 0,(function*(){let t=e;for(;;){if(""===t||"."===t)return null;if("eth"!==e&&"eth"===t)return null;const r=yield this._getResolver(t,"getResolver");if(null!=r){const n=new Wa(this,r,e);return t===e||(yield n.supportsWildcard())?n:null}t=t.split(".").slice(1).join(".")}}))}_getResolver(e,t){return Ia(this,void 0,void 0,(function*(){null==t&&(t="ENS");const r=yield this.getNetwork();r.ensAddress||Oa.throwError("network does not support ENS",b.errors.UNSUPPORTED_OPERATION,{operation:t,network:r.name});try{const t=yield this.call({to:r.ensAddress,data:"0x0178b8bf"+la(e).substring(2)});return this.formatter.callAddress(t)}catch(e){}return null}))}resolveName(e){return Ia(this,void 0,void 0,(function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(t){if(P(e))throw t}"string"!=typeof e&&Oa.throwArgumentError("invalid ENS name","name",e);const t=yield this.getResolver(e);return t?yield t.getAddress():null}))}lookupAddress(e){return Ia(this,void 0,void 0,(function*(){e=yield e;const t=(e=this.formatter.address(e)).substring(2).toLowerCase()+".addr.reverse",r=yield this._getResolver(t,"lookupAddress");if(null==r)return null;const n=Ga(yield this.call({to:r,data:"0x691f3431"+la(t).substring(2)}),0);return(yield this.resolveName(n))!=e?null:n}))}getAvatar(e){return Ia(this,void 0,void 0,(function*(){let t=null;if(P(e)){const r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(r,"getAvatar");if(!n)return null;t=new Wa(this,n,r);try{const e=yield t.getAvatar();if(e)return e.url}catch(e){if(e.code!==b.errors.CALL_EXCEPTION)throw e}try{const e=Ga(yield this.call({to:n,data:"0x691f3431"+la(r).substring(2)}),0);t=yield this.getResolver(e)}catch(e){if(e.code!==b.errors.CALL_EXCEPTION)throw e;return null}}else if(t=yield this.getResolver(e),!t)return null;const r=yield t.getAvatar();return null==r?null:r.url}))}perform(e,t){return Oa.throwError(e+" not implemented",b.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_stopEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_addEventListener(e,t,r){const n=new Fa(Ba(e),t,r);return this._events.push(n),this._startEvent(n),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let r=!1,n=[],i=Ba(e);return this._events=this._events.filter((e=>e.tag!==i||(setTimeout((()=>{e.listener.apply(this,t)}),0),r=!0,!e.once||(n.push(e),!1)))),n.forEach((e=>{this._stopEvent(e)})),r}listenerCount(e){if(!e)return this._events.length;let t=Ba(e);return this._events.filter((e=>e.tag===t)).length}listeners(e){if(null==e)return this._events.map((e=>e.listener));let t=Ba(e);return this._events.filter((e=>e.tag===t)).map((e=>e.listener))}off(e,t){if(null==t)return this.removeAllListeners(e);const r=[];let n=!1,i=Ba(e);return this._events=this._events.filter((e=>e.tag!==i||e.listener!=t||(!!n||(n=!0,r.push(e),!1)))),r.forEach((e=>{this._stopEvent(e)})),this}removeAllListeners(e){let t=[];if(null==e)t=this._events,this._events=[];else{const r=Ba(e);this._events=this._events.filter((e=>e.tag!==r||(t.push(e),!1)))}return t.forEach((e=>{this._stopEvent(e)})),this}}var es=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ts=new b(ka),rs=["call","estimateGas"];function ns(e,t){if(null==e)return null;if("string"==typeof e.message&&e.message.match("reverted")){const r=P(e.data)?e.data:null;if(!t||r)return{message:e.message,data:r}}if("object"==typeof e){for(const r in e){const n=ns(e[r],t);if(n)return n}return null}if("string"==typeof e)try{return ns(JSON.parse(e),t)}catch(e){}return null}function is(e,t,r){const n=r.transaction||r.signedTransaction;if("call"===e){const e=ns(t,!0);if(e)return e.data;ts.throwError("missing revert data in call exception; Transaction reverted without a reason string",b.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:t})}if("estimateGas"===e){let r=ns(t.body,!1);null==r&&(r=ns(t,!1)),r&&ts.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:e,transaction:n,error:t})}let i=t.message;throw t.code===b.errors.SERVER_ERROR&&t.error&&"string"==typeof t.error.message?i=t.error.message:"string"==typeof t.body?i=t.body:"string"==typeof t.responseText&&(i=t.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&ts.throwError("insufficient funds for intrinsic transaction cost",b.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:n}),i.match(/nonce (is )?too low/i)&&ts.throwError("nonce has already been used",b.errors.NONCE_EXPIRED,{error:t,method:e,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&ts.throwError("replacement fee too low",b.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:n}),i.match(/only replay-protected/i)&&ts.throwError("legacy pre-eip-155 transactions not supported",b.errors.UNSUPPORTED_OPERATION,{error:t,method:e,transaction:n}),rs.indexOf(e)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&ts.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:n}),t}function os(e){return new Promise((function(t){setTimeout(t,e)}))}function as(e){if(e.error){const t=new Error(e.error.message);throw t.code=e.error.code,t.data=e.error.data,t}return e.result}function ss(e){return e?e.toLowerCase():e}const us={};class cs extends lr{constructor(e,t,r){if(super(),e!==us)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");te(this,"provider",t),null==r&&(r=0),"string"==typeof r?(te(this,"_address",this.provider.formatter.address(r)),te(this,"_index",null)):"number"==typeof r?(te(this,"_index",r),te(this,"_address",null)):ts.throwArgumentError("invalid address or index","addressOrIndex",r)}connect(e){return ts.throwError("cannot alter JSON-RPC Signer connection",b.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new ls(us,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then((e=>(e.length<=this._index&&ts.throwError("unknown account #"+this._index,b.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index]))))}sendUncheckedTransaction(e){e=oe(e);const t=this.getAddress().then((e=>(e&&(e=e.toLowerCase()),e)));if(null==e.gasLimit){const r=oe(e);r.from=t,e.gasLimit=this.provider.estimateGas(r)}return null!=e.to&&(e.to=Promise.resolve(e.to).then((e=>es(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.provider.resolveName(e);return null==t&&ts.throwArgumentError("provided ENS name resolves to null","tx.to",e),t}))))),ne({tx:ne(e),sender:t}).then((({tx:t,sender:r})=>{null!=t.from?t.from.toLowerCase()!==r&&ts.throwArgumentError("from address mismatch","transaction",e):t.from=r;const n=this.provider.constructor.hexlifyTransaction(t,{from:!0});return this.provider.send("eth_sendTransaction",[n]).then((e=>e),(e=>("string"==typeof e.message&&e.message.match(/user denied/i)&&ts.throwError("user rejected transaction",b.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:t}),is("sendTransaction",e,n))))}))}signTransaction(e){return ts.throwError("signing transactions is unsupported",b.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return es(this,void 0,void 0,(function*(){const t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),r=yield this.sendUncheckedTransaction(e);try{return yield wa((()=>es(this,void 0,void 0,(function*(){const e=yield this.provider.getTransaction(r);if(null!==e)return this.provider._wrapTransaction(e,r,t)}))),{oncePoll:this.provider})}catch(e){throw e.transactionHash=r,e}}))}signMessage(e){return es(this,void 0,void 0,(function*(){const t="string"==typeof e?qe(e):e,r=yield this.getAddress();try{return yield this.provider.send("personal_sign",[O(t),r.toLowerCase()])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&ts.throwError("user rejected signing",b.errors.ACTION_REJECTED,{action:"signMessage",from:r,messageData:e}),t}}))}_legacySignMessage(e){return es(this,void 0,void 0,(function*(){const t="string"==typeof e?qe(e):e,r=yield this.getAddress();try{return yield this.provider.send("eth_sign",[r.toLowerCase(),O(t)])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&ts.throwError("user rejected signing",b.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:r,messageData:e}),t}}))}_signTypedData(e,t,r){return es(this,void 0,void 0,(function*(){const n=yield di.resolveNames(e,t,r,(e=>this.provider.resolveName(e))),i=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[i.toLowerCase(),JSON.stringify(di.getPayload(n.domain,t,n.value))])}catch(e){throw"string"==typeof e.message&&e.message.match(/user denied/i)&&ts.throwError("user rejected signing",b.errors.ACTION_REJECTED,{action:"_signTypedData",from:i,messageData:{domain:n.domain,types:t,value:n.value}}),e}}))}unlock(e){return es(this,void 0,void 0,(function*(){const t=this.provider,r=yield this.getAddress();return t.send("personal_unlockAccount",[r.toLowerCase(),e,null])}))}}class ls extends cs{sendTransaction(e){return this.sendUncheckedTransaction(e).then((e=>({hash:e,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:t=>this.provider.waitForTransaction(e,t)})))}}const fs={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0};class hs extends $a{constructor(e,t){let r=t;null==r&&(r=new Promise(((e,t)=>{setTimeout((()=>{this.detectNetwork().then((t=>{e(t)}),(e=>{t(e)}))}),0)}))),super(r),e||(e=re(this.constructor,"defaultUrl")()),te(this,"connection","string"==typeof e?Object.freeze({url:e}):Object.freeze(oe(e))),this._nextId=42}get _cache(){return null==this._eventLoopCache&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout((()=>{this._cache.detectNetwork=null}),0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return es(this,void 0,void 0,(function*(){yield os(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch(t){try{e=yield this.send("net_version",[])}catch(e){}}if(null!=e){const t=re(this.constructor,"getNetwork");try{return t(X.from(e).toNumber())}catch(t){return ts.throwError("could not detect network",b.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:t})}}return ts.throwError("could not detect network",b.errors.NETWORK_ERROR,{event:"noNetwork"})}))}getSigner(e){return new cs(us,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then((e=>e.map((e=>this.formatter.address(e)))))}send(e,t){const r={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:ce(r),provider:this});const n=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(n&&this._cache[e])return this._cache[e];const i=va(this.connection,JSON.stringify(r),as).then((e=>(this.emit("debug",{action:"response",request:r,response:e,provider:this}),e)),(e=>{throw this.emit("debug",{action:"response",error:e,request:r,provider:this}),e}));return n&&(this._cache[e]=i,setTimeout((()=>{this._cache[e]=null}),0)),i}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[ss(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[ss(t.address),t.blockTag]];case"getCode":return["eth_getCode",[ss(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[ss(t.address),U(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":return["eth_call",[re(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0}),t.blockTag]];case"estimateGas":return["eth_estimateGas",[re(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0})]];case"getLogs":return t.filter&&null!=t.filter.address&&(t.filter.address=ss(t.filter.address)),["eth_getLogs",[t.filter]]}return null}perform(e,t){return es(this,void 0,void 0,(function*(){if("call"===e||"estimateGas"===e){const e=t.transaction;if(e&&null!=e.type&&X.from(e.type).isZero()&&null==e.maxFeePerGas&&null==e.maxPriorityFeePerGas){const r=yield this.getFeeData();null==r.maxFeePerGas&&null==r.maxPriorityFeePerGas&&((t=oe(t)).transaction=oe(e),delete t.transaction.type)}}const r=this.prepareRequest(e,t);null==r&&ts.throwError(e+" not implemented",b.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(r[0],r[1])}catch(r){return is(e,r,t)}}))}_startEvent(e){"pending"===e.tag&&this._startPending(),super._startEvent(e)}_startPending(){if(null!=this._pendingFilter)return;const e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then((function(r){return function n(){e.send("eth_getFilterChanges",[r]).then((function(r){if(e._pendingFilter!=t)return null;let n=Promise.resolve();return r.forEach((function(t){e._emitted["t:"+t.toLowerCase()]="pending",n=n.then((function(){return e.getTransaction(t).then((function(t){return e.emit("pending",t),null}))}))})),n.then((function(){return os(1e3)}))})).then((function(){if(e._pendingFilter==t)return setTimeout((function(){n()}),0),null;e.send("eth_uninstallFilter",[r])})).catch((e=>{}))}(),r})).catch((e=>{}))}_stopEvent(e){"pending"===e.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){const r=oe(fs);if(t)for(const e in t)t[e]&&(r[e]=!0);ie(e,r);const n={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach((function(t){if(null==e[t])return;const r=N(X.from(e[t]));"gasLimit"===t&&(t="gas"),n[t]=r})),["from","to","data"].forEach((function(t){null!=e[t]&&(n[t]=O(e[t]))})),e.accessList&&(n.accessList=dn(e.accessList)),n}}let ds=null;try{if(ds=WebSocket,null==ds)throw new Error("inject please")}catch(e){const t=new b(ka);ds=function(){t.throwError("WebSockets not supported in this environment",b.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var ps=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const ms=new b(ka);let ys=1;class gs extends hs{constructor(e,t){"any"===t&&ms.throwError("WebSocketProvider does not support 'any' network yet",b.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),super("string"==typeof e?e:"_websocket",t),this._pollingInterval=-1,this._wsReady=!1,te(this,"_websocket","string"==typeof e?new ds(this.connection.url):e),te(this,"_requests",{}),te(this,"_subs",{}),te(this,"_subIds",{}),te(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach((e=>{this.websocket.send(this._requests[e].payload)}))},this.websocket.onmessage=e=>{const t=e.data,r=JSON.parse(t);if(null!=r.id){const e=String(r.id),n=this._requests[e];if(delete this._requests[e],void 0!==r.result)n.callback(null,r.result),this.emit("debug",{action:"response",request:JSON.parse(n.payload),response:r.result,provider:this});else{let e=null;r.error?(e=new Error(r.error.message||"unknown error"),te(e,"code",r.error.code||null),te(e,"response",t)):e=new Error("unknown error"),n.callback(e,void 0),this.emit("debug",{action:"response",error:e,request:JSON.parse(n.payload),provider:this})}}else if("eth_subscription"===r.method){const e=this._subs[r.params.subscription];e&&e.processFunc(r.params.result)}else console.warn("this should not happen")};const r=setInterval((()=>{this.emit("poll")}),1e3);r.unref&&r.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){ms.throwError("cannot reset events block on WebSocketProvider",b.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){ms.throwError("cannot set polling interval on WebSocketProvider",b.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return ps(this,void 0,void 0,(function*(){return null}))}set polling(e){e&&ms.throwError("cannot set polling on WebSocketProvider",b.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){const r=ys++;return new Promise(((n,i)=>{const o=JSON.stringify({method:e,params:t,id:r,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(r)]={callback:function(e,t){return e?i(e):n(t)},payload:o},this._wsReady&&this.websocket.send(o)}))}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,r){return ps(this,void 0,void 0,(function*(){let n=this._subIds[e];null==n&&(n=Promise.all(t).then((e=>this.send("eth_subscribe",e))),this._subIds[e]=n);const i=yield n;this._subs[i]={tag:e,processFunc:r}}))}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],(e=>{const t=X.from(e.number).toNumber();this._emitted.block=t,this.emit("block",t)}));break;case"pending":this._subscribe("pending",["newPendingTransactions"],(e=>{this.emit("pending",e)}));break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],(t=>{null==t.removed&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))}));break;case"tx":{const t=e=>{const t=e.hash;this.getTransactionReceipt(t).then((e=>{e&&this.emit(t,e)}))};t(e),this._subscribe("tx",["newHeads"],(e=>{this._events.filter((e=>"tx"===e.type)).forEach(t)}));break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e)}}_stopEvent(e){let t=e.tag;if("tx"===e.type){if(this._events.filter((e=>"tx"===e.type)).length)return;t="tx"}else if(this.listenerCount(e.event))return;const r=this._subIds[t];r&&(delete this._subIds[t],r.then((e=>{this._subs[e]&&(delete this._subs[e],this.send("eth_unsubscribe",[e]))})))}destroy(){return ps(this,void 0,void 0,(function*(){this.websocket.readyState===ds.CONNECTING&&(yield new Promise((e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}}))),this.websocket.close(1e3)}))}}var bs=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const vs=new b(ka);class ws extends hs{detectNetwork(){const e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return bs(this,void 0,void 0,(function*(){let t=this.network;return null==t&&(t=yield e.detectNetwork.call(this),t||vs.throwError("no network detected",b.errors.UNKNOWN_ERROR,{}),null==this._network&&(te(this,"_network",t),this.emit("network",t,null))),t}))}}class As extends ws{constructor(e,t){vs.checkAbstract(new.target,As),e=re(new.target,"getNetwork")(e),t=re(new.target,"getApiKey")(t);super(re(new.target,"getUrl")(e,t),e),"string"==typeof t?te(this,"apiKey",t):null!=t&&Object.keys(t).forEach((e=>{te(this,e,t[e])}))}_startPending(){vs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return vs.throwError("API provider does not support signing",b.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return vs.throwError("not implemented; sub-classes must override getUrl",b.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}}const Ss=new b(ka),ks="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC";class Es extends gs{constructor(e,t){const r=new _s(e,t);super(r.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi."),r.network),te(this,"apiKey",r.apiKey)}isCommunityResource(){return this.apiKey===ks}}class _s extends As{static getWebSocketProvider(e,t){return new Es(e,t)}static getApiKey(e){return null==e?ks:(e&&"string"!=typeof e&&Ss.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let r=null;switch(e.name){case"homestead":r="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":r="eth-goerli.g.alchemy.com/v2/";break;case"matic":r="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":r="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":r="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":r="arb-goerli.g.alchemy.com/v2/";break;case"optimism":r="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":r="opt-goerli.g.alchemy.com/v2/";break;default:Ss.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+r+t,throttleCallback:(e,r)=>(t===ks&&Pa(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===ks}}const Ms=new b(ka),Ts="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function xs(e){switch(e){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return Ms.throwArgumentError("unsupported network","name",e)}class Ps extends As{isCommunityResource(){return this.apiKey===Ts}static getApiKey(e){return null==e?Ts:e}static getUrl(e,t){null==t&&(t=Ts);const r={allowGzip:!0,url:"https://"+xs(e.name)+t,throttleCallback:(e,r)=>(t.apiKey===Ts&&Pa(),Promise.resolve(!0))};return null!=t.projectSecret&&(r.user="",r.password=t.projectSecret),r}}var Is=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const Os=new b(ka);class Rs extends As{static getApiKey(e){return null!=e&&Os.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let r=null;if("homestead"===e.name)r="https://cloudflare-eth.com/";else Os.throwArgumentError("unsupported network","network",arguments[0]);return r}perform(e,t){const r=Object.create(null,{perform:{get:()=>super.perform}});return Is(this,void 0,void 0,(function*(){if("getBlockNumber"===e){return(yield r.perform.call(this,"getBlock",{blockTag:"latest"})).number}return r.perform.call(this,e,t)}))}}var Cs=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const Bs=new b(ka);function Ns(e){const t={};for(let r in e){if(null==e[r])continue;let n=e[r];"type"===r&&0===n||(n={type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[r]?N(O(n)):"accessList"===r?"["+dn(n).map((e=>`{address:"${e.address}",storageKeys:["${e.storageKeys.join('","')}"]}`)).join(",")+"]":O(n),t[r]=n)}return t}function Ls(e){if(0==e.status&&("No records found"===e.message||"No transactions found"===e.message))return e.result;if(1!=e.status||"string"!=typeof e.message||!e.message.match(/^OK/)){const t=new Error("invalid response");throw t.result=JSON.stringify(e),(e.result||"").toLowerCase().indexOf("rate limit")>=0&&(t.throttleRetry=!0),t}return e.result}function Us(e){if(e&&0==e.status&&"NOTOK"==e.message&&(e.result||"").toLowerCase().indexOf("rate limit")>=0){const t=new Error("throttled response");throw t.result=JSON.stringify(e),t.throttleRetry=!0,t}if("2.0"!=e.jsonrpc){const t=new Error("invalid response");throw t.result=JSON.stringify(e),t}if(e.error){const t=new Error(e.error.message||"unknown error");throw e.error.code&&(t.code=e.error.code),e.error.data&&(t.data=e.error.data),t}return e.result}function Fs(e){if("pending"===e)throw new Error("pending not supported");return"latest"===e?e:parseInt(e.substring(2),16)}function Ds(e,t,r){if("call"===e&&t.code===b.errors.SERVER_ERROR){const e=t.error;if(e&&(e.message.match(/reverted/i)||e.message.match(/VM execution error/i))){let r=e.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),P(r))return r;Bs.throwError("missing revert data in call exception",b.errors.CALL_EXCEPTION,{error:t,data:"0x"})}}let n=t.message;throw t.code===b.errors.SERVER_ERROR&&(t.error&&"string"==typeof t.error.message?n=t.error.message:"string"==typeof t.body?n=t.body:"string"==typeof t.responseText&&(n=t.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Bs.throwError("insufficient funds for intrinsic transaction cost",b.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:r}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Bs.throwError("nonce has already been used",b.errors.NONCE_EXPIRED,{error:t,method:e,transaction:r}),n.match(/another transaction with same nonce/)&&Bs.throwError("replacement fee too low",b.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:r}),n.match(/execution failed due to an exception|execution reverted/)&&Bs.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",b.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:r}),t}class js extends $a{constructor(e,t){super(e),te(this,"baseUrl",this.getBaseUrl()),te(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io"}return Bs.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){const r=Object.keys(t).reduce(((e,r)=>{const n=t[r];return null!=n&&(e+=`&${r}=${n}`),e}),""),n=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${r}${n}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,r){return Cs(this,void 0,void 0,(function*(){const n=r?this.getPostUrl():this.getUrl(e,t),i=r?this.getPostData(e,t):null,o="proxy"===e?Us:Ls;this.emit("debug",{action:"request",request:n,provider:this});const a={url:n,throttleSlotInterval:1e3,throttleCallback:(e,t)=>(this.isCommunityResource()&&Pa(),Promise.resolve(!0))};let s=null;i&&(a.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},s=Object.keys(i).map((e=>`${e}=${i[e]}`)).join("&"));const u=yield va(a,s,o||Us);return this.emit("debug",{action:"response",request:n,response:ce(u),provider:this}),u}))}detectNetwork(){return Cs(this,void 0,void 0,(function*(){return this.network}))}perform(e,t){const r=Object.create(null,{perform:{get:()=>super.perform}});return Cs(this,void 0,void 0,(function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch((e=>Ds("sendTransaction",e,t.signedTransaction)));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if("latest"!==t.blockTag)throw new Error("EtherscanProvider does not support blockTag for call");const e=Ns(t.transaction);e.module="proxy",e.action="eth_call";try{return yield this.fetch("proxy",e,!0)}catch(e){return Ds("call",e,t.transaction)}}case"estimateGas":{const e=Ns(t.transaction);e.module="proxy",e.action="eth_estimateGas";try{return yield this.fetch("proxy",e,!0)}catch(e){return Ds("estimateGas",e,t.transaction)}}case"getLogs":{const e={action:"getLogs"};if(t.filter.fromBlock&&(e.fromBlock=Fs(t.filter.fromBlock)),t.filter.toBlock&&(e.toBlock=Fs(t.filter.toBlock)),t.filter.address&&(e.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Bs.throwError("unsupported topic count",b.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),1===t.filter.topics.length)){const r=t.filter.topics[0];"string"==typeof r&&66===r.length||Bs.throwError("unsupported topic format",b.errors.UNSUPPORTED_OPERATION,{topic0:r}),e.topic0=r}const r=yield this.fetch("logs",e);let n={};for(let e=0;e{["contractAddress","to"].forEach((function(t){""==e[t]&&delete e[t]})),null==e.creates&&null!=e.contractAddress&&(e.creates=e.contractAddress);const t=this.formatter.transactionResponse(e);return e.timeStamp&&(t.timestamp=parseInt(e.timeStamp)),t}))}))}isCommunityResource(){return null==this.apiKey}}function Hs(e){for(let t=(e=e.slice()).length-1;t>0;t--){const r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}return e}var Js=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))};const zs=new b(ka);function Gs(){return(new Date).getTime()}function qs(e){let t=null;for(let r=0;rt?null:(n+i)/2}function Vs(e){if(null===e)return"null";if("number"==typeof e||"boolean"==typeof e)return JSON.stringify(e);if("string"==typeof e)return e;if(X.isBigNumber(e))return e.toString();if(Array.isArray(e))return JSON.stringify(e.map((e=>Vs(e))));if("object"==typeof e){const t=Object.keys(e);return t.sort(),"{"+t.map((t=>{let r=e[t];return r="function"==typeof r?"[function]":Vs(r),JSON.stringify(t)+":"+r})).join(",")+"}"}throw new Error("unknown value type: "+typeof e)}let Xs=1;function Qs(e){let t=null,r=null,n=new Promise((n=>{t=function(){r&&(clearTimeout(r),r=null),n()},r=setTimeout(t,e)}));return{cancel:t,getPromise:function(){return n},wait:e=>(n=n.then(e),n)}}const Ws=[b.errors.CALL_EXCEPTION,b.errors.INSUFFICIENT_FUNDS,b.errors.NONCE_EXPIRED,b.errors.REPLACEMENT_UNDERPRICED,b.errors.UNPREDICTABLE_GAS_LIMIT],Zs=["address","args","errorArgs","errorSignature","method","transaction"];function Ys(e,t){const r={weight:e.weight};return Object.defineProperty(r,"provider",{get:()=>e.provider}),e.start&&(r.start=e.start),t&&(r.duration=t-e.start),e.done&&(e.error?r.error=e.error:r.result=e.result||null),r}function $s(e,t,r){let n=Vs;switch(t){case"getBlockNumber":return function(t){const r=t.map((e=>e.result));let n=Ks(t.map((e=>e.result)),2);if(null!=n)return n=Math.ceil(n),r.indexOf(n+1)>=0&&n++,n>=e._highestBlockNumber&&(e._highestBlockNumber=n),e._highestBlockNumber};case"getGasPrice":return function(e){const t=e.map((e=>e.result));return t.sort(),t[Math.floor(t.length/2)]};case"getEtherPrice":return function(e){return Ks(e.map((e=>e.result)))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(e){return null==e?null:((e=oe(e)).confirmations=-1,Vs(e))};break;case"getBlock":n=r.includeTransactions?function(e){return null==e?null:((e=oe(e)).transactions=e.transactions.map((e=>((e=oe(e)).confirmations=-1,e))),Vs(e))}:function(e){return null==e?null:Vs(e)};break;default:throw new Error("unknown method: "+t)}return function(e,t){return function(r){const n={};r.forEach((t=>{const r=e(t.result);n[r]||(n[r]={count:0,result:t.result}),n[r].count++}));const i=Object.keys(n);for(let e=0;e=t)return r.result}}}(n,e.quorum)}function eu(e,t){return Js(this,void 0,void 0,(function*(){const r=e.provider;return null!=r.blockNumber&&r.blockNumber>=t||-1===t?r:wa((()=>new Promise(((n,i)=>{setTimeout((function(){return r.blockNumber>=t?n(r):e.cancelled?n(null):n(void 0)}),0)}))),{oncePoll:r})}))}function tu(e,t,r,n){return Js(this,void 0,void 0,(function*(){let i=e.provider;switch(r){case"getBlockNumber":case"getGasPrice":return i[r]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),i[r](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&P(n.blockTag)&&(i=yield eu(e,t)),"call"===r&&n.blockTag?i[r](n.transaction,n.blockTag):i[r](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[r](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&P(r.fromBlock)||r.toBlock&&P(r.toBlock))&&(i=yield eu(e,t)),i.getLogs(r)}}return zs.throwError("unknown method error",b.errors.UNKNOWN_ERROR,{method:r,params:n})}))}class ru extends $a{constructor(e,t){0===e.length&&zs.throwArgumentError("missing providers","providers",e);const r=e.map(((e,t)=>{if(or.isProvider(e)){const t=Ta(e)?2e3:750,r=1;return Object.freeze({provider:e,weight:1,stallTimeout:t,priority:r})}const r=oe(e);null==r.priority&&(r.priority=1),null==r.stallTimeout&&(r.stallTimeout=Ta(e)?2e3:750),null==r.weight&&(r.weight=1);const n=r.weight;return(n%1||n>512||n<1)&&zs.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${t}].weight`,n),Object.freeze(r)})),n=r.reduce(((e,t)=>e+t.weight),0);null==t?t=n/2:t>n&&zs.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let i=qs(r.map((e=>e.provider.network)));null==i&&(i=new Promise(((e,t)=>{setTimeout((()=>{this.detectNetwork().then(e,t)}),0)}))),super(i),te(this,"providerConfigs",Object.freeze(r)),te(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return Js(this,void 0,void 0,(function*(){return qs(yield Promise.all(this.providerConfigs.map((e=>e.provider.getNetwork()))))}))}perform(e,t){return Js(this,void 0,void 0,(function*(){if("sendTransaction"===e){const e=yield Promise.all(this.providerConfigs.map((e=>e.provider.sendTransaction(t.signedTransaction).then((e=>e.hash),(e=>e)))));for(let t=0;te.priority-t.priority));const i=this._highestBlockNumber;let o=0,a=!0;for(;;){const s=Gs();let u=n.filter((e=>e.runner&&s-e.starte+t.weight),0);for(;u{r.staller=null})),r.runner=tu(r,i,e,t).then((n=>{r.done=!0,r.result=n,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:a,backend:Ys(r,Gs()),request:{method:e,params:ce(t)},provider:this})}),(n=>{r.done=!0,r.error=n,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:a,backend:Ys(r,Gs()),request:{method:e,params:ce(t)},provider:this})})),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:a,backend:Ys(r,null),request:{method:e,params:ce(t)},provider:this}),u+=r.weight}const c=[];n.forEach((e=>{!e.done&&e.runner&&(c.push(e.runner),e.staller&&c.push(e.staller.getPromise()))})),c.length&&(yield Promise.race(c));const l=n.filter((e=>e.done&&null==e.error));if(l.length>=this.quorum){const e=r(l);if(void 0!==e)return n.forEach((e=>{e.staller&&e.staller.cancel(),e.cancelled=!0})),e;a||(yield Qs(100).getPromise()),a=!1}const f=n.reduce(((e,t)=>{if(!t.done||null==t.error)return e;const r=t.error.code;return Ws.indexOf(r)>=0&&(e[r]||(e[r]={error:t.error,weight:0}),e[r].weight+=t.weight),e}),{});if(Object.keys(f).forEach((e=>{const t=f[e];if(t.weight{e.staller&&e.staller.cancel(),e.cancelled=!0}));const r=t.error,i={};Zs.forEach((e=>{null!=r[e]&&(i[e]=r[e])})),zs.throwError(r.reason||r.message,e,i)})),0===n.filter((e=>!e.done)).length)break}return n.forEach((e=>{e.staller&&e.staller.cancel(),e.cancelled=!0})),zs.throwError("failed to meet quorum",b.errors.SERVER_ERROR,{method:e,params:t,results:n.map((e=>Ys(e))),provider:this})}))}}const nu=null,iu=new b(ka),ou="84842078b09946638c03157f83405213";class au extends gs{constructor(e,t){const r=new su(e,t),n=r.connection;n.password&&iu.throwError("INFURA WebSocket project secrets unsupported",b.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});super(n.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/"),e),te(this,"apiKey",r.projectId),te(this,"projectId",r.projectId),te(this,"projectSecret",r.projectSecret)}isCommunityResource(){return this.projectId===ou}}class su extends As{static getWebSocketProvider(e,t){return new au(e,t)}static getApiKey(e){const t={apiKey:ou,projectId:ou,projectSecret:null};return null==e||("string"==typeof e?t.projectId=e:null!=e.projectSecret?(iu.assertArgument("string"==typeof e.projectId,"projectSecret requires a projectId","projectId",e.projectId),iu.assertArgument("string"==typeof e.projectSecret,"invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let r=null;switch(e?e.name:"unknown"){case"homestead":r="mainnet.infura.io";break;case"goerli":r="goerli.infura.io";break;case"sepolia":r="sepolia.infura.io";break;case"matic":r="polygon-mainnet.infura.io";break;case"maticmum":r="polygon-mumbai.infura.io";break;case"optimism":r="optimism-mainnet.infura.io";break;case"optimism-goerli":r="optimism-goerli.infura.io";break;case"arbitrum":r="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":r="arbitrum-goerli.infura.io";break;default:iu.throwError("unsupported network",b.errors.INVALID_ARGUMENT,{argument:"network",value:e})}const n={allowGzip:!0,url:"https://"+r+"/v3/"+t.projectId,throttleCallback:(e,r)=>(t.projectId===ou&&Pa(),Promise.resolve(!0))};return null!=t.projectSecret&&(n.user="",n.password=t.projectSecret),n}isCommunityResource(){return this.projectId===ou}}class uu extends hs{send(e,t){const r={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};null==this._pendingBatch&&(this._pendingBatch=[]);const n={request:r,resolve:null,reject:null},i=new Promise(((e,t)=>{n.resolve=e,n.reject=t}));return this._pendingBatch.push(n),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout((()=>{const e=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;const t=e.map((e=>e.request));return this.emit("debug",{action:"requestBatch",request:ce(t),provider:this}),va(this.connection,JSON.stringify(t)).then((r=>{this.emit("debug",{action:"response",request:t,response:r,provider:this}),e.forEach(((e,t)=>{const n=r[t];if(n.error){const t=new Error(n.error.message);t.code=n.error.code,t.data=n.error.data,e.reject(t)}else e.resolve(n.result)}))}),(r=>{this.emit("debug",{action:"response",error:r,request:t,provider:this}),e.forEach((e=>{e.reject(r)}))}))}),10)),i}}const cu=new b(ka);class lu extends As{static getApiKey(e){return e&&"string"!=typeof e&&cu.throwArgumentError("invalid apiKey","apiKey",e),e||"ETHERS_JS_SHARED"}static getUrl(e,t){cu.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let r=null;switch(e.name){case"homestead":r="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":r="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":r="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":r="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":r="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:cu.throwArgumentError("unsupported network","network",arguments[0])}return r+"?apiKey="+t}}const fu=new b(ka),hu="62e1ad51b37b8e00394bda3b";class du extends As{static getApiKey(e){const t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return null==e?t.applicationId=hu:"string"==typeof e?t.applicationId=e:null!=e.applicationSecretKey?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:fu.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let r=null;switch(e?e.name:"unknown"){case"goerli":r="eth-goerli.gateway.pokt.network";break;case"homestead":r="eth-mainnet.gateway.pokt.network";break;case"kovan":r="poa-kovan.gateway.pokt.network";break;case"matic":r="poly-mainnet.gateway.pokt.network";break;case"maticmum":r="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":r="eth-rinkeby.gateway.pokt.network";break;case"ropsten":r="eth-ropsten.gateway.pokt.network";break;default:fu.throwError("unsupported network",b.errors.INVALID_ARGUMENT,{argument:"network",value:e})}const n={headers:{},url:`https://${r}/v1/lb/${t.applicationId}`};return null!=t.applicationSecretKey&&(n.user="",n.password=t.applicationSecretKey),n}isCommunityResource(){return this.applicationId===hu}}const pu=new b(ka);let mu=1;function yu(e,t){const r="Web3LegacyFetcher";return function(e,n){const i={method:e,params:n,id:mu++,jsonrpc:"2.0"};return new Promise(((e,n)=>{this.emit("debug",{action:"request",fetcher:r,request:ce(i),provider:this}),t(i,((t,o)=>{if(t)return this.emit("debug",{action:"response",fetcher:r,error:t,request:i,provider:this}),n(t);if(this.emit("debug",{action:"response",fetcher:r,request:i,response:o,provider:this}),o.error){const e=new Error(o.error.message);return e.code=o.error.code,e.data=o.error.data,n(e)}e(o.result)}))}))}}class gu extends hs{constructor(e,t){null==e&&pu.throwArgumentError("missing provider","provider",e);let r=null,n=null,i=null;"function"==typeof e?(r="unknown:",n=e):(r=e.host||e.path||"",!r&&e.isMetaMask&&(r="metamask"),i=e,e.request?(""===r&&(r="eip-1193:"),n=function(e){return function(t,r){null==r&&(r=[]);const n={method:t,params:r};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:ce(n),provider:this}),e.request(n).then((e=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:e,provider:this}),e)),(e=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:e,provider:this}),e}))}}(e)):e.sendAsync?n=yu(0,e.sendAsync.bind(e)):e.send?n=yu(0,e.send.bind(e)):pu.throwArgumentError("unsupported provider","provider",e),r||(r="unknown:")),super(r,t),te(this,"jsonRpcFetchFunc",n),te(this,"provider",i)}send(e,t){return this.jsonRpcFetchFunc(e,t)}}const bu=new b(ka);function vu(e,t){if(null==e&&(e="homestead"),"string"==typeof e){const t=e.match(/^(ws|http)s?:/i);if(t)switch(t[1].toLowerCase()){case"http":case"https":return new hs(e);case"ws":case"wss":return new gs(e);default:bu.throwArgumentError("unsupported URL scheme","network",e)}}const r=Uo(e);return r&&r._defaultProvider||bu.throwError("unsupported getDefaultProvider network",b.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:e}),r._defaultProvider({FallbackProvider:ru,AlchemyProvider:_s,AnkrProvider:Ps,CloudflareProvider:Rs,EtherscanProvider:js,InfuraProvider:su,JsonRpcProvider:hs,NodesmithProvider:lu,PocketProvider:du,Web3Provider:gu,IpcProvider:nu},t)}const wu=new RegExp("^bytes([0-9]+)$"),Au=new RegExp("^(u?int)([0-9]*)$"),Su=new RegExp("^(.*)\\[([0-9]*)\\]$"),ku=new b("solidity/5.7.0");function Eu(e,t,r){switch(e){case"address":return r?x(t,32):_(t);case"string":return qe(t);case"bytes":return _(t);case"bool":return t=t?"0x01":"0x00",r?x(t,32):_(t)}let n=e.match(Au);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!=0||0===i||i>256)&&ku.throwArgumentError("invalid number type","type",e),r&&(i=256),x(t=X.from(t).toTwos(i),i/8)}if(n=e.match(wu),n){const i=parseInt(n[1]);return(String(i)!==n[1]||0===i||i>32)&&ku.throwArgumentError("invalid bytes type","type",e),_(t).byteLength!==i&&ku.throwArgumentError(`invalid value for ${e}`,"value",t),r?_((t+"0000000000000000000000000000000000000000000000000000000000000000").substring(0,66)):t}if(n=e.match(Su),n&&Array.isArray(t)){const r=n[1];parseInt(n[2]||String(t.length))!=t.length&&ku.throwArgumentError(`invalid array length for ${e}`,"value",t);const i=[];return t.forEach((function(e){i.push(Eu(r,e,!0))})),M(i)}return ku.throwArgumentError("invalid type","type",e)}function _u(e,t){e.length!=t.length&&ku.throwArgumentError("wrong number of values; expected ${ types.length }","values",t);const r=[];return e.forEach((function(e,n){r.push(Eu(e,t[n]))})),O(M(r))}function Mu(e,t){return ve(_u(e,t))}function Tu(e,t){return vi(_u(e,t))}function xu(e,t){t||(t=function(e){return[parseInt(e,16)]});let r=0,n={};return e.split(",").forEach((e=>{let i=e.split(":");r+=parseInt(i[0],16),n[r]=t(i[1])})),n}function Pu(e){let t=0;return e.split(",").map((e=>{let r=e.split("-");1===r.length?r[1]="0":""===r[1]&&(r[1]="1");let n=t+parseInt(r[0],16);return t=parseInt(r[1],16),{l:n,h:t}}))}function Iu(e,t){let r=0;for(let n=0;n=r&&e<=r+i.h&&(e-r)%(i.d||1)==0){if(i.e&&-1!==i.e.indexOf(e-r))continue;return i}}return null}const Ou=Pu("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),Ru="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((e=>parseInt(e,16))),Cu=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],Bu=xu("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),Nu=xu("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),Lu=xu("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",(function(e){if(e.length%4!=0)throw new Error("bad data");let t=[];for(let r=0;r{if(Ru.indexOf(e)>=0)return[];if(e>=65024&&e<=65039)return[];let t=function(e){let t=Iu(e,Cu);if(t)return[e+t.s];let r=Bu[e];if(r)return r;let n=Nu[e];return n?[e+n[0]]:Lu[e]||null}(e);return t||[e]})),t=r.reduce(((e,t)=>(t.forEach((t=>{e.push(t)})),e)),[]),t=We(Xe(t),je.NFKC),t.forEach((e=>{if(Iu(e,Uu))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),t.forEach((e=>{if(Iu(e,Ou))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));let n=Xe(t);if("-"===n.substring(0,1)||"--"===n.substring(2,4)||"-"===n.substring(n.length-1))throw new Error("invalid hyphen");return n}function Du(e){const t=qe(e);if(t.length>31)throw new Error("bytes32 string must be less than 32 bytes");return O(M([t,xo]).slice(0,32))}function ju(e){const t=_(e);if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");let r=31;for(;0===t[r-1];)r--;return Qe(t.slice(0,r))}const Hu=new b("units/5.7.0"),Ju=["wei","kwei","mwei","gwei","szabo","finney","ether"];function zu(e){const t=String(e).split(".");(t.length>2||!t[0].match(/^-?[0-9]*$/)||t[1]&&!t[1].match(/^[0-9]*$/)||"."===e||"-."===e)&&Hu.throwArgumentError("invalid value","value",e);let r=t[0],n="";for("-"===r.substring(0,1)&&(n="-",r=r.substring(1));"0"===r.substring(0,1);)r=r.substring(1);""===r&&(r="0");let i="";for(2===t.length&&(i="."+(t[1]||"0"));i.length>2&&"0"===i[i.length-1];)i=i.substring(0,i.length-1);const o=[];for(;r.length;){if(r.length<=3){o.unshift(r);break}{const e=r.length-3;o.unshift(r.substring(e)),r=r.substring(0,e)}}return n+o.join(",")+i}function Gu(e,t){if("string"==typeof t){const e=Ju.indexOf(t);-1!==e&&(t=3*e)}return Gn(e,null!=t?t:18)}function qu(e,t){if("string"!=typeof e&&Hu.throwArgumentError("value must be a string","value",e),"string"==typeof t){const e=Ju.indexOf(t);-1!==e&&(t=3*e)}return qn(e,null!=t?t:18)}function Ku(e){return Gu(e,18)}function Vu(e){return qu(e,18)}const Xu="ethers/5.7.2",Qu=new b(Xu);try{const e=window;null==e._ethers&&(e._ethers=u)}catch(e){}},88459:(e,t,r)=>{const n=r(54099);e.exports=async function(e){return n.utils.sha256(n.utils.toUtf8Bytes(e))}},9669:(e,t,r)=>{e.exports=r(51609)},55448:(e,t,r)=>{"use strict";var n=r(64867),i=r(36026),o=r(4372),a=r(15327),s=r(94097),u=r(84109),c=r(67985),l=r(77874),f=r(82648),h=r(60644),d=r(90205);e.exports=function(e){return new Promise((function(t,r){var p,m=e.data,y=e.headers,g=e.responseType;function b(){e.cancelToken&&e.cancelToken.unsubscribe(p),e.signal&&e.signal.removeEventListener("abort",p)}n.isFormData(m)&&n.isStandardBrowserEnv()&&delete y["Content-Type"];var v=new XMLHttpRequest;if(e.auth){var w=e.auth.username||"",A=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";y.Authorization="Basic "+btoa(w+":"+A)}var S=s(e.baseURL,e.url);function k(){if(v){var n="getAllResponseHeaders"in v?u(v.getAllResponseHeaders()):null,o={data:g&&"text"!==g&&"json"!==g?v.response:v.responseText,status:v.status,statusText:v.statusText,headers:n,config:e,request:v};i((function(e){t(e),b()}),(function(e){r(e),b()}),o),v=null}}if(v.open(e.method.toUpperCase(),a(S,e.params,e.paramsSerializer),!0),v.timeout=e.timeout,"onloadend"in v?v.onloadend=k:v.onreadystatechange=function(){v&&4===v.readyState&&(0!==v.status||v.responseURL&&0===v.responseURL.indexOf("file:"))&&setTimeout(k)},v.onabort=function(){v&&(r(new f("Request aborted",f.ECONNABORTED,e,v)),v=null)},v.onerror=function(){r(new f("Network Error",f.ERR_NETWORK,e,v,v)),v=null},v.ontimeout=function(){var t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded",n=e.transitional||l;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),r(new f(t,n.clarifyTimeoutError?f.ETIMEDOUT:f.ECONNABORTED,e,v)),v=null},n.isStandardBrowserEnv()){var E=(e.withCredentials||c(S))&&e.xsrfCookieName?o.read(e.xsrfCookieName):void 0;E&&(y[e.xsrfHeaderName]=E)}"setRequestHeader"in v&&n.forEach(y,(function(e,t){void 0===m&&"content-type"===t.toLowerCase()?delete y[t]:v.setRequestHeader(t,e)})),n.isUndefined(e.withCredentials)||(v.withCredentials=!!e.withCredentials),g&&"json"!==g&&(v.responseType=e.responseType),"function"==typeof e.onDownloadProgress&&v.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&v.upload&&v.upload.addEventListener("progress",e.onUploadProgress),(e.cancelToken||e.signal)&&(p=function(e){v&&(r(!e||e&&e.type?new h:e),v.abort(),v=null)},e.cancelToken&&e.cancelToken.subscribe(p),e.signal&&(e.signal.aborted?p():e.signal.addEventListener("abort",p))),m||(m=null);var _=d(S);_&&-1===["http","https","file"].indexOf(_)?r(new f("Unsupported protocol "+_+":",f.ERR_BAD_REQUEST,e)):v.send(m)}))}},51609:(e,t,r)=>{"use strict";var n=r(64867),i=r(91849),o=r(30321),a=r(47185);var s=function e(t){var r=new o(t),s=i(o.prototype.request,r);return n.extend(s,o.prototype,r),n.extend(s,r),s.create=function(r){return e(a(t,r))},s}(r(45546));s.Axios=o,s.CanceledError=r(60644),s.CancelToken=r(14972),s.isCancel=r(26502),s.VERSION=r(97288).version,s.toFormData=r(47675),s.AxiosError=r(82648),s.Cancel=s.CanceledError,s.all=function(e){return Promise.all(e)},s.spread=r(8713),s.isAxiosError=r(16268),e.exports=s,e.exports.default=s},14972:(e,t,r)=>{"use strict";var n=r(60644);function i(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var r=this;this.promise.then((function(e){if(r._listeners){var t,n=r._listeners.length;for(t=0;t{"use strict";var n=r(82648);function i(e){n.call(this,null==e?"canceled":e,n.ERR_CANCELED),this.name="CanceledError"}r(64867).inherits(i,n,{__CANCEL__:!0}),e.exports=i},26502:e=>{"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},30321:(e,t,r)=>{"use strict";var n=r(64867),i=r(15327),o=r(80782),a=r(13572),s=r(47185),u=r(94097),c=r(54875),l=c.validators;function f(e){this.defaults=e,this.interceptors={request:new o,response:new o}}f.prototype.request=function(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},(t=s(this.defaults,t)).method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var r=t.transitional;void 0!==r&&c.assertOptions(r,{silentJSONParsing:l.transitional(l.boolean),forcedJSONParsing:l.transitional(l.boolean),clarifyTimeoutError:l.transitional(l.boolean)},!1);var n=[],i=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(i=i&&e.synchronous,n.unshift(e.fulfilled,e.rejected))}));var o,u=[];if(this.interceptors.response.forEach((function(e){u.push(e.fulfilled,e.rejected)})),!i){var f=[a,void 0];for(Array.prototype.unshift.apply(f,n),f=f.concat(u),o=Promise.resolve(t);f.length;)o=o.then(f.shift(),f.shift());return o}for(var h=t;n.length;){var d=n.shift(),p=n.shift();try{h=d(h)}catch(e){p(e);break}}try{o=a(h)}catch(e){return Promise.reject(e)}for(;u.length;)o=o.then(u.shift(),u.shift());return o},f.prototype.getUri=function(e){e=s(this.defaults,e);var t=u(e.baseURL,e.url);return i(t,e.params,e.paramsSerializer)},n.forEach(["delete","get","head","options"],(function(e){f.prototype[e]=function(t,r){return this.request(s(r||{},{method:e,url:t,data:(r||{}).data}))}})),n.forEach(["post","put","patch"],(function(e){function t(t){return function(r,n,i){return this.request(s(i||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:n}))}}f.prototype[e]=t(),f.prototype[e+"Form"]=t(!0)})),e.exports=f},82648:(e,t,r)=>{"use strict";var n=r(64867);function i(e,t,r,n,i){Error.call(this),this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i)}n.inherits(i,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var o=i.prototype,a={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach((function(e){a[e]={value:e}})),Object.defineProperties(i,a),Object.defineProperty(o,"isAxiosError",{value:!0}),i.from=function(e,t,r,a,s,u){var c=Object.create(o);return n.toFlatObject(e,c,(function(e){return e!==Error.prototype})),i.call(c,e.message,t,r,a,s),c.name=e.name,u&&Object.assign(c,u),c},e.exports=i},80782:(e,t,r)=>{"use strict";var n=r(64867);function i(){this.handlers=[]}i.prototype.use=function(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1},i.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},i.prototype.forEach=function(e){n.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=i},94097:(e,t,r)=>{"use strict";var n=r(91793),i=r(7303);e.exports=function(e,t){return e&&!n(t)?i(e,t):t}},13572:(e,t,r)=>{"use strict";var n=r(64867),i=r(18527),o=r(26502),a=r(45546),s=r(60644);function u(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new s}e.exports=function(e){return u(e),e.headers=e.headers||{},e.data=i.call(e,e.data,e.headers,e.transformRequest),e.headers=n.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),n.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]})),(e.adapter||a.adapter)(e).then((function(t){return u(e),t.data=i.call(e,t.data,t.headers,e.transformResponse),t}),(function(t){return o(t)||(u(e),t&&t.response&&(t.response.data=i.call(e,t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},47185:(e,t,r)=>{"use strict";var n=r(64867);e.exports=function(e,t){t=t||{};var r={};function i(e,t){return n.isPlainObject(e)&&n.isPlainObject(t)?n.merge(e,t):n.isPlainObject(t)?n.merge({},t):n.isArray(t)?t.slice():t}function o(r){return n.isUndefined(t[r])?n.isUndefined(e[r])?void 0:i(void 0,e[r]):i(e[r],t[r])}function a(e){if(!n.isUndefined(t[e]))return i(void 0,t[e])}function s(r){return n.isUndefined(t[r])?n.isUndefined(e[r])?void 0:i(void 0,e[r]):i(void 0,t[r])}function u(r){return r in t?i(e[r],t[r]):r in e?i(void 0,e[r]):void 0}var c={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:u};return n.forEach(Object.keys(e).concat(Object.keys(t)),(function(e){var t=c[e]||o,i=t(e);n.isUndefined(i)&&t!==u||(r[e]=i)})),r}},36026:(e,t,r)=>{"use strict";var n=r(82648);e.exports=function(e,t,r){var i=r.config.validateStatus;r.status&&i&&!i(r.status)?t(new n("Request failed with status code "+r.status,[n.ERR_BAD_REQUEST,n.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r)):e(r)}},18527:(e,t,r)=>{"use strict";var n=r(64867),i=r(45546);e.exports=function(e,t,r){var o=this||i;return n.forEach(r,(function(r){e=r.call(o,e,t)})),e}},45546:(e,t,r)=>{"use strict";var n=r(34155),i=r(64867),o=r(16016),a=r(82648),s=r(77874),u=r(47675),c={"Content-Type":"application/x-www-form-urlencoded"};function l(e,t){!i.isUndefined(e)&&i.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var f,h={transitional:s,adapter:(("undefined"!=typeof XMLHttpRequest||void 0!==n&&"[object process]"===Object.prototype.toString.call(n))&&(f=r(55448)),f),transformRequest:[function(e,t){if(o(t,"Accept"),o(t,"Content-Type"),i.isFormData(e)||i.isArrayBuffer(e)||i.isBuffer(e)||i.isStream(e)||i.isFile(e)||i.isBlob(e))return e;if(i.isArrayBufferView(e))return e.buffer;if(i.isURLSearchParams(e))return l(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString();var r,n=i.isObject(e),a=t&&t["Content-Type"];if((r=i.isFileList(e))||n&&"multipart/form-data"===a){var s=this.env&&this.env.FormData;return u(r?{"files[]":e}:e,s&&new s)}return n||"application/json"===a?(l(t,"application/json"),function(e,t,r){if(i.isString(e))try{return(t||JSON.parse)(e),i.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(r||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){var t=this.transitional||h.transitional,r=t&&t.silentJSONParsing,n=t&&t.forcedJSONParsing,o=!r&&"json"===this.responseType;if(o||n&&i.isString(e)&&e.length)try{return JSON.parse(e)}catch(e){if(o){if("SyntaxError"===e.name)throw a.from(e,a.ERR_BAD_RESPONSE,this,null,this.response);throw e}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:r(91623)},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};i.forEach(["delete","get","head"],(function(e){h.headers[e]={}})),i.forEach(["post","put","patch"],(function(e){h.headers[e]=i.merge(c)})),e.exports=h},77874:e=>{"use strict";e.exports={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1}},97288:e=>{e.exports={version:"0.27.2"}},91849:e=>{"use strict";e.exports=function(e,t){return function(){for(var r=new Array(arguments.length),n=0;n{"use strict";var n=r(64867);function i(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}e.exports=function(e,t,r){if(!t)return e;var o;if(r)o=r(t);else if(n.isURLSearchParams(t))o=t.toString();else{var a=[];n.forEach(t,(function(e,t){null!=e&&(n.isArray(e)?t+="[]":e=[e],n.forEach(e,(function(e){n.isDate(e)?e=e.toISOString():n.isObject(e)&&(e=JSON.stringify(e)),a.push(i(t)+"="+i(e))})))})),o=a.join("&")}if(o){var s=e.indexOf("#");-1!==s&&(e=e.slice(0,s)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}},7303:e=>{"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},4372:(e,t,r)=>{"use strict";var n=r(64867);e.exports=n.isStandardBrowserEnv()?{write:function(e,t,r,i,o,a){var s=[];s.push(e+"="+encodeURIComponent(t)),n.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),n.isString(i)&&s.push("path="+i),n.isString(o)&&s.push("domain="+o),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},91793:e=>{"use strict";e.exports=function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}},16268:(e,t,r)=>{"use strict";var n=r(64867);e.exports=function(e){return n.isObject(e)&&!0===e.isAxiosError}},67985:(e,t,r)=>{"use strict";var n=r(64867);e.exports=n.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");function i(e){var n=e;return t&&(r.setAttribute("href",n),n=r.href),r.setAttribute("href",n),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:"/"===r.pathname.charAt(0)?r.pathname:"/"+r.pathname}}return e=i(window.location.href),function(t){var r=n.isString(t)?i(t):t;return r.protocol===e.protocol&&r.host===e.host}}():function(){return!0}},16016:(e,t,r)=>{"use strict";var n=r(64867);e.exports=function(e,t){n.forEach(e,(function(r,n){n!==t&&n.toUpperCase()===t.toUpperCase()&&(e[t]=r,delete e[n])}))}},91623:e=>{e.exports=null},84109:(e,t,r)=>{"use strict";var n=r(64867),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,r,o,a={};return e?(n.forEach(e.split("\n"),(function(e){if(o=e.indexOf(":"),t=n.trim(e.substr(0,o)).toLowerCase(),r=n.trim(e.substr(o+1)),t){if(a[t]&&i.indexOf(t)>=0)return;a[t]="set-cookie"===t?(a[t]?a[t]:[]).concat([r]):a[t]?a[t]+", "+r:r}})),a):a}},90205:e=>{"use strict";e.exports=function(e){var t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}},8713:e=>{"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},47675:(e,t,r)=>{"use strict";var n=r(48764).Buffer,i=r(64867);e.exports=function(e,t){t=t||new FormData;var r=[];function o(e){return null===e?"":i.isDate(e)?e.toISOString():i.isArrayBuffer(e)||i.isTypedArray(e)?"function"==typeof Blob?new Blob([e]):n.from(e):e}return function e(n,a){if(i.isPlainObject(n)||i.isArray(n)){if(-1!==r.indexOf(n))throw Error("Circular reference detected in "+a);r.push(n),i.forEach(n,(function(r,n){if(!i.isUndefined(r)){var s,u=a?a+"."+n:n;if(r&&!a&&"object"==typeof r)if(i.endsWith(n,"{}"))r=JSON.stringify(r);else if(i.endsWith(n,"[]")&&(s=i.toArray(r)))return void s.forEach((function(e){!i.isUndefined(e)&&t.append(u,o(e))}));e(r,u)}})),r.pop()}else t.append(a,o(n))}(e),t}},54875:(e,t,r)=>{"use strict";var n=r(97288).version,i=r(82648),o={};["object","boolean","number","function","string","symbol"].forEach((function(e,t){o[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}}));var a={};o.transitional=function(e,t,r){function o(e,t){return"[Axios v"+n+"] Transitional option '"+e+"'"+t+(r?". "+r:"")}return function(r,n,s){if(!1===e)throw new i(o(n," has been removed"+(t?" in "+t:"")),i.ERR_DEPRECATED);return t&&!a[n]&&(a[n]=!0,console.warn(o(n," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(r,n,s)}},e.exports={assertOptions:function(e,t,r){if("object"!=typeof e)throw new i("options must be an object",i.ERR_BAD_OPTION_VALUE);for(var n=Object.keys(e),o=n.length;o-- >0;){var a=n[o],s=t[a];if(s){var u=e[a],c=void 0===u||s(u,a,e);if(!0!==c)throw new i("option "+a+" must be "+c,i.ERR_BAD_OPTION_VALUE)}else if(!0!==r)throw new i("Unknown option "+a,i.ERR_BAD_OPTION)}},validators:o}},64867:(e,t,r)=>{"use strict";var n,i=r(91849),o=Object.prototype.toString,a=(n=Object.create(null),function(e){var t=o.call(e);return n[t]||(n[t]=t.slice(8,-1).toLowerCase())});function s(e){return e=e.toLowerCase(),function(t){return a(t)===e}}function u(e){return Array.isArray(e)}function c(e){return void 0===e}var l=s("ArrayBuffer");function f(e){return null!==e&&"object"==typeof e}function h(e){if("object"!==a(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}var d=s("Date"),p=s("File"),m=s("Blob"),y=s("FileList");function g(e){return"[object Function]"===o.call(e)}var b=s("URLSearchParams");function v(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),u(e))for(var r=0,n=e.length;r0;)a[o=n[i]]||(t[o]=e[o],a[o]=!0);e=Object.getPrototypeOf(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},kindOf:a,kindOfTest:s,endsWith:function(e,t,r){e=String(e),(void 0===r||r>e.length)&&(r=e.length),r-=t.length;var n=e.indexOf(t,r);return-1!==n&&n===r},toArray:function(e){if(!e)return null;var t=e.length;if(c(t))return null;for(var r=new Array(t);t-- >0;)r[t]=e[t];return r},isTypedArray:A,isFileList:y}},79742:(e,t)=>{"use strict";t.byteLength=function(e){var t=u(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,o=u(e),a=o[0],s=o[1],c=new i(function(e,t,r){return 3*(t+r)/4-r}(0,a,s)),l=0,f=s>0?a-4:a;for(r=0;r>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===s&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,c[l++]=255&t);1===s&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],a=16383,s=0,u=n-i;su?u:s+a));1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return o.join("")};for(var r=[],n=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=o.length;a0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function c(e,t,n){for(var i,o,a=[],s=t;s>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},92882:e=>{"use strict";for(var t="qpzry9x8gf2tvdw0s3jn54khce6mua7l",r={},n=0;n>25;return(33554431&e)<<5^996825010&-(t>>0&1)^642813549&-(t>>1&1)^513874426&-(t>>2&1)^1027748829&-(t>>3&1)^705979059&-(t>>4&1)}function a(e){for(var t=1,r=0;r126)return"Invalid prefix ("+e+")";t=o(t)^n>>5}for(t=o(t),r=0;rt)return"Exceeds length limit";var n=e.toLowerCase(),i=e.toUpperCase();if(e!==n&&e!==i)return"Mixed-case string "+e;var s=(e=n).lastIndexOf("1");if(-1===s)return"No separator character for "+e;if(0===s)return"Missing prefix for "+e;var u=e.slice(0,s),c=e.slice(s+1);if(c.length<6)return"Data too short";var l=a(u);if("string"==typeof l)return l;for(var f=[],h=0;h=c.length||f.push(p)}return 1!==l?"Invalid checksum for "+e:{prefix:u,words:f}}function u(e,t,r,n){for(var i=0,o=0,a=(1<=r;)o-=r,s.push(i>>o&a);if(n)o>0&&s.push(i<=t)return"Excess padding";if(i<n)throw new TypeError("Exceeds length limit");var i=a(e=e.toLowerCase());if("string"==typeof i)throw new Error(i);for(var s=e+"1",u=0;u>5!=0)throw new Error("Non 5-bit word");i=o(i)^c,s+=t.charAt(c)}for(u=0;u<6;++u)i=o(i);for(i^=1,u=0;u<6;++u){s+=t.charAt(i>>5*(5-u)&31)}return s},toWordsUnsafe:function(e){var t=u(e,8,5,!0);if(Array.isArray(t))return t},toWords:function(e){var t=u(e,8,5,!0);if(Array.isArray(t))return t;throw new Error(t)},fromWordsUnsafe:function(e){var t=u(e,5,8,!1);if(Array.isArray(t))return t},fromWords:function(e){var t=u(e,5,8,!1);if(Array.isArray(t))return t;throw new Error(t)}}},13550:function(e,t,r){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(46601).Buffer}catch(e){}function s(e,t){var r=e.charCodeAt(t);return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void n(!1,"Invalid character in "+e)}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,i){for(var o=0,a=0,s=Math.min(e.length,r),u=t;u=49?c-49+10:c>=17?c-17+10:c,n(c>=0&&a0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this._strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this._strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{o.prototype[Symbol.for("nodejs.util.inspect.custom")]=f}catch(e){o.prototype.inspect=f}else o.prototype.inspect=f;function f(){return(this.red?""}var h=["","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"],d=[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],p=[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];o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215,(i+=2)>=26&&(i-=26,a--),r=0!==o||a!==this.length-1?h[6-u.length]+u+r:u+r}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=d[e],l=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modrn(l).toString(e);r=(f=f.idivn(l)).isZero()?m+r:h[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16,2)},a&&(o.prototype.toBuffer=function(e,t){return this.toArrayLike(a,e,t)}),o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)};function m(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r._strip()}o.prototype.toArrayLike=function(e,t,r){this._strip();var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0");var a=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,o);return this["_toArrayLike"+("le"===t?"LE":"BE")](a,i),a},o.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,i=0,o=0;i>8&255),r>16&255),6===o?(r>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r=0&&(e[r--]=a>>8&255),r>=0&&(e[r--]=a>>16&255),6===o?(r>=0&&(e[r--]=a>>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this._strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function g(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r._strip()}function b(e,t,r){return g(e,t,r)}function v(e,t){this.x=e,this.y=t}Math.imul||(y=m),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?y(this,e,t):r<63?m(this,e,t):r<1024?g(this,e,t):b(this,e,t)},v.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},v.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,r+=o/67108864|0,r+=a>>>26,this.words[i]=67108863&a}return 0!==r&&(this.words[i]=r,this.length++),t?this.ineg():this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i&1}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this._strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this._strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modrn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modrn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=(1<<26)%e,i=0,o=this.length-1;o>=0;o--)i=(r*i+(0|this.words[o]))%e;return t?-i:i},o.prototype.modn=function(e){return this.modrn(e)},o.prototype.idivn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=0,i=this.length-1;i>=0;i--){var o=(0|this.words[i])+67108864*r;this.words[i]=o/e|0,r=o%e}return this._strip(),t?this.ineg():this},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new M(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var w={k256:null,p224:null,p192:null,p25519:null};function A(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function S(){A.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function k(){A.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function E(){A.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){A.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function T(e){M.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}A.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},A.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},A.prototype.split=function(e,t){e.iushrn(this.n,0,t)},A.prototype.imulK=function(e){return e.imul(this.k)},i(S,A),S.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},S.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(w[e])return w[e];var t;if("k256"===e)t=new S;else if("p224"===e)t=new k;else if("p192"===e)t=new E;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new _}return w[e]=t,t},M.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},M.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},M.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(l(e,e.umod(this.m)._forceRed(this)),e)},M.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},M.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},M.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},M.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},M.prototype.isqr=function(e){return this.imul(e,e.clone())},M.prototype.sqr=function(e){return this.mul(e,e)},M.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},M.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},M.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new T(e)},i(T,M),T.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},T.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},T.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},T.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},T.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},29931:(e,t,r)=>{var n;function i(e){this.rand=e}if(e.exports=function(e){return n||(n=new i(null)),n.generate(e)},e.exports.Rand=i,i.prototype.generate=function(e){return this._rand(e)},i.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r{var n=r(89509).Buffer;function i(e){n.isBuffer(e)||(e=n.from(e));for(var t=e.length/4|0,r=new Array(t),i=0;i>>24]^l[p>>>16&255]^f[m>>>8&255]^h[255&y]^t[g++],a=c[p>>>24]^l[m>>>16&255]^f[y>>>8&255]^h[255&d]^t[g++],s=c[m>>>24]^l[y>>>16&255]^f[d>>>8&255]^h[255&p]^t[g++],u=c[y>>>24]^l[d>>>16&255]^f[p>>>8&255]^h[255&m]^t[g++],d=o,p=a,m=s,y=u;return o=(n[d>>>24]<<24|n[p>>>16&255]<<16|n[m>>>8&255]<<8|n[255&y])^t[g++],a=(n[p>>>24]<<24|n[m>>>16&255]<<16|n[y>>>8&255]<<8|n[255&d])^t[g++],s=(n[m>>>24]<<24|n[y>>>16&255]<<16|n[d>>>8&255]<<8|n[255&p])^t[g++],u=(n[y>>>24]<<24|n[d>>>16&255]<<16|n[p>>>8&255]<<8|n[255&m])^t[g++],[o>>>=0,a>>>=0,s>>>=0,u>>>=0]}var s=[0,1,2,4,8,16,32,64,128,27,54],u=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],o=[[],[],[],[]],a=0,s=0,u=0;u<256;++u){var c=s^s<<1^s<<2^s<<3^s<<4;c=c>>>8^255&c^99,r[a]=c,n[c]=a;var l=e[a],f=e[l],h=e[f],d=257*e[c]^16843008*c;i[0][a]=d<<24|d>>>8,i[1][a]=d<<16|d>>>16,i[2][a]=d<<8|d>>>24,i[3][a]=d,d=16843009*h^65537*f^257*l^16843008*a,o[0][c]=d<<24|d>>>8,o[1][c]=d<<16|d>>>16,o[2][c]=d<<8|d>>>24,o[3][c]=d,0===a?a=s=1:(a=l^e[e[e[h^l]]],s^=e[e[s]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:o}}();function c(e){this._key=i(e),this._reset()}c.blockSize=16,c.keySize=32,c.prototype.blockSize=c.blockSize,c.prototype.keySize=c.keySize,c.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=4*(r+1),i=[],o=0;o>>24,a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a],a^=s[o/t|0]<<24):t>6&&o%t==4&&(a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a]),i[o]=i[o-t]^a}for(var c=[],l=0;l>>24]]^u.INV_SUB_MIX[1][u.SBOX[h>>>16&255]]^u.INV_SUB_MIX[2][u.SBOX[h>>>8&255]]^u.INV_SUB_MIX[3][u.SBOX[255&h]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=c},c.prototype.encryptBlockRaw=function(e){return a(e=i(e),this._keySchedule,u.SUB_MIX,u.SBOX,this._nRounds)},c.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=n.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},c.prototype.decryptBlock=function(e){var t=(e=i(e))[1];e[1]=e[3],e[3]=t;var r=a(e,this._invKeySchedule,u.INV_SUB_MIX,u.INV_SBOX,this._nRounds),o=n.allocUnsafe(16);return o.writeUInt32BE(r[0],0),o.writeUInt32BE(r[3],4),o.writeUInt32BE(r[2],8),o.writeUInt32BE(r[1],12),o},c.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},e.exports.AES=c},62422:(e,t,r)=>{var n=r(74497),i=r(89509).Buffer,o=r(71027),a=r(35717),s=r(83288),u=r(67295),c=r(20685);function l(e,t,r,a){o.call(this);var u=i.alloc(4,0);this._cipher=new n.AES(t);var l=this._cipher.encryptBlock(u);this._ghash=new s(l),r=function(e,t,r){if(12===t.length)return e._finID=i.concat([t,i.from([0,0,0,1])]),i.concat([t,i.from([0,0,0,2])]);var n=new s(r),o=t.length,a=o%16;n.update(t),a&&(a=16-a,n.update(i.alloc(a,0))),n.update(i.alloc(8,0));var u=8*o,l=i.alloc(8);l.writeUIntBE(u,0,8),n.update(l),e._finID=n.state;var f=i.from(e._finID);return c(f),f}(this,r,l),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}a(l,o),l.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=i.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},l.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=u(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i{var n=r(71494),i=r(66193),o=r(44946);t.createCipher=t.Cipher=n.createCipher,t.createCipheriv=t.Cipheriv=n.createCipheriv,t.createDecipher=t.Decipher=i.createDecipher,t.createDecipheriv=t.Decipheriv=i.createDecipheriv,t.listCiphers=t.getCiphers=function(){return Object.keys(o)}},66193:(e,t,r)=>{var n=r(62422),i=r(89509).Buffer,o=r(45),a=r(25969),s=r(71027),u=r(74497),c=r(13048);function l(e,t,r){s.call(this),this._cache=new f,this._last=void 0,this._cipher=new u.AES(t),this._prev=i.from(r),this._mode=e,this._autopadding=!0}function f(){this.cache=i.allocUnsafe(0)}function h(e,t,r){var s=o[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=i.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=i.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===s.type?new a(s.module,t,r,!0):"auth"===s.type?new n(s.module,t,r,!0):new l(s.module,t,r)}r(35717)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return i.concat(n)},l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");var r=-1;for(;++r16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},f.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=function(e,t){var r=o[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=c(t,!1,r.key,r.iv);return h(e,n.key,n.iv)},t.createDecipheriv=h},71494:(e,t,r)=>{var n=r(45),i=r(62422),o=r(89509).Buffer,a=r(25969),s=r(71027),u=r(74497),c=r(13048);function l(e,t,r){s.call(this),this._cache=new h,this._cipher=new u.AES(t),this._prev=o.from(r),this._mode=e,this._autopadding=!0}r(35717)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return o.concat(n)};var f=o.alloc(16,16);function h(){this.cache=o.allocUnsafe(0)}function d(e,t,r){var s=n[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=o.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof r&&(r=o.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);return"stream"===s.type?new a(s.module,t,r):"auth"===s.type?new i(s.module,t,r):new l(s.module,t,r)}l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(f))throw this._cipher.scrub(),new Error("data not multiple of block length")},l.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},h.prototype.add=function(e){this.cache=o.concat([this.cache,e])},h.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},h.prototype.flush=function(){for(var e=16-this.cache.length,t=o.allocUnsafe(e),r=-1;++r{var n=r(89509).Buffer,i=n.alloc(16,0);function o(e){var t=n.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function a(e){this.h=e,this.state=n.alloc(16,0),this.cache=n.allocUnsafe(0)}a.prototype.ghash=function(e){for(var t=-1;++t0;t--)n[t]=n[t]>>>1|(1&n[t-1])<<31;n[0]=n[0]>>>1,r&&(n[0]=n[0]^225<<24)}this.state=o(i)},a.prototype.update=function(e){var t;for(this.cache=n.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},a.prototype.final=function(e,t){return this.cache.length&&this.ghash(n.concat([this.cache,i],16)),this.ghash(o([0,e,0,t])),this.state},e.exports=a},20685:e=>{e.exports=function(e){for(var t,r=e.length;r--;){if(255!==(t=e.readUInt8(r))){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}},25292:(e,t,r)=>{var n=r(67295);t.encrypt=function(e,t){var r=n(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},t.decrypt=function(e,t){var r=e._prev;e._prev=t;var i=e._cipher.decryptBlock(t);return n(i,r)}},86311:(e,t,r)=>{var n=r(89509).Buffer,i=r(67295);function o(e,t,r){var o=t.length,a=i(t,e._cache);return e._cache=e._cache.slice(o),e._prev=n.concat([e._prev,r?t:a]),a}t.encrypt=function(e,t,r){for(var i,a=n.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=n.allocUnsafe(0)),!(e._cache.length<=t.length)){a=n.concat([a,o(e,t,r)]);break}i=e._cache.length,a=n.concat([a,o(e,t.slice(0,i),r)]),t=t.slice(i)}return a}},21510:(e,t,r)=>{var n=r(89509).Buffer;function i(e,t,r){for(var n,i,a=-1,s=0;++a<8;)n=t&1<<7-a?128:0,s+=(128&(i=e._cipher.encryptBlock(e._prev)[0]^n))>>a%8,e._prev=o(e._prev,r?n:i);return s}function o(e,t){var r=e.length,i=-1,o=n.allocUnsafe(e.length);for(e=n.concat([e,n.from([t])]);++i>7;return o}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{var n=r(89509).Buffer;function i(e,t,r){var i=e._cipher.encryptBlock(e._prev)[0]^t;return e._prev=n.concat([e._prev.slice(1),n.from([r?t:i])]),i}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{var n=r(67295),i=r(89509).Buffer,o=r(20685);function a(e){var t=e._cipher.encryptBlockRaw(e._prev);return o(e._prev),t}t.encrypt=function(e,t){var r=Math.ceil(t.length/16),o=e._cache.length;e._cache=i.concat([e._cache,i.allocUnsafe(16*r)]);for(var s=0;s{t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},45:(e,t,r)=>{var n={ECB:r(11084),CBC:r(25292),CFB:r(86311),CFB8:r(71964),CFB1:r(21510),OFB:r(18861),CTR:r(96009),GCM:r(96009)},i=r(44946);for(var o in i)i[o].module=n[i[o].mode];e.exports=i},18861:(e,t,r)=>{var n=r(48764).Buffer,i=r(67295);function o(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(e,t){for(;e._cache.length{var n=r(74497),i=r(89509).Buffer,o=r(71027);function a(e,t,r,a){o.call(this),this._cipher=new n.AES(t),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._mode=e}r(35717)(a,o),a.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},a.prototype._final=function(){this._cipher.scrub()},e.exports=a},53614:(e,t,r)=>{var n=r(47667),i=r(44696),o=r(45),a=r(99715),s=r(13048);function u(e,t,r){if(e=e.toLowerCase(),o[e])return i.createCipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function c(e,t,r){if(e=e.toLowerCase(),o[e])return i.createDecipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}t.createCipher=t.Cipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return u(e,i.key,i.iv)},t.createCipheriv=t.Cipheriv=u,t.createDecipher=t.Decipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return c(e,i.key,i.iv)},t.createDecipheriv=t.Decipheriv=c,t.listCiphers=t.getCiphers=function(){return Object.keys(a).concat(i.getCiphers())}},47667:(e,t,r)=>{var n=r(71027),i=r(15251),o=r(35717),a=r(89509).Buffer,s={"des-ede3-cbc":i.CBC.instantiate(i.EDE),"des-ede3":i.EDE,"des-ede-cbc":i.CBC.instantiate(i.EDE),"des-ede":i.EDE,"des-cbc":i.CBC.instantiate(i.DES),"des-ecb":i.DES};function u(e){n.call(this);var t,r=e.mode.toLowerCase(),i=s[r];t=e.decrypt?"decrypt":"encrypt";var o=e.key;a.isBuffer(o)||(o=a.from(o)),"des-ede"!==r&&"des-ede-cbc"!==r||(o=a.concat([o,o.slice(0,8)]));var u=e.iv;a.isBuffer(u)||(u=a.from(u)),this._des=i.create({key:o,iv:u,type:t})}s.des=s["des-cbc"],s.des3=s["des-ede3-cbc"],e.exports=u,o(u,n),u.prototype._update=function(e){return a.from(this._des.update(e))},u.prototype._final=function(){return a.from(this._des.final())}},99715:(e,t)=>{t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}},23663:(e,t,r)=>{var n=r(48764).Buffer,i=r(13550),o=r(61798);function a(e){var t,r=e.modulus.byteLength();do{t=new i(o(r))}while(t.cmp(e.modulus)>=0||!t.umod(e.prime1)||!t.umod(e.prime2));return t}function s(e,t){var r=function(e){var t=a(e);return{blinder:t.toRed(i.mont(e.modulus)).redPow(new i(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(t),o=t.modulus.byteLength(),s=new i(e).mul(r.blinder).umod(t.modulus),u=s.toRed(i.mont(t.prime1)),c=s.toRed(i.mont(t.prime2)),l=t.coefficient,f=t.prime1,h=t.prime2,d=u.redPow(t.exponent1).fromRed(),p=c.redPow(t.exponent2).fromRed(),m=d.isub(p).imul(l).umod(f).imul(h);return p.iadd(m).imul(r.unblinder).umod(t.modulus).toArrayLike(n,"be",o)}s.getr=a,e.exports=s},56042:(e,t,r)=>{e.exports=r(75207)},64743:(e,t,r)=>{var n=r(89509).Buffer,i=r(23482),o=r(88473),a=r(35717),s=r(82957),u=r(47753),c=r(75207);function l(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function f(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function h(e){return new l(e)}function d(e){return new f(e)}Object.keys(c).forEach((function(e){c[e].id=n.from(c[e].id,"hex"),c[e.toLowerCase()]=c[e]})),a(l,o.Writable),l.prototype._write=function(e,t,r){this._hash.update(e),r()},l.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},l.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),n=s(r,e,this._hashType,this._signType,this._tag);return t?n.toString(t):n},a(f,o.Writable),f.prototype._write=function(e,t,r){this._hash.update(e),r()},f.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},f.prototype.verify=function(e,t,r){"string"==typeof t&&(t=n.from(t,r)),this.end();var i=this._hash.digest();return u(t,i,e,this._signType,this._tag)},e.exports={Sign:h,Verify:d,createSign:h,createVerify:d}},82957:(e,t,r)=>{var n=r(89509).Buffer,i=r(58355),o=r(23663),a=r(86266).ec,s=r(13550),u=r(70980),c=r(1308);function l(e,t,r,o){if((e=n.from(e.toArray())).length0&&r.ishrn(n),r}function h(e,t,r){var o,a;do{for(o=n.alloc(0);8*o.length{var n=r(89509).Buffer,i=r(13550),o=r(86266).ec,a=r(70980),s=r(1308);function u(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=t)throw new Error("invalid sig")}e.exports=function(e,t,r,c,l){var f=a(r);if("ec"===f.type){if("ecdsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=s[r.data.algorithm.curve.join(".")];if(!n)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var i=new o(n),a=r.data.subjectPrivateKey.data;return i.verify(t,e,a)}(e,t,f)}if("dsa"===f.type){if("dsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=r.data.p,o=r.data.q,s=r.data.g,c=r.data.pub_key,l=a.signature.decode(e,"der"),f=l.s,h=l.r;u(f,o),u(h,o);var d=i.mont(n),p=f.invm(o);return 0===s.toRed(d).redPow(new i(t).mul(p).mod(o)).fromRed().mul(c.toRed(d).redPow(h.mul(p).mod(o)).fromRed()).mod(n).mod(o).cmp(h)}(e,t,f)}if("rsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");t=n.concat([l,t]);for(var h=f.modulus.byteLength(),d=[1],p=0;t.length+d.length+2{var n=r(48764).Buffer;e.exports=function(e){for(var t=new n(e.length),r=0,i=e.length-1;r<=i;++r,--i)t[r]=e[i],t[i]=e[r];return t}},67295:(e,t,r)=>{var n=r(48764).Buffer;e.exports=function(e,t){for(var r=Math.min(e.length,t.length),i=new n(r),o=0;o{"use strict";const n=r(79742),i=r(80645),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=u,t.SlowBuffer=function(e){+e!=e&&(e=0);return u.alloc(+e)},t.INSPECT_MAX_BYTES=50;const a=2147483647;function s(e){if(e>a)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,u.prototype),t}function u(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return f(e)}return c(e,t,r)}function c(e,t,r){if("string"==typeof e)return function(e,t){"string"==typeof t&&""!==t||(t="utf8");if(!u.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|m(e,t);let n=s(r);const i=n.write(e,t);i!==r&&(n=n.slice(0,i));return n}(e,t);if(ArrayBuffer.isView(e))return function(e){if(Q(e,Uint8Array)){const t=new Uint8Array(e);return d(t.buffer,t.byteOffset,t.byteLength)}return h(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(Q(e,ArrayBuffer)||e&&Q(e.buffer,ArrayBuffer))return d(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(Q(e,SharedArrayBuffer)||e&&Q(e.buffer,SharedArrayBuffer)))return d(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return u.from(n,t,r);const i=function(e){if(u.isBuffer(e)){const t=0|p(e.length),r=s(t);return 0===r.length||e.copy(r,0,0,t),r}if(void 0!==e.length)return"number"!=typeof e.length||W(e.length)?s(0):h(e);if("Buffer"===e.type&&Array.isArray(e.data))return h(e.data)}(e);if(i)return i;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return u.from(e[Symbol.toPrimitive]("string"),t,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function f(e){return l(e),s(e<0?0:0|p(e))}function h(e){const t=e.length<0?0:0|p(e.length),r=s(t);for(let n=0;n=a)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a.toString(16)+" bytes");return 0|e}function m(e,t){if(u.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||Q(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const r=e.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let i=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return K(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return V(e).length;default:if(i)return n?-1:K(e).length;t=(""+t).toLowerCase(),i=!0}}function y(e,t,r){let n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return I(this,t,r);case"utf8":case"utf-8":return M(this,t,r);case"ascii":return x(this,t,r);case"latin1":case"binary":return P(this,t,r);case"base64":return _(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function g(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function b(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),W(r=+r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=u.from(t,n)),u.isBuffer(t))return 0===t.length?-1:v(e,t,r,n,i);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):v(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function v(e,t,r,n,i){let o,a=1,s=e.length,u=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,r/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){let n=-1;for(o=r;os&&(r=s-u),o=r;o>=0;o--){let r=!0;for(let n=0;ni&&(n=i):n=i;const o=t.length;let a;for(n>o/2&&(n=o/2),a=0;a>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function _(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function M(e,t,r){r=Math.min(e.length,r);const n=[];let i=t;for(;i239?4:t>223?3:t>191?2:1;if(i+a<=r){let r,n,s,u;switch(a){case 1:t<128&&(o=t);break;case 2:r=e[i+1],128==(192&r)&&(u=(31&t)<<6|63&r,u>127&&(o=u));break;case 3:r=e[i+1],n=e[i+2],128==(192&r)&&128==(192&n)&&(u=(15&t)<<12|(63&r)<<6|63&n,u>2047&&(u<55296||u>57343)&&(o=u));break;case 4:r=e[i+1],n=e[i+2],s=e[i+3],128==(192&r)&&128==(192&n)&&128==(192&s)&&(u=(15&t)<<18|(63&r)<<12|(63&n)<<6|63&s,u>65535&&u<1114112&&(o=u))}}null===o?(o=65533,a=1):o>65535&&(o-=65536,n.push(o>>>10&1023|55296),o=56320|1023&o),n.push(o),i+=a}return function(e){const t=e.length;if(t<=T)return String.fromCharCode.apply(String,e);let r="",n=0;for(;nn.length?(u.isBuffer(t)||(t=u.from(t)),t.copy(n,i)):Uint8Array.prototype.set.call(n,t,i);else{if(!u.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(n,i)}i+=t.length}return n},u.byteLength=m,u.prototype._isBuffer=!0,u.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tr&&(e+=" ... "),""},o&&(u.prototype[o]=u.prototype.inspect),u.prototype.compare=function(e,t,r,n,i){if(Q(e,Uint8Array)&&(e=u.from(e,e.offset,e.byteLength)),!u.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;let o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0);const s=Math.min(o,a),c=this.slice(n,i),l=e.slice(t,r);for(let e=0;e>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const i=this.length-t;if((void 0===r||r>i)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let o=!1;for(;;)switch(n){case"hex":return w(this,e,t,r);case"utf8":case"utf-8":return A(this,e,t,r);case"ascii":case"latin1":case"binary":return S(this,e,t,r);case"base64":return k(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const T=4096;function x(e,t,r){let n="";r=Math.min(e.length,r);for(let i=t;in)&&(r=n);let i="";for(let n=t;nr)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,r,n,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function B(e,t,r,n,i){J(t,n,i,e,r,7);let o=Number(t&BigInt(4294967295));e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,r}function N(e,t,r,n,i){J(t,n,i,e,r,7);let o=Number(t&BigInt(4294967295));e[r+7]=o,o>>=8,e[r+6]=o,o>>=8,e[r+5]=o,o>>=8,e[r+4]=o;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=a,a>>=8,e[r+2]=a,a>>=8,e[r+1]=a,a>>=8,e[r]=a,r+8}function L(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function U(e,t,r,n,o){return t=+t,r>>>=0,o||L(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function F(e,t,r,n,o){return t=+t,r>>>=0,o||L(e,0,r,8),i.write(e,t,r,n,52,8),r+8}u.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t>>=0,t>>>=0,r||R(e,t,this.length);let n=this[e],i=1,o=0;for(;++o>>=0,t>>>=0,r||R(e,t,this.length);let n=this[e+--t],i=1;for(;t>0&&(i*=256);)n+=this[e+--t]*i;return n},u.prototype.readUint8=u.prototype.readUInt8=function(e,t){return e>>>=0,t||R(e,1,this.length),this[e]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(e,t){return e>>>=0,t||R(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(e,t){return e>>>=0,t||R(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(e,t){return e>>>=0,t||R(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(e,t){return e>>>=0,t||R(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readBigUInt64LE=Y((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,i=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(n)+(BigInt(i)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=t*2**24+65536*this[++e]+256*this[++e]+this[++e],i=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(n)<>>=0,t>>>=0,r||R(e,t,this.length);let n=this[e],i=1,o=0;for(;++o=i&&(n-=Math.pow(2,8*t)),n},u.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||R(e,t,this.length);let n=t,i=1,o=this[e+--n];for(;n>0&&(i*=256);)o+=this[e+--n]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return e>>>=0,t||R(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){e>>>=0,t||R(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(e,t){e>>>=0,t||R(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(e,t){return e>>>=0,t||R(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return e>>>=0,t||R(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readBigInt64LE=Y((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(n)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(n)<>>=0,t||R(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return e>>>=0,t||R(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return e>>>=0,t||R(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return e>>>=0,t||R(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUintLE=u.prototype.writeUIntLE=function(e,t,r,n){if(e=+e,t>>>=0,r>>>=0,!n){C(this,e,t,r,Math.pow(2,8*r)-1,0)}let i=1,o=0;for(this[t]=255&e;++o>>=0,r>>>=0,!n){C(this,e,t,r,Math.pow(2,8*r)-1,0)}let i=r-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+r},u.prototype.writeUint8=u.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,1,255,0),this[t]=255&e,t+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},u.prototype.writeBigUInt64LE=Y((function(e,t=0){return B(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeBigUInt64BE=Y((function(e,t=0){return N(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);C(this,e,t,r,n-1,-n)}let i=0,o=1,a=0;for(this[t]=255&e;++i>0)-a&255;return t+r},u.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);C(this,e,t,r,n-1,-n)}let i=r-1,o=1,a=0;for(this[t+i]=255&e;--i>=0&&(o*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/o>>0)-a&255;return t+r},u.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},u.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},u.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},u.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},u.prototype.writeBigInt64LE=Y((function(e,t=0){return B(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeBigInt64BE=Y((function(e,t=0){return N(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeFloatLE=function(e,t,r){return U(this,e,t,!0,r)},u.prototype.writeFloatBE=function(e,t,r){return U(this,e,t,!1,r)},u.prototype.writeDoubleLE=function(e,t,r){return F(this,e,t,!0,r)},u.prototype.writeDoubleBE=function(e,t,r){return F(this,e,t,!1,r)},u.prototype.copy=function(e,t,r,n){if(!u.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(i=t;i=n+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function J(e,t,r,n,i,o){if(e>r||e3?0===t||t===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(o+1)}${n}`:`>= -(2${n} ** ${8*(o+1)-1}${n}) and < 2 ** ${8*(o+1)-1}${n}`:`>= ${t}${n} and <= ${r}${n}`,new D.ERR_OUT_OF_RANGE("value",i,e)}!function(e,t,r){z(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||G(t,e.length-(r+1))}(n,i,o)}function z(e,t){if("number"!=typeof e)throw new D.ERR_INVALID_ARG_TYPE(t,"number",e)}function G(e,t,r){if(Math.floor(e)!==e)throw z(e,r),new D.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new D.ERR_BUFFER_OUT_OF_BOUNDS;throw new D.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${t}`,e)}j("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),j("ERR_INVALID_ARG_TYPE",(function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`}),TypeError),j("ERR_OUT_OF_RANGE",(function(e,t,r){let n=`The value of "${e}" is out of range.`,i=r;return Number.isInteger(r)&&Math.abs(r)>2**32?i=H(String(r)):"bigint"==typeof r&&(i=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(i=H(i)),i+="n"),n+=` It must be ${t}. Received ${i}`,n}),RangeError);const q=/[^+/0-9A-Za-z-_]/g;function K(e,t){let r;t=t||1/0;const n=e.length;let i=null;const o=[];for(let a=0;a55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function V(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(q,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function X(e,t,r,n){let i;for(i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}function Q(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function W(e){return e!=e}const Z=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let i=0;i<16;++i)t[n+i]=e[r]+e[i]}return t}();function Y(e){return"undefined"==typeof BigInt?$:e}function $(){throw new Error("BigInt not supported")}},39376:e=>{"use strict";e.exports={mask:(e,t,r,n,i)=>{for(var o=0;o{const r=e.length;for(var n=0;n{"use strict";try{e.exports=r(19516)("/")}catch(t){e.exports=r(39376)}},50584:e=>{e.exports={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}},21924:(e,t,r)=>{"use strict";var n=r(40210),i=r(55559),o=i(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&o(e,".prototype.")>-1?i(r):r}},55559:(e,t,r)=>{"use strict";var n=r(58612),i=r(40210),o=i("%Function.prototype.apply%"),a=i("%Function.prototype.call%"),s=i("%Reflect.apply%",!0)||n.call(a,o),u=i("%Object.getOwnPropertyDescriptor%",!0),c=i("%Object.defineProperty%",!0),l=i("%Math.max%");if(c)try{c({},"a",{value:1})}catch(e){c=null}e.exports=function(e){var t=s(n,a,arguments);if(u&&c){var r=u(t,"length");r.configurable&&c(t,"length",{value:1+l(0,e.length-(arguments.length-1))})}return t};var f=function(){return s(n,o,arguments)};c?c(e.exports,"apply",{value:f}):e.exports.apply=f},95456:e=>{"use strict";e.exports=function e(t){return null===t||"object"!=typeof t||null!=t.toJSON?JSON.stringify(t):Array.isArray(t)?"["+t.reduce(((t,r,n)=>t+(0===n?"":",")+e(void 0===r||"symbol"==typeof r?null:r)),"")+"]":"{"+Object.keys(t).sort().reduce(((r,n,i)=>{if(void 0===t[n]||"symbol"==typeof t[n])return r;return r+(0===r.length?"":",")+e(n)+":"+e(t[n])}),"")+"}"}},71027:(e,t,r)=>{var n=r(89509).Buffer,i=r(42830).Transform,o=r(32553).s;function a(e){i.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(35717)(a,i),a.prototype.update=function(e,t,r){"string"==typeof e&&(e=n.from(e,t));var i=this._update(e);return this.hashMode?this:(r&&(i=this._toString(i,r)),i)},a.prototype.setAutoPadding=function(){},a.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},a.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},a.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},a.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){n=e}finally{r(n)}},a.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},a.prototype._finalOrDigest=function(e){var t=this.__final()||n.alloc(0);return e&&(t=this._toString(t,e,!0)),t},a.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new o(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n},e.exports=a},76393:(e,t,r)=>{var n=r(48764).Buffer,i=r(86266),o=r(16426);e.exports=function(e){return new s(e)};var a={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function s(e){this.curveType=a[e],this.curveType||(this.curveType={name:e}),this.curve=new i.ec(this.curveType.name),this.keys=void 0}function u(e,t,r){Array.isArray(e)||(e=e.toArray());var i=new n(e);if(r&&i.length=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},23482:(e,t,r)=>{"use strict";var n=r(35717),i=r(62318),o=r(79785),a=r(89072),s=r(71027);function u(e){s.call(this,"digest"),this._hash=e}n(u,s),u.prototype._update=function(e){this._hash.update(e)},u.prototype._final=function(){return this._hash.digest()},e.exports=function(e){return"md5"===(e=e.toLowerCase())?new i:"rmd160"===e||"ripemd160"===e?new o:new u(a(e))}},78028:(e,t,r)=>{var n=r(62318);e.exports=function(e){return(new n).update(e).digest()}},58355:(e,t,r)=>{"use strict";var n=r(35717),i=r(51031),o=r(71027),a=r(89509).Buffer,s=r(78028),u=r(79785),c=r(89072),l=a.alloc(128);function f(e,t){o.call(this,"digest"),"string"==typeof t&&(t=a.from(t));var r="sha512"===e||"sha384"===e?128:64;(this._alg=e,this._key=t,t.length>r)?t=("rmd160"===e?new u:c(e)).update(t).digest():t.length{"use strict";var n=r(35717),i=r(89509).Buffer,o=r(71027),a=i.alloc(128),s=64;function u(e,t){o.call(this,"digest"),"string"==typeof t&&(t=i.from(t)),this._alg=e,this._key=t,t.length>s?t=e(t):t.length{"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=r(61798),t.createHash=t.Hash=r(23482),t.createHmac=t.Hmac=r(58355);var n=r(56042),i=Object.keys(n),o=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(i);t.getHashes=function(){return o};var a=r(25632);t.pbkdf2=a.pbkdf2,t.pbkdf2Sync=a.pbkdf2Sync;var s=r(53614);t.Cipher=s.Cipher,t.createCipher=s.createCipher,t.Cipheriv=s.Cipheriv,t.createCipheriv=s.createCipheriv,t.Decipher=s.Decipher,t.createDecipher=s.createDecipher,t.Decipheriv=s.Decipheriv,t.createDecipheriv=s.createDecipheriv,t.getCiphers=s.getCiphers,t.listCiphers=s.listCiphers;var u=r(62607);t.DiffieHellmanGroup=u.DiffieHellmanGroup,t.createDiffieHellmanGroup=u.createDiffieHellmanGroup,t.getDiffieHellman=u.getDiffieHellman,t.createDiffieHellman=u.createDiffieHellman,t.DiffieHellman=u.DiffieHellman;var c=r(64743);t.createSign=c.createSign,t.Sign=c.Sign,t.createVerify=c.createVerify,t.Verify=c.Verify,t.createECDH=r(76393);var l=r(7900);t.publicEncrypt=l.publicEncrypt,t.privateEncrypt=l.privateEncrypt,t.publicDecrypt=l.publicDecrypt,t.privateDecrypt=l.privateDecrypt;var f=r(77963);t.randomFill=f.randomFill,t.randomFillSync=f.randomFillSync,t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},40452:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib.BlockCipher,r=e.algo,i=[],o=[],a=[],s=[],u=[],c=[],l=[],f=[],h=[],d=[];!function(){for(var e=[],t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;var r=0,n=0;for(t=0;t<256;t++){var p=n^n<<1^n<<2^n<<3^n<<4;p=p>>>8^255&p^99,i[r]=p,o[p]=r;var m=e[r],y=e[m],g=e[y],b=257*e[p]^16843008*p;a[r]=b<<24|b>>>8,s[r]=b<<16|b>>>16,u[r]=b<<8|b>>>24,c[r]=b,b=16843009*g^65537*y^257*m^16843008*r,l[p]=b<<24|b>>>8,f[p]=b<<16|b>>>16,h[p]=b<<8|b>>>24,d[p]=b,r?(r=m^e[e[e[g^m]]],n^=e[e[n]]):r=n=1}}();var p=[0,1,2,4,8,16,32,64,128,27,54],m=r.AES=t.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var e=this._keyPriorReset=this._key,t=e.words,r=e.sigBytes/4,n=4*((this._nRounds=r+6)+1),o=this._keySchedule=[],a=0;a6&&a%r==4&&(s=i[s>>>24]<<24|i[s>>>16&255]<<16|i[s>>>8&255]<<8|i[255&s]):(s=i[(s=s<<8|s>>>24)>>>24]<<24|i[s>>>16&255]<<16|i[s>>>8&255]<<8|i[255&s],s^=p[a/r|0]<<24),o[a]=o[a-r]^s}for(var u=this._invKeySchedule=[],c=0;c>>24]]^f[i[s>>>16&255]]^h[i[s>>>8&255]]^d[i[255&s]]}},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,a,s,u,c,i)},decryptBlock:function(e,t){var r=e[t+1];e[t+1]=e[t+3],e[t+3]=r,this._doCryptBlock(e,t,this._invKeySchedule,l,f,h,d,o),r=e[t+1],e[t+1]=e[t+3],e[t+3]=r},_doCryptBlock:function(e,t,r,n,i,o,a,s){for(var u=this._nRounds,c=e[t]^r[0],l=e[t+1]^r[1],f=e[t+2]^r[2],h=e[t+3]^r[3],d=4,p=1;p>>24]^i[l>>>16&255]^o[f>>>8&255]^a[255&h]^r[d++],y=n[l>>>24]^i[f>>>16&255]^o[h>>>8&255]^a[255&c]^r[d++],g=n[f>>>24]^i[h>>>16&255]^o[c>>>8&255]^a[255&l]^r[d++],b=n[h>>>24]^i[c>>>16&255]^o[l>>>8&255]^a[255&f]^r[d++];c=m,l=y,f=g,h=b}m=(s[c>>>24]<<24|s[l>>>16&255]<<16|s[f>>>8&255]<<8|s[255&h])^r[d++],y=(s[l>>>24]<<24|s[f>>>16&255]<<16|s[h>>>8&255]<<8|s[255&c])^r[d++],g=(s[f>>>24]<<24|s[h>>>16&255]<<16|s[c>>>8&255]<<8|s[255&l])^r[d++],b=(s[h>>>24]<<24|s[c>>>16&255]<<16|s[l>>>8&255]<<8|s[255&f])^r[d++],e[t]=m,e[t+1]=y,e[t+2]=g,e[t+3]=b},keySize:8});e.AES=t._createHelper(m)}(),n.AES)},75109:function(e,t,r){var n;e.exports=(n=r(78249),r(90888),void(n.lib.Cipher||function(e){var t=n,r=t.lib,i=r.Base,o=r.WordArray,a=r.BufferedBlockAlgorithm,s=t.enc,u=(s.Utf8,s.Base64),c=t.algo.EvpKDF,l=r.Cipher=a.extend({cfg:i.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,r){this.cfg=this.cfg.extend(r),this._xformMode=e,this._key=t,this.reset()},reset:function(){a.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){return e&&this._append(e),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function e(e){return"string"==typeof e?v:g}return function(t){return{encrypt:function(r,n,i){return e(n).encrypt(t,r,n,i)},decrypt:function(r,n,i){return e(n).decrypt(t,r,n,i)}}}}()}),f=(r.StreamCipher=l.extend({_doFinalize:function(){return this._process(!0)},blockSize:1}),t.mode={}),h=r.BlockCipherMode=i.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}}),d=f.CBC=function(){var t=h.extend();function r(t,r,n){var i=this._iv;if(i){var o=i;this._iv=e}else o=this._prevBlock;for(var a=0;a>>2];e.sigBytes-=t}},m=(r.BlockCipher=l.extend({cfg:l.cfg.extend({mode:d,padding:p}),reset:function(){l.reset.call(this);var e=this.cfg,t=e.iv,r=e.mode;if(this._xformMode==this._ENC_XFORM_MODE)var n=r.createEncryptor;else n=r.createDecryptor,this._minBufferSize=1;this._mode&&this._mode.__creator==n?this._mode.init(this,t&&t.words):(this._mode=n.call(r,this,t&&t.words),this._mode.__creator=n)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){e.pad(this._data,this.blockSize);var t=this._process(!0)}else t=this._process(!0),e.unpad(t);return t},blockSize:4}),r.CipherParams=i.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}})),y=(t.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext,r=e.salt;if(r)var n=o.create([1398893684,1701076831]).concat(r).concat(t);else n=t;return n.toString(u)},parse:function(e){var t=u.parse(e),r=t.words;if(1398893684==r[0]&&1701076831==r[1]){var n=o.create(r.slice(2,4));r.splice(0,4),t.sigBytes-=16}return m.create({ciphertext:t,salt:n})}},g=r.SerializableCipher=i.extend({cfg:i.extend({format:y}),encrypt:function(e,t,r,n){n=this.cfg.extend(n);var i=e.createEncryptor(r,n),o=i.finalize(t),a=i.cfg;return m.create({ciphertext:o,key:r,iv:a.iv,algorithm:e,mode:a.mode,padding:a.padding,blockSize:e.blockSize,formatter:n.format})},decrypt:function(e,t,r,n){return n=this.cfg.extend(n),t=this._parse(t,n.format),e.createDecryptor(r,n).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),b=(t.kdf={}).OpenSSL={execute:function(e,t,r,n){n||(n=o.random(8));var i=c.create({keySize:t+r}).compute(e,n),a=o.create(i.words.slice(t),4*r);return i.sigBytes=4*t,m.create({key:i,iv:a,salt:n})}},v=r.PasswordBasedCipher=g.extend({cfg:g.cfg.extend({kdf:b}),encrypt:function(e,t,r,n){var i=(n=this.cfg.extend(n)).kdf.execute(r,e.keySize,e.ivSize);n.iv=i.iv;var o=g.encrypt.call(this,e,t,i.key,n);return o.mixIn(i),o},decrypt:function(e,t,r,n){n=this.cfg.extend(n),t=this._parse(t,n.format);var i=n.kdf.execute(r,e.keySize,e.ivSize,t.salt);return n.iv=i.iv,g.decrypt.call(this,e,t,i.key,n)}})}()))},78249:function(e,t){var r;e.exports=(r=r||function(e,t){var r=Object.create||function(){function e(){}return function(t){var r;return e.prototype=t,r=new e,e.prototype=null,r}}(),n={},i=n.lib={},o=i.Base={extend:function(e){var t=r(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},a=i.WordArray=o.extend({init:function(e,r){e=this.words=e||[],this.sigBytes=r!=t?r:4*e.length},toString:function(e){return(e||u).stringify(this)},concat:function(e){var t=this.words,r=e.words,n=this.sigBytes,i=e.sigBytes;if(this.clamp(),n%4)for(var o=0;o>>2]>>>24-o%4*8&255;t[n+o>>>2]|=a<<24-(n+o)%4*8}else for(o=0;o>>2]=r[o>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,r=this.sigBytes;t[r>>>2]&=4294967295<<32-r%4*8,t.length=e.ceil(r/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var r,n=[],i=function(t){var r=987654321,n=4294967295;return function(){var i=((r=36969*(65535&r)+(r>>16)&n)<<16)+(t=18e3*(65535&t)+(t>>16)&n)&n;return i/=4294967296,(i+=.5)*(e.random()>.5?1:-1)}},o=0;o>>2]>>>24-i%4*8&255;n.push((o>>>4).toString(16)),n.push((15&o).toString(16))}return n.join("")},parse:function(e){for(var t=e.length,r=[],n=0;n>>3]|=parseInt(e.substr(n,2),16)<<24-n%8*4;return new a.init(r,t/2)}},c=s.Latin1={stringify:function(e){for(var t=e.words,r=e.sigBytes,n=[],i=0;i>>2]>>>24-i%4*8&255;n.push(String.fromCharCode(o))}return n.join("")},parse:function(e){for(var t=e.length,r=[],n=0;n>>2]|=(255&e.charCodeAt(n))<<24-n%4*8;return new a.init(r,t)}},l=s.Utf8={stringify:function(e){try{return decodeURIComponent(escape(c.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return c.parse(unescape(encodeURIComponent(e)))}},f=i.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new a.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=l.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var r=this._data,n=r.words,i=r.sigBytes,o=this.blockSize,s=i/(4*o),u=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*o,c=e.min(4*u,i);if(u){for(var l=0;l>>6-a%4*2;i[o>>>2]|=(s|u)<<24-o%4*8,o++}return t.create(i,o)}e.enc.Base64={stringify:function(e){var t=e.words,r=e.sigBytes,n=this._map;e.clamp();for(var i=[],o=0;o>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,s=0;s<4&&o+.75*s>>6*(3-s)&63));var u=n.charAt(64);if(u)for(;i.length%4;)i.push(u);return i.join("")},parse:function(e){var t=e.length,n=this._map,i=this._reverseMap;if(!i){i=this._reverseMap=[];for(var o=0;o>>8&16711935}r.Utf16=r.Utf16BE={stringify:function(e){for(var t=e.words,r=e.sigBytes,n=[],i=0;i>>2]>>>16-i%4*8&65535;n.push(String.fromCharCode(o))}return n.join("")},parse:function(e){for(var r=e.length,n=[],i=0;i>>1]|=e.charCodeAt(i)<<16-i%2*16;return t.create(n,2*r)}},r.Utf16LE={stringify:function(e){for(var t=e.words,r=e.sigBytes,n=[],o=0;o>>2]>>>16-o%4*8&65535);n.push(String.fromCharCode(a))}return n.join("")},parse:function(e){for(var r=e.length,n=[],o=0;o>>1]|=i(e.charCodeAt(o)<<16-o%2*16);return t.create(n,2*r)}}}(),n.enc.Utf16)},90888:function(e,t,r){var n,i,o,a,s,u,c,l;e.exports=(l=r(78249),r(62783),r(89824),i=(n=l).lib,o=i.Base,a=i.WordArray,s=n.algo,u=s.MD5,c=s.EvpKDF=o.extend({cfg:o.extend({keySize:4,hasher:u,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var r=this.cfg,n=r.hasher.create(),i=a.create(),o=i.words,s=r.keySize,u=r.iterations;o.lengthn&&(t=e.finalize(t)),t.clamp();for(var i=this._oKey=t.clone(),o=this._iKey=t.clone(),s=i.words,u=o.words,c=0;c>>2]|=e[i]<<24-i%4*8;t.call(this,n,r)}else t.apply(this,arguments)};r.prototype=e}}(),n.lib.WordArray)},68214:function(e,t,r){var n;e.exports=(n=r(78249),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=[];!function(){for(var t=0;t<64;t++)s[t]=4294967296*e.abs(e.sin(t+1))|0}();var u=a.MD5=o.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var r=0;r<16;r++){var n=t+r,i=e[n];e[n]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o=this._hash.words,a=e[t+0],u=e[t+1],d=e[t+2],p=e[t+3],m=e[t+4],y=e[t+5],g=e[t+6],b=e[t+7],v=e[t+8],w=e[t+9],A=e[t+10],S=e[t+11],k=e[t+12],E=e[t+13],_=e[t+14],M=e[t+15],T=o[0],x=o[1],P=o[2],I=o[3];T=c(T,x,P,I,a,7,s[0]),I=c(I,T,x,P,u,12,s[1]),P=c(P,I,T,x,d,17,s[2]),x=c(x,P,I,T,p,22,s[3]),T=c(T,x,P,I,m,7,s[4]),I=c(I,T,x,P,y,12,s[5]),P=c(P,I,T,x,g,17,s[6]),x=c(x,P,I,T,b,22,s[7]),T=c(T,x,P,I,v,7,s[8]),I=c(I,T,x,P,w,12,s[9]),P=c(P,I,T,x,A,17,s[10]),x=c(x,P,I,T,S,22,s[11]),T=c(T,x,P,I,k,7,s[12]),I=c(I,T,x,P,E,12,s[13]),P=c(P,I,T,x,_,17,s[14]),T=l(T,x=c(x,P,I,T,M,22,s[15]),P,I,u,5,s[16]),I=l(I,T,x,P,g,9,s[17]),P=l(P,I,T,x,S,14,s[18]),x=l(x,P,I,T,a,20,s[19]),T=l(T,x,P,I,y,5,s[20]),I=l(I,T,x,P,A,9,s[21]),P=l(P,I,T,x,M,14,s[22]),x=l(x,P,I,T,m,20,s[23]),T=l(T,x,P,I,w,5,s[24]),I=l(I,T,x,P,_,9,s[25]),P=l(P,I,T,x,p,14,s[26]),x=l(x,P,I,T,v,20,s[27]),T=l(T,x,P,I,E,5,s[28]),I=l(I,T,x,P,d,9,s[29]),P=l(P,I,T,x,b,14,s[30]),T=f(T,x=l(x,P,I,T,k,20,s[31]),P,I,y,4,s[32]),I=f(I,T,x,P,v,11,s[33]),P=f(P,I,T,x,S,16,s[34]),x=f(x,P,I,T,_,23,s[35]),T=f(T,x,P,I,u,4,s[36]),I=f(I,T,x,P,m,11,s[37]),P=f(P,I,T,x,b,16,s[38]),x=f(x,P,I,T,A,23,s[39]),T=f(T,x,P,I,E,4,s[40]),I=f(I,T,x,P,a,11,s[41]),P=f(P,I,T,x,p,16,s[42]),x=f(x,P,I,T,g,23,s[43]),T=f(T,x,P,I,w,4,s[44]),I=f(I,T,x,P,k,11,s[45]),P=f(P,I,T,x,M,16,s[46]),T=h(T,x=f(x,P,I,T,d,23,s[47]),P,I,a,6,s[48]),I=h(I,T,x,P,b,10,s[49]),P=h(P,I,T,x,_,15,s[50]),x=h(x,P,I,T,y,21,s[51]),T=h(T,x,P,I,k,6,s[52]),I=h(I,T,x,P,p,10,s[53]),P=h(P,I,T,x,A,15,s[54]),x=h(x,P,I,T,u,21,s[55]),T=h(T,x,P,I,v,6,s[56]),I=h(I,T,x,P,M,10,s[57]),P=h(P,I,T,x,g,15,s[58]),x=h(x,P,I,T,E,21,s[59]),T=h(T,x,P,I,m,6,s[60]),I=h(I,T,x,P,S,10,s[61]),P=h(P,I,T,x,d,15,s[62]),x=h(x,P,I,T,w,21,s[63]),o[0]=o[0]+T|0,o[1]=o[1]+x|0,o[2]=o[2]+P|0,o[3]=o[3]+I|0},_doFinalize:function(){var t=this._data,r=t.words,n=8*this._nDataBytes,i=8*t.sigBytes;r[i>>>5]|=128<<24-i%32;var o=e.floor(n/4294967296),a=n;r[15+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),r[14+(i+64>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),t.sigBytes=4*(r.length+1),this._process();for(var s=this._hash,u=s.words,c=0;c<4;c++){var l=u[c];u[c]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}return s},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function c(e,t,r,n,i,o,a){var s=e+(t&r|~t&n)+i+a;return(s<>>32-o)+t}function l(e,t,r,n,i,o,a){var s=e+(t&n|r&~n)+i+a;return(s<>>32-o)+t}function f(e,t,r,n,i,o,a){var s=e+(t^r^n)+i+a;return(s<>>32-o)+t}function h(e,t,r,n,i,o,a){var s=e+(r^(t|~n))+i+a;return(s<>>32-o)+t}t.MD5=o._createHelper(u),t.HmacMD5=o._createHmacHelper(u)}(Math),n.MD5)},8568:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.mode.CFB=function(){var e=n.lib.BlockCipherMode.extend();function t(e,t,r,n){var i=this._iv;if(i){var o=i.slice(0);this._iv=void 0}else o=this._prevBlock;n.encryptBlock(o,0);for(var a=0;a>24&255)){var t=e>>16&255,r=e>>8&255,n=255&e;255===t?(t=0,255===r?(r=0,255===n?n=0:++n):++r):++t,e=0,e+=t<<16,e+=r<<8,e+=n}else e+=1<<24;return e}function r(e){return 0===(e[0]=t(e[0]))&&(e[1]=t(e[1])),e}var i=e.Encryptor=e.extend({processBlock:function(e,t){var n=this._cipher,i=n.blockSize,o=this._iv,a=this._counter;o&&(a=this._counter=o.slice(0),this._iv=void 0),r(a);var s=a.slice(0);n.encryptBlock(s,0);for(var u=0;u>>2]|=i<<24-o%4*8,e.sigBytes+=i},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},n.pad.Ansix923)},92807:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.Iso10126={pad:function(e,t){var r=4*t,i=r-e.sigBytes%r;e.concat(n.lib.WordArray.random(i-1)).concat(n.lib.WordArray.create([i<<24],1))},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},n.pad.Iso10126)},71077:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.Iso97971={pad:function(e,t){e.concat(n.lib.WordArray.create([2147483648],1)),n.pad.ZeroPadding.pad(e,t)},unpad:function(e){n.pad.ZeroPadding.unpad(e),e.sigBytes--}},n.pad.Iso97971)},16991:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.NoPadding={pad:function(){},unpad:function(){}},n.pad.NoPadding)},56475:function(e,t,r){var n;e.exports=(n=r(78249),r(75109),n.pad.ZeroPadding={pad:function(e,t){var r=4*t;e.clamp(),e.sigBytes+=r-(e.sigBytes%r||r)},unpad:function(e){for(var t=e.words,r=e.sigBytes-1;!(t[r>>>2]>>>24-r%4*8&255);)r--;e.sigBytes=r+1}},n.pad.ZeroPadding)},2112:function(e,t,r){var n,i,o,a,s,u,c,l,f;e.exports=(f=r(78249),r(62783),r(89824),i=(n=f).lib,o=i.Base,a=i.WordArray,s=n.algo,u=s.SHA1,c=s.HMAC,l=s.PBKDF2=o.extend({cfg:o.extend({keySize:4,hasher:u,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var r=this.cfg,n=c.create(r.hasher,e),i=a.create(),o=a.create([1]),s=i.words,u=o.words,l=r.keySize,f=r.iterations;s.length>>16,e[1],e[0]<<16|e[3]>>>16,e[2],e[1]<<16|e[0]>>>16,e[3],e[2]<<16|e[1]>>>16],n=this._C=[e[2]<<16|e[2]>>>16,4294901760&e[0]|65535&e[1],e[3]<<16|e[3]>>>16,4294901760&e[1]|65535&e[2],e[0]<<16|e[0]>>>16,4294901760&e[2]|65535&e[3],e[1]<<16|e[1]>>>16,4294901760&e[3]|65535&e[0]];this._b=0;for(var i=0;i<4;i++)u.call(this);for(i=0;i<8;i++)n[i]^=r[i+4&7];if(t){var o=t.words,a=o[0],s=o[1],c=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),l=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),f=c>>>16|4294901760&l,h=l<<16|65535&c;for(n[0]^=c,n[1]^=f,n[2]^=l,n[3]^=h,n[4]^=c,n[5]^=f,n[6]^=l,n[7]^=h,i=0;i<4;i++)u.call(this)}},_doProcessBlock:function(e,t){var r=this._X;u.call(this),i[0]=r[0]^r[5]>>>16^r[3]<<16,i[1]=r[2]^r[7]>>>16^r[5]<<16,i[2]=r[4]^r[1]>>>16^r[7]<<16,i[3]=r[6]^r[3]>>>16^r[1]<<16;for(var n=0;n<4;n++)i[n]=16711935&(i[n]<<8|i[n]>>>24)|4278255360&(i[n]<<24|i[n]>>>8),e[t+n]^=i[n]},blockSize:4,ivSize:2});function u(){for(var e=this._X,t=this._C,r=0;r<8;r++)o[r]=t[r];for(t[0]=t[0]+1295307597+this._b|0,t[1]=t[1]+3545052371+(t[0]>>>0>>0?1:0)|0,t[2]=t[2]+886263092+(t[1]>>>0>>0?1:0)|0,t[3]=t[3]+1295307597+(t[2]>>>0>>0?1:0)|0,t[4]=t[4]+3545052371+(t[3]>>>0>>0?1:0)|0,t[5]=t[5]+886263092+(t[4]>>>0>>0?1:0)|0,t[6]=t[6]+1295307597+(t[5]>>>0>>0?1:0)|0,t[7]=t[7]+3545052371+(t[6]>>>0>>0?1:0)|0,this._b=t[7]>>>0>>0?1:0,r=0;r<8;r++){var n=e[r]+t[r],i=65535&n,s=n>>>16,u=((i*i>>>17)+i*s>>>15)+s*s,c=((4294901760&n)*n|0)+((65535&n)*n|0);a[r]=u^c}e[0]=a[0]+(a[7]<<16|a[7]>>>16)+(a[6]<<16|a[6]>>>16)|0,e[1]=a[1]+(a[0]<<8|a[0]>>>24)+a[7]|0,e[2]=a[2]+(a[1]<<16|a[1]>>>16)+(a[0]<<16|a[0]>>>16)|0,e[3]=a[3]+(a[2]<<8|a[2]>>>24)+a[1]|0,e[4]=a[4]+(a[3]<<16|a[3]>>>16)+(a[2]<<16|a[2]>>>16)|0,e[5]=a[5]+(a[4]<<8|a[4]>>>24)+a[3]|0,e[6]=a[6]+(a[5]<<16|a[5]>>>16)+(a[4]<<16|a[4]>>>16)|0,e[7]=a[7]+(a[6]<<8|a[6]>>>24)+a[5]|0}e.RabbitLegacy=t._createHelper(s)}(),n.RabbitLegacy)},84454:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib.StreamCipher,r=e.algo,i=[],o=[],a=[],s=r.Rabbit=t.extend({_doReset:function(){for(var e=this._key.words,t=this.cfg.iv,r=0;r<4;r++)e[r]=16711935&(e[r]<<8|e[r]>>>24)|4278255360&(e[r]<<24|e[r]>>>8);var n=this._X=[e[0],e[3]<<16|e[2]>>>16,e[1],e[0]<<16|e[3]>>>16,e[2],e[1]<<16|e[0]>>>16,e[3],e[2]<<16|e[1]>>>16],i=this._C=[e[2]<<16|e[2]>>>16,4294901760&e[0]|65535&e[1],e[3]<<16|e[3]>>>16,4294901760&e[1]|65535&e[2],e[0]<<16|e[0]>>>16,4294901760&e[2]|65535&e[3],e[1]<<16|e[1]>>>16,4294901760&e[3]|65535&e[0]];for(this._b=0,r=0;r<4;r++)u.call(this);for(r=0;r<8;r++)i[r]^=n[r+4&7];if(t){var o=t.words,a=o[0],s=o[1],c=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),l=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),f=c>>>16|4294901760&l,h=l<<16|65535&c;for(i[0]^=c,i[1]^=f,i[2]^=l,i[3]^=h,i[4]^=c,i[5]^=f,i[6]^=l,i[7]^=h,r=0;r<4;r++)u.call(this)}},_doProcessBlock:function(e,t){var r=this._X;u.call(this),i[0]=r[0]^r[5]>>>16^r[3]<<16,i[1]=r[2]^r[7]>>>16^r[5]<<16,i[2]=r[4]^r[1]>>>16^r[7]<<16,i[3]=r[6]^r[3]>>>16^r[1]<<16;for(var n=0;n<4;n++)i[n]=16711935&(i[n]<<8|i[n]>>>24)|4278255360&(i[n]<<24|i[n]>>>8),e[t+n]^=i[n]},blockSize:4,ivSize:2});function u(){for(var e=this._X,t=this._C,r=0;r<8;r++)o[r]=t[r];for(t[0]=t[0]+1295307597+this._b|0,t[1]=t[1]+3545052371+(t[0]>>>0>>0?1:0)|0,t[2]=t[2]+886263092+(t[1]>>>0>>0?1:0)|0,t[3]=t[3]+1295307597+(t[2]>>>0>>0?1:0)|0,t[4]=t[4]+3545052371+(t[3]>>>0>>0?1:0)|0,t[5]=t[5]+886263092+(t[4]>>>0>>0?1:0)|0,t[6]=t[6]+1295307597+(t[5]>>>0>>0?1:0)|0,t[7]=t[7]+3545052371+(t[6]>>>0>>0?1:0)|0,this._b=t[7]>>>0>>0?1:0,r=0;r<8;r++){var n=e[r]+t[r],i=65535&n,s=n>>>16,u=((i*i>>>17)+i*s>>>15)+s*s,c=((4294901760&n)*n|0)+((65535&n)*n|0);a[r]=u^c}e[0]=a[0]+(a[7]<<16|a[7]>>>16)+(a[6]<<16|a[6]>>>16)|0,e[1]=a[1]+(a[0]<<8|a[0]>>>24)+a[7]|0,e[2]=a[2]+(a[1]<<16|a[1]>>>16)+(a[0]<<16|a[0]>>>16)|0,e[3]=a[3]+(a[2]<<8|a[2]>>>24)+a[1]|0,e[4]=a[4]+(a[3]<<16|a[3]>>>16)+(a[2]<<16|a[2]>>>16)|0,e[5]=a[5]+(a[4]<<8|a[4]>>>24)+a[3]|0,e[6]=a[6]+(a[5]<<16|a[5]>>>16)+(a[4]<<16|a[4]>>>16)|0,e[7]=a[7]+(a[6]<<8|a[6]>>>24)+a[5]|0}e.Rabbit=t._createHelper(s)}(),n.Rabbit)},51857:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib.StreamCipher,r=e.algo,i=r.RC4=t.extend({_doReset:function(){for(var e=this._key,t=e.words,r=e.sigBytes,n=this._S=[],i=0;i<256;i++)n[i]=i;i=0;for(var o=0;i<256;i++){var a=i%r,s=t[a>>>2]>>>24-a%4*8&255;o=(o+n[i]+s)%256;var u=n[i];n[i]=n[o],n[o]=u}this._i=this._j=0},_doProcessBlock:function(e,t){e[t]^=o.call(this)},keySize:8,ivSize:0});function o(){for(var e=this._S,t=this._i,r=this._j,n=0,i=0;i<4;i++){r=(r+e[t=(t+1)%256])%256;var o=e[t];e[t]=e[r],e[r]=o,n|=e[(e[t]+e[r])%256]<<24-8*i}return this._i=t,this._j=r,n}e.RC4=t._createHelper(i);var a=r.RC4Drop=i.extend({cfg:i.cfg.extend({drop:192}),_doReset:function(){i._doReset.call(this);for(var e=this.cfg.drop;e>0;e--)o.call(this)}});e.RC4Drop=t._createHelper(a)}(),n.RC4)},30706:function(e,t,r){var n;e.exports=(n=r(78249),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=i.create([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]),u=i.create([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]),c=i.create([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]),l=i.create([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]),f=i.create([0,1518500249,1859775393,2400959708,2840853838]),h=i.create([1352829926,1548603684,1836072691,2053994217,0]),d=a.RIPEMD160=o.extend({_doReset:function(){this._hash=i.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var r=0;r<16;r++){var n=t+r,i=e[n];e[n]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o,a,d,w,A,S,k,E,_,M,T,x=this._hash.words,P=f.words,I=h.words,O=s.words,R=u.words,C=c.words,B=l.words;for(S=o=x[0],k=a=x[1],E=d=x[2],_=w=x[3],M=A=x[4],r=0;r<80;r+=1)T=o+e[t+O[r]]|0,T+=r<16?p(a,d,w)+P[0]:r<32?m(a,d,w)+P[1]:r<48?y(a,d,w)+P[2]:r<64?g(a,d,w)+P[3]:b(a,d,w)+P[4],T=(T=v(T|=0,C[r]))+A|0,o=A,A=w,w=v(d,10),d=a,a=T,T=S+e[t+R[r]]|0,T+=r<16?b(k,E,_)+I[0]:r<32?g(k,E,_)+I[1]:r<48?y(k,E,_)+I[2]:r<64?m(k,E,_)+I[3]:p(k,E,_)+I[4],T=(T=v(T|=0,B[r]))+M|0,S=M,M=_,_=v(E,10),E=k,k=T;T=x[1]+d+_|0,x[1]=x[2]+w+M|0,x[2]=x[3]+A+S|0,x[3]=x[4]+o+k|0,x[4]=x[0]+a+E|0,x[0]=T},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;t[n>>>5]|=128<<24-n%32,t[14+(n+64>>>9<<4)]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8),e.sigBytes=4*(t.length+1),this._process();for(var i=this._hash,o=i.words,a=0;a<5;a++){var s=o[a];o[a]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8)}return i},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function p(e,t,r){return e^t^r}function m(e,t,r){return e&t|~e&r}function y(e,t,r){return(e|~t)^r}function g(e,t,r){return e&r|t&~r}function b(e,t,r){return e^(t|~r)}function v(e,t){return e<>>32-t}t.RIPEMD160=o._createHelper(d),t.HmacRIPEMD160=o._createHmacHelper(d)}(Math),n.RIPEMD160)},62783:function(e,t,r){var n,i,o,a,s,u,c,l;e.exports=(l=r(78249),i=(n=l).lib,o=i.WordArray,a=i.Hasher,s=n.algo,u=[],c=s.SHA1=a.extend({_doReset:function(){this._hash=new o.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],c=0;c<80;c++){if(c<16)u[c]=0|e[t+c];else{var l=u[c-3]^u[c-8]^u[c-14]^u[c-16];u[c]=l<<1|l>>>31}var f=(n<<5|n>>>27)+s+u[c];f+=c<20?1518500249+(i&o|~i&a):c<40?1859775393+(i^o^a):c<60?(i&o|i&a|o&a)-1894007588:(i^o^a)-899497514,s=a,a=o,o=i<<30|i>>>2,i=n,n=f}r[0]=r[0]+n|0,r[1]=r[1]+i|0,r[2]=r[2]+o|0,r[3]=r[3]+a|0,r[4]=r[4]+s|0},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;return t[n>>>5]|=128<<24-n%32,t[14+(n+64>>>9<<4)]=Math.floor(r/4294967296),t[15+(n+64>>>9<<4)]=r,e.sigBytes=4*t.length,this._process(),this._hash},clone:function(){var e=a.clone.call(this);return e._hash=this._hash.clone(),e}}),n.SHA1=a._createHelper(c),n.HmacSHA1=a._createHmacHelper(c),l.SHA1)},87792:function(e,t,r){var n,i,o,a,s,u;e.exports=(u=r(78249),r(52153),i=(n=u).lib.WordArray,o=n.algo,a=o.SHA256,s=o.SHA224=a.extend({_doReset:function(){this._hash=new i.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var e=a._doFinalize.call(this);return e.sigBytes-=4,e}}),n.SHA224=a._createHelper(s),n.HmacSHA224=a._createHmacHelper(s),u.SHA224)},52153:function(e,t,r){var n;e.exports=(n=r(78249),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.algo,s=[],u=[];!function(){function t(t){for(var r=e.sqrt(t),n=2;n<=r;n++)if(!(t%n))return!1;return!0}function r(e){return 4294967296*(e-(0|e))|0}for(var n=2,i=0;i<64;)t(n)&&(i<8&&(s[i]=r(e.pow(n,.5))),u[i]=r(e.pow(n,1/3)),i++),n++}();var c=[],l=a.SHA256=o.extend({_doReset:function(){this._hash=new i.init(s.slice(0))},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],l=r[5],f=r[6],h=r[7],d=0;d<64;d++){if(d<16)c[d]=0|e[t+d];else{var p=c[d-15],m=(p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3,y=c[d-2],g=(y<<15|y>>>17)^(y<<13|y>>>19)^y>>>10;c[d]=m+c[d-7]+g+c[d-16]}var b=n&i^n&o^i&o,v=(n<<30|n>>>2)^(n<<19|n>>>13)^(n<<10|n>>>22),w=h+((s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25))+(s&l^~s&f)+u[d]+c[d];h=f,f=l,l=s,s=a+w|0,a=o,o=i,i=n,n=w+(v+b)|0}r[0]=r[0]+n|0,r[1]=r[1]+i|0,r[2]=r[2]+o|0,r[3]=r[3]+a|0,r[4]=r[4]+s|0,r[5]=r[5]+l|0,r[6]=r[6]+f|0,r[7]=r[7]+h|0},_doFinalize:function(){var t=this._data,r=t.words,n=8*this._nDataBytes,i=8*t.sigBytes;return r[i>>>5]|=128<<24-i%32,r[14+(i+64>>>9<<4)]=e.floor(n/4294967296),r[15+(i+64>>>9<<4)]=n,t.sigBytes=4*r.length,this._process(),this._hash},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=o._createHelper(l),t.HmacSHA256=o._createHmacHelper(l)}(Math),n.SHA256)},13327:function(e,t,r){var n;e.exports=(n=r(78249),r(64938),function(e){var t=n,r=t.lib,i=r.WordArray,o=r.Hasher,a=t.x64.Word,s=t.algo,u=[],c=[],l=[];!function(){for(var e=1,t=0,r=0;r<24;r++){u[e+5*t]=(r+1)*(r+2)/2%64;var n=(2*e+3*t)%5;e=t%5,t=n}for(e=0;e<5;e++)for(t=0;t<5;t++)c[e+5*t]=t+(2*e+3*t)%5*5;for(var i=1,o=0;o<24;o++){for(var s=0,f=0,h=0;h<7;h++){if(1&i){var d=(1<>>24)|4278255360&(o<<24|o>>>8),a=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),(x=r[i]).high^=a,x.low^=o}for(var s=0;s<24;s++){for(var h=0;h<5;h++){for(var d=0,p=0,m=0;m<5;m++)d^=(x=r[h+5*m]).high,p^=x.low;var y=f[h];y.high=d,y.low=p}for(h=0;h<5;h++){var g=f[(h+4)%5],b=f[(h+1)%5],v=b.high,w=b.low;for(d=g.high^(v<<1|w>>>31),p=g.low^(w<<1|v>>>31),m=0;m<5;m++)(x=r[h+5*m]).high^=d,x.low^=p}for(var A=1;A<25;A++){var S=(x=r[A]).high,k=x.low,E=u[A];E<32?(d=S<>>32-E,p=k<>>32-E):(d=k<>>64-E,p=S<>>64-E);var _=f[c[A]];_.high=d,_.low=p}var M=f[0],T=r[0];for(M.high=T.high,M.low=T.low,h=0;h<5;h++)for(m=0;m<5;m++){var x=r[A=h+5*m],P=f[A],I=f[(h+1)%5+5*m],O=f[(h+2)%5+5*m];x.high=P.high^~I.high&O.high,x.low=P.low^~I.low&O.low}x=r[0];var R=l[s];x.high^=R.high,x.low^=R.low}},_doFinalize:function(){var t=this._data,r=t.words,n=(this._nDataBytes,8*t.sigBytes),o=32*this.blockSize;r[n>>>5]|=1<<24-n%32,r[(e.ceil((n+1)/o)*o>>>5)-1]|=128,t.sigBytes=4*r.length,this._process();for(var a=this._state,s=this.cfg.outputLength/8,u=s/8,c=[],l=0;l>>24)|4278255360&(h<<24|h>>>8),d=16711935&(d<<8|d>>>24)|4278255360&(d<<24|d>>>8),c.push(d),c.push(h)}return new i.init(c,s)},clone:function(){for(var e=o.clone.call(this),t=e._state=this._state.slice(0),r=0;r<25;r++)t[r]=t[r].clone();return e}});t.SHA3=o._createHelper(h),t.HmacSHA3=o._createHmacHelper(h)}(Math),n.SHA3)},17460:function(e,t,r){var n,i,o,a,s,u,c,l;e.exports=(l=r(78249),r(64938),r(70034),i=(n=l).x64,o=i.Word,a=i.WordArray,s=n.algo,u=s.SHA512,c=s.SHA384=u.extend({_doReset:function(){this._hash=new a.init([new o.init(3418070365,3238371032),new o.init(1654270250,914150663),new o.init(2438529370,812702999),new o.init(355462360,4144912697),new o.init(1731405415,4290775857),new o.init(2394180231,1750603025),new o.init(3675008525,1694076839),new o.init(1203062813,3204075428)])},_doFinalize:function(){var e=u._doFinalize.call(this);return e.sigBytes-=16,e}}),n.SHA384=u._createHelper(c),n.HmacSHA384=u._createHmacHelper(c),l.SHA384)},70034:function(e,t,r){var n;e.exports=(n=r(78249),r(64938),function(){var e=n,t=e.lib.Hasher,r=e.x64,i=r.Word,o=r.WordArray,a=e.algo;function s(){return i.create.apply(i,arguments)}var u=[s(1116352408,3609767458),s(1899447441,602891725),s(3049323471,3964484399),s(3921009573,2173295548),s(961987163,4081628472),s(1508970993,3053834265),s(2453635748,2937671579),s(2870763221,3664609560),s(3624381080,2734883394),s(310598401,1164996542),s(607225278,1323610764),s(1426881987,3590304994),s(1925078388,4068182383),s(2162078206,991336113),s(2614888103,633803317),s(3248222580,3479774868),s(3835390401,2666613458),s(4022224774,944711139),s(264347078,2341262773),s(604807628,2007800933),s(770255983,1495990901),s(1249150122,1856431235),s(1555081692,3175218132),s(1996064986,2198950837),s(2554220882,3999719339),s(2821834349,766784016),s(2952996808,2566594879),s(3210313671,3203337956),s(3336571891,1034457026),s(3584528711,2466948901),s(113926993,3758326383),s(338241895,168717936),s(666307205,1188179964),s(773529912,1546045734),s(1294757372,1522805485),s(1396182291,2643833823),s(1695183700,2343527390),s(1986661051,1014477480),s(2177026350,1206759142),s(2456956037,344077627),s(2730485921,1290863460),s(2820302411,3158454273),s(3259730800,3505952657),s(3345764771,106217008),s(3516065817,3606008344),s(3600352804,1432725776),s(4094571909,1467031594),s(275423344,851169720),s(430227734,3100823752),s(506948616,1363258195),s(659060556,3750685593),s(883997877,3785050280),s(958139571,3318307427),s(1322822218,3812723403),s(1537002063,2003034995),s(1747873779,3602036899),s(1955562222,1575990012),s(2024104815,1125592928),s(2227730452,2716904306),s(2361852424,442776044),s(2428436474,593698344),s(2756734187,3733110249),s(3204031479,2999351573),s(3329325298,3815920427),s(3391569614,3928383900),s(3515267271,566280711),s(3940187606,3454069534),s(4118630271,4000239992),s(116418474,1914138554),s(174292421,2731055270),s(289380356,3203993006),s(460393269,320620315),s(685471733,587496836),s(852142971,1086792851),s(1017036298,365543100),s(1126000580,2618297676),s(1288033470,3409855158),s(1501505948,4234509866),s(1607167915,987167468),s(1816402316,1246189591)],c=[];!function(){for(var e=0;e<80;e++)c[e]=s()}();var l=a.SHA512=t.extend({_doReset:function(){this._hash=new o.init([new i.init(1779033703,4089235720),new i.init(3144134277,2227873595),new i.init(1013904242,4271175723),new i.init(2773480762,1595750129),new i.init(1359893119,2917565137),new i.init(2600822924,725511199),new i.init(528734635,4215389547),new i.init(1541459225,327033209)])},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],l=r[5],f=r[6],h=r[7],d=n.high,p=n.low,m=i.high,y=i.low,g=o.high,b=o.low,v=a.high,w=a.low,A=s.high,S=s.low,k=l.high,E=l.low,_=f.high,M=f.low,T=h.high,x=h.low,P=d,I=p,O=m,R=y,C=g,B=b,N=v,L=w,U=A,F=S,D=k,j=E,H=_,J=M,z=T,G=x,q=0;q<80;q++){var K=c[q];if(q<16)var V=K.high=0|e[t+2*q],X=K.low=0|e[t+2*q+1];else{var Q=c[q-15],W=Q.high,Z=Q.low,Y=(W>>>1|Z<<31)^(W>>>8|Z<<24)^W>>>7,$=(Z>>>1|W<<31)^(Z>>>8|W<<24)^(Z>>>7|W<<25),ee=c[q-2],te=ee.high,re=ee.low,ne=(te>>>19|re<<13)^(te<<3|re>>>29)^te>>>6,ie=(re>>>19|te<<13)^(re<<3|te>>>29)^(re>>>6|te<<26),oe=c[q-7],ae=oe.high,se=oe.low,ue=c[q-16],ce=ue.high,le=ue.low;V=(V=(V=Y+ae+((X=$+se)>>>0<$>>>0?1:0))+ne+((X+=ie)>>>0>>0?1:0))+ce+((X+=le)>>>0>>0?1:0),K.high=V,K.low=X}var fe,he=U&D^~U&H,de=F&j^~F&J,pe=P&O^P&C^O&C,me=I&R^I&B^R&B,ye=(P>>>28|I<<4)^(P<<30|I>>>2)^(P<<25|I>>>7),ge=(I>>>28|P<<4)^(I<<30|P>>>2)^(I<<25|P>>>7),be=(U>>>14|F<<18)^(U>>>18|F<<14)^(U<<23|F>>>9),ve=(F>>>14|U<<18)^(F>>>18|U<<14)^(F<<23|U>>>9),we=u[q],Ae=we.high,Se=we.low,ke=z+be+((fe=G+ve)>>>0>>0?1:0),Ee=ge+me;z=H,G=J,H=D,J=j,D=U,j=F,U=N+(ke=(ke=(ke=ke+he+((fe+=de)>>>0>>0?1:0))+Ae+((fe+=Se)>>>0>>0?1:0))+V+((fe+=X)>>>0>>0?1:0))+((F=L+fe|0)>>>0>>0?1:0)|0,N=C,L=B,C=O,B=R,O=P,R=I,P=ke+(ye+pe+(Ee>>>0>>0?1:0))+((I=fe+Ee|0)>>>0>>0?1:0)|0}p=n.low=p+I,n.high=d+P+(p>>>0>>0?1:0),y=i.low=y+R,i.high=m+O+(y>>>0>>0?1:0),b=o.low=b+B,o.high=g+C+(b>>>0>>0?1:0),w=a.low=w+L,a.high=v+N+(w>>>0>>0?1:0),S=s.low=S+F,s.high=A+U+(S>>>0>>0?1:0),E=l.low=E+j,l.high=k+D+(E>>>0>>0?1:0),M=f.low=M+J,f.high=_+H+(M>>>0>>0?1:0),x=h.low=x+G,h.high=T+z+(x>>>0>>0?1:0)},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;return t[n>>>5]|=128<<24-n%32,t[30+(n+128>>>10<<5)]=Math.floor(r/4294967296),t[31+(n+128>>>10<<5)]=r,e.sigBytes=4*t.length,this._process(),this._hash.toX32()},clone:function(){var e=t.clone.call(this);return e._hash=this._hash.clone(),e},blockSize:32});e.SHA512=t._createHelper(l),e.HmacSHA512=t._createHmacHelper(l)}(),n.SHA512)},94253:function(e,t,r){var n;e.exports=(n=r(78249),r(98269),r(68214),r(90888),r(75109),function(){var e=n,t=e.lib,r=t.WordArray,i=t.BlockCipher,o=e.algo,a=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],s=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],u=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],c=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],l=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],f=o.DES=i.extend({_doReset:function(){for(var e=this._key.words,t=[],r=0;r<56;r++){var n=a[r]-1;t[r]=e[n>>>5]>>>31-n%32&1}for(var i=this._subKeys=[],o=0;o<16;o++){var c=i[o]=[],l=u[o];for(r=0;r<24;r++)c[r/6|0]|=t[(s[r]-1+l)%28]<<31-r%6,c[4+(r/6|0)]|=t[28+(s[r+24]-1+l)%28]<<31-r%6;for(c[0]=c[0]<<1|c[0]>>>31,r=1;r<7;r++)c[r]=c[r]>>>4*(r-1)+3;c[7]=c[7]<<5|c[7]>>>27}var f=this._invSubKeys=[];for(r=0;r<16;r++)f[r]=i[15-r]},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._subKeys)},decryptBlock:function(e,t){this._doCryptBlock(e,t,this._invSubKeys)},_doCryptBlock:function(e,t,r){this._lBlock=e[t],this._rBlock=e[t+1],h.call(this,4,252645135),h.call(this,16,65535),d.call(this,2,858993459),d.call(this,8,16711935),h.call(this,1,1431655765);for(var n=0;n<16;n++){for(var i=r[n],o=this._lBlock,a=this._rBlock,s=0,u=0;u<8;u++)s|=c[u][((a^i[u])&l[u])>>>0];this._lBlock=a,this._rBlock=o^s}var f=this._lBlock;this._lBlock=this._rBlock,this._rBlock=f,h.call(this,1,1431655765),d.call(this,8,16711935),d.call(this,2,858993459),h.call(this,16,65535),h.call(this,4,252645135),e[t]=this._lBlock,e[t+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});function h(e,t){var r=(this._lBlock>>>e^this._rBlock)&t;this._rBlock^=r,this._lBlock^=r<>>e^this._lBlock)&t;this._lBlock^=r,this._rBlock^=r<{"use strict";t.utils=r(11278),t.Cipher=r(55756),t.DES=r(70778),t.CBC=r(39051),t.EDE=r(50651)},39051:(e,t,r)=>{"use strict";var n=r(79746),i=r(35717),o={};function a(e){n.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t{"use strict";var n=r(79746);function i(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}e.exports=i,i.prototype._init=function(){},i.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},i.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n0;n--)t+=this._buffer(e,t),r+=this._flushBuffer(i,r);return t+=this._buffer(e,t),i},i.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},i.prototype._pad=function(e,t){if(0===t)return!1;for(;t{"use strict";var n=r(79746),i=r(35717),o=r(11278),a=r(55756);function s(){this.tmp=new Array(2),this.keys=null}function u(e){a.call(this,e);var t=new s;this._desState=t,this.deriveKeys(t,e.key)}i(u,a),e.exports=u,u.create=function(e){return new u(e)};var c=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];u.prototype.deriveKeys=function(e,t){e.keys=new Array(32),n.equal(t.length,this.blockSize,"Invalid key length");var r=o.readUInt32BE(t,0),i=o.readUInt32BE(t,4);o.pc1(r,i,e.tmp,0),r=e.tmp[0],i=e.tmp[1];for(var a=0;a>>1];r=o.r28shl(r,s),i=o.r28shl(i,s),o.pc2(r,i,e.keys,a)}},u.prototype._update=function(e,t,r,n){var i=this._desState,a=o.readUInt32BE(e,t),s=o.readUInt32BE(e,t+4);o.ip(a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],"encrypt"===this.type?this._encrypt(i,a,s,i.tmp,0):this._decrypt(i,a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],o.writeUInt32BE(r,a,n),o.writeUInt32BE(r,s,n+4)},u.prototype._pad=function(e,t){for(var r=e.length-t,n=t;n>>0,a=h}o.rip(s,a,n,i)},u.prototype._decrypt=function(e,t,r,n,i){for(var a=r,s=t,u=e.keys.length-2;u>=0;u-=2){var c=e.keys[u],l=e.keys[u+1];o.expand(a,e.tmp,0),c^=e.tmp[0],l^=e.tmp[1];var f=o.substitute(c,l),h=a;a=(s^o.permute(f))>>>0,s=h}o.rip(a,s,n,i)}},50651:(e,t,r)=>{"use strict";var n=r(79746),i=r(35717),o=r(55756),a=r(70778);function s(e,t){n.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),i=t.slice(8,16),o=t.slice(16,24);this.ciphers="encrypt"===e?[a.create({type:"encrypt",key:r}),a.create({type:"decrypt",key:i}),a.create({type:"encrypt",key:o})]:[a.create({type:"decrypt",key:o}),a.create({type:"encrypt",key:i}),a.create({type:"decrypt",key:r})]}function u(e){o.call(this,e);var t=new s(this.type,this.options.key);this._edeState=t}i(u,o),e.exports=u,u.create=function(e){return new u(e)},u.prototype._update=function(e,t,r,n){var i=this._edeState;i.ciphers[0]._update(e,t,r,n),i.ciphers[1]._update(r,n,r,n),i.ciphers[2]._update(r,n,r,n)},u.prototype._pad=a.prototype._pad,u.prototype._unpad=a.prototype._unpad},11278:(e,t)=>{"use strict";t.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},t.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},t.ip=function(e,t,r,n){for(var i=0,o=0,a=6;a>=0;a-=2){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>>s+a&1}for(a=6;a>=0;a-=2){for(s=1;s<=25;s+=8)o<<=1,o|=t>>>s+a&1;for(s=1;s<=25;s+=8)o<<=1,o|=e>>>s+a&1}r[n+0]=i>>>0,r[n+1]=o>>>0},t.rip=function(e,t,r,n){for(var i=0,o=0,a=0;a<4;a++)for(var s=24;s>=0;s-=8)i<<=1,i|=t>>>s+a&1,i<<=1,i|=e>>>s+a&1;for(a=4;a<8;a++)for(s=24;s>=0;s-=8)o<<=1,o|=t>>>s+a&1,o<<=1,o|=e>>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.pc1=function(e,t,r,n){for(var i=0,o=0,a=7;a>=5;a--){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>s+a&1}for(s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(a=1;a<=3;a++){for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1;for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1}for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.r28shl=function(e,t){return e<>>28-t};var r=[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];t.pc2=function(e,t,n,i){for(var o=0,a=0,s=r.length>>>1,u=0;u>>r[u]&1;for(u=s;u>>r[u]&1;n[i+0]=o>>>0,n[i+1]=a>>>0},t.expand=function(e,t,r){var n=0,i=0;n=(1&e)<<5|e>>>27;for(var o=23;o>=15;o-=4)n<<=6,n|=e>>>o&63;for(o=11;o>=3;o-=4)i|=e>>>o&63,i<<=6;i|=(31&e)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=i>>>0};var n=[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];t.substitute=function(e,t){for(var r=0,i=0;i<4;i++){r<<=4,r|=n[64*i+(e>>>18-6*i&63)]}for(i=0;i<4;i++){r<<=4,r|=n[256+64*i+(t>>>18-6*i&63)]}return r>>>0};var i=[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];t.permute=function(e){for(var t=0,r=0;r>>i[r]&1;return t>>>0},t.padSplit=function(e,t,r){for(var n=e.toString(2);n.length{var n=r(48764).Buffer,i=r(43590),o=r(29799),a=r(57426);var s={binary:!0,hex:!0,base64:!0};t.DiffieHellmanGroup=t.createDiffieHellmanGroup=t.getDiffieHellman=function(e){var t=new n(o[e].prime,"hex"),r=new n(o[e].gen,"hex");return new a(t,r)},t.createDiffieHellman=t.DiffieHellman=function e(t,r,o,u){return n.isBuffer(r)||void 0===s[r]?e(t,"binary",r,o):(r=r||"binary",u=u||"binary",o=o||new n([2]),n.isBuffer(o)||(o=new n(o,u)),"number"==typeof t?new a(i(t,o),o,!0):(n.isBuffer(t)||(t=new n(t,r)),new a(t,o,!0)))}},57426:(e,t,r)=>{var n=r(48764).Buffer,i=r(83620),o=new(r(63047)),a=new i(24),s=new i(11),u=new i(10),c=new i(3),l=new i(7),f=r(43590),h=r(61798);function d(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._pub=new i(e),this}function p(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._priv=new i(e),this}e.exports=y;var m={};function y(e,t,r){this.setGenerator(t),this.__prime=new i(e),this._prime=i.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=d,this.setPrivateKey=p):this._primeCode=8}function g(e,t){var r=new n(e.toArray());return t?r.toString(t):r}Object.defineProperty(y.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),n=[r,e.toString(16)].join("_");if(n in m)return m[n];var i,h=0;if(e.isEven()||!f.simpleSieve||!f.fermatTest(e)||!o.test(e))return h+=1,h+="02"===r||"05"===r?8:4,m[n]=h,h;switch(o.test(e.shrn(1))||(h+=2),r){case"02":e.mod(a).cmp(s)&&(h+=8);break;case"05":(i=e.mod(u)).cmp(c)&&i.cmp(l)&&(h+=8);break;default:h+=4}return m[n]=h,h}(this.__prime,this.__gen)),this._primeCode}}),y.prototype.generateKeys=function(){return this._priv||(this._priv=new i(h(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},y.prototype.computeSecret=function(e){var t=(e=(e=new i(e)).toRed(this._prime)).redPow(this._priv).fromRed(),r=new n(t.toArray()),o=this.getPrime();if(r.length{var n=r(61798);e.exports=b,b.simpleSieve=y,b.fermatTest=g;var i=r(83620),o=new i(24),a=new(r(63047)),s=new i(1),u=new i(2),c=new i(5),l=(new i(16),new i(8),new i(10)),f=new i(3),h=(new i(7),new i(11)),d=new i(4),p=(new i(12),null);function m(){if(null!==p)return p;var e=[];e[0]=2;for(var t=1,r=3;r<1048576;r+=2){for(var n=Math.ceil(Math.sqrt(r)),i=0;ie;)r.ishrn(1);if(r.isEven()&&r.iadd(s),r.testn(1)||r.iadd(u),t.cmp(u)){if(!t.cmp(c))for(;r.mod(l).cmp(f);)r.iadd(d)}else for(;r.mod(o).cmp(h);)r.iadd(d);if(y(p=r.shrn(1))&&y(r)&&g(p)&&g(r)&&a.test(p)&&a.test(r))return r}}},83620:function(e,t,r){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(7748).Buffer}catch(e){}function s(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},86266:(e,t,r)=>{"use strict";var n=t;n.version=r(18597).i8,n.utils=r(80953),n.rand=r(29931),n.curve=r(88254),n.curves=r(45427),n.ec=r(57954),n.eddsa=r(65980)},4918:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953),o=i.getNAF,a=i.getJSF,s=i.assert;function u(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function c(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=u,u.prototype.point=function(){throw new Error("Not implemented")},u.prototype.validate=function(){throw new Error("Not implemented")},u.prototype._fixedNafMul=function(e,t){s(e.precomputed);var r=e._getDoubles(),n=o(t,1,this._bitLength),i=(1<=a;l--)u=(u<<1)+n[l];c.push(u)}for(var f=this.jpoint(null,null,null),h=this.jpoint(null,null,null),d=i;d>0;d--){for(a=0;a=0;c--){for(var l=0;c>=0&&0===a[c];c--)l++;if(c>=0&&l++,u=u.dblp(l),c<0)break;var f=a[c];s(0!==f),u="affine"===e.type?f>0?u.mixedAdd(i[f-1>>1]):u.mixedAdd(i[-f-1>>1].neg()):f>0?u.add(i[f-1>>1]):u.add(i[-f-1>>1].neg())}return"affine"===e.type?u.toP():u},u.prototype._wnafMulAdd=function(e,t,r,n,i){var s,u,c,l=this._wnafT1,f=this._wnafT2,h=this._wnafT3,d=0;for(s=0;s=1;s-=2){var m=s-1,y=s;if(1===l[m]&&1===l[y]){var g=[t[m],null,null,t[y]];0===t[m].y.cmp(t[y].y)?(g[1]=t[m].add(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg())):0===t[m].y.cmp(t[y].y.redNeg())?(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].add(t[y].neg())):(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg()));var b=[-3,-1,-5,-7,0,7,5,1,3],v=a(r[m],r[y]);for(d=Math.max(v[0].length,d),h[m]=new Array(d),h[y]=new Array(d),u=0;u=0;s--){for(var E=0;s>=0;){var _=!0;for(u=0;u=0&&E++,S=S.dblp(E),s<0)break;for(u=0;u0?c=f[u][M-1>>1]:M<0&&(c=f[u][-M-1>>1].neg()),S="affine"===c.type?S.mixedAdd(c):S.add(c))}}for(s=0;s=Math.ceil((e.bitLength()+1)/t.step)},c.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i{"use strict";var n=r(80953),i=r(73785),o=r(35717),a=r(4918),s=n.assert;function u(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,a.call(this,"edwards",e),this.a=new i(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new i(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new i(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function c(e,t,r,n,o){a.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===n?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new i(t,16),this.y=new i(r,16),this.z=n?new i(n,16):this.curve.one,this.t=o&&new i(o,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}o(u,a),e.exports=u,u.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},u.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},u.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=n.redMul(o.redInvm()),s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");var u=s.fromRed().isOdd();return(t&&!u||!t&&u)&&(s=s.redNeg()),this.point(e,s)},u.prototype.pointFromY=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=n.redMul(o.redInvm());if(0===a.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");return s.fromRed().isOdd()!==t&&(s=s.redNeg()),this.point(s,e)},u.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===n.cmp(i)},o(c,a.BasePoint),u.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},u.prototype.point=function(e,t,r,n){return new c(this,e,t,r,n)},c.fromJSON=function(e,t){return new c(e,t[0],t[1],t[2])},c.prototype.inspect=function(){return this.isInfinity()?"":""},c.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},c.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),o=n.redAdd(t),a=o.redSub(r),s=n.redSub(t),u=i.redMul(a),c=o.redMul(s),l=i.redMul(s),f=a.redMul(o);return this.curve.point(u,c,f,l)},c.prototype._projDbl=function(){var e,t,r,n,i,o,a=this.x.redAdd(this.y).redSqr(),s=this.x.redSqr(),u=this.y.redSqr();if(this.curve.twisted){var c=(n=this.curve._mulA(s)).redAdd(u);this.zOne?(e=a.redSub(s).redSub(u).redMul(c.redSub(this.curve.two)),t=c.redMul(n.redSub(u)),r=c.redSqr().redSub(c).redSub(c)):(i=this.z.redSqr(),o=c.redSub(i).redISub(i),e=a.redSub(s).redISub(u).redMul(o),t=c.redMul(n.redSub(u)),r=c.redMul(o))}else n=s.redAdd(u),i=this.curve._mulC(this.z).redSqr(),o=n.redSub(i).redSub(i),e=this.curve._mulC(a.redISub(n)).redMul(o),t=this.curve._mulC(n).redMul(s.redISub(u)),r=n.redMul(o);return this.curve.point(e,t,r)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},c.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),o=r.redSub(t),a=i.redSub(n),s=i.redAdd(n),u=r.redAdd(t),c=o.redMul(a),l=s.redMul(u),f=o.redMul(u),h=a.redMul(s);return this.curve.point(c,l,h,f)},c.prototype._projAdd=function(e){var t,r,n=this.z.redMul(e.z),i=n.redSqr(),o=this.x.redMul(e.x),a=this.y.redMul(e.y),s=this.curve.d.redMul(o).redMul(a),u=i.redSub(s),c=i.redAdd(s),l=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(o).redISub(a),f=n.redMul(u).redMul(l);return this.curve.twisted?(t=n.redMul(c).redMul(a.redSub(this.curve._mulA(o))),r=u.redMul(c)):(t=n.redMul(c).redMul(a.redSub(o)),r=this.curve._mulC(u).redMul(c)),this.curve.point(f,t,r)},c.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},c.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},c.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},c.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},c.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()},c.prototype.getY=function(){return this.normalize(),this.y.fromRed()},c.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},c.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(n),0===this.x.cmp(t))return!0}},c.prototype.toP=c.prototype.normalize,c.prototype.mixedAdd=c.prototype.add},88254:(e,t,r)=>{"use strict";var n=t;n.base=r(4918),n.short=r(6673),n.mont=r(22881),n.edwards=r(31138)},22881:(e,t,r)=>{"use strict";var n=r(73785),i=r(35717),o=r(4918),a=r(80953);function s(e){o.call(this,"mont",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.i4=new n(4).toRed(this.red).redInvm(),this.two=new n(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function u(e,t,r){o.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new n(t,16),this.z=new n(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}i(s,o),e.exports=s,s.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===n.redSqrt().redSqr().cmp(n)},i(u,o.BasePoint),s.prototype.decodePoint=function(e,t){return this.point(a.toArray(e,t),1)},s.prototype.point=function(e,t){return new u(this,e,t)},s.prototype.pointFromJSON=function(e){return u.fromJSON(this,e)},u.prototype.precompute=function(){},u.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},u.fromJSON=function(e,t){return new u(e,t[0],t[1]||e.one)},u.prototype.inspect=function(){return this.isInfinity()?"":""},u.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},u.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),n=e.redMul(t),i=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(n,i)},u.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),o=e.x.redSub(e.z).redMul(r),a=i.redMul(n),s=t.z.redMul(o.redAdd(a).redSqr()),u=t.x.redMul(o.redISub(a).redSqr());return this.curve.point(s,u)},u.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=[];0!==t.cmpn(0);t.iushrn(1))i.push(t.andln(1));for(var o=i.length-1;o>=0;o--)0===i[o]?(r=r.diffAdd(n,this),n=n.dbl()):(n=r.diffAdd(n,this),r=r.dbl());return n},u.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},u.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},u.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},6673:(e,t,r)=>{"use strict";var n=r(80953),i=r(73785),o=r(35717),a=r(4918),s=n.assert;function u(e){a.call(this,"short",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.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(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function c(e,t,r,n){a.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new i(t,16),this.y=new i(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function l(e,t,r,n){a.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new i(0)):(this.x=new i(t,16),this.y=new i(r,16),this.z=new i(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}o(u,a),e.exports=u,u.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new i(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new i(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],s(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new i(e.a,16),b:new i(e.b,16)}})):this._getEndoBasis(r)}}},u.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:i.mont(e),r=new i(2).toRed(t).redInvm(),n=r.redNeg(),o=new i(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(o).fromRed(),n.redSub(o).fromRed()]},u.prototype._getEndoBasis=function(e){for(var t,r,n,o,a,s,u,c,l,f=this.n.ushrn(Math.floor(this.n.bitLength()/2)),h=e,d=this.n.clone(),p=new i(1),m=new i(0),y=new i(0),g=new i(1),b=0;0!==h.cmpn(0);){var v=d.div(h);c=d.sub(v.mul(h)),l=y.sub(v.mul(p));var w=g.sub(v.mul(m));if(!n&&c.cmp(f)<0)t=u.neg(),r=p,n=c.neg(),o=l;else if(n&&2==++b)break;u=c,d=h,h=c,y=p,p=l,g=m,m=w}a=c.neg(),s=l;var A=n.sqr().add(o.sqr());return a.sqr().add(s.sqr()).cmp(A)>=0&&(a=t,s=r),n.negative&&(n=n.neg(),o=o.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:n,b:o},{a,b:s}]},u.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=n.fromRed().isOdd();return(t&&!o||!t&&o)&&(n=n.redNeg()),this.point(e,n)},u.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},u.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},c.prototype.isInfinity=function(){return this.inf},c.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},c.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},c.prototype.getX=function(){return this.x.fromRed()},c.prototype.getY=function(){return this.y.fromRed()},c.prototype.mul=function(e){return e=new i(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},c.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},c.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},c.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},c.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(l,a.BasePoint),u.prototype.jpoint=function(e,t,r){return new l(this,e,t,r)},l.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},l.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},l.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},l.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},l.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},l.prototype.inspect=function(){return this.isInfinity()?"":""},l.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},45427:(e,t,r)=>{"use strict";var n,i=t,o=r(33715),a=r(88254),s=r(80953).assert;function u(e){"short"===e.type?this.curve=new a.short(e):"edwards"===e.type?this.curve=new a.edwards(e):this.curve=new a.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,s(this.g.validate(),"Invalid curve"),s(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(i,e,{configurable:!0,enumerable:!0,get:function(){var r=new u(t);return Object.defineProperty(i,e,{configurable:!0,enumerable:!0,value:r}),r}})}i.PresetCurve=u,c("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:o.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("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:o.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("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:o.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("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:o.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"]}),c("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:o.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"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["9"]}),c("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:o.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{n=r(91037)}catch(e){n=void 0}c("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:o.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",n]})},57954:(e,t,r)=>{"use strict";var n=r(73785),i=r(2156),o=r(80953),a=r(45427),s=r(29931),u=o.assert,c=r(31251),l=r(90611);function f(e){if(!(this instanceof f))return new f(e);"string"==typeof e&&(u(Object.prototype.hasOwnProperty.call(a,e),"Unknown curve "+e),e=a[e]),e instanceof a.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=f,f.prototype.keyPair=function(e){return new c(this,e)},f.prototype.keyFromPrivate=function(e,t){return c.fromPrivate(this,e,t)},f.prototype.keyFromPublic=function(e,t){return c.fromPublic(this,e,t)},f.prototype.genKeyPair=function(e){e||(e={});for(var t=new i({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||s(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),o=this.n.sub(new n(2));;){var a=new n(t.generate(r));if(!(a.cmp(o)>0))return a.iaddn(1),this.keyFromPrivate(a)}},f.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},f.prototype.sign=function(e,t,r,o){"object"==typeof r&&(o=r,r=null),o||(o={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new n(e,16));for(var a=this.n.byteLength(),s=t.getPrivate().toArray("be",a),u=e.toArray("be",a),c=new i({hash:this.hash,entropy:s,nonce:u,pers:o.pers,persEnc:o.persEnc||"utf8"}),f=this.n.sub(new n(1)),h=0;;h++){var d=o.k?o.k(h):new n(c.generate(this.n.byteLength()));if(!((d=this._truncateToN(d,!0)).cmpn(1)<=0||d.cmp(f)>=0)){var p=this.g.mul(d);if(!p.isInfinity()){var m=p.getX(),y=m.umod(this.n);if(0!==y.cmpn(0)){var g=d.invm(this.n).mul(y.mul(t.getPrivate()).iadd(e));if(0!==(g=g.umod(this.n)).cmpn(0)){var b=(p.getY().isOdd()?1:0)|(0!==m.cmp(y)?2:0);return o.canonical&&g.cmp(this.nh)>0&&(g=this.n.sub(g),b^=1),new l({r:y,s:g,recoveryParam:b})}}}}}},f.prototype.verify=function(e,t,r,i){e=this._truncateToN(new n(e,16)),r=this.keyFromPublic(r,i);var o=(t=new l(t,"hex")).r,a=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),c=u.mul(e).umod(this.n),f=u.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(c,r.getPublic(),f)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(c,r.getPublic(),f)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},f.prototype.recoverPubKey=function(e,t,r,i){u((3&r)===r,"The recovery param is more than two bits"),t=new l(t,i);var o=this.n,a=new n(e),s=t.r,c=t.s,f=1&r,h=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&h)throw new Error("Unable to find sencond key candinate");s=h?this.curve.pointFromX(s.add(this.curve.n),f):this.curve.pointFromX(s,f);var d=t.r.invm(o),p=o.sub(a).mul(d).umod(o),m=c.mul(d).umod(o);return this.g.mulAdd(p,s,m)},f.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new l(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")}},31251:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953).assert;function o(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=o,o.fromPublic=function(e,t,r){return t instanceof o?t:new o(e,{pub:t,pubEnc:r})},o.fromPrivate=function(e,t,r){return t instanceof o?t:new o(e,{priv:t,privEnc:r})},o.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.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"}},o.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},o.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},o.prototype._importPrivate=function(e,t){this.priv=new n(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},o.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?i(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||i(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},o.prototype.derive=function(e){return e.validate()||i(e.validate(),"public point not validated"),e.mul(this.priv).getX()},o.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},o.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},o.prototype.inspect=function(){return""}},90611:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953),o=i.assert;function a(e,t){if(e instanceof a)return e;this._importDER(e,t)||(o(e.r&&e.s,"Signature without r or s"),this.r=new n(e.r,16),this.s=new n(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function s(){this.place=0}function u(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function c(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}e.exports=a,a.prototype._importDER=function(e,t){e=i.toArray(e,t);var r=new s;if(48!==e[r.place++])return!1;var o=u(e,r);if(!1===o)return!1;if(o+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var a=u(e,r);if(!1===a)return!1;var c=e.slice(r.place,a+r.place);if(r.place+=a,2!==e[r.place++])return!1;var l=u(e,r);if(!1===l)return!1;if(e.length!==l+r.place)return!1;var f=e.slice(r.place,l+r.place);if(0===c[0]){if(!(128&c[1]))return!1;c=c.slice(1)}if(0===f[0]){if(!(128&f[1]))return!1;f=f.slice(1)}return this.r=new n(c),this.s=new n(f),this.recoveryParam=null,!0},a.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=c(t),r=c(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];l(n,t.length),(n=n.concat(t)).push(2),l(n,r.length);var o=n.concat(r),a=[48];return l(a,o.length),a=a.concat(o),i.encode(a,e)}},65980:(e,t,r)=>{"use strict";var n=r(33715),i=r(45427),o=r(80953),a=o.assert,s=o.parseBytes,u=r(79087),c=r(23622);function l(e){if(a("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof l))return new l(e);e=i[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=n.sha512}e.exports=l,l.prototype.sign=function(e,t){e=s(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),o=this.encodePoint(i),a=this.hashInt(o,r.pubBytes(),e).mul(r.priv()),u=n.add(a).umod(this.curve.n);return this.makeSignature({R:i,S:u,Rencoded:o})},l.prototype.verify=function(e,t,r){e=s(e),t=this.makeSignature(t);var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),o=this.g.mul(t.S());return t.R().add(n.pub().mul(i)).eq(o)},l.prototype.hashInt=function(){for(var e=this.hash(),t=0;t{"use strict";var n=r(80953),i=n.assert,o=n.parseBytes,a=n.cachedProperty;function s(e,t){this.eddsa=e,this._secret=o(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=o(t.pub)}s.fromPublic=function(e,t){return t instanceof s?t:new s(e,{pub:t})},s.fromSecret=function(e,t){return t instanceof s?t:new s(e,{secret:t})},s.prototype.secret=function(){return this._secret},a(s,"pubBytes",(function(){return this.eddsa.encodePoint(this.pub())})),a(s,"pub",(function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())})),a(s,"privBytes",(function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n})),a(s,"priv",(function(){return this.eddsa.decodeInt(this.privBytes())})),a(s,"hash",(function(){return this.eddsa.hash().update(this.secret()).digest()})),a(s,"messagePrefix",(function(){return this.hash().slice(this.eddsa.encodingLength)})),s.prototype.sign=function(e){return i(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},s.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},s.prototype.getSecret=function(e){return i(this._secret,"KeyPair is public only"),n.encode(this.secret(),e)},s.prototype.getPublic=function(e){return n.encode(this.pubBytes(),e)},e.exports=s},23622:(e,t,r)=>{"use strict";var n=r(73785),i=r(80953),o=i.assert,a=i.cachedProperty,s=i.parseBytes;function u(e,t){this.eddsa=e,"object"!=typeof t&&(t=s(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),o(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof n&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}a(u,"S",(function(){return this.eddsa.decodeInt(this.Sencoded())})),a(u,"R",(function(){return this.eddsa.decodePoint(this.Rencoded())})),a(u,"Rencoded",(function(){return this.eddsa.encodePoint(this.R())})),a(u,"Sencoded",(function(){return this.eddsa.encodeInt(this.S())})),u.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},u.prototype.toHex=function(){return i.encode(this.toBytes(),"hex").toUpperCase()},e.exports=u},91037:e=>{e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},80953:(e,t,r)=>{"use strict";var n=t,i=r(73785),o=r(79746),a=r(34504);n.assert=o,n.toArray=a.toArray,n.zero2=a.zero2,n.toHex=a.toHex,n.encode=a.encode,n.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!==(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!==(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"==typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new i(e,"hex","le")}},73785:function(e,t,r){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(85568).Buffer}catch(e){}function s(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},10639:(e,t,r)=>{"use strict";const n=r(97912);n.createWebSocketStream=r(73899),n.Server=r(25504),n.Receiver=r(75853),n.Sender=r(80877),n.WebSocket=n,n.WebSocketServer=n.Server,e.exports=n},65966:(e,t,r)=>{"use strict";var n=r(48764).Buffer;const{EMPTY_BUFFER:i}=r(62638);function o(e,t){if(0===e.length)return i;if(1===e.length)return e[0];const r=n.allocUnsafe(t);let o=0;for(let t=0;t{"use strict";var n=r(48764).Buffer;e.exports={BINARY_TYPES:["nodebuffer","arraybuffer","fragments"],EMPTY_BUFFER:n.alloc(0),GUID:"258EAFA5-E914-47DA-95CA-C5AB0DC85B11",kForOnEventAttribute:Symbol("kIsForOnEventAttribute"),kListener:Symbol("kListener"),kStatusCode:Symbol("status-code"),kWebSocket:Symbol("websocket"),NOOP:()=>{}}},27086:(e,t,r)=>{"use strict";const{kForOnEventAttribute:n,kListener:i}=r(62638),o=Symbol("kCode"),a=Symbol("kData"),s=Symbol("kError"),u=Symbol("kMessage"),c=Symbol("kReason"),l=Symbol("kTarget"),f=Symbol("kType"),h=Symbol("kWasClean");class d{constructor(e){this[l]=null,this[f]=e}get target(){return this[l]}get type(){return this[f]}}Object.defineProperty(d.prototype,"target",{enumerable:!0}),Object.defineProperty(d.prototype,"type",{enumerable:!0});class p extends d{constructor(e,t={}){super(e),this[o]=void 0===t.code?0:t.code,this[c]=void 0===t.reason?"":t.reason,this[h]=void 0!==t.wasClean&&t.wasClean}get code(){return this[o]}get reason(){return this[c]}get wasClean(){return this[h]}}Object.defineProperty(p.prototype,"code",{enumerable:!0}),Object.defineProperty(p.prototype,"reason",{enumerable:!0}),Object.defineProperty(p.prototype,"wasClean",{enumerable:!0});class m extends d{constructor(e,t={}){super(e),this[s]=void 0===t.error?null:t.error,this[u]=void 0===t.message?"":t.message}get error(){return this[s]}get message(){return this[u]}}Object.defineProperty(m.prototype,"error",{enumerable:!0}),Object.defineProperty(m.prototype,"message",{enumerable:!0});class y extends d{constructor(e,t={}){super(e),this[a]=void 0===t.data?null:t.data}get data(){return this[a]}}Object.defineProperty(y.prototype,"data",{enumerable:!0});const g={addEventListener(e,t,r={}){let o;if("message"===e)o=function(e,r){const n=new y("message",{data:r?e:e.toString()});n[l]=this,t.call(this,n)};else if("close"===e)o=function(e,r){const n=new p("close",{code:e,reason:r.toString(),wasClean:this._closeFrameReceived&&this._closeFrameSent});n[l]=this,t.call(this,n)};else if("error"===e)o=function(e){const r=new m("error",{error:e,message:e.message});r[l]=this,t.call(this,r)};else{if("open"!==e)return;o=function(){const e=new d("open");e[l]=this,t.call(this,e)}}o[n]=!!r[n],o[i]=t,r.once?this.once(e,o):this.on(e,o)},removeEventListener(e,t){for(const r of this.listeners(e))if(r[i]===t&&!r[n]){this.removeListener(e,r);break}}};e.exports={CloseEvent:p,ErrorEvent:m,Event:d,EventTarget:g,MessageEvent:y}},21800:(e,t,r)=>{"use strict";const{tokenChars:n}=r(42371);function i(e,t,r){void 0===e[t]?e[t]=[r]:e[t].push(r)}e.exports={format:function(e){return Object.keys(e).map((t=>{let r=e[t];return Array.isArray(r)||(r=[r]),r.map((e=>[t].concat(Object.keys(e).map((t=>{let r=e[t];return Array.isArray(r)||(r=[r]),r.map((e=>!0===e?t:`${t}=${e}`)).join("; ")}))).join("; "))).join(", ")})).join(", ")},parse:function(e){const t=Object.create(null);let r,o,a=Object.create(null),s=!1,u=!1,c=!1,l=-1,f=-1,h=-1,d=0;for(;d{"use strict";const t=Symbol("kDone"),r=Symbol("kRun");e.exports=class{constructor(e){this[t]=()=>{this.pending--,this[r]()},this.concurrency=e||1/0,this.jobs=[],this.pending=0}add(e){this.jobs.push(e),this[r]()}[r](){if(this.pending!==this.concurrency&&this.jobs.length){const e=this.jobs.shift();this.pending++,e(this[t])}}}},32702:(e,t,r)=>{"use strict";var n=r(48764).Buffer;const i=r(3996),o=r(65966),a=r(60964),{kStatusCode:s}=r(62638),u=n.from([0,0,255,255]),c=Symbol("permessage-deflate"),l=Symbol("total-length"),f=Symbol("callback"),h=Symbol("buffers"),d=Symbol("error");let p;function m(e){this[h].push(e),this[l]+=e.length}function y(e){this[l]+=e.length,this[c]._maxPayload<1||this[l]<=this[c]._maxPayload?this[h].push(e):(this[d]=new RangeError("Max payload size exceeded"),this[d].code="WS_ERR_UNSUPPORTED_MESSAGE_LENGTH",this[d][s]=1009,this.removeListener("data",y),this.reset())}function g(e){this[c]._inflate=null,e[s]=1007,this[f](e)}e.exports=class{constructor(e,t,r){if(this._maxPayload=0|r,this._options=e||{},this._threshold=void 0!==this._options.threshold?this._options.threshold:1024,this._isServer=!!t,this._deflate=null,this._inflate=null,this.params=null,!p){const e=void 0!==this._options.concurrencyLimit?this._options.concurrencyLimit:10;p=new a(e)}}static get extensionName(){return"permessage-deflate"}offer(){const e={};return this._options.serverNoContextTakeover&&(e.server_no_context_takeover=!0),this._options.clientNoContextTakeover&&(e.client_no_context_takeover=!0),this._options.serverMaxWindowBits&&(e.server_max_window_bits=this._options.serverMaxWindowBits),this._options.clientMaxWindowBits?e.client_max_window_bits=this._options.clientMaxWindowBits:null==this._options.clientMaxWindowBits&&(e.client_max_window_bits=!0),e}accept(e){return e=this.normalizeParams(e),this.params=this._isServer?this.acceptAsServer(e):this.acceptAsClient(e),this.params}cleanup(){if(this._inflate&&(this._inflate.close(),this._inflate=null),this._deflate){const e=this._deflate[f];this._deflate.close(),this._deflate=null,e&&e(new Error("The deflate stream was closed while data was being processed"))}}acceptAsServer(e){const t=this._options,r=e.find((e=>!(!1===t.serverNoContextTakeover&&e.server_no_context_takeover||e.server_max_window_bits&&(!1===t.serverMaxWindowBits||"number"==typeof t.serverMaxWindowBits&&t.serverMaxWindowBits>e.server_max_window_bits)||"number"==typeof t.clientMaxWindowBits&&!e.client_max_window_bits)));if(!r)throw new Error("None of the extension offers can be accepted");return t.serverNoContextTakeover&&(r.server_no_context_takeover=!0),t.clientNoContextTakeover&&(r.client_no_context_takeover=!0),"number"==typeof t.serverMaxWindowBits&&(r.server_max_window_bits=t.serverMaxWindowBits),"number"==typeof t.clientMaxWindowBits?r.client_max_window_bits=t.clientMaxWindowBits:!0!==r.client_max_window_bits&&!1!==t.clientMaxWindowBits||delete r.client_max_window_bits,r}acceptAsClient(e){const t=e[0];if(!1===this._options.clientNoContextTakeover&&t.client_no_context_takeover)throw new Error('Unexpected parameter "client_no_context_takeover"');if(t.client_max_window_bits){if(!1===this._options.clientMaxWindowBits||"number"==typeof this._options.clientMaxWindowBits&&t.client_max_window_bits>this._options.clientMaxWindowBits)throw new Error('Unexpected or invalid parameter "client_max_window_bits"')}else"number"==typeof this._options.clientMaxWindowBits&&(t.client_max_window_bits=this._options.clientMaxWindowBits);return t}normalizeParams(e){return e.forEach((e=>{Object.keys(e).forEach((t=>{let r=e[t];if(r.length>1)throw new Error(`Parameter "${t}" must have only a single value`);if(r=r[0],"client_max_window_bits"===t){if(!0!==r){const e=+r;if(!Number.isInteger(e)||e<8||e>15)throw new TypeError(`Invalid value for parameter "${t}": ${r}`);r=e}else if(!this._isServer)throw new TypeError(`Invalid value for parameter "${t}": ${r}`)}else if("server_max_window_bits"===t){const e=+r;if(!Number.isInteger(e)||e<8||e>15)throw new TypeError(`Invalid value for parameter "${t}": ${r}`);r=e}else{if("client_no_context_takeover"!==t&&"server_no_context_takeover"!==t)throw new Error(`Unknown parameter "${t}"`);if(!0!==r)throw new TypeError(`Invalid value for parameter "${t}": ${r}`)}e[t]=r}))})),e}decompress(e,t,r){p.add((n=>{this._decompress(e,t,((e,t)=>{n(),r(e,t)}))}))}compress(e,t,r){p.add((n=>{this._compress(e,t,((e,t)=>{n(),r(e,t)}))}))}_decompress(e,t,r){const n=this._isServer?"client":"server";if(!this._inflate){const e=`${n}_max_window_bits`,t="number"!=typeof this.params[e]?i.Z_DEFAULT_WINDOWBITS:this.params[e];this._inflate=i.createInflateRaw({...this._options.zlibInflateOptions,windowBits:t}),this._inflate[c]=this,this._inflate[l]=0,this._inflate[h]=[],this._inflate.on("error",g),this._inflate.on("data",y)}this._inflate[f]=r,this._inflate.write(e),t&&this._inflate.write(u),this._inflate.flush((()=>{const e=this._inflate[d];if(e)return this._inflate.close(),this._inflate=null,void r(e);const i=o.concat(this._inflate[h],this._inflate[l]);this._inflate._readableState.endEmitted?(this._inflate.close(),this._inflate=null):(this._inflate[l]=0,this._inflate[h]=[],t&&this.params[`${n}_no_context_takeover`]&&this._inflate.reset()),r(null,i)}))}_compress(e,t,r){const n=this._isServer?"server":"client";if(!this._deflate){const e=`${n}_max_window_bits`,t="number"!=typeof this.params[e]?i.Z_DEFAULT_WINDOWBITS:this.params[e];this._deflate=i.createDeflateRaw({...this._options.zlibDeflateOptions,windowBits:t}),this._deflate[l]=0,this._deflate[h]=[],this._deflate.on("data",m)}this._deflate[f]=r,this._deflate.write(e),this._deflate.flush(i.Z_SYNC_FLUSH,(()=>{if(!this._deflate)return;let e=o.concat(this._deflate[h],this._deflate[l]);t&&(e=e.slice(0,e.length-4)),this._deflate[f]=null,this._deflate[l]=0,this._deflate[h]=[],t&&this.params[`${n}_no_context_takeover`]&&this._deflate.reset(),r(null,e)}))}}},75853:(e,t,r)=>{"use strict";var n=r(48764).Buffer;const{Writable:i}=r(42830),o=r(32702),{BINARY_TYPES:a,EMPTY_BUFFER:s,kStatusCode:u,kWebSocket:c}=r(62638),{concat:l,toArrayBuffer:f,unmask:h}=r(65966),{isValidStatusCode:d,isValidUTF8:p}=r(42371);function m(e,t,r,n,i){const o=new e(r?`Invalid WebSocket frame: ${t}`:t);return Error.captureStackTrace(o,m),o.code=i,o[u]=n,o}e.exports=class extends i{constructor(e={}){super(),this._binaryType=e.binaryType||a[0],this._extensions=e.extensions||{},this._isServer=!!e.isServer,this._maxPayload=0|e.maxPayload,this._skipUTF8Validation=!!e.skipUTF8Validation,this[c]=void 0,this._bufferedBytes=0,this._buffers=[],this._compressed=!1,this._payloadLength=0,this._mask=void 0,this._fragmented=0,this._masked=!1,this._fin=!1,this._opcode=0,this._totalPayloadLength=0,this._messageLength=0,this._fragments=[],this._state=0,this._loop=!1}_write(e,t,r){if(8===this._opcode&&0==this._state)return r();this._bufferedBytes+=e.length,this._buffers.push(e),this.startLoop(r)}consume(e){if(this._bufferedBytes-=e,e===this._buffers[0].length)return this._buffers.shift();if(e=r.length?t.set(this._buffers.shift(),n):(t.set(new Uint8Array(r.buffer,r.byteOffset,e),n),this._buffers[0]=r.slice(e)),e-=r.length}while(e>0);return t}startLoop(e){let t;this._loop=!0;do{switch(this._state){case 0:t=this.getInfo();break;case 1:t=this.getPayloadLength16();break;case 2:t=this.getPayloadLength64();break;case 3:this.getMask();break;case 4:t=this.getData(e);break;default:return void(this._loop=!1)}}while(this._loop);e(t)}getInfo(){if(this._bufferedBytes<2)return void(this._loop=!1);const e=this.consume(2);if(0!=(48&e[0]))return this._loop=!1,m(RangeError,"RSV2 and RSV3 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_2_3");const t=64==(64&e[0]);if(t&&!this._extensions[o.extensionName])return this._loop=!1,m(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(this._fin=128==(128&e[0]),this._opcode=15&e[0],this._payloadLength=127&e[1],0===this._opcode){if(t)return this._loop=!1,m(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(!this._fragmented)return this._loop=!1,m(RangeError,"invalid opcode 0",!0,1002,"WS_ERR_INVALID_OPCODE");this._opcode=this._fragmented}else if(1===this._opcode||2===this._opcode){if(this._fragmented)return this._loop=!1,m(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");this._compressed=t}else{if(!(this._opcode>7&&this._opcode<11))return this._loop=!1,m(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");if(!this._fin)return this._loop=!1,m(RangeError,"FIN must be set",!0,1002,"WS_ERR_EXPECTED_FIN");if(t)return this._loop=!1,m(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(this._payloadLength>125)return this._loop=!1,m(RangeError,`invalid payload length ${this._payloadLength}`,!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH")}if(this._fin||this._fragmented||(this._fragmented=this._opcode),this._masked=128==(128&e[1]),this._isServer){if(!this._masked)return this._loop=!1,m(RangeError,"MASK must be set",!0,1002,"WS_ERR_EXPECTED_MASK")}else if(this._masked)return this._loop=!1,m(RangeError,"MASK must be clear",!0,1002,"WS_ERR_UNEXPECTED_MASK");if(126===this._payloadLength)this._state=1;else{if(127!==this._payloadLength)return this.haveLength();this._state=2}}getPayloadLength16(){if(!(this._bufferedBytes<2))return this._payloadLength=this.consume(2).readUInt16BE(0),this.haveLength();this._loop=!1}getPayloadLength64(){if(this._bufferedBytes<8)return void(this._loop=!1);const e=this.consume(8),t=e.readUInt32BE(0);return t>Math.pow(2,21)-1?(this._loop=!1,m(RangeError,"Unsupported WebSocket frame: payload length > 2^53 - 1",!1,1009,"WS_ERR_UNSUPPORTED_DATA_PAYLOAD_LENGTH")):(this._payloadLength=t*Math.pow(2,32)+e.readUInt32BE(4),this.haveLength())}haveLength(){if(this._payloadLength&&this._opcode<8&&(this._totalPayloadLength+=this._payloadLength,this._totalPayloadLength>this._maxPayload&&this._maxPayload>0))return this._loop=!1,m(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH");this._masked?this._state=3:this._state=4}getMask(){this._bufferedBytes<4?this._loop=!1:(this._mask=this.consume(4),this._state=4)}getData(e){let t=s;if(this._payloadLength){if(this._bufferedBytes7?this.controlMessage(t):this._compressed?(this._state=5,void this.decompress(t,e)):(t.length&&(this._messageLength=this._totalPayloadLength,this._fragments.push(t)),this.dataMessage())}decompress(e,t){this._extensions[o.extensionName].decompress(e,this._fin,((e,r)=>{if(e)return t(e);if(r.length){if(this._messageLength+=r.length,this._messageLength>this._maxPayload&&this._maxPayload>0)return t(m(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH"));this._fragments.push(r)}const n=this.dataMessage();if(n)return t(n);this.startLoop(t)}))}dataMessage(){if(this._fin){const e=this._messageLength,t=this._fragments;if(this._totalPayloadLength=0,this._messageLength=0,this._fragmented=0,this._fragments=[],2===this._opcode){let r;r="nodebuffer"===this._binaryType?l(t,e):"arraybuffer"===this._binaryType?f(l(t,e)):t,this.emit("message",r,!0)}else{const r=l(t,e);if(!this._skipUTF8Validation&&!p(r))return this._loop=!1,m(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");this.emit("message",r,!1)}}this._state=0}controlMessage(e){if(8===this._opcode)if(this._loop=!1,0===e.length)this.emit("conclude",1005,s),this.end();else{if(1===e.length)return m(RangeError,"invalid payload length 1",!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH");{const t=e.readUInt16BE(0);if(!d(t))return m(RangeError,`invalid status code ${t}`,!0,1002,"WS_ERR_INVALID_CLOSE_CODE");const r=e.slice(2);if(!this._skipUTF8Validation&&!p(r))return m(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");this.emit("conclude",t,r),this.end()}}else 9===this._opcode?this.emit("ping",e):this.emit("pong",e);this._state=0}}},80877:(e,t,r)=>{"use strict";var n=r(48764).Buffer;r(59477),r(32859);const{randomFillSync:i}=r(55835),o=r(32702),{EMPTY_BUFFER:a}=r(62638),{isValidStatusCode:s}=r(42371),{mask:u,toBuffer:c}=r(65966),l=Symbol("kByteLength"),f=n.alloc(4);class h{constructor(e,t,r){this._extensions=t||{},r&&(this._generateMask=r,this._maskBuffer=n.alloc(4)),this._socket=e,this._firstFragment=!0,this._compress=!1,this._bufferedBytes=0,this._deflating=!1,this._queue=[]}static frame(e,t){let r,o,a=!1,s=2,c=!1;t.mask&&(r=t.maskBuffer||f,t.generateMask?t.generateMask(r):i(r,0,4),c=0==(r[0]|r[1]|r[2]|r[3]),s=6),"string"==typeof e?o=t.mask&&!c||void 0===t[l]?(e=n.from(e)).length:t[l]:(o=e.length,a=t.mask&&t.readOnly&&!c);let h=o;o>=65536?(s+=8,h=127):o>125&&(s+=2,h=126);const d=n.allocUnsafe(a?o+s:s);return d[0]=t.fin?128|t.opcode:t.opcode,t.rsv1&&(d[0]|=64),d[1]=h,126===h?d.writeUInt16BE(o,2):127===h&&(d[2]=d[3]=0,d.writeUIntBE(o,4,6)),t.mask?(d[1]|=128,d[s-4]=r[0],d[s-3]=r[1],d[s-2]=r[2],d[s-1]=r[3],c?[d,e]:a?(u(e,r,d,s,o),[d]):(u(e,r,e,0,o),[d,e])):[d,e]}close(e,t,r,i){let o;if(void 0===e)o=a;else{if("number"!=typeof e||!s(e))throw new TypeError("First argument must be a valid error code number");if(void 0!==t&&t.length){const r=n.byteLength(t);if(r>123)throw new RangeError("The message must not be greater than 123 bytes");o=n.allocUnsafe(2+r),o.writeUInt16BE(e,0),"string"==typeof t?o.write(t,2):o.set(t,2)}else o=n.allocUnsafe(2),o.writeUInt16BE(e,0)}const u={[l]:o.length,fin:!0,generateMask:this._generateMask,mask:r,maskBuffer:this._maskBuffer,opcode:8,readOnly:!1,rsv1:!1};this._deflating?this.enqueue([this.dispatch,o,!1,u,i]):this.sendFrame(h.frame(o,u),i)}ping(e,t,r){let i,o;if("string"==typeof e?(i=n.byteLength(e),o=!1):(i=(e=c(e)).length,o=c.readOnly),i>125)throw new RangeError("The data size must not be greater than 125 bytes");const a={[l]:i,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:9,readOnly:o,rsv1:!1};this._deflating?this.enqueue([this.dispatch,e,!1,a,r]):this.sendFrame(h.frame(e,a),r)}pong(e,t,r){let i,o;if("string"==typeof e?(i=n.byteLength(e),o=!1):(i=(e=c(e)).length,o=c.readOnly),i>125)throw new RangeError("The data size must not be greater than 125 bytes");const a={[l]:i,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:10,readOnly:o,rsv1:!1};this._deflating?this.enqueue([this.dispatch,e,!1,a,r]):this.sendFrame(h.frame(e,a),r)}send(e,t,r){const i=this._extensions[o.extensionName];let a,s,u=t.binary?2:1,f=t.compress;if("string"==typeof e?(a=n.byteLength(e),s=!1):(a=(e=c(e)).length,s=c.readOnly),this._firstFragment?(this._firstFragment=!1,f&&i&&i.params[i._isServer?"server_no_context_takeover":"client_no_context_takeover"]&&(f=a>=i._threshold),this._compress=f):(f=!1,u=0),t.fin&&(this._firstFragment=!0),i){const n={[l]:a,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:u,readOnly:s,rsv1:f};this._deflating?this.enqueue([this.dispatch,e,this._compress,n,r]):this.dispatch(e,this._compress,n,r)}else this.sendFrame(h.frame(e,{[l]:a,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:u,readOnly:s,rsv1:!1}),r)}dispatch(e,t,r,n){if(!t)return void this.sendFrame(h.frame(e,r),n);const i=this._extensions[o.extensionName];this._bufferedBytes+=r[l],this._deflating=!0,i.compress(e,r.fin,((e,t)=>{if(this._socket.destroyed){const e=new Error("The socket was closed while data was being compressed");"function"==typeof n&&n(e);for(let t=0;t{"use strict";var n=r(34155);const{Duplex:i}=r(42830);function o(e){e.emit("close")}function a(){!this.destroyed&&this._writableState.finished&&this.destroy()}function s(e){this.removeListener("error",s),this.destroy(),0===this.listenerCount("error")&&this.emit("error",e)}e.exports=function(e,t){let r=!0;const u=new i({...t,autoDestroy:!1,emitClose:!1,objectMode:!1,writableObjectMode:!1});return e.on("message",(function(t,r){const n=!r&&u._readableState.objectMode?t.toString():t;u.push(n)||e.pause()})),e.once("error",(function(e){u.destroyed||(r=!1,u.destroy(e))})),e.once("close",(function(){u.destroyed||u.push(null)})),u._destroy=function(t,i){if(e.readyState===e.CLOSED)return i(t),void n.nextTick(o,u);let a=!1;e.once("error",(function(e){a=!0,i(e)})),e.once("close",(function(){a||i(t),n.nextTick(o,u)})),r&&e.terminate()},u._final=function(t){e.readyState!==e.CONNECTING?null!==e._socket&&(e._socket._writableState.finished?(t(),u._readableState.endEmitted&&u.destroy()):(e._socket.once("finish",(function(){t()})),e.close())):e.once("open",(function(){u._final(t)}))},u._read=function(){e.isPaused&&e.resume()},u._write=function(t,r,n){e.readyState!==e.CONNECTING?e.send(t,n):e.once("open",(function(){u._write(t,r,n)}))},u.on("end",a),u.on("error",s),u}},75151:(e,t,r)=>{"use strict";const{tokenChars:n}=r(42371);e.exports={parse:function(e){const t=new Set;let r=-1,i=-1,o=0;for(;o{"use strict";const n=[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,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0];function i(e){return e>=1e3&&e<=1014&&1004!==e&&1005!==e&&1006!==e||e>=3e3&&e<=4999}function o(e){const t=e.length;let r=0;for(;r=t||128!=(192&e[r+1])||128!=(192&e[r+2])||224===e[r]&&128==(224&e[r+1])||237===e[r]&&160==(224&e[r+1]))return!1;r+=3}else{if(240!=(248&e[r]))return!1;if(r+3>=t||128!=(192&e[r+1])||128!=(192&e[r+2])||128!=(192&e[r+3])||240===e[r]&&128==(240&e[r+1])||244===e[r]&&e[r+1]>143||e[r]>244)return!1;r+=4}return!0}try{const t=r(70311);e.exports={isValidStatusCode:i,isValidUTF8:e=>e.length<150?o(e):t(e),tokenChars:n}}catch(t){e.exports={isValidStatusCode:i,isValidUTF8:o,tokenChars:n}}},25504:(e,t,r)=>{"use strict";var n=r(34155),i=r(48764).Buffer;const o=r(17187),a=r(8501),{createHash:s}=(r(79267),r(59477),r(32859),r(55835)),u=r(21800),c=r(32702),l=r(75151),f=r(97912),{GUID:h,kWebSocket:d}=r(62638),p=/^[+/0-9A-Za-z]{22}==$/;function m(e){e._state=2,e.emit("close")}function y(){this.destroy()}function g(e,t,r,n){e.writable&&(r=r||a.STATUS_CODES[t],n={Connection:"close","Content-Type":"text/html","Content-Length":i.byteLength(r),...n},e.write(`HTTP/1.1 ${t} ${a.STATUS_CODES[t]}\r\n`+Object.keys(n).map((e=>`${e}: ${n[e]}`)).join("\r\n")+"\r\n\r\n"+r)),e.removeListener("error",y),e.destroy()}e.exports=class extends o{constructor(e,t){if(super(),null==(e={maxPayload:104857600,skipUTF8Validation:!1,perMessageDeflate:!1,handleProtocols:null,clientTracking:!0,verifyClient:null,noServer:!1,backlog:null,server:null,host:null,path:null,port:null,WebSocket:f,...e}).port&&!e.server&&!e.noServer||null!=e.port&&(e.server||e.noServer)||e.server&&e.noServer)throw new TypeError('One and only one of the "port", "server", or "noServer" options must be specified');if(null!=e.port?(this._server=a.createServer(((e,t)=>{const r=a.STATUS_CODES[426];t.writeHead(426,{"Content-Length":r.length,"Content-Type":"text/plain"}),t.end(r)})),this._server.listen(e.port,e.host,e.backlog,t)):e.server&&(this._server=e.server),this._server){const e=this.emit.bind(this,"connection");this._removeListeners=function(e,t){for(const r of Object.keys(t))e.on(r,t[r]);return function(){for(const r of Object.keys(t))e.removeListener(r,t[r])}}(this._server,{listening:this.emit.bind(this,"listening"),error:this.emit.bind(this,"error"),upgrade:(t,r,n)=>{this.handleUpgrade(t,r,n,e)}})}!0===e.perMessageDeflate&&(e.perMessageDeflate={}),e.clientTracking&&(this.clients=new Set,this._shouldEmitClose=!1),this.options=e,this._state=0}address(){if(this.options.noServer)throw new Error('The server is operating in "noServer" mode');return this._server?this._server.address():null}close(e){if(2===this._state)return e&&this.once("close",(()=>{e(new Error("The server is not running"))})),void n.nextTick(m,this);if(e&&this.once("close",e),1!==this._state)if(this._state=1,this.options.noServer||this.options.server)this._server&&(this._removeListeners(),this._removeListeners=this._server=null),this.clients&&this.clients.size?this._shouldEmitClose=!0:n.nextTick(m,this);else{const e=this._server;this._removeListeners(),this._removeListeners=this._server=null,e.close((()=>{m(this)}))}}shouldHandle(e){if(this.options.path){const t=e.url.indexOf("?");if((-1!==t?e.url.slice(0,t):e.url)!==this.options.path)return!1}return!0}handleUpgrade(e,t,r,n){t.on("error",y);const i=void 0!==e.headers["sec-websocket-key"]&&e.headers["sec-websocket-key"],o=+e.headers["sec-websocket-version"];if("GET"!==e.method||"websocket"!==e.headers.upgrade.toLowerCase()||!i||!p.test(i)||8!==o&&13!==o||!this.shouldHandle(e))return g(t,400);const a=e.headers["sec-websocket-protocol"];let s=new Set;if(void 0!==a)try{s=l.parse(a)}catch(e){return g(t,400)}const f=e.headers["sec-websocket-extensions"],h={};if(this.options.perMessageDeflate&&void 0!==f){const e=new c(this.options.perMessageDeflate,!0,this.options.maxPayload);try{const t=u.parse(f);t[c.extensionName]&&(e.accept(t[c.extensionName]),h[c.extensionName]=e)}catch(e){return g(t,400)}}if(this.options.verifyClient){const a={origin:e.headers[""+(8===o?"sec-websocket-origin":"origin")],secure:!(!e.socket.authorized&&!e.socket.encrypted),req:e};if(2===this.options.verifyClient.length)return void this.options.verifyClient(a,((o,a,u,c)=>{if(!o)return g(t,a||401,u,c);this.completeUpgrade(h,i,s,e,t,r,n)}));if(!this.options.verifyClient(a))return g(t,401)}this.completeUpgrade(h,i,s,e,t,r,n)}completeUpgrade(e,t,r,i,o,a,l){if(!o.readable||!o.writable)return o.destroy();if(o[d])throw new Error("server.handleUpgrade() was called more than once with the same socket, possibly due to a misconfiguration");if(this._state>0)return g(o,503);const f=["HTTP/1.1 101 Switching Protocols","Upgrade: websocket","Connection: Upgrade",`Sec-WebSocket-Accept: ${s("sha1").update(t+h).digest("base64")}`],p=new this.options.WebSocket(null);if(r.size){const e=this.options.handleProtocols?this.options.handleProtocols(r,i):r.values().next().value;e&&(f.push(`Sec-WebSocket-Protocol: ${e}`),p._protocol=e)}if(e[c.extensionName]){const t=e[c.extensionName].params,r=u.format({[c.extensionName]:[t]});f.push(`Sec-WebSocket-Extensions: ${r}`),p._extensions=e}this.emit("headers",f,i),o.write(f.concat("\r\n").join("\r\n")),o.removeListener("error",y),p.setSocket(o,a,{maxPayload:this.options.maxPayload,skipUTF8Validation:this.options.skipUTF8Validation}),this.clients&&(this.clients.add(p),p.on("close",(()=>{this.clients.delete(p),this._shouldEmitClose&&!this.clients.size&&n.nextTick(m,this)}))),l(p,i)}}},97912:(e,t,r)=>{"use strict";var n=r(48764).Buffer,i=r(34155);const o=r(17187),a=r(79267),s=r(8501),u=r(59477),c=r(32859),{randomBytes:l,createHash:f}=r(55835),{Readable:h}=r(42830),{URL:d}=r(8575),p=r(32702),m=r(75853),y=r(80877),{BINARY_TYPES:g,EMPTY_BUFFER:b,GUID:v,kForOnEventAttribute:w,kListener:A,kStatusCode:S,kWebSocket:k,NOOP:E}=r(62638),{EventTarget:{addEventListener:_,removeEventListener:M}}=r(27086),{format:T,parse:x}=r(21800),{toBuffer:P}=r(65966),I=["CONNECTING","OPEN","CLOSING","CLOSED"],O=/^[!#$%&'*+\-.0-9A-Z^_`|a-z~]+$/,R=[8,13];class C extends o{constructor(e,t,r){super(),this._binaryType=g[0],this._closeCode=1006,this._closeFrameReceived=!1,this._closeFrameSent=!1,this._closeMessage=b,this._closeTimer=null,this._extensions={},this._paused=!1,this._protocol="",this._readyState=C.CONNECTING,this._receiver=null,this._sender=null,this._socket=null,null!==e?(this._bufferedAmount=0,this._isServer=!1,this._redirects=0,void 0===t?t=[]:Array.isArray(t)||("object"==typeof t&&null!==t?(r=t,t=[]):t=[t]),B(this,e,t,r)):this._isServer=!0}get binaryType(){return this._binaryType}set binaryType(e){g.includes(e)&&(this._binaryType=e,this._receiver&&(this._receiver._binaryType=e))}get bufferedAmount(){return this._socket?this._socket._writableState.length+this._sender._bufferedBytes:this._bufferedAmount}get extensions(){return Object.keys(this._extensions).join()}get isPaused(){return this._paused}get onclose(){return null}get onerror(){return null}get onopen(){return null}get onmessage(){return null}get protocol(){return this._protocol}get readyState(){return this._readyState}get url(){return this._url}setSocket(e,t,r){const n=new m({binaryType:this.binaryType,extensions:this._extensions,isServer:this._isServer,maxPayload:r.maxPayload,skipUTF8Validation:r.skipUTF8Validation});this._sender=new y(e,this._extensions,r.generateMask),this._receiver=n,this._socket=e,n[k]=this,e[k]=this,n.on("conclude",j),n.on("drain",H),n.on("error",J),n.on("message",G),n.on("ping",q),n.on("pong",K),e.setTimeout(0),e.setNoDelay(),t.length>0&&e.unshift(t),e.on("close",X),e.on("data",Q),e.on("end",W),e.on("error",Z),this._readyState=C.OPEN,this.emit("open")}emitClose(){if(!this._socket)return this._readyState=C.CLOSED,void this.emit("close",this._closeCode,this._closeMessage);this._extensions[p.extensionName]&&this._extensions[p.extensionName].cleanup(),this._receiver.removeAllListeners(),this._readyState=C.CLOSED,this.emit("close",this._closeCode,this._closeMessage)}close(e,t){if(this.readyState!==C.CLOSED){if(this.readyState===C.CONNECTING){const e="WebSocket was closed before the connection was established";return F(this,this._req,e)}this.readyState!==C.CLOSING?(this._readyState=C.CLOSING,this._sender.close(e,t,!this._isServer,(e=>{e||(this._closeFrameSent=!0,(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end())})),this._closeTimer=setTimeout(this._socket.destroy.bind(this._socket),3e4)):this._closeFrameSent&&(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end()}}pause(){this.readyState!==C.CONNECTING&&this.readyState!==C.CLOSED&&(this._paused=!0,this._socket.pause())}ping(e,t,r){if(this.readyState===C.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");"function"==typeof e?(r=e,e=t=void 0):"function"==typeof t&&(r=t,t=void 0),"number"==typeof e&&(e=e.toString()),this.readyState===C.OPEN?(void 0===t&&(t=!this._isServer),this._sender.ping(e||b,t,r)):D(this,e,r)}pong(e,t,r){if(this.readyState===C.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");"function"==typeof e?(r=e,e=t=void 0):"function"==typeof t&&(r=t,t=void 0),"number"==typeof e&&(e=e.toString()),this.readyState===C.OPEN?(void 0===t&&(t=!this._isServer),this._sender.pong(e||b,t,r)):D(this,e,r)}resume(){this.readyState!==C.CONNECTING&&this.readyState!==C.CLOSED&&(this._paused=!1,this._receiver._writableState.needDrain||this._socket.resume())}send(e,t,r){if(this.readyState===C.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if("function"==typeof t&&(r=t,t={}),"number"==typeof e&&(e=e.toString()),this.readyState!==C.OPEN)return void D(this,e,r);const n={binary:"string"!=typeof e,mask:!this._isServer,compress:!0,fin:!0,...t};this._extensions[p.extensionName]||(n.compress=!1),this._sender.send(e||b,n,r)}terminate(){if(this.readyState!==C.CLOSED){if(this.readyState===C.CONNECTING){const e="WebSocket was closed before the connection was established";return F(this,this._req,e)}this._socket&&(this._readyState=C.CLOSING,this._socket.destroy())}}}function B(e,t,r,i){const o={protocolVersion:R[1],maxPayload:104857600,skipUTF8Validation:!1,perMessageDeflate:!0,followRedirects:!1,maxRedirects:10,...i,createConnection:void 0,socketPath:void 0,hostname:void 0,protocol:void 0,timeout:void 0,method:void 0,host:void 0,path:void 0,port:void 0};if(!R.includes(o.protocolVersion))throw new RangeError(`Unsupported protocol version: ${o.protocolVersion} (supported versions: ${R.join(", ")})`);let u;if(t instanceof d)u=t,e._url=t.href;else{try{u=new d(t)}catch(e){throw new SyntaxError(`Invalid URL: ${t}`)}e._url=t}const c="wss:"===u.protocol,h="ws+unix:"===u.protocol;let m;if("ws:"===u.protocol||c||h?h&&!u.pathname?m="The URL's pathname is empty":u.hash&&(m="The URL contains a fragment identifier"):m='The URL\'s protocol must be one of "ws:", "wss:", or "ws+unix:"',m){const t=new SyntaxError(m);if(0===e._redirects)throw t;return void N(e,t)}const y=c?443:80,g=l(16).toString("base64"),b=c?a.get:s.get,w=new Set;let A;if(o.createConnection=c?U:L,o.defaultPort=o.defaultPort||y,o.port=u.port||y,o.host=u.hostname.startsWith("[")?u.hostname.slice(1,-1):u.hostname,o.headers={"Sec-WebSocket-Version":o.protocolVersion,"Sec-WebSocket-Key":g,Connection:"Upgrade",Upgrade:"websocket",...o.headers},o.path=u.pathname+u.search,o.timeout=o.handshakeTimeout,o.perMessageDeflate&&(A=new p(!0!==o.perMessageDeflate?o.perMessageDeflate:{},!1,o.maxPayload),o.headers["Sec-WebSocket-Extensions"]=T({[p.extensionName]:A.offer()})),r.length){for(const e of r){if("string"!=typeof e||!O.test(e)||w.has(e))throw new SyntaxError("An invalid or duplicated subprotocol was specified");w.add(e)}o.headers["Sec-WebSocket-Protocol"]=r.join(",")}if(o.origin&&(o.protocolVersion<13?o.headers["Sec-WebSocket-Origin"]=o.origin:o.headers.Origin=o.origin),(u.username||u.password)&&(o.auth=`${u.username}:${u.password}`),h){const e=o.path.split(":");o.socketPath=e[0],o.path=e[1]}if(o.followRedirects){if(0===e._redirects){e._originalHost=u.host;const t=i&&i.headers;if(i={...i,headers:{}},t)for(const[e,r]of Object.entries(t))i.headers[e.toLowerCase()]=r}else u.host!==e._originalHost&&(delete o.headers.authorization,delete o.headers.cookie,delete o.headers.host,o.auth=void 0);o.auth&&!i.headers.authorization&&(i.headers.authorization="Basic "+n.from(o.auth).toString("base64"))}let S=e._req=b(o);o.timeout&&S.on("timeout",(()=>{F(e,S,"Opening handshake has timed out")})),S.on("error",(t=>{null===S||S.aborted||(S=e._req=null,N(e,t))})),S.on("response",(n=>{const a=n.headers.location,s=n.statusCode;if(a&&o.followRedirects&&s>=300&&s<400){if(++e._redirects>o.maxRedirects)return void F(e,S,"Maximum redirects exceeded");let n;S.abort();try{n=new d(a,t)}catch(t){const r=new SyntaxError(`Invalid URL: ${a}`);return void N(e,r)}B(e,n,r,i)}else e.emit("unexpected-response",S,n)||F(e,S,`Unexpected server response: ${n.statusCode}`)})),S.on("upgrade",((t,r,n)=>{if(e.emit("upgrade",t),e.readyState!==C.CONNECTING)return;S=e._req=null;const i=f("sha1").update(g+v).digest("base64");if(t.headers["sec-websocket-accept"]!==i)return void F(e,r,"Invalid Sec-WebSocket-Accept header");const a=t.headers["sec-websocket-protocol"];let s;if(void 0!==a?w.size?w.has(a)||(s="Server sent an invalid subprotocol"):s="Server sent a subprotocol but none was requested":w.size&&(s="Server sent no subprotocol"),s)return void F(e,r,s);a&&(e._protocol=a);const u=t.headers["sec-websocket-extensions"];if(void 0!==u){if(!A){return void F(e,r,"Server sent a Sec-WebSocket-Extensions header but no extension was requested")}let t;try{t=x(u)}catch(t){return void F(e,r,"Invalid Sec-WebSocket-Extensions header")}const n=Object.keys(t);if(1!==n.length||n[0]!==p.extensionName){return void F(e,r,"Server indicated an extension that was not requested")}try{A.accept(t[p.extensionName])}catch(t){return void F(e,r,"Invalid Sec-WebSocket-Extensions header")}e._extensions[p.extensionName]=A}e.setSocket(r,n,{generateMask:o.generateMask,maxPayload:o.maxPayload,skipUTF8Validation:o.skipUTF8Validation})}))}function N(e,t){e._readyState=C.CLOSING,e.emit("error",t),e.emitClose()}function L(e){return e.path=e.socketPath,u.connect(e)}function U(e){return e.path=void 0,e.servername||""===e.servername||(e.servername=u.isIP(e.host)?"":e.host),c.connect(e)}function F(e,t,r){e._readyState=C.CLOSING;const n=new Error(r);Error.captureStackTrace(n,F),t.setHeader?(t.abort(),t.socket&&!t.socket.destroyed&&t.socket.destroy(),t.once("abort",e.emitClose.bind(e)),e.emit("error",n)):(t.destroy(n),t.once("error",e.emit.bind(e,"error")),t.once("close",e.emitClose.bind(e)))}function D(e,t,r){if(t){const r=P(t).length;e._socket?e._sender._bufferedBytes+=r:e._bufferedAmount+=r}if(r){r(new Error(`WebSocket is not open: readyState ${e.readyState} (${I[e.readyState]})`))}}function j(e,t){const r=this[k];r._closeFrameReceived=!0,r._closeMessage=t,r._closeCode=e,void 0!==r._socket[k]&&(r._socket.removeListener("data",Q),i.nextTick(V,r._socket),1005===e?r.close():r.close(e,t))}function H(){const e=this[k];e.isPaused||e._socket.resume()}function J(e){const t=this[k];void 0!==t._socket[k]&&(t._socket.removeListener("data",Q),i.nextTick(V,t._socket),t.close(e[S])),t.emit("error",e)}function z(){this[k].emitClose()}function G(e,t){this[k].emit("message",e,t)}function q(e){const t=this[k];t.pong(e,!t._isServer,E),t.emit("ping",e)}function K(e){this[k].emit("pong",e)}function V(e){e.resume()}function X(){const e=this[k];let t;this.removeListener("close",X),this.removeListener("data",Q),this.removeListener("end",W),e._readyState=C.CLOSING,this._readableState.endEmitted||e._closeFrameReceived||e._receiver._writableState.errorEmitted||null===(t=e._socket.read())||e._receiver.write(t),e._receiver.end(),this[k]=void 0,clearTimeout(e._closeTimer),e._receiver._writableState.finished||e._receiver._writableState.errorEmitted?e.emitClose():(e._receiver.on("error",z),e._receiver.on("finish",z))}function Q(e){this[k]._receiver.write(e)||this.pause()}function W(){const e=this[k];e._readyState=C.CLOSING,e._receiver.end(),this.end()}function Z(){const e=this[k];this.removeListener("error",Z),this.on("error",E),e&&(e._readyState=C.CLOSING,this.destroy())}Object.defineProperty(C,"CONNECTING",{enumerable:!0,value:I.indexOf("CONNECTING")}),Object.defineProperty(C.prototype,"CONNECTING",{enumerable:!0,value:I.indexOf("CONNECTING")}),Object.defineProperty(C,"OPEN",{enumerable:!0,value:I.indexOf("OPEN")}),Object.defineProperty(C.prototype,"OPEN",{enumerable:!0,value:I.indexOf("OPEN")}),Object.defineProperty(C,"CLOSING",{enumerable:!0,value:I.indexOf("CLOSING")}),Object.defineProperty(C.prototype,"CLOSING",{enumerable:!0,value:I.indexOf("CLOSING")}),Object.defineProperty(C,"CLOSED",{enumerable:!0,value:I.indexOf("CLOSED")}),Object.defineProperty(C.prototype,"CLOSED",{enumerable:!0,value:I.indexOf("CLOSED")}),["binaryType","bufferedAmount","extensions","isPaused","protocol","readyState","url"].forEach((e=>{Object.defineProperty(C.prototype,e,{enumerable:!0})})),["open","error","close","message"].forEach((e=>{Object.defineProperty(C.prototype,`on${e}`,{enumerable:!0,get(){for(const t of this.listeners(e))if(t[w])return t[A];return null},set(t){for(const t of this.listeners(e))if(t[w]){this.removeListener(e,t);break}"function"==typeof t&&this.addEventListener(e,t,{[w]:!0})}})})),C.prototype.addEventListener=_,C.prototype.removeEventListener=M,e.exports=C},17187:e=>{"use strict";var t,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var i=Number.isNaN||function(e){return e!=e};function o(){o.init.call(this)}e.exports=o,e.exports.once=function(e,t){return new Promise((function(r,n){function i(r){e.removeListener(t,o),n(r)}function o(){"function"==typeof e.removeListener&&e.removeListener("error",i),r([].slice.call(arguments))}m(e,t,o,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&m(e,"error",t,r)}(e,i,{once:!0})}))},o.EventEmitter=o,o.prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var a=10;function s(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function u(e){return void 0===e._maxListeners?o.defaultMaxListeners:e._maxListeners}function c(e,t,r,n){var i,o,a,c;if(s(r),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),o=e._events),a=o[t]),void 0===a)a=o[t]=r,++e._eventsCount;else if("function"==typeof a?a=o[t]=n?[r,a]:[a,r]:n?a.unshift(r):a.push(r),(i=u(e))>0&&a.length>i&&!a.warned){a.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=a.length,c=l,console&&console.warn&&console.warn(c)}return e}function l(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function f(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=l.bind(n);return i.listener=r,n.wrapFn=i,i}function h(e,t,r){var n=e._events;if(void 0===n)return[];var i=n[t];return void 0===i?[]:"function"==typeof i?r?[i.listener||i]:[i]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(a=t[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var u=o[e];if(void 0===u)return!1;if("function"==typeof u)n(u,this,t);else{var c=u.length,l=p(u,c);for(r=0;r=0;o--)if(r[o]===t||r[o].listener===t){a=r[o].listener,i=o;break}if(i<0)return this;0===i?r.shift():function(e,t){for(;t+1=0;n--)this.removeListener(e,t[n]);return this},o.prototype.listeners=function(e){return h(this,e,!0)},o.prototype.rawListeners=function(e){return h(this,e,!1)},o.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},o.prototype.listenerCount=d,o.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},13048:(e,t,r)=>{var n=r(89509).Buffer,i=r(62318);e.exports=function(e,t,r,o){if(n.isBuffer(e)||(e=n.from(e,"binary")),t&&(n.isBuffer(t)||(t=n.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var a=r/8,s=n.alloc(a),u=n.alloc(o||0),c=n.alloc(0);a>0||o>0;){var l=new i;l.update(c),l.update(e),t&&l.update(t),c=l.digest();var f=0;if(a>0){var h=s.length-a;f=Math.min(a,c.length),c.copy(s,h,0,f),a-=f}if(f0){var d=u.length-o,p=Math.min(o,c.length-f);c.copy(u,d,f,f+p),o-=p}}return c.fill(0),{key:s,iv:u}}},17648:e=>{"use strict";var t="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,i="[object Function]";e.exports=function(e){var o=this;if("function"!=typeof o||n.call(o)!==i)throw new TypeError(t+o);for(var a,s=r.call(arguments,1),u=function(){if(this instanceof a){var t=o.apply(this,s.concat(r.call(arguments)));return Object(t)===t?t:this}return o.apply(e,s.concat(r.call(arguments)))},c=Math.max(0,o.length-s.length),l=[],f=0;f{"use strict";var n=r(17648);e.exports=Function.prototype.bind||n},40210:(e,t,r)=>{"use strict";var n,i=SyntaxError,o=Function,a=TypeError,s=function(e){try{return o('"use strict"; return ('+e+").constructor;")()}catch(e){}},u=Object.getOwnPropertyDescriptor;if(u)try{u({},"")}catch(e){u=null}var c=function(){throw new a},l=u?function(){try{return c}catch(e){try{return u(arguments,"callee").get}catch(e){return c}}}():c,f=r(41405)(),h=Object.getPrototypeOf||function(e){return e.__proto__},d={},p="undefined"==typeof Uint8Array?n:h(Uint8Array),m={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":f?h([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":d,"%AsyncGenerator%":d,"%AsyncGeneratorFunction%":d,"%AsyncIteratorPrototype%":d,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":d,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":f?h(h([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&f?h((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&f?h((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":f?h(""[Symbol.iterator]()):n,"%Symbol%":f?Symbol:n,"%SyntaxError%":i,"%ThrowTypeError%":l,"%TypedArray%":p,"%TypeError%":a,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},y=function e(t){var r;if("%AsyncFunction%"===t)r=s("async function () {}");else if("%GeneratorFunction%"===t)r=s("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=s("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(r=h(i.prototype))}return m[t]=r,r},g={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},b=r(58612),v=r(17642),w=b.call(Function.call,Array.prototype.concat),A=b.call(Function.apply,Array.prototype.splice),S=b.call(Function.call,String.prototype.replace),k=b.call(Function.call,String.prototype.slice),E=b.call(Function.call,RegExp.prototype.exec),_=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,M=/\\(\\)?/g,T=function(e){var t=k(e,0,1),r=k(e,-1);if("%"===t&&"%"!==r)throw new i("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new i("invalid intrinsic syntax, expected opening `%`");var n=[];return S(e,_,(function(e,t,r,i){n[n.length]=r?S(i,M,"$1"):t||e})),n},x=function(e,t){var r,n=e;if(v(g,n)&&(n="%"+(r=g[n])[0]+"%"),v(m,n)){var o=m[n];if(o===d&&(o=y(n)),void 0===o&&!t)throw new a("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new i("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new a("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new a('"allowMissing" argument must be a boolean');if(null===E(/^%?[^%]*%?$/,e))throw new i("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=T(e),n=r.length>0?r[0]:"",o=x("%"+n+"%",t),s=o.name,c=o.value,l=!1,f=o.alias;f&&(n=f[0],A(r,w([0,1],f)));for(var h=1,d=!0;h=r.length){var b=u(c,p);c=(d=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:c[p]}else d=v(c,p),c=c[p];d&&!l&&(m[s]=c)}}return c}},41405:(e,t,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,i=r(55419);e.exports=function(){return"function"==typeof n&&("function"==typeof Symbol&&("symbol"==typeof n("foo")&&("symbol"==typeof Symbol("bar")&&i())))}},55419:e=>{"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var n=Object.getOwnPropertySymbols(e);if(1!==n.length||n[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(e,t);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},17642:(e,t,r)=>{"use strict";var n=r(58612);e.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},3349:(e,t,r)=>{"use strict";var n=r(89509).Buffer,i=r(88473).Transform;function o(e){i.call(this),this._block=n.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(35717)(o,i),o.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)},o.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},o.prototype.update=function(e,t){if(function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError(t+" must be a string or a buffer")}(e,"Data"),this._finalized)throw new Error("Digest already called");n.isBuffer(e)||(e=n.from(e,t));for(var r=this._block,i=0;this._blockOffset+e.length-i>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},o.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=o},33715:(e,t,r)=>{var n=t;n.utils=r(26436),n.common=r(95772),n.sha=r(89041),n.ripemd=r(12949),n.hmac=r(52344),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},95772:(e,t,r)=>{"use strict";var n=r(26436),i=r(79746);function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}t.BlockHash=o,o.prototype.update=function(e,t){if(e=n.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var i=0;i>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o{"use strict";var n=r(26436),i=r(79746);function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(n.toArray(t,r))}e.exports=o,o.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t{"use strict";var n=r(26436),i=r(95772),o=n.rotl32,a=n.sum32,s=n.sum32_3,u=n.sum32_4,c=i.BlockHash;function l(){if(!(this instanceof l))return new l;c.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function f(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function h(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function d(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}n.inherits(l,c),t.ripemd160=l,l.blockSize=512,l.outSize=160,l.hmacStrength=192,l.padLength=64,l.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],c=this.h[3],l=this.h[4],b=r,v=n,w=i,A=c,S=l,k=0;k<80;k++){var E=a(o(u(r,f(k,n,i,c),e[p[k]+t],h(k)),y[k]),l);r=l,l=c,c=o(i,10),i=n,n=E,E=a(o(u(b,f(79-k,v,w,A),e[m[k]+t],d(k)),g[k]),S),b=S,S=A,A=o(w,10),w=v,v=E}E=s(this.h[1],i,A),this.h[1]=s(this.h[2],c,S),this.h[2]=s(this.h[3],l,b),this.h[3]=s(this.h[4],r,v),this.h[4]=s(this.h[0],n,w),this.h[0]=E},l.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"little"):n.split32(this.h,"little")};var p=[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],m=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],y=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],g=[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]},89041:(e,t,r)=>{"use strict";t.sha1=r(84761),t.sha224=r(10799),t.sha256=r(89344),t.sha384=r(80772),t.sha512=r(45900)},84761:(e,t,r)=>{"use strict";var n=r(26436),i=r(95772),o=r(37038),a=n.rotl32,s=n.sum32,u=n.sum32_5,c=o.ft_1,l=i.BlockHash,f=[1518500249,1859775393,2400959708,3395469782];function h(){if(!(this instanceof h))return new h;l.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}n.inherits(h,l),e.exports=h,h.blockSize=512,h.outSize=160,h.hmacStrength=80,h.padLength=64,h.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(26436),i=r(89344);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,7),"big"):n.split32(this.h.slice(0,7),"big")}},89344:(e,t,r)=>{"use strict";var n=r(26436),i=r(95772),o=r(37038),a=r(79746),s=n.sum32,u=n.sum32_4,c=n.sum32_5,l=o.ch32,f=o.maj32,h=o.s0_256,d=o.s1_256,p=o.g0_256,m=o.g1_256,y=i.BlockHash,g=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function b(){if(!(this instanceof b))return new b;y.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=g,this.W=new Array(64)}n.inherits(b,y),e.exports=b,b.blockSize=512,b.outSize=256,b.hmacStrength=192,b.padLength=64,b.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(26436),i=r(45900);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,12),"big"):n.split32(this.h.slice(0,12),"big")}},45900:(e,t,r)=>{"use strict";var n=r(26436),i=r(95772),o=r(79746),a=n.rotr64_hi,s=n.rotr64_lo,u=n.shr64_hi,c=n.shr64_lo,l=n.sum64,f=n.sum64_hi,h=n.sum64_lo,d=n.sum64_4_hi,p=n.sum64_4_lo,m=n.sum64_5_hi,y=n.sum64_5_lo,g=i.BlockHash,b=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=b,this.W=new Array(160)}function w(e,t,r,n,i){var o=e&r^~e&i;return o<0&&(o+=4294967296),o}function A(e,t,r,n,i,o){var a=t&n^~t&o;return a<0&&(a+=4294967296),a}function S(e,t,r,n,i){var o=e&r^e&i^r&i;return o<0&&(o+=4294967296),o}function k(e,t,r,n,i,o){var a=t&n^t&o^n&o;return a<0&&(a+=4294967296),a}function E(e,t){var r=a(e,t,28)^a(t,e,2)^a(t,e,7);return r<0&&(r+=4294967296),r}function _(e,t){var r=s(e,t,28)^s(t,e,2)^s(t,e,7);return r<0&&(r+=4294967296),r}function M(e,t){var r=a(e,t,14)^a(e,t,18)^a(t,e,9);return r<0&&(r+=4294967296),r}function T(e,t){var r=s(e,t,14)^s(e,t,18)^s(t,e,9);return r<0&&(r+=4294967296),r}function x(e,t){var r=a(e,t,1)^a(e,t,8)^u(e,t,7);return r<0&&(r+=4294967296),r}function P(e,t){var r=s(e,t,1)^s(e,t,8)^c(e,t,7);return r<0&&(r+=4294967296),r}function I(e,t){var r=a(e,t,19)^a(t,e,29)^u(e,t,6);return r<0&&(r+=4294967296),r}function O(e,t){var r=s(e,t,19)^s(t,e,29)^c(e,t,6);return r<0&&(r+=4294967296),r}n.inherits(v,g),e.exports=v,v.blockSize=1024,v.outSize=512,v.hmacStrength=192,v.padLength=128,v.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(26436).rotr32;function i(e,t,r){return e&t^~e&r}function o(e,t,r){return e&t^e&r^t&r}function a(e,t,r){return e^t^r}t.ft_1=function(e,t,r,n){return 0===e?i(t,r,n):1===e||3===e?a(t,r,n):2===e?o(t,r,n):void 0},t.ch32=i,t.maj32=o,t.p32=a,t.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},t.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},t.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},26436:(e,t,r)=>{"use strict";var n=r(79746),i=r(35717);function o(e,t){return 55296==(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1)))}function a(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function s(e){return 1===e.length?"0"+e:e}function u(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=i,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),i=0;i>6|192,r[n++]=63&a|128):o(e,i)?(a=65536+((1023&a)<<10)+(1023&e.charCodeAt(++i)),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=63&a|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=63&a|128)}else for(i=0;i>>0}return a},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,n){return(t+n>>>0>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,o,a,s){var u=0,c=t;return u+=(c=c+n>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,n,i,o,a,s){return t+n+o+s>>>0},t.sum64_5_hi=function(e,t,r,n,i,o,a,s,u,c){var l=0,f=t;return l+=(f=f+n>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,n,i,o,a,s,u,c){return t+n+o+s+c>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},2156:(e,t,r)=>{"use strict";var n=r(33715),i=r(34504),o=r(79746);function a(e){if(!(this instanceof a))return new a(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=i.toArray(e.entropy,e.entropyEnc||"hex"),r=i.toArray(e.nonce,e.nonceEnc||"hex"),n=i.toArray(e.pers,e.persEnc||"hex");o(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}e.exports=a,a.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},a.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=i.toArray(r,n||"hex"),this._update(r));for(var o=[];o.length{var n=r(8501),i=r(8575),o=e.exports;for(var a in n)n.hasOwnProperty(a)&&(o[a]=n[a]);function s(e){if("string"==typeof e&&(e=i.parse(e)),e.protocol||(e.protocol="https:"),"https:"!==e.protocol)throw new Error('Protocol "'+e.protocol+'" not supported. Expected "https:"');return e}o.request=function(e,t){return e=s(e),n.request.call(this,e,t)},o.get=function(e,t){return e=s(e),n.get.call(this,e,t)}},80645:(e,t)=>{t.read=function(e,t,r,n,i){var o,a,s=8*i-n-1,u=(1<>1,l=-7,f=r?i-1:0,h=r?-1:1,d=e[t+f];for(f+=h,o=d&(1<<-l)-1,d>>=-l,l+=s;l>0;o=256*o+e[t+f],f+=h,l-=8);for(a=o&(1<<-l)-1,o>>=-l,l+=n;l>0;a=256*a+e[t+f],f+=h,l-=8);if(0===o)o=1-c;else{if(o===u)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),o-=c}return(d?-1:1)*a*Math.pow(2,o-n)},t.write=function(e,t,r,n,i,o){var a,s,u,c=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:o-1,p=n?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=l):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),(t+=a+f>=1?h/u:h*Math.pow(2,1-f))*u>=2&&(a++,u/=2),a+f>=l?(s=0,a=l):a+f>=1?(s=(t*u-1)*Math.pow(2,i),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),a=0));i>=8;e[r+d]=255&s,d+=p,s/=256,i-=8);for(a=a<0;e[r+d]=255&a,d+=p,a/=256,c-=8);e[r+d-p]|=128*m}},35717:e=>{"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},91094:(e,t,r)=>{var n,i=r(34155);!function(){"use strict";var o="input is invalid type",a="object"==typeof window,s=a?window:{};s.JS_SHA3_NO_WINDOW&&(a=!1);var u=!a&&"object"==typeof self;!s.JS_SHA3_NO_NODE_JS&&"object"==typeof i&&i.versions&&i.versions.node?s=r.g:u&&(s=self);var c=!s.JS_SHA3_NO_COMMON_JS&&e.exports,l=r.amdO,f=!s.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,h="0123456789abcdef".split(""),d=[4,1024,262144,67108864],p=[0,8,16,24],m=[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],y=[224,256,384,512],g=[128,256],b=["hex","buffer","arrayBuffer","array","digest"],v={128:168,256:136};!s.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!f||!s.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"==typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var w=function(e,t,r){return function(n){return new N(e,t,e).update(n)[r]()}},A=function(e,t,r){return function(n,i){return new N(e,t,i).update(n)[r]()}},S=function(e,t,r){return function(t,n,i,o){return T["cshake"+e].update(t,n,i,o)[r]()}},k=function(e,t,r){return function(t,n,i,o){return T["kmac"+e].update(t,n,i,o)[r]()}},E=function(e,t,r,n){for(var i=0;i>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function L(e,t,r){N.call(this,e,t,r)}N.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(o);if(null===e)throw new Error(o);if(f&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||f&&ArrayBuffer.isView(e)))throw new Error(o);t=!0}for(var n,i,a=this.blocks,s=this.byteCount,u=e.length,c=this.blockCount,l=0,h=this.s;l>2]|=e[l]<>2]|=i<>2]|=(192|i>>6)<>2]|=(128|63&i)<=57344?(a[n>>2]|=(224|i>>12)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<>2]|=(240|i>>18)<>2]|=(128|i>>12&63)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<=s){for(this.start=n-s,this.block=a[c],n=0;n>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},N.prototype.encodeString=function(e){var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(o);if(null===e)throw new Error(o);if(f&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||f&&ArrayBuffer.isView(e)))throw new Error(o);t=!0}var n=0,i=e.length;if(t)n=i;else for(var a=0;a=57344?n+=3:(s=65536+((1023&s)<<10|1023&e.charCodeAt(++a)),n+=4)}return n+=this.encode(8*n),this.update(e),n},N.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+h[15&e]+h[e>>12&15]+h[e>>8&15]+h[e>>20&15]+h[e>>16&15]+h[e>>28&15]+h[e>>24&15];a%t==0&&(U(r),o=0)}return i&&(e=r[o],s+=h[e>>4&15]+h[15&e],i>1&&(s+=h[e>>12&15]+h[e>>8&15]),i>2&&(s+=h[e>>20&15]+h[e>>16&15])),s},N.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&U(n)}return o&&(e=s<<2,t=n[a],u[e]=255&t,o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u},L.prototype=new N,L.prototype.finalize=function(){return this.encode(this.outputBits,!0),N.prototype.finalize.call(this)};var U=function(e){var t,r,n,i,o,a,s,u,c,l,f,h,d,p,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],u=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],l=e[6]^e[16]^e[26]^e[36]^e[46],f=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(d=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|c>>>31),r=o^(c<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(l<<1|f>>>31),r=s^(f<<1|l>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(h<<1|d>>>31),r=c^(d<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=l^(i<<1|o>>>31),r=f^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=p^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&p,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~p&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=m[n],e[1]^=m[n+1]};if(c)e.exports=T;else{for(P=0;P{"use strict";const{isArray:n,isObject:i,isString:o}=r(30832),{asArray:a}=r(51055),{prependBase:s}=r(82278),u=r(54093),c=r(26767);function l(e){throw new u("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:e})}function f({context:e,base:t}){if(!e)return;const r=e["@context"];if(o(r))e["@context"]=s(t,r);else if(n(r))for(let e=0;e10)throw new u("Maximum number of @context URLs exceeded.","jsonld.ContextUrlError",{code:"json-ld-1.0"===e.processingMode?"loading remote context failed":"context overflow",max:10});if(a.has(t))throw new u("Cyclical @context URLs detected.","jsonld.ContextUrlError",{code:"json-ld-1.0"===e.processingMode?"recursive context inclusion":"context overflow",url:t});let s,c;a.add(t);try{c=await r(t),s=c.document||null,o(s)&&(s=JSON.parse(s))}catch(e){throw new u("Dereferencing a URL did not result in a valid JSON-LD object. Possible causes are an inaccessible URL perhaps due to a same-origin policy (ensure the server uses CORS if you are using client-side JavaScript), too many redirects, a non-JSON response, or more than one HTTP Link Header was provided for a remote context.","jsonld.InvalidUrl",{code:"loading remote context failed",url:t,cause:e})}if(!i(s))throw new u("Dereferencing a URL did not result in a JSON object. The response was valid JSON, but it was not a JSON object.","jsonld.InvalidUrl",{code:"invalid remote context",url:t});return s="@context"in s?{"@context":s["@context"]}:{"@context":{}},c.contextUrl&&(n(s["@context"])||(s["@context"]=[s["@context"]]),s["@context"].push(c.contextUrl)),{context:s,remoteDoc:c}}}},54093:e=>{"use strict";e.exports=class extends Error{constructor(e="An unspecified JSON-LD error occurred.",t="jsonld.Error",r={}){super(e),this.name=t,this.message=e,this.details=r}}},60731:e=>{"use strict";e.exports=e=>{class t{toString(){return"[object JsonLdProcessor]"}}return Object.defineProperty(t,"prototype",{writable:!1,enumerable:!1}),Object.defineProperty(t.prototype,"constructor",{writable:!0,enumerable:!1,configurable:!0,value:t}),t.compact=function(t,r){return arguments.length<2?Promise.reject(new TypeError("Could not compact, too few arguments.")):e.compact(t,r)},t.expand=function(t){return arguments.length<1?Promise.reject(new TypeError("Could not expand, too few arguments.")):e.expand(t)},t.flatten=function(t){return arguments.length<1?Promise.reject(new TypeError("Could not flatten, too few arguments.")):e.flatten(t)},t}},69048:(e,t,r)=>{"use strict";e.exports=r(47055).NQuads},40533:e=>{"use strict";e.exports=class{constructor(){this._requests={}}wrapLoader(e){const t=this;return t._loader=e,function(){return t.add.apply(t,arguments)}}async add(e){let t=this._requests[e];if(t)return Promise.resolve(t);t=this._requests[e]=this._loader(e);try{return await t}finally{delete this._requests[e]}}}},26767:(e,t,r)=>{"use strict";const n=r(39593);e.exports=class{constructor({document:e}){this.document=e,this.cache=new n({max:10})}getProcessed(e){return this.cache.get(e)}setProcessed(e,t){this.cache.set(e,t)}}},83251:(e,t,r)=>{"use strict";const n=r(54093),{isArray:i,isObject:o,isString:a,isUndefined:s}=r(30832),{isList:u,isValue:c,isGraph:l,isSimpleGraph:f,isSubjectReference:h}=r(18463),{expandIri:d,getContextValue:p,isKeyword:m,process:y,processingMode:g}=r(54131),{removeBase:b,prependBase:v}=r(82278),{REGEX_KEYWORD:w,addValue:A,asArray:S,compareShortestLeast:k}=r(51055),E={};function _(e,t,r){if("@nest"!==d(e,t,{vocab:!0},r))throw new n("JSON-LD compact error; nested property must have an @nest value resolving to @nest.","jsonld.SyntaxError",{code:"invalid @nest value"})}e.exports=E,E.compact=async({activeCtx:e,activeProperty:t=null,element:r,options:d={}})=>{if(i(r)){let n=[];for(let i=0;i1&&(M=Array.from(M).sort());const T=e;for(const t of M){const r=E.compactIri({activeCtx:T,iri:t,relativeTo:{vocab:!0}}),n=p(w,r,"@context");s(n)||(e=await y({activeCtx:e,localCtx:n,options:d,propagate:!1}))}const x=Object.keys(r).sort();for(const s of x){const h=r[s];if("@id"!==s)if("@type"!==s)if("@reverse"!==s)if("@preserve"!==s)if("@index"!==s)if("@graph"!==s&&"@list"!==s&&"@included"!==s&&m(s)){const t=E.compactIri({activeCtx:e,iri:s,relativeTo:{vocab:!0}});A(v,t,h)}else{if(!i(h))throw new n("JSON-LD expansion error; expanded value must be an array.","jsonld.SyntaxError");if(0===h.length){const t=E.compactIri({activeCtx:e,iri:s,value:h,relativeTo:{vocab:!0},reverse:b}),r=e.mappings.has(t)?e.mappings.get(t)["@nest"]:null;let n=v;r&&(_(e,r,d),o(v[r])||(v[r]={}),n=v[r]),A(n,t,h,{propertyIsArray:!0})}for(const t of h){const r=E.compactIri({activeCtx:e,iri:s,value:t,relativeTo:{vocab:!0},reverse:b}),n=e.mappings.has(r)?e.mappings.get(r)["@nest"]:null;let h=v;n&&(_(e,n,d),o(v[n])||(v[n]={}),h=v[n]);const m=p(e,r,"@container")||[],y=l(t),g=u(t);let w;g?w=t["@list"]:y&&(w=t["@graph"]);let k=await E.compact({activeCtx:e,activeProperty:r,element:g||y?w:t,options:d});if(g){if(i(k)||(k=[k]),m.includes("@list")){A(h,r,k,{valueIsArray:!0,allowDuplicate:!0});continue}k={[E.compactIri({activeCtx:e,iri:"@list",relativeTo:{vocab:!0}})]:k},"@index"in t&&(k[E.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=t["@index"])}if(y)if(m.includes("@graph")&&(m.includes("@id")||m.includes("@index")&&f(t))){let n;h.hasOwnProperty(r)?n=h[r]:h[r]=n={};const i=(m.includes("@id")?t["@id"]:t["@index"])||E.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}});A(n,i,k,{propertyIsArray:!d.compactArrays||m.includes("@set")})}else m.includes("@graph")&&f(t)?(i(k)&&k.length>1&&(k={"@included":k}),A(h,r,k,{propertyIsArray:!d.compactArrays||m.includes("@set")})):(i(k)&&1===k.length&&d.compactArrays&&(k=k[0]),k={[E.compactIri({activeCtx:e,iri:"@graph",relativeTo:{vocab:!0}})]:k},"@id"in t&&(k[E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]=t["@id"]),"@index"in t&&(k[E.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=t["@index"]),A(h,r,k,{propertyIsArray:!d.compactArrays||m.includes("@set")}));else if(m.includes("@language")||m.includes("@index")||m.includes("@id")||m.includes("@type")){let n,i;if(h.hasOwnProperty(r)?n=h[r]:h[r]=n={},m.includes("@language"))c(k)&&(k=k["@value"]),i=t["@language"];else if(m.includes("@index")){const n=p(e,r,"@index")||"@index",o=E.compactIri({activeCtx:e,iri:n,relativeTo:{vocab:!0}});if("@index"===n)i=t["@index"],delete k[o];else{let e;if([i,...e]=S(k[n]||[]),a(i))switch(e.length){case 0:delete k[n];break;case 1:k[n]=e[0];break;default:k[n]=e}else i=null}}else if(m.includes("@id")){const t=E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}});i=k[t],delete k[t]}else if(m.includes("@type")){const n=E.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}});let o;switch([i,...o]=S(k[n]||[]),o.length){case 0:delete k[n];break;case 1:k[n]=o[0];break;default:k[n]=o}1===Object.keys(k).length&&"@id"in t&&(k=await E.compact({activeCtx:e,activeProperty:r,element:{"@id":t["@id"]},options:d}))}i||(i=E.compactIri({activeCtx:e,iri:"@none",relativeTo:{vocab:!0}})),A(n,i,k,{propertyIsArray:m.includes("@set")})}else{const e=!d.compactArrays||m.includes("@set")||m.includes("@list")||i(k)&&0===k.length||"@list"===s||"@graph"===s;A(h,r,k,{propertyIsArray:e})}}}else{if((p(e,t,"@container")||[]).includes("@index"))continue;const r=E.compactIri({activeCtx:e,iri:s,relativeTo:{vocab:!0}});A(v,r,h)}else{const r=await E.compact({activeCtx:e,activeProperty:t,element:h,options:d});i(r)&&0===r.length||A(v,s,r)}else{const t=await E.compact({activeCtx:e,activeProperty:"@reverse",element:h,options:d});for(const r in t)if(e.mappings.has(r)&&e.mappings.get(r).reverse){const n=t[r],i=(p(e,r,"@container")||[]).includes("@set")||!d.compactArrays;A(v,r,n,{propertyIsArray:i}),delete t[r]}if(Object.keys(t).length>0){const r=E.compactIri({activeCtx:e,iri:s,relativeTo:{vocab:!0}});A(v,r,t)}}else{let t=S(h).map((e=>E.compactIri({activeCtx:w,iri:e,relativeTo:{vocab:!0}})));1===t.length&&(t=t[0]);const r=E.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}}),n=(p(e,r,"@container")||[]).includes("@set")&&g(e,1.1)||i(t)&&0===h.length;A(v,r,t,{propertyIsArray:n})}else{let t=S(h).map((t=>E.compactIri({activeCtx:e,iri:t,relativeTo:{vocab:!1},base:d.base})));1===t.length&&(t=t[0]);v[E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]=t}}return v}return r},E.compactIri=({activeCtx:e,iri:t,value:r=null,relativeTo:i={vocab:!1},reverse:a=!1,base:s=null})=>{if(null===t)return t;e.isPropertyTermScoped&&e.previousContext&&(e=e.previousContext);const f=e.getInverse();if(m(t)&&t in f&&"@none"in f[t]&&"@type"in f[t]["@none"]&&"@none"in f[t]["@none"]["@type"])return f[t]["@none"]["@type"]["@none"];if(i.vocab&&t in f){const n=e["@language"]||"@none",i=[];o(r)&&"@index"in r&&!("@graph"in r)&&i.push("@index","@index@set"),o(r)&&"@preserve"in r&&(r=r["@preserve"][0]),l(r)?("@index"in r&&i.push("@graph@index","@graph@index@set","@index","@index@set"),"@id"in r&&i.push("@graph@id","@graph@id@set"),i.push("@graph","@graph@set","@set"),"@index"in r||i.push("@graph@index","@graph@index@set","@index","@index@set"),"@id"in r||i.push("@graph@id","@graph@id@set")):o(r)&&!c(r)&&i.push("@id","@id@set","@type","@set@type");let s="@language",f="@null";if(a)s="@type",f="@reverse",i.push("@set");else if(u(r)){"@index"in r||i.push("@list");const e=r["@list"];if(0===e.length)s="@any",f="@none";else{let t=0===e.length?n:null,r=null;for(let n=0;ne.includes("_")));e&&s.push(e.replace(/^[^_]+_/,"_"))}s.push("@none");const u=e.inverse[t];for(const e of n){if(!(e in u))continue;const t=u[e][i];for(const e of s)if(e in t)return t[e]}return null}(e,t,r,i,s,f);if(null!==h)return h}if(i.vocab&&"@vocab"in e){const r=e["@vocab"];if(0===t.indexOf(r)&&t!==r){const n=t.substr(r.length);if(!e.mappings.has(n))return n}}let h=null;const d=[];let p=e.fastCurieMap;const y=t.length-1;for(let e=0;e=0;--n){const i=d[n],o=i.terms;for(const n of o){const o=n+":"+t.substr(i.iri.length);e.mappings.get(n)._prefix&&(!e.mappings.has(o)||null===r&&e.mappings.get(o)["@id"]===t)&&(null===h||k(o,h)<0)&&(h=o)}}if(null!==h)return h;for(const[r,i]of e.mappings)if(i&&i._prefix&&t.startsWith(r+":"))throw new n(`Absolute IRI "${t}" confused with prefix "${r}".`,"jsonld.SyntaxError",{code:"IRI confused with prefix",context:e});if(!i.vocab){if("@base"in e){if(e["@base"]){const r=b(v(s,e["@base"]),t);return w.test(r)?`./${r}`:r}return t}return b(s,t)}return t},E.compactValue=({activeCtx:e,activeProperty:t,value:r,options:n})=>{if(c(r)){const n=p(e,t,"@type"),i=p(e,t,"@language"),o=p(e,t,"@direction"),s=p(e,t,"@container")||[],u="@index"in r&&!s.includes("@index");if(!u&&"@none"!==n){if(r["@type"]===n)return r["@value"];if("@language"in r&&r["@language"]===i&&"@direction"in r&&r["@direction"]===o)return r["@value"];if("@language"in r&&r["@language"]===i)return r["@value"];if("@direction"in r&&r["@direction"]===o)return r["@value"]}const c=Object.keys(r).length,l=1===c||2===c&&"@index"in r&&!u,f="@language"in e,h=a(r["@value"]),d=e.mappings.has(t)&&null===e.mappings.get(t)["@language"];if(l&&"@none"!==n&&(!f||!h||d))return r["@value"];const m={};return u&&(m[E.compactIri({activeCtx:e,iri:"@index",relativeTo:{vocab:!0}})]=r["@index"]),"@type"in r?m[E.compactIri({activeCtx:e,iri:"@type",relativeTo:{vocab:!0}})]=E.compactIri({activeCtx:e,iri:r["@type"],relativeTo:{vocab:!0}}):"@language"in r&&(m[E.compactIri({activeCtx:e,iri:"@language",relativeTo:{vocab:!0}})]=r["@language"]),"@direction"in r&&(m[E.compactIri({activeCtx:e,iri:"@direction",relativeTo:{vocab:!0}})]=r["@direction"]),m[E.compactIri({activeCtx:e,iri:"@value",relativeTo:{vocab:!0}})]=r["@value"],m}const i=d(e,t,{vocab:!0},n),o=p(e,t,"@type"),s=E.compactIri({activeCtx:e,iri:r["@id"],relativeTo:{vocab:"@vocab"===o},base:n.base});return"@id"===o||"@vocab"===o||"@graph"===i?s:{[E.compactIri({activeCtx:e,iri:"@id",relativeTo:{vocab:!0}})]:s}}},93770:e=>{"use strict";const t="http://www.w3.org/1999/02/22-rdf-syntax-ns#",r="http://www.w3.org/2001/XMLSchema#";e.exports={LINK_HEADER_REL:"http://www.w3.org/ns/json-ld#context",LINK_HEADER_CONTEXT:"http://www.w3.org/ns/json-ld#context",RDF:t,RDF_LIST:t+"List",RDF_FIRST:t+"first",RDF_REST:t+"rest",RDF_NIL:t+"nil",RDF_TYPE:t+"type",RDF_PLAIN_LITERAL:t+"PlainLiteral",RDF_XML_LITERAL:t+"XMLLiteral",RDF_JSON_LITERAL:t+"JSON",RDF_OBJECT:t+"object",RDF_LANGSTRING:t+"langString",XSD:r,XSD_BOOLEAN:r+"boolean",XSD_DOUBLE:r+"double",XSD_INTEGER:r+"integer",XSD_STRING:r+"string"}},54131:(e,t,r)=>{"use strict";const n=r(51055),i=r(54093),{isArray:o,isObject:a,isString:s,isUndefined:u}=r(30832),{isAbsolute:c,isRelative:l,prependBase:f}=r(82278),{handleEvent:h}=r(91696),{REGEX_BCP47:d,REGEX_KEYWORD:p,asArray:m,compareShortestLeast:y}=r(51055),g=new Map,b={};function v(e,t,r,n,i,o){if(null===t||!s(t)||b.isKeyword(t))return t;if(t.match(p))return null;if(n&&n.hasOwnProperty(t)&&!0!==i.get(t)&&b.createTermDefinition({activeCtx:e,localCtx:n,term:t,defined:i,options:o}),(r=r||{}).vocab){const r=e.mappings.get(t);if(null===r)return null;if(a(r)&&"@id"in r)return r["@id"]}const u=t.indexOf(":");if(u>0){const r=t.substr(0,u),a=t.substr(u+1);if("_"===r||0===a.indexOf("//"))return t;n&&n.hasOwnProperty(r)&&b.createTermDefinition({activeCtx:e,localCtx:n,term:r,defined:i,options:o});const s=e.mappings.get(r);if(s&&s._prefix)return s["@id"]+a;if(c(t))return t}if(r.vocab&&"@vocab"in e){t=e["@vocab"]+t}else if(r.base){let r,n;"@base"in e?e["@base"]?(n=f(o.base,e["@base"]),r=f(n,t)):(n=e["@base"],r=t):(n=o.base,r=f(o.base,t)),t=r}return t}function w(e,t){if(!e||"object"!=typeof e||!t||"object"!=typeof t)return e===t;const r=Array.isArray(e);if(r!==Array.isArray(t))return!1;if(r){if(e.length!==t.length)return!1;for(let r=0;r{a(t)&&"@context"in t&&o(t["@context"])&&(t=t["@context"]);if(0===m(t).length)return e;const y=[],g=[({event:e,next:t})=>{y.push(e),t()}];r.eventHandler&&g.push(r.eventHandler);const w=r;r={...r,eventHandler:g};const A=await r.contextResolver.resolve({activeCtx:e,context:t,documentLoader:r.documentLoader,base:r.base});a(A[0].document)&&"boolean"==typeof A[0].document["@propagate"]&&(n=A[0].document["@propagate"]);let S=e;n||S.previousContext||(S=S.clone(),S.previousContext=e);for(const n of A){let{document:o}=n;if(e=S,null===o){if(!u&&0!==Object.keys(e.protected).length)throw new i("Tried to nullify a context with protected terms outside of a term definition.","jsonld.SyntaxError",{code:"invalid context nullification"});S=e=b.getInitialContext(r).clone();continue}const m=n.getProcessed(e);if(m){if(w.eventHandler)for(const e of m.events)h({event:e,options:w});S=e=m.context;continue}if(a(o)&&"@context"in o&&(o=o["@context"]),!a(o))throw new i("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:o});S=S.clone();const g=new Map;if("@version"in o){if(1.1!==o["@version"])throw new i("Unsupported JSON-LD version: "+o["@version"],"jsonld.UnsupportedVersion",{code:"invalid @version value",context:o});if(e.processingMode&&"json-ld-1.0"===e.processingMode)throw new i("@version: "+o["@version"]+" not compatible with "+e.processingMode,"jsonld.ProcessingModeConflict",{code:"processing mode conflict",context:o});S.processingMode="json-ld-1.1",S["@version"]=o["@version"],g.set("@version",!0)}if(S.processingMode=S.processingMode||e.processingMode,"@base"in o){let e=o["@base"];if(null===e||c(e));else{if(!l(e))throw new i('Invalid JSON-LD syntax; the value of "@base" in a @context must be an absolute IRI, a relative IRI, or null.',"jsonld.SyntaxError",{code:"invalid base IRI",context:o});e=f(S["@base"],e)}S["@base"]=e,g.set("@base",!0)}if("@vocab"in o){const e=o["@vocab"];if(null===e)delete S["@vocab"];else{if(!s(e))throw new i('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:o});if(!c(e)&&b.processingMode(S,1))throw new i('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be an absolute IRI.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:o});{const t=v(S,e,{vocab:!0,base:!0},void 0,void 0,r);c(t)||r.eventHandler&&h({event:{type:["JsonLdEvent"],code:"relative @vocab reference",level:"warning",message:"Relative @vocab reference found.",details:{vocab:t}},options:r}),S["@vocab"]=t}}g.set("@vocab",!0)}if("@language"in o){const e=o["@language"];if(null===e)delete S["@language"];else{if(!s(e))throw new i('Invalid JSON-LD syntax; the value of "@language" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid default language",context:o});e.match(d)||r.eventHandler&&h({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e}},options:r}),S["@language"]=e.toLowerCase()}g.set("@language",!0)}if("@direction"in o){const t=o["@direction"];if("json-ld-1.0"===e.processingMode)throw new i("Invalid JSON-LD syntax; @direction not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context member",context:o});if(null===t)delete S["@direction"];else{if("ltr"!==t&&"rtl"!==t)throw new i('Invalid JSON-LD syntax; the value of "@direction" in a @context must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:o});S["@direction"]=t}g.set("@direction",!0)}if("@propagate"in o){const r=o["@propagate"];if("json-ld-1.0"===e.processingMode)throw new i("Invalid JSON-LD syntax; @propagate not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:o});if("boolean"!=typeof r)throw new i("Invalid JSON-LD syntax; @propagate value must be a boolean.","jsonld.SyntaxError",{code:"invalid @propagate value",context:t});g.set("@propagate",!0)}if("@import"in o){const n=o["@import"];if("json-ld-1.0"===e.processingMode)throw new i("Invalid JSON-LD syntax; @import not compatible with "+e.processingMode,"jsonld.SyntaxError",{code:"invalid context entry",context:o});if(!s(n))throw new i("Invalid JSON-LD syntax; @import must be a string.","jsonld.SyntaxError",{code:"invalid @import value",context:t});const a=await r.contextResolver.resolve({activeCtx:e,context:n,documentLoader:r.documentLoader,base:r.base});if(1!==a.length)throw new i("Invalid JSON-LD syntax; @import must reference a single context.","jsonld.SyntaxError",{code:"invalid remote context",context:t});const u=a[0].getProcessed(e);if(u)o=u;else{const r=a[0].document;if("@import"in r)throw new i("Invalid JSON-LD syntax: imported context must not include @import.","jsonld.SyntaxError",{code:"invalid context entry",context:t});for(const e in r)o.hasOwnProperty(e)||(o[e]=r[e]);a[0].setProcessed(e,o)}g.set("@import",!0)}g.set("@protected",o["@protected"]||!1);for(const e in o)if(b.createTermDefinition({activeCtx:S,localCtx:o,term:e,defined:g,options:r,overrideProtected:u}),a(o[e])&&"@context"in o[e]){const t=o[e]["@context"];let n=!0;if(s(t)){const e=f(r.base,t);p.has(e)?n=!1:p.add(e)}if(n)try{await b.process({activeCtx:S.clone(),localCtx:o[e]["@context"],overrideProtected:!0,options:r,cycles:p})}catch(t){throw new i("Invalid JSON-LD syntax; invalid scoped context.","jsonld.SyntaxError",{code:"invalid scoped context",context:o[e]["@context"],term:e})}}n.setProcessed(e,{context:S,events:y})}return S},b.createTermDefinition=({activeCtx:e,localCtx:t,term:r,defined:n,options:u,overrideProtected:l=!1})=>{if(n.has(r)){if(n.get(r))return;throw new i("Cyclical context definition detected.","jsonld.CyclicalContext",{code:"cyclic IRI mapping",context:t,term:r})}let f;if(n.set(r,!1),t.hasOwnProperty(r)&&(f=t[r]),"@type"===r&&a(f)&&"@set"===(f["@container"]||"@set")&&b.processingMode(e,1.1)){const e=["@container","@id","@protected"],n=Object.keys(f);if(0===n.length||n.some((t=>!e.includes(t))))throw new i("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:r})}else{if(b.isKeyword(r))throw new i("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:r});if(r.match(p))return void(u.eventHandler&&h({event:{type:["JsonLdEvent"],code:"reserved term",level:"warning",message:'Terms beginning with "@" are reserved for future use and dropped.',details:{term:r}},options:u}));if(""===r)throw new i("Invalid JSON-LD syntax; a term cannot be an empty string.","jsonld.SyntaxError",{code:"invalid term definition",context:t})}const d=e.mappings.get(r);e.mappings.has(r)&&e.mappings.delete(r);let m=!1;if((s(f)||null===f)&&(m=!0,f={"@id":f}),!a(f))throw new i("Invalid JSON-LD syntax; @context term values must be strings or objects.","jsonld.SyntaxError",{code:"invalid term definition",context:t});const y={};e.mappings.set(r,y),y.reverse=!1;const g=["@container","@id","@language","@reverse","@type"];b.processingMode(e,1.1)&&g.push("@context","@direction","@index","@nest","@prefix","@protected");for(const e in f)if(!g.includes(e))throw new i("Invalid JSON-LD syntax; a term definition must not contain "+e,"jsonld.SyntaxError",{code:"invalid term definition",context:t});const A=r.indexOf(":");if(y._termHasColon=A>0,"@reverse"in f){if("@id"in f)throw new i("Invalid JSON-LD syntax; a @reverse term definition must not contain @id.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});if("@nest"in f)throw new i("Invalid JSON-LD syntax; a @reverse term definition must not contain @nest.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});const o=f["@reverse"];if(!s(o))throw new i("Invalid JSON-LD syntax; a @context @reverse value must be a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(o.match(p))return u.eventHandler&&h({event:{type:["JsonLdEvent"],code:"reserved @reverse value",level:"warning",message:'@reverse values beginning with "@" are reserved for future use and dropped.',details:{reverse:o}},options:u}),void(d?e.mappings.set(r,d):e.mappings.delete(r));const a=v(e,o,{vocab:!0,base:!1},t,n,u);if(!c(a))throw new i("Invalid JSON-LD syntax; a @context @reverse value must be an absolute IRI or a blank node identifier.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});y["@id"]=a,y.reverse=!0}else if("@id"in f){let o=f["@id"];if(o&&!s(o))throw new i("Invalid JSON-LD syntax; a @context @id value must be an array of strings or a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(null===o)y["@id"]=null;else{if(!b.isKeyword(o)&&o.match(p))return u.eventHandler&&h({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:'@id values beginning with "@" are reserved for future use and dropped.',details:{id:o}},options:u}),void(d?e.mappings.set(r,d):e.mappings.delete(r));if(o!==r){if(o=v(e,o,{vocab:!0,base:!1},t,n,u),!c(o)&&!b.isKeyword(o))throw new i("Invalid JSON-LD syntax; a @context @id value must be an absolute IRI, a blank node identifier, or a keyword.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(r.match(/(?::[^:])|\//)){if(v(e,r,{vocab:!0,base:!1},t,new Map(n).set(r,!0),u)!==o)throw new i("Invalid JSON-LD syntax; term in form of IRI must expand to definition.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t})}y["@id"]=o,y._prefix=m&&!y._termHasColon&&o.match(/[:\/\?#\[\]@]$/)}}}if(!("@id"in y))if(y._termHasColon){const i=r.substr(0,A);if(t.hasOwnProperty(i)&&b.createTermDefinition({activeCtx:e,localCtx:t,term:i,defined:n,options:u}),e.mappings.has(i)){const t=r.substr(A+1);y["@id"]=e.mappings.get(i)["@id"]+t}else y["@id"]=r}else if("@type"===r)y["@id"]=r;else{if(!("@vocab"in e))throw new i("Invalid JSON-LD syntax; @context terms must define an @id.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t,term:r});y["@id"]=e["@vocab"]+r}if((!0===f["@protected"]||!0===n.get("@protected")&&!1!==f["@protected"])&&(e.protected[r]=!0,y.protected=!0),n.set(r,!0),"@type"in f){let r=f["@type"];if(!s(r))throw new i("Invalid JSON-LD syntax; an @context @type value must be a string.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if("@json"===r||"@none"===r){if(b.processingMode(e,1))throw new i(`Invalid JSON-LD syntax; an @context @type value must not be "${r}" in JSON-LD 1.0 mode.`,"jsonld.SyntaxError",{code:"invalid type mapping",context:t})}else if("@id"!==r&&"@vocab"!==r){if(r=v(e,r,{vocab:!0,base:!1},t,n,u),!c(r))throw new i("Invalid JSON-LD syntax; an @context @type value must be an absolute IRI.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if(0===r.indexOf("_:"))throw new i("Invalid JSON-LD syntax; an @context @type value must be an IRI, not a blank node identifier.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}y["@type"]=r}if("@container"in f){const r=s(f["@container"])?[f["@container"]]:f["@container"]||[],n=["@list","@set","@index","@language"];let a=!0;const u=r.includes("@set");if(b.processingMode(e,1.1)){if(n.push("@graph","@id","@type"),r.includes("@list")){if(1!==r.length)throw new i("Invalid JSON-LD syntax; @context @container with @list must have no other values","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else if(r.includes("@graph")){if(r.some((e=>"@graph"!==e&&"@id"!==e&&"@index"!==e&&"@set"!==e)))throw new i("Invalid JSON-LD syntax; @context @container with @graph must have no other values other than @id, @index, and @set","jsonld.SyntaxError",{code:"invalid container mapping",context:t})}else a&=r.length<=(u?2:1);if(r.includes("@type")&&(y["@type"]=y["@type"]||"@id",!["@id","@vocab"].includes(y["@type"])))throw new i("Invalid JSON-LD syntax; container: @type requires @type to be @id or @vocab.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}else a&=!o(f["@container"]),a&=r.length<=1;if(a&=r.every((e=>n.includes(e))),a&=!(u&&r.includes("@list")),!a)throw new i("Invalid JSON-LD syntax; @context @container value must be one of the following: "+n.join(", "),"jsonld.SyntaxError",{code:"invalid container mapping",context:t});if(y.reverse&&!r.every((e=>["@index","@set"].includes(e))))throw new i("Invalid JSON-LD syntax; @context @container value for a @reverse type definition must be @index or @set.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});y["@container"]=r}if("@index"in f){if(!("@container"in f)||!y["@container"].includes("@index"))throw new i(`Invalid JSON-LD syntax; @index without @index in @container: "${f["@index"]}" on term "${r}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});if(!s(f["@index"])||0===f["@index"].indexOf("@"))throw new i(`Invalid JSON-LD syntax; @index must expand to an IRI: "${f["@index"]}" on term "${r}".`,"jsonld.SyntaxError",{code:"invalid term definition",context:t});y["@index"]=f["@index"]}if("@context"in f&&(y["@context"]=f["@context"]),"@language"in f&&!("@type"in f)){let e=f["@language"];if(null!==e&&!s(e))throw new i("Invalid JSON-LD syntax; @context @language value must be a string or null.","jsonld.SyntaxError",{code:"invalid language mapping",context:t});null!==e&&(e=e.toLowerCase()),y["@language"]=e}if("@prefix"in f){if(r.match(/:|\//))throw new i("Invalid JSON-LD syntax; @context @prefix used on a compact IRI term","jsonld.SyntaxError",{code:"invalid term definition",context:t});if(b.isKeyword(y["@id"]))throw new i("Invalid JSON-LD syntax; keywords may not be used as prefixes","jsonld.SyntaxError",{code:"invalid term definition",context:t});if("boolean"!=typeof f["@prefix"])throw new i("Invalid JSON-LD syntax; @context value for @prefix must be boolean","jsonld.SyntaxError",{code:"invalid @prefix value",context:t});y._prefix=!0===f["@prefix"]}if("@direction"in f){const e=f["@direction"];if(null!==e&&"ltr"!==e&&"rtl"!==e)throw new i('Invalid JSON-LD syntax; @direction value must be null, "ltr", or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",context:t});y["@direction"]=e}if("@nest"in f){const e=f["@nest"];if(!s(e)||"@nest"!==e&&0===e.indexOf("@"))throw new i("Invalid JSON-LD syntax; @context @nest value must be a string which is not a keyword other than @nest.","jsonld.SyntaxError",{code:"invalid @nest value",context:t});y["@nest"]=e}const S=y["@id"];if("@context"===S||"@preserve"===S)throw new i("Invalid JSON-LD syntax; @context and @preserve cannot be aliased.","jsonld.SyntaxError",{code:"invalid keyword alias",context:t});if(d&&d.protected&&!l&&(e.protected[r]=!0,y.protected=!0,!w(d,y)))throw new i("Invalid JSON-LD syntax; tried to redefine a protected term.","jsonld.SyntaxError",{code:"protected term redefinition",context:t,term:r})},b.expandIri=(e,t,r,n)=>v(e,t,r,void 0,void 0,n),b.getInitialContext=e=>{const t=JSON.stringify({processingMode:e.processingMode}),r=g.get(t);if(r)return r;const i={processingMode:e.processingMode,mappings:new Map,inverse:null,getInverse:function(){const e=this;if(e.inverse)return e.inverse;const t=e.inverse={},r=e.fastCurieMap={},n={},i=(e["@language"]||"@none").toLowerCase(),s=e["@direction"],u=e.mappings,c=[...u.keys()].sort(y);for(const e of c){const o=u.get(e);if(null===o)continue;let c=o["@container"]||"@none";if(c=[].concat(c).sort().join(""),null===o["@id"])continue;const l=m(o["@id"]);for(const u of l){let l=t[u];const f=b.isKeyword(u);if(l)f||o._termHasColon||n[u].push(e);else if(t[u]=l={},!f&&!o._termHasColon){n[u]=[e];const t={iri:u,terms:n[u]};u[0]in r?r[u[0]].push(t):r[u[0]]=[t]}if(l[c]||(l[c]={"@language":{},"@type":{},"@any":{}}),l=l[c],a(e,l["@any"],"@none"),o.reverse)a(e,l["@type"],"@reverse");else if("@none"===o["@type"])a(e,l["@any"],"@none"),a(e,l["@language"],"@none"),a(e,l["@type"],"@none");else if("@type"in o)a(e,l["@type"],o["@type"]);else if("@language"in o&&"@direction"in o){const t=o["@language"],r=o["@direction"];a(e,l["@language"],t&&r?`${t}_${r}`.toLowerCase():t?t.toLowerCase():r?`_${r}`:"@null")}else"@language"in o?a(e,l["@language"],(o["@language"]||"@null").toLowerCase()):"@direction"in o?o["@direction"]?a(e,l["@language"],`_${o["@direction"]}`):a(e,l["@language"],"@none"):s?(a(e,l["@language"],`_${s}`),a(e,l["@language"],"@none"),a(e,l["@type"],"@none")):(a(e,l["@language"],i),a(e,l["@language"],"@none"),a(e,l["@type"],"@none"))}}for(const e in r)o(r,e,1);return t},clone:function(){const e={};e.mappings=n.clone(this.mappings),e.clone=this.clone,e.inverse=null,e.getInverse=this.getInverse,e.protected=n.clone(this.protected),this.previousContext&&(e.previousContext=this.previousContext.clone());e.revertToPreviousContext=this.revertToPreviousContext,"@base"in this&&(e["@base"]=this["@base"]);"@language"in this&&(e["@language"]=this["@language"]);"@vocab"in this&&(e["@vocab"]=this["@vocab"]);return e},revertToPreviousContext:function(){if(!this.previousContext)return this;return this.previousContext.clone()},protected:{}};return 1e4===g.size&&g.clear(),g.set(t,i),i;function o(e,t,r){const n=e[t],i=e[t]={};let a,s;for(const e of n)a=e.iri,s=r>=a.length?"":a[r],s in i?i[s].push(e):i[s]=[e];for(const e in i)""!==e&&o(i,e,r+1)}function a(e,t,r){t.hasOwnProperty(r)||(t[r]=e)}},b.getContextValue=(e,t,r)=>{if(null===t){if("@context"===r)return;return null}if(e.mappings.has(t)){const n=e.mappings.get(t);if(u(r))return n;if(n.hasOwnProperty(r))return n[r]}return"@language"===r&&r in e||"@direction"===r&&r in e?e[r]:"@context"!==r?null:void 0},b.processingMode=(e,t)=>t.toString()>="1.1"?!e.processingMode||e.processingMode>="json-ld-"+t.toString():"json-ld-1.0"===e.processingMode,b.isKeyword=e=>{if(!s(e)||"@"!==e[0])return!1;switch(e){case"@base":case"@container":case"@context":case"@default":case"@direction":case"@embed":case"@explicit":case"@graph":case"@id":case"@included":case"@index":case"@json":case"@language":case"@list":case"@nest":case"@none":case"@omitDefault":case"@prefix":case"@preserve":case"@protected":case"@requireAll":case"@reverse":case"@set":case"@type":case"@value":case"@version":case"@vocab":return!0}return!1}},8831:(e,t,r)=>{"use strict";const{parseLinkHeader:n,buildHeaders:i}=r(51055),{LINK_HEADER_CONTEXT:o}=r(93770),a=r(54093),s=r(40533),{prependBase:u}=r(82278),c=/(^|(\r\n))link:/i;e.exports=({secure:e,headers:t={},xhr:r}={headers:{}})=>{t=i(t);return(new s).wrapLoader((async function i(s){if(0!==s.indexOf("http:")&&0!==s.indexOf("https:"))throw new a('URL could not be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:s});if(e&&0!==s.indexOf("https"))throw new a('URL could not be dereferenced; secure mode is enabled and the URL\'s scheme is not "https".',"jsonld.InvalidUrl",{code:"loading document failed",url:s});let l;try{l=await function(e,t,r){const n=new(e=e||XMLHttpRequest);return new Promise(((e,i)=>{n.onload=()=>e(n),n.onerror=e=>i(e),n.open("GET",t,!0);for(const e in r)n.setRequestHeader(e,r[e]);n.send()}))}(r,s,t)}catch(e){throw new a("URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:s,cause:e})}if(l.status>=400)throw new a("URL could not be dereferenced: "+l.statusText,"jsonld.LoadDocumentError",{code:"loading document failed",url:s,httpStatusCode:l.status});let f={contextUrl:null,documentUrl:s,document:l.response},h=null;const d=l.getResponseHeader("Content-Type");let p;c.test(l.getAllResponseHeaders())&&(p=l.getResponseHeader("Link"));if(p&&"application/ld+json"!==d){const e=n(p),t=e[o];if(Array.isArray(t))throw new a("URL could not be dereferenced, it has more than one associated HTTP Link Header.","jsonld.InvalidUrl",{code:"multiple context link headers",url:s});t&&(f.contextUrl=t.target),h=e.alternate,h&&"application/ld+json"==h.type&&!(d||"").match(/^application\/(\w*\+)?json$/)&&(f=await i(u(s,h.target)))}return f}))}},91696:(e,t,r)=>{"use strict";const n=r(54093),{isArray:i}=r(30832),{asArray:o}=r(51055),a={};function s({event:e,handlers:t}){let r=!0;for(let o=0;r&&o{r=!0}});else{if("object"!=typeof a)throw new n("Invalid event handler.","jsonld.InvalidEventHandler",{event:e});e.code in a?a[e.code]({event:e,next:()=>{r=!0}}):r=!0}}return r}e.exports=a,a.defaultEventHandler=null,a.setupEventHandler=({options:e={}})=>{const t=[].concat(e.safe?a.safeEventHandler:[],e.eventHandler?o(e.eventHandler):[],a.defaultEventHandler?a.defaultEventHandler:[]);return 0===t.length?null:t},a.handleEvent=({event:e,options:t})=>{s({event:e,handlers:t.eventHandler})};const u=new Set(["empty object","free-floating scalar","invalid @language value","invalid property","null @id value","null @value value","object with only @id","object with only @language","object with only @list","object with only @value","relative @id reference","relative @type reference","relative @vocab reference","reserved @id value","reserved @reverse value","reserved term","blank node predicate","relative graph reference","relative object reference","relative predicate reference","relative subject reference"]);a.safeEventHandler=function({event:e,next:t}){if("warning"===e.level&&u.has(e.code))throw new n("Safe mode validation error.","jsonld.ValidationError",{event:e});t()},a.logEventHandler=function({event:e,next:t}){console.log(`EVENT: ${e.message}`,{event:e}),t()},a.logWarningEventHandler=function({event:e,next:t}){"warning"===e.level&&console.warn(`WARNING: ${e.message}`,{event:e}),t()},a.unhandledEventHandler=function({event:e}){throw new n("No handler for event.","jsonld.UnhandledEvent",{event:e})},a.setDefaultEventHandler=function({eventHandler:e}={}){a.defaultEventHandler=e?o(e):null}},62759:(e,t,r)=>{"use strict";const n=r(54093),{isArray:i,isObject:o,isEmptyObject:a,isString:s,isUndefined:u}=r(30832),{isList:c,isValue:l,isGraph:f,isSubject:h}=r(18463),{expandIri:d,getContextValue:p,isKeyword:m,process:y,processingMode:g}=r(54131),{isAbsolute:b}=r(82278),{REGEX_BCP47:v,REGEX_KEYWORD:w,addValue:A,asArray:S,getValues:k,validateTypeValue:E}=r(51055),{handleEvent:_}=r(91696),M={};async function T({activeCtx:e,activeProperty:t,expandedActiveProperty:r,element:f,expandedParent:w,options:k={},insideList:x,typeKey:O,typeScopedContext:R}){const C=Object.keys(f).sort(),B=[];let N;const L=f[O]&&"@json"===d(e,i(f[O])?f[O][0]:f[O],{vocab:!0},{...k,typeExpansion:!0});for(const T of C){let x,O=f[T];if("@context"===T)continue;const C=d(e,T,{vocab:!0},k);if(null===C||!b(C)&&!m(C)){k.eventHandler&&_({event:{type:["JsonLdEvent"],code:"invalid property",level:"warning",message:"Dropping property that did not expand into an absolute IRI or keyword.",details:{property:T,expandedProperty:C}},options:k});continue}if(m(C)){if("@reverse"===r)throw new n("Invalid JSON-LD syntax; a keyword cannot be used as a @reverse property.","jsonld.SyntaxError",{code:"invalid reverse property map",value:O});if(C in w&&"@included"!==C&&"@type"!==C)throw new n("Invalid JSON-LD syntax; colliding keywords detected.","jsonld.SyntaxError",{code:"colliding keywords",keyword:C})}if("@id"===C){if(!s(O)){if(!k.isFrame)throw new n('Invalid JSON-LD syntax; "@id" value must a string.',"jsonld.SyntaxError",{code:"invalid @id value",value:O});if(o(O)){if(!a(O))throw new n('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:O})}else{if(!i(O))throw new n('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:O});if(!O.every((e=>s(e))))throw new n('Invalid JSON-LD syntax; "@id" value an empty object or array of strings, if framing',"jsonld.SyntaxError",{code:"invalid @id value",value:O})}}A(w,"@id",S(O).map((t=>{if(s(t)){const r=d(e,t,{base:!0},k);return k.eventHandler&&(null===r?_(null===t?{event:{type:["JsonLdEvent"],code:"null @id value",level:"warning",message:"Null @id found.",details:{id:t}},options:k}:{event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:t}},options:k}):b(r)||_({event:{type:["JsonLdEvent"],code:"relative @id reference",level:"warning",message:"Relative @id reference found.",details:{id:t,expandedId:r}},options:k})),r}return t})),{propertyIsArray:k.isFrame});continue}if("@type"===C){o(O)&&(O=Object.fromEntries(Object.entries(O).map((([e,t])=>[d(R,e,{vocab:!0}),S(t).map((e=>d(R,e,{base:!0,vocab:!0},{...k,typeExpansion:!0})))])))),E(O,k.isFrame),A(w,"@type",S(O).map((e=>{if(s(e)){const t=d(R,e,{base:!0,vocab:!0},{...k,typeExpansion:!0});return b(t)||k.eventHandler&&_({event:{type:["JsonLdEvent"],code:"relative @type reference",level:"warning",message:"Relative @type reference found.",details:{type:e}},options:k}),t}return e})),{propertyIsArray:k.isFrame});continue}if("@included"===C&&g(e,1.1)){const r=S(await M.expand({activeCtx:e,activeProperty:t,element:O,options:k}));if(!r.every((e=>h(e))))throw new n("Invalid JSON-LD syntax; values of @included must expand to node objects.","jsonld.SyntaxError",{code:"invalid @included value",value:O});A(w,"@included",r,{propertyIsArray:!0});continue}if("@graph"===C&&!o(O)&&!i(O))throw new n('Invalid JSON-LD syntax; "@graph" value must not be an object or an array.',"jsonld.SyntaxError",{code:"invalid @graph value",value:O});if("@value"===C){N=O,L&&g(e,1.1)?w["@value"]=O:A(w,"@value",O,{propertyIsArray:k.isFrame});continue}if("@language"===C){if(null===O)continue;if(!s(O)&&!k.isFrame)throw new n('Invalid JSON-LD syntax; "@language" value must be a string.',"jsonld.SyntaxError",{code:"invalid language-tagged string",value:O});O=S(O).map((e=>s(e)?e.toLowerCase():e));for(const e of O)s(e)&&!e.match(v)&&k.eventHandler&&_({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e}},options:k});A(w,"@language",O,{propertyIsArray:k.isFrame});continue}if("@direction"===C){if(!s(O)&&!k.isFrame)throw new n('Invalid JSON-LD syntax; "@direction" value must be a string.',"jsonld.SyntaxError",{code:"invalid base direction",value:O});O=S(O);for(const e of O)if(s(e)&&"ltr"!==e&&"rtl"!==e)throw new n('Invalid JSON-LD syntax; "@direction" must be "ltr" or "rtl".',"jsonld.SyntaxError",{code:"invalid base direction",value:O});A(w,"@direction",O,{propertyIsArray:k.isFrame});continue}if("@index"===C){if(!s(O))throw new n('Invalid JSON-LD syntax; "@index" value must be a string.',"jsonld.SyntaxError",{code:"invalid @index value",value:O});A(w,"@index",O);continue}if("@reverse"===C){if(!o(O))throw new n('Invalid JSON-LD syntax; "@reverse" value must be an object.',"jsonld.SyntaxError",{code:"invalid @reverse value",value:O});if(x=await M.expand({activeCtx:e,activeProperty:"@reverse",element:O,options:k}),"@reverse"in x)for(const e in x["@reverse"])A(w,e,x["@reverse"][e],{propertyIsArray:!0});let t=w["@reverse"]||null;for(const e in x){if("@reverse"===e)continue;null===t&&(t=w["@reverse"]={}),A(t,e,[],{propertyIsArray:!0});const r=x[e];for(let i=0;i"@id"===e||"@index"===e))&&(x=S(x).map((e=>({"@graph":S(e)})))),U.mappings.has(T)&&U.mappings.get(T).reverse){const e=w["@reverse"]=w["@reverse"]||{};x=S(x);for(let t=0;t"@value"===d(e,t,{vocab:!0},k))))throw new n("Invalid JSON-LD syntax; nested value must be a node object.","jsonld.SyntaxError",{code:"invalid @nest value",value:i});await T({activeCtx:e,activeProperty:t,expandedActiveProperty:r,element:i,expandedParent:w,options:k,insideList:x,typeScopedContext:R,typeKey:O})}}}function x({activeCtx:e,activeProperty:t,value:r,options:n}){if(null==r)return null;const i=d(e,t,{vocab:!0},n);if("@id"===i)return d(e,r,{base:!0},n);if("@type"===i)return d(e,r,{vocab:!0,base:!0},{...n,typeExpansion:!0});const o=p(e,t,"@type");if(("@id"===o||"@graph"===i)&&s(r)){const i=d(e,r,{base:!0},n);return null===i&&r.match(w)&&n.eventHandler&&_({event:{type:["JsonLdEvent"],code:"reserved @id value",level:"warning",message:"Reserved @id found.",details:{id:t}},options:n}),{"@id":i}}if("@vocab"===o&&s(r))return{"@id":d(e,r,{vocab:!0,base:!0},n)};if(m(i))return r;const a={};if(o&&!["@id","@vocab","@none"].includes(o))a["@type"]=o;else if(s(r)){const r=p(e,t,"@language");null!==r&&(a["@language"]=r);const n=p(e,t,"@direction");null!==n&&(a["@direction"]=n)}return["boolean","number","string"].includes(typeof r)||(r=r.toString()),a["@value"]=r,a}function P(e,t,r,o){const a=[],u=Object.keys(t).sort();for(const c of u){const u=d(e,c,{vocab:!0},o);let l=t[c];i(l)||(l=[l]);for(const e of l){if(null===e)continue;if(!s(e))throw new n("Invalid JSON-LD syntax; language map values must be strings.","jsonld.SyntaxError",{code:"invalid language map value",languageMap:t});const i={"@value":e};"@none"!==u&&(c.match(v)||o.eventHandler&&_({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:c}},options:o}),i["@language"]=c.toLowerCase()),r&&(i["@direction"]=r),a.push(i)}}return a}async function I({activeCtx:e,options:t,activeProperty:r,value:o,asGraph:a,indexKey:s,propertyIndex:c}){const h=[],m=Object.keys(o).sort(),g="@type"===s;for(let b of m){if(g){const r=p(e,b,"@context");u(r)||(e=await y({activeCtx:e,localCtx:r,propagate:!1,options:t}))}let m,v=o[b];i(v)||(v=[v]),v=await M.expand({activeCtx:e,activeProperty:r,element:v,options:t,insideList:!1,insideIndex:!0}),m=c?"@none"===b?"@none":x({activeCtx:e,activeProperty:s,value:b,options:t}):d(e,b,{vocab:!0},t),"@id"===s?b=d(e,b,{base:!0},t):g&&(b=m);for(let e of v){if(a&&!f(e)&&(e={"@graph":[e]}),"@type"===s)"@none"===m||(e["@type"]?e["@type"]=[b].concat(e["@type"]):e["@type"]=[b]);else{if(l(e)&&!["@language","@type","@index"].includes(s))throw new n(`Invalid JSON-LD syntax; Attempt to add illegal key to value object: "${s}".`,"jsonld.SyntaxError",{code:"invalid value object",value:e});c?"@none"!==m&&A(e,c,m,{propertyIsArray:!0,prependValue:!0}):"@none"===m||s in e||(e[s]=b)}h.push(e)}}return h}e.exports=M,M.expand=async({activeCtx:e,activeProperty:t=null,element:r,options:c={},insideList:l=!1,insideIndex:f=!1,typeScopedContext:h=null})=>{if(null==r)return null;if("@default"===t&&(c=Object.assign({},c,{isFrame:!1})),!i(r)&&!o(r))return l||null!==t&&"@graph"!==d(e,t,{vocab:!0},c)?x({activeCtx:e,activeProperty:t,value:r,options:c}):(c.eventHandler&&_({event:{type:["JsonLdEvent"],code:"free-floating scalar",level:"warning",message:"Dropping free-floating scalar not in a list.",details:{value:r}},options:c}),null);if(i(r)){let n=[];const o=p(e,t,"@container")||[];l=l||o.includes("@list");for(let o=0;o1?n.slice().sort():n:[n];for(const t of i){const r=p(h,t,"@context");u(r)||(e=await y({activeCtx:e,localCtx:r,options:c,propagate:!1}))}}}let P={};await T({activeCtx:e,activeProperty:t,expandedActiveProperty:m,element:r,expandedParent:P,options:c,insideList:l,typeKey:E,typeScopedContext:h}),w=Object.keys(P);let I=w.length;if("@value"in P){if("@type"in P&&("@language"in P||"@direction"in P))throw new n('Invalid JSON-LD syntax; an element containing "@value" may not contain both "@type" and either "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:P});let t=I-1;if("@type"in P&&(t-=1),"@index"in P&&(t-=1),"@language"in P&&(t-=1),"@direction"in P&&(t-=1),0!==t)throw new n('Invalid JSON-LD syntax; an element containing "@value" may only have an "@index" property and either "@type" or either or both "@language" or "@direction".',"jsonld.SyntaxError",{code:"invalid value object",element:P});const r=null===P["@value"]?[]:S(P["@value"]),i=k(P,"@type");if(g(e,1.1)&&i.includes("@json")&&1===i.length);else if(0===r.length)c.eventHandler&&_({event:{type:["JsonLdEvent"],code:"null @value value",level:"warning",message:"Dropping null @value value.",details:{value:P}},options:c}),P=null;else{if(!r.every((e=>s(e)||a(e)))&&"@language"in P)throw new n("Invalid JSON-LD syntax; only strings may be language-tagged.","jsonld.SyntaxError",{code:"invalid language-tagged value",element:P});if(!i.every((e=>b(e)&&!(s(e)&&0===e.indexOf("_:"))||a(e))))throw new n('Invalid JSON-LD syntax; an element containing "@value" and "@type" must have an absolute IRI for the value of "@type".',"jsonld.SyntaxError",{code:"invalid typed value",element:P})}}else if("@type"in P&&!i(P["@type"]))P["@type"]=[P["@type"]];else if("@set"in P||"@list"in P){if(I>1&&(2!==I||!("@index"in P)))throw new n('Invalid JSON-LD syntax; if an element has the property "@set" or "@list", then it can have at most one other property that is "@index".',"jsonld.SyntaxError",{code:"invalid set or list object",element:P});"@set"in P&&(P=P["@set"],w=Object.keys(P),I=w.length)}else 1===I&&"@language"in P&&(c.eventHandler&&_({event:{type:["JsonLdEvent"],code:"object with only @language",level:"warning",message:"Dropping object with only @language.",details:{value:P}},options:c}),P=null);if(o(P)&&!c.keepFreeFloatingNodes&&!l&&(null===t||"@graph"===m)&&(0===I||"@value"in P||"@list"in P||1===I&&"@id"in P)){if(c.eventHandler){let e,t;0===I?(e="empty object",t="Dropping empty object."):"@value"in P?(e="object with only @value",t="Dropping object with only @value."):"@list"in P?(e="object with only @list",t="Dropping object with only @list."):1===I&&"@id"in P&&(e="object with only @id",t="Dropping object with only @id."),_({event:{type:["JsonLdEvent"],code:e,level:"warning",message:t,details:{value:P}},options:c})}P=null}return P}},41565:(e,t,r)=>{"use strict";const{isSubjectReference:n}=r(18463),{createMergedNodeMap:i}=r(32664),o={};e.exports=o,o.flatten=e=>{const t=i(e),r=[],o=Object.keys(t).sort();for(let e=0;e{"use strict";const{isKeyword:n}=r(54131),i=r(18463),o=r(30832),a=r(51055),s=r(82278),u=r(54093),{createNodeMap:c,mergeNodeMapGraphs:l}=r(32664),f={};function h(e){const t={};for(const r in e)void 0!==e[r]&&(t["@"+r]=[e[r]]);return[t]}function d(e,t,r){for(let n=r.length-1;n>=0;--n){const i=r[n];if(i.graph===t&&i.subject["@id"]===e["@id"])return!0}return!1}function p(e,t,r){const n="@"+r;let i=n in e?e[n][0]:t[r];if("embed"===r)if(!0===i)i="@once";else if(!1===i)i="@never";else if("@always"!==i&&"@never"!==i&&"@link"!==i&&"@first"!==i&&"@last"!==i&&"@once"!==i)throw new u("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:e});return i}function m(e){if(!o.isArray(e)||1!==e.length||!o.isObject(e[0]))throw new u("Invalid JSON-LD syntax; a JSON-LD frame must be a single object.","jsonld.SyntaxError",{frame:e});if("@id"in e[0])for(const t of a.asArray(e[0]["@id"]))if(!o.isObject(t)&&!s.isAbsolute(t)||o.isString(t)&&0===t.indexOf("_:"))throw new u("Invalid JSON-LD syntax; invalid @id in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e});if("@type"in e[0])for(const t of a.asArray(e[0]["@type"]))if(!o.isObject(t)&&!s.isAbsolute(t)||o.isString(t)&&0===t.indexOf("_:"))throw new u("Invalid JSON-LD syntax; invalid @type in frame.","jsonld.SyntaxError",{code:"invalid frame",frame:e})}function y(e,t,r,s){let u=!0,c=!1;for(const l in r){let f=!1;const h=a.getValues(t,l),d=0===a.getValues(r,l).length;if("@id"===l){if(o.isEmptyObject(r["@id"][0]||{})?f=!0:r["@id"].length>=0&&(f=r["@id"].includes(h[0])),!s.requireAll)return f}else if("@type"===l){if(u=!1,d){if(h.length>0)return!1;f=!0}else if(1===r["@type"].length&&o.isEmptyObject(r["@type"][0]))f=h.length>0;else for(const e of r["@type"])f=!(!o.isObject(e)||!("@default"in e))||(f||h.some((t=>t===e)));if(!s.requireAll)return f}else{if(n(l))continue;{const t=a.getValues(r,l)[0];let n=!1;if(t&&(m([t]),n="@default"in t),u=!1,0===h.length&&n)continue;if(h.length>0&&d)return!1;if(void 0===t){if(h.length>0)return!1;f=!0}else if(i.isList(t)){const r=t["@list"][0];if(i.isList(h[0])){const t=h[0]["@list"];i.isValue(r)?f=t.some((e=>A(r,e))):(i.isSubject(r)||i.isSubjectReference(r))&&(f=t.some((t=>w(e,r,t,s))))}}else f=i.isValue(t)?h.some((e=>A(t,e))):i.isSubjectReference(t)?h.some((r=>w(e,t,r,s))):!!o.isObject(t)&&h.length>0}}if(!f&&s.requireAll)return!1;c=c||f}return u||c}function g(e,t){const r=e.uniqueEmbeds[e.graph],n=r[t],i=n.parent,s=n.property,u={"@id":t};if(o.isArray(i)){for(let e=0;e{const t=Object.keys(r);for(const n of t)n in r&&o.isObject(r[n].parent)&&r[n].parent["@id"]===e&&(delete r[n],c(n))};c(t)}function b(e,t){if(o.isArray(e))return e.map((e=>b(e,t)));if(o.isObject(e)){if("@preserve"in e)return e["@preserve"][0];if(i.isValue(e))return e;if(i.isList(e))return e["@list"]=b(e["@list"],t),e;if("@id"in e){const r=e["@id"];if(t.link.hasOwnProperty(r)){const n=t.link[r].indexOf(e);if(-1!==n)return t.link[r][n];t.link[r].push(e)}else t.link[r]=[e]}for(const r in e)"@id"===r&&t.bnodesToClear.includes(e[r])?delete e["@id"]:e[r]=b(e[r],t)}return e}function v(e,t,r){o.isObject(e)?a.addValue(e,t,r,{propertyIsArray:!0}):e.push(r)}function w(e,t,r,n){if(!("@id"in r))return!1;const i=e.subjects[r["@id"]];return i&&y(e,i,t,n)}function A(e,t){const r=t["@value"],n=t["@type"],i=t["@language"],a=e["@value"]?o.isArray(e["@value"])?e["@value"]:[e["@value"]]:[],s=e["@type"]?o.isArray(e["@type"])?e["@type"]:[e["@type"]]:[],u=e["@language"]?o.isArray(e["@language"])?e["@language"]:[e["@language"]]:[];return 0===a.length&&0===s.length&&0===u.length||!(!a.includes(r)&&!o.isEmptyObject(a[0]))&&(!!(!n&&0===s.length||s.includes(n)||n&&o.isEmptyObject(s[0]))&&!!(!i&&0===u.length||u.includes(i)||i&&o.isEmptyObject(u[0])))}e.exports=f,f.frameMergedOrDefault=(e,t,r)=>{const n={options:r,embedded:!1,graph:"@default",graphMap:{"@default":{}},subjectStack:[],link:{},bnodeMap:{}},i=new a.IdentifierIssuer("_:b");c(e,n.graphMap,"@default",i),r.merged&&(n.graphMap["@merged"]=l(n.graphMap),n.graph="@merged"),n.subjects=n.graphMap[n.graph];const o=[];return f.frame(n,Object.keys(n.subjects).sort(),t,o),r.pruneBlankNodeIdentifiers&&(r.bnodesToClear=Object.keys(n.bnodeMap).filter((e=>1===n.bnodeMap[e].length))),r.link={},b(o,r)},f.frame=(e,t,r,s,c=null)=>{m(r),r=r[0];const l=e.options,b={embed:p(r,l,"embed"),explicit:p(r,l,"explicit"),requireAll:p(r,l,"requireAll")};e.link.hasOwnProperty(e.graph)||(e.link[e.graph]={});const w=e.link[e.graph],S=function(e,t,r,n){const i={};for(const o of t){const t=e.graphMap[e.graph][o];y(e,t,r,n)&&(i[o]=t)}return i}(e,t,r,b),k=Object.keys(S).sort();for(const m of k){const y=S[m];if(null===c?e.uniqueEmbeds={[e.graph]:{}}:e.uniqueEmbeds[e.graph]=e.uniqueEmbeds[e.graph]||{},"@link"===b.embed&&m in w){v(s,c,w[m]);continue}const k={"@id":m};if(0===m.indexOf("_:")&&a.addValue(e.bnodeMap,m,k,{propertyIsArray:!0}),w[m]=k,("@first"===b.embed||"@last"===b.embed)&&e.is11)throw new u("Invalid JSON-LD syntax; invalid value of @embed.","jsonld.SyntaxError",{code:"invalid @embed value",frame:r});if(e.embedded||!e.uniqueEmbeds[e.graph].hasOwnProperty(m))if(!e.embedded||"@never"!==b.embed&&!d(y,e.graph,e.subjectStack))if(!e.embedded||"@first"!=b.embed&&"@once"!=b.embed||!e.uniqueEmbeds[e.graph].hasOwnProperty(m)){if("@last"===b.embed&&m in e.uniqueEmbeds[e.graph]&&g(e,m),e.uniqueEmbeds[e.graph][m]={parent:s,property:c},e.subjectStack.push({subject:y,graph:e.graph}),m in e.graphMap){let t=!1,n=null;"@graph"in r?(n=r["@graph"][0],t=!("@merged"===m||"@default"===m),o.isObject(n)||(n={})):(t="@merged"!==e.graph,n={}),t&&f.frame({...e,graph:m,embedded:!1},Object.keys(e.graphMap[m]).sort(),[n],k,"@graph")}"@included"in r&&f.frame({...e,embedded:!1},t,r["@included"],k,"@included");for(const t of Object.keys(y).sort())if(n(t)){if(k[t]=a.clone(y[t]),"@type"===t)for(const t of y["@type"])0===t.indexOf("_:")&&a.addValue(e.bnodeMap,t,k,{propertyIsArray:!0})}else if(!b.explicit||t in r)for(const n of y[t]){const o=t in r?r[t]:h(b);if(i.isList(n)){const o=r[t]&&r[t][0]&&r[t][0]["@list"]?r[t][0]["@list"]:h(b),s={"@list":[]};v(k,t,s);const u=n["@list"];for(const t of u)i.isSubjectReference(t)?f.frame({...e,embedded:!0},[t["@id"]],o,s,"@list"):v(s,"@list",a.clone(t))}else i.isSubjectReference(n)?f.frame({...e,embedded:!0},[n["@id"]],o,k,t):A(o[0],n)&&v(k,t,a.clone(n))}for(const e of Object.keys(r).sort()){if("@type"===e){if(!o.isObject(r[e][0])||!("@default"in r[e][0]))continue}else if(n(e))continue;const t=r[e][0]||{};if(!p(t,l,"omitDefault")&&!(e in k)){let r="@null";"@default"in t&&(r=a.clone(t["@default"])),o.isArray(r)||(r=[r]),k[e]=[{"@preserve":r}]}}for(const t of Object.keys(r["@reverse"]||{}).sort()){const n=r["@reverse"][t];for(const r of Object.keys(e.subjects)){a.getValues(e.subjects[r],t).some((e=>e["@id"]===m))&&(k["@reverse"]=k["@reverse"]||{},a.addValue(k["@reverse"],t,[],{propertyIsArray:!0}),f.frame({...e,embedded:!0},[r],n,k["@reverse"][t],c))}}v(s,c,k),e.subjectStack.pop()}else v(s,c,k);else v(s,c,k)}},f.cleanupNull=(e,t)=>{if(o.isArray(e)){return e.map((e=>f.cleanupNull(e,t))).filter((e=>e))}if("@null"===e)return null;if(o.isObject(e)){if("@id"in e){const r=e["@id"];if(t.link.hasOwnProperty(r)){const n=t.link[r].indexOf(e);if(-1!==n)return t.link[r][n];t.link[r].push(e)}else t.link[r]=[e]}for(const r in e)e[r]=f.cleanupNull(e[r],t)}return e}},25076:(e,t,r)=>{"use strict";const n=r(54093),i=r(18463),o=r(30832),{REGEX_BCP47:a,addValue:s}=r(51055),{handleEvent:u}=r(91696),{RDF_LIST:c,RDF_FIRST:l,RDF_REST:f,RDF_NIL:h,RDF_TYPE:d,RDF_JSON_LITERAL:p,XSD_BOOLEAN:m,XSD_DOUBLE:y,XSD_INTEGER:g,XSD_STRING:b}=r(93770),v={};function w(e,t,r,i){if(e.termType.endsWith("Node"))return{"@id":e.value};const s={"@value":e.value};if(e.language)e.language.match(a)||i.eventHandler&&u({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e.language}},options:i}),s["@language"]=e.language;else{let c=e.datatype.value;if(c||(c=b),c===p){c="@json";try{s["@value"]=JSON.parse(s["@value"])}catch(e){throw new n("JSON literal could not be parsed.","jsonld.InvalidJsonLiteral",{code:"invalid JSON literal",value:s["@value"],cause:e})}}if(t){if(c===m)"true"===s["@value"]?s["@value"]=!0:"false"===s["@value"]&&(s["@value"]=!1);else if(o.isNumeric(s["@value"]))if(c===g){const e=parseInt(s["@value"],10);e.toFixed(0)===s["@value"]&&(s["@value"]=e)}else c===y&&(s["@value"]=parseFloat(s["@value"]));[m,g,y,b].includes(c)||(s["@type"]=c)}else if("i18n-datatype"===r&&c.startsWith("https://www.w3.org/ns/i18n#")){const[,e,t]=c.split(/[#_]/);e.length>0&&(s["@language"]=e,e.match(a)||i.eventHandler&&u({event:{type:["JsonLdEvent"],code:"invalid @language value",level:"warning",message:"@language value must be valid BCP47.",details:{language:e}},options:i})),s["@direction"]=t}else c!==b&&(s["@type"]=c)}return s}e.exports=v,v.fromRDF=async(e,t)=>{const r={},n={"@default":r},a={},{useRdfType:u=!1,useNativeTypes:p=!1,rdfDirection:m=null}=t;for(const i of e){const e="DefaultGraph"===i.graph.termType?"@default":i.graph.value;e in n||(n[e]={}),"@default"===e||e in r||(r[e]={"@id":e});const o=n[e],c=i.subject.value,l=i.predicate.value,f=i.object;c in o||(o[c]={"@id":c});const y=o[c],g=f.termType.endsWith("Node");if(g&&!(f.value in o)&&(o[f.value]={"@id":f.value}),l===d&&!u&&g){s(y,"@type",f.value,{propertyIsArray:!0});continue}const b=w(f,p,m,t);if(s(y,l,b,{propertyIsArray:!0}),g)if(f.value===h){const e=o[f.value];"usages"in e||(e.usages=[]),e.usages.push({node:y,property:l,value:b})}else f.value in a?a[f.value]=!1:a[f.value]={node:y,property:l,value:b}}for(const e in n){const t=n[e];if(!(h in t))continue;const r=t[h];if(r.usages){for(let e of r.usages){let r=e.node,n=e.property,s=e.value;const u=[],h=[];let d=Object.keys(r).length;for(;n===f&&o.isObject(a[r["@id"]])&&o.isArray(r[l])&&1===r[l].length&&o.isArray(r[f])&&1===r[f].length&&(3===d||4===d&&o.isArray(r["@type"])&&1===r["@type"].length&&r["@type"][0]===c)&&(u.push(r[l][0]),h.push(r["@id"]),e=a[r["@id"]],r=e.node,n=e.property,s=e.value,d=Object.keys(r).length,i.isBlankNode(r)););delete s["@id"],s["@list"]=u.reverse();for(const e of h)delete t[e]}delete r.usages}}const y=[],g=Object.keys(r).sort();for(const e of g){const t=r[e];if(e in n){const r=t["@graph"]=[],o=n[e],a=Object.keys(o).sort();for(const e of a){const t=o[e];i.isSubjectReference(t)||r.push(t)}}i.isSubjectReference(t)||y.push(t)}return y}},18463:(e,t,r)=>{"use strict";const n=r(30832),i={};e.exports=i,i.isSubject=e=>{if(n.isObject(e)&&!("@value"in e||"@set"in e||"@list"in e)){return Object.keys(e).length>1||!("@id"in e)}return!1},i.isSubjectReference=e=>n.isObject(e)&&1===Object.keys(e).length&&"@id"in e,i.isValue=e=>n.isObject(e)&&"@value"in e,i.isList=e=>n.isObject(e)&&"@list"in e,i.isGraph=e=>n.isObject(e)&&"@graph"in e&&1===Object.keys(e).filter((e=>"@id"!==e&&"@index"!==e)).length,i.isSimpleGraph=e=>i.isGraph(e)&&!("@id"in e),i.isBlankNode=e=>{if(n.isObject(e)){if("@id"in e){const t=e["@id"];return!n.isString(t)||0===t.indexOf("_:")}return 0===Object.keys(e).length||!("@value"in e||"@set"in e||"@list"in e)}return!1}},36805:(e,t,r)=>{const n=r(47055),i=r(67222),o=r(51055),a=r(68058),s=o.IdentifierIssuer,u=r(54093),c=r(39593),l=r(69048),{expand:f}=r(62759),{flatten:h}=r(41565),{fromRDF:d}=r(25076),{toRDF:p}=r(19382),{frameMergedOrDefault:m,cleanupNull:y}=r(63859),{isArray:g,isObject:b,isString:v}=r(30832),{isSubjectReference:w}=r(18463),{expandIri:A,getInitialContext:S,process:k,processingMode:E}=r(54131),{compact:_,compactIri:M}=r(83251),{createNodeMap:T,createMergedNodeMap:x,mergeNodeMaps:P}=r(32664),{logEventHandler:I,logWarningEventHandler:O,safeEventHandler:R,setDefaultEventHandler:C,setupEventHandler:B,strictEventHandler:N,unhandledEventHandler:L}=r(91696),U=function(e){const t={},U=new c({max:100});function F(t,{documentLoader:r=e.documentLoader,...n}){if(t&&"compactionMap"in t)throw new u('"compactionMap" not supported.',"jsonld.OptionsError");if(t&&"expansionMap"in t)throw new u('"expansionMap" not supported.',"jsonld.OptionsError");return Object.assign({},{documentLoader:r},n,t,{eventHandler:B({options:t})})}return e.compact=async function(t,r,n){if(arguments.length<2)throw new TypeError("Could not compact, too few arguments.");if(null===r)throw new u("The compaction context must not be null.","jsonld.CompactError",{code:"invalid local context"});if(null===t)return null;let i;(n=F(n,{base:v(t)?t:"",compactArrays:!0,compactToRelative:!0,graph:!1,skipExpansion:!1,link:!1,issuer:new s("_:b"),contextResolver:new a({sharedCache:U})})).link&&(n.skipExpansion=!0),n.compactToRelative||delete n.base,i=n.skipExpansion?t:await e.expand(t,n);const c=await e.processContext(S(n),r,n);let l=await _({activeCtx:c,element:i,options:n});n.compactArrays&&!n.graph&&g(l)?1===l.length?l=l[0]:0===l.length&&(l={}):n.graph&&b(l)&&(l=[l]),b(r)&&"@context"in r&&(r=r["@context"]),r=o.clone(r),g(r)||(r=[r]);const f=r;r=[];for(let e=0;e0)&&r.push(f[e]);const h=r.length>0;if(1===r.length&&(r=r[0]),g(l)){const e=M({activeCtx:c,iri:"@graph",relativeTo:{vocab:!0}}),t=l;l={},h&&(l["@context"]=r),l[e]=t}else if(b(l)&&h){const e=l;l={"@context":r};for(const t in e)l[t]=e[t]}return l},e.expand=async function(t,r){if(arguments.length<1)throw new TypeError("Could not expand, too few arguments.");const n={},i=[];if("expandContext"in(r=F(r,{keepFreeFloatingNodes:!1,contextResolver:new a({sharedCache:U})}))){const e=o.clone(r.expandContext);b(e)&&"@context"in e?n.expandContext=e:n.expandContext={"@context":e},i.push(n.expandContext)}let s;if(v(t)){const o=await e.get(t,r);s=o.documentUrl,n.input=o.document,o.contextUrl&&(n.remoteContext={"@context":o.contextUrl},i.push(n.remoteContext))}else n.input=o.clone(t);"base"in r||(r.base=s||"");let u=S(r);for(const e of i)u=await k({activeCtx:u,localCtx:e,options:r});let c=await f({activeCtx:u,element:n.input,options:r});return b(c)&&"@graph"in c&&1===Object.keys(c).length?c=c["@graph"]:null===c&&(c=[]),g(c)||(c=[c]),c},e.flatten=async function(t,r,n){if(arguments.length<1)return new TypeError("Could not flatten, too few arguments.");r="function"==typeof r?null:r||null,n=F(n,{base:v(t)?t:"",contextResolver:new a({sharedCache:U})});const i=await e.expand(t,n),o=h(i);if(null===r)return o;n.graph=!0,n.skipExpansion=!0;const s=await e.compact(o,r,n);return s},e.frame=async function(t,r,n){if(arguments.length<2)throw new TypeError("Could not frame, too few arguments.");if(n=F(n,{base:v(t)?t:"",embed:"@once",explicit:!1,requireAll:!1,omitDefault:!1,bnodesToClear:[],contextResolver:new a({sharedCache:U})}),v(r)){const t=await e.get(r,n);if(r=t.document,t.contextUrl){let e=r["@context"];e?g(e)?e.push(t.contextUrl):e=[e,t.contextUrl]:e=t.contextUrl,r["@context"]=e}}const i=r&&r["@context"]||{},o=await e.processContext(S(n),i,n);n.hasOwnProperty("omitGraph")||(n.omitGraph=E(o,1.1)),n.hasOwnProperty("pruneBlankNodeIdentifiers")||(n.pruneBlankNodeIdentifiers=E(o,1.1));const s=await e.expand(t,n),u={...n};u.isFrame=!0,u.keepFreeFloatingNodes=!0;const c=await e.expand(r,u),l=Object.keys(r).map((e=>A(o,e,{vocab:!0})));u.merged=!l.includes("@graph"),u.is11=E(o,1.1);const f=m(s,c,u);u.graph=!n.omitGraph,u.skipExpansion=!0,u.link={},u.framing=!0;let h=await e.compact(f,i,u);return u.link={},h=y(h,u),h},e.link=async function(t,r,n){const i={};return r&&(i["@context"]=r),i["@embed"]="@link",e.frame(t,i,n)},e.normalize=e.canonize=async function(t,r){if(arguments.length<1)throw new TypeError("Could not canonize, too few arguments.");if("inputFormat"in(r=F(r,{base:v(t)?t:null,algorithm:"URDNA2015",skipExpansion:!1,safe:!0,contextResolver:new a({sharedCache:U})}))){if("application/n-quads"!==r.inputFormat&&"application/nquads"!==r.inputFormat)throw new u("Unknown canonicalization input format.","jsonld.CanonizeError");const e=l.parse(t);return n.canonize(e,r)}const i={...r};delete i.format,i.produceGeneralizedRdf=!1;const o=await e.toRDF(t,i);return n.canonize(o,r)},e.fromRDF=async function(e,r){if(arguments.length<1)throw new TypeError("Could not convert from RDF, too few arguments.");r=F(r,{format:v(e)?"application/n-quads":void 0});const{format:n}=r;let{rdfParser:i}=r;if(n){if(i=i||t[n],!i)throw new u("Unknown input format.","jsonld.UnknownFormat",{format:n})}else i=()=>e;const o=await i(e);return d(o,r)},e.toRDF=async function(t,r){if(arguments.length<1)throw new TypeError("Could not convert to RDF, too few arguments.");let n;n=(r=F(r,{base:v(t)?t:"",skipExpansion:!1,contextResolver:new a({sharedCache:U})})).skipExpansion?t:await e.expand(t,r);const i=p(n,r);if(r.format){if("application/n-quads"===r.format||"application/nquads"===r.format)return l.serialize(i);throw new u("Unknown output format.","jsonld.UnknownFormat",{format:r.format})}return i},e.createNodeMap=async function(t,r){if(arguments.length<1)throw new TypeError("Could not create node map, too few arguments.");r=F(r,{base:v(t)?t:"",contextResolver:new a({sharedCache:U})});const n=await e.expand(t,r);return x(n,r)},e.merge=async function(t,r,n){if(arguments.length<1)throw new TypeError("Could not merge, too few arguments.");if(!g(t))throw new TypeError('Could not merge, "docs" must be an array.');r="function"==typeof r?null:r||null,n=F(n,{contextResolver:new a({sharedCache:U})});const i=await Promise.all(t.map((t=>{const r={...n};return e.expand(t,r)})));let u=!0;"mergeNodes"in n&&(u=n.mergeNodes);const c=n.issuer||new s("_:b"),l={"@default":{}};for(let e=0;ee._documentLoader,set:t=>e._documentLoader=t}),e.documentLoader=async e=>{throw new u("Could not retrieve a JSON-LD document from the URL. URL dereferencing not implemented.","jsonld.LoadDocumentError",{code:"loading document failed",url:e})},e.get=async function(t,r){let n;n="function"==typeof r.documentLoader?r.documentLoader:e.documentLoader;const i=await n(t);try{if(!i.document)throw new u("No remote document found at the given URL.","jsonld.NullRemoteDocument");v(i.document)&&(i.document=JSON.parse(i.document))}catch(e){throw new u("Could not retrieve a JSON-LD document from the URL.","jsonld.LoadDocumentError",{code:"loading document failed",cause:e,remoteDoc:i})}return i},e.processContext=async function(e,t,r){return r=F(r,{base:"",contextResolver:new a({sharedCache:U})}),null===t?S(r):(t=o.clone(t),b(t)&&"@context"in t||(t={"@context":t}),k({activeCtx:e,localCtx:t,options:r}))},e.getContextValue=r(54131).getContextValue,e.documentLoaders={},e.useDocumentLoader=function(t){if(!(t in e.documentLoaders))throw new u('Unknown document loader type: "'+t+'"',"jsonld.UnknownDocumentLoader",{type:t});e.documentLoader=e.documentLoaders[t].apply(e,Array.prototype.slice.call(arguments,1))},e.registerRDFParser=function(e,r){t[e]=r},e.unregisterRDFParser=function(e){delete t[e]},e.registerRDFParser("application/n-quads",l.parse),e.registerRDFParser("application/nquads",l.parse),e.url=r(82278),e.logEventHandler=I,e.logWarningEventHandler=O,e.safeEventHandler=R,e.setDefaultEventHandler=C,e.strictEventHandler=N,e.unhandledEventHandler=L,e.util=o,Object.assign(e,o),e.promises=e,e.RequestQueue=r(40533),e.JsonLdProcessor=r(60731)(e),i.setupGlobals(e),i.setupDocumentLoaders(e),e},F=function(){return U((function(){return F()}))};U(F),e.exports=F},32664:(e,t,r)=>{"use strict";const{isKeyword:n}=r(54131),i=r(18463),o=r(30832),a=r(51055),s=r(54093),u={};e.exports=u,u.createMergedNodeMap=(e,t)=>{const r=(t=t||{}).issuer||new a.IdentifierIssuer("_:b"),n={"@default":{}};return u.createNodeMap(e,n,"@default",r),u.mergeNodeMaps(n)},u.createNodeMap=(e,t,r,c,l,f)=>{if(o.isArray(e)){for(const n of e)u.createNodeMap(n,t,r,c,void 0,f);return}if(!o.isObject(e))return void(f&&f.push(e));if(i.isValue(e)){if("@type"in e){let t=e["@type"];0===t.indexOf("_:")&&(e["@type"]=t=c.getId(t))}return void(f&&f.push(e))}if(f&&i.isList(e)){const n=[];return u.createNodeMap(e["@list"],t,r,c,l,n),void f.push({"@list":n})}if("@type"in e){const t=e["@type"];for(const e of t)0===e.indexOf("_:")&&c.getId(e)}o.isUndefined(l)&&(l=i.isBlankNode(e)?c.getId(e["@id"]):e["@id"]),f&&f.push({"@id":l});const h=t[r],d=h[l]=h[l]||{};d["@id"]=l;const p=Object.keys(e).sort();for(let o of p){if("@id"===o)continue;if("@reverse"===o){const n={"@id":l},o=e["@reverse"];for(const e in o){const s=o[e];for(const o of s){let s=o["@id"];i.isBlankNode(o)&&(s=c.getId(s)),u.createNodeMap(o,t,r,c,s),a.addValue(h[s],e,n,{propertyIsArray:!0,allowDuplicate:!1})}}continue}if("@graph"===o){l in t||(t[l]={}),u.createNodeMap(e[o],t,l,c);continue}if("@included"===o){u.createNodeMap(e[o],t,r,c);continue}if("@type"!==o&&n(o)){if("@index"===o&&o in d&&(e[o]!==d[o]||e[o]["@id"]!==d[o]["@id"]))throw new s("Invalid JSON-LD syntax; conflicting @index property detected.","jsonld.SyntaxError",{code:"conflicting indexes",subject:d});d[o]=e[o];continue}const f=e[o];if(0===o.indexOf("_:")&&(o=c.getId(o)),0!==f.length)for(let e of f)if("@type"===o&&(e=0===e.indexOf("_:")?c.getId(e):e),i.isSubject(e)||i.isSubjectReference(e)){if("@id"in e&&!e["@id"])continue;const n=i.isBlankNode(e)?c.getId(e["@id"]):e["@id"];a.addValue(d,o,{"@id":n},{propertyIsArray:!0,allowDuplicate:!1}),u.createNodeMap(e,t,r,c,n)}else if(i.isValue(e))a.addValue(d,o,e,{propertyIsArray:!0,allowDuplicate:!1});else if(i.isList(e)){const n=[];u.createNodeMap(e["@list"],t,r,c,l,n),e={"@list":n},a.addValue(d,o,e,{propertyIsArray:!0,allowDuplicate:!1})}else u.createNodeMap(e,t,r,c,l),a.addValue(d,o,e,{propertyIsArray:!0,allowDuplicate:!1});else a.addValue(d,o,[],{propertyIsArray:!0})}},u.mergeNodeMapGraphs=e=>{const t={};for(const r of Object.keys(e).sort())for(const i of Object.keys(e[r]).sort()){const o=e[r][i];i in t||(t[i]={"@id":i});const s=t[i];for(const e of Object.keys(o).sort())if(n(e)&&"@type"!==e)s[e]=a.clone(o[e]);else for(const t of o[e])a.addValue(s,e,a.clone(t),{propertyIsArray:!0,allowDuplicate:!1})}return t},u.mergeNodeMaps=e=>{const t=e["@default"],r=Object.keys(e).sort();for(const n of r){if("@default"===n)continue;const r=e[n];let o=t[n];o?"@graph"in o||(o["@graph"]=[]):t[n]=o={"@id":n,"@graph":[]};const a=o["@graph"];for(const e of Object.keys(r).sort()){const t=r[e];i.isSubjectReference(t)||a.push(t)}}return t}},67222:(e,t,r)=>{"use strict";const n=r(8831),i={};e.exports=i,i.setupDocumentLoaders=function(e){"undefined"!=typeof XMLHttpRequest&&(e.documentLoaders.xhr=n,e.useDocumentLoader("xhr"))},i.setupGlobals=function(e){void 0===globalThis.JsonLdProcessor&&Object.defineProperty(globalThis,"JsonLdProcessor",{writable:!0,enumerable:!1,configurable:!0,value:e.JsonLdProcessor})}},19382:(e,t,r)=>{"use strict";const{createNodeMap:n}=r(32664),{isKeyword:i}=r(54131),o=r(18463),a=r(95456),s=r(30832),u=r(51055),{handleEvent:c}=r(91696),{RDF_FIRST:l,RDF_REST:f,RDF_NIL:h,RDF_TYPE:d,RDF_JSON_LITERAL:p,RDF_LANGSTRING:m,XSD_BOOLEAN:y,XSD_DOUBLE:g,XSD_INTEGER:b,XSD_STRING:v}=r(93770),{isAbsolute:w}=r(82278),A={};function S(e,t,r,n,o){const a=Object.keys(t).sort();for(const s of a){const a=t[s],u=Object.keys(a).sort();for(let t of u){const u=a[t];if("@type"===t)t=d;else if(i(t))continue;for(const i of u){const a={termType:s.startsWith("_:")?"BlankNode":"NamedNode",value:s};if(!w(s)){o.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative subject reference",level:"warning",message:"Relative subject reference found.",details:{subject:s}},options:o});continue}const u={termType:t.startsWith("_:")?"BlankNode":"NamedNode",value:t};if(!w(t)){o.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative predicate reference",level:"warning",message:"Relative predicate reference found.",details:{predicate:t}},options:o});continue}if("BlankNode"===u.termType&&!o.produceGeneralizedRdf){o.eventHandler&&c({event:{type:["JsonLdEvent"],code:"blank node predicate",level:"warning",message:"Dropping blank node predicate.",details:{property:n.getOldIds().find((e=>n.getId(e)===t))}},options:o});continue}const l=k(i,n,e,r,o.rdfDirection,o);l&&e.push({subject:a,predicate:u,object:l,graph:r})}}}}function k(e,t,r,n,i,u){const d={};if(o.isValue(e)){d.termType="Literal",d.value=void 0,d.datatype={termType:"NamedNode"};let t=e["@value"];const r=e["@type"]||null;if("@json"===r)d.value=a(t),d.datatype.value=p;else if(s.isBoolean(t))d.value=t.toString(),d.datatype.value=r||y;else if(s.isDouble(t)||r===g)s.isDouble(t)||(t=parseFloat(t)),d.value=t.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),d.datatype.value=r||g;else if(s.isNumber(t))d.value=t.toFixed(0),d.datatype.value=r||b;else if("i18n-datatype"===i&&"@direction"in e){const r="https://www.w3.org/ns/i18n#"+(e["@language"]||"")+`_${e["@direction"]}`;d.datatype.value=r,d.value=t}else"@language"in e?(d.value=t,d.datatype.value=r||m,d.language=e["@language"]):(d.value=t,d.datatype.value=r||v)}else if(o.isList(e)){const o=function(e,t,r,n,i,o){const a={termType:"NamedNode",value:l},s={termType:"NamedNode",value:f},u={termType:"NamedNode",value:h},c=e.pop(),d=c?{termType:"BlankNode",value:t.getId()}:u;let p=d;for(const u of e){const e=k(u,t,r,n,i,o),c={termType:"BlankNode",value:t.getId()};r.push({subject:p,predicate:a,object:e,graph:n}),r.push({subject:p,predicate:s,object:c,graph:n}),p=c}if(c){const e=k(c,t,r,n,i,o);r.push({subject:p,predicate:a,object:e,graph:n}),r.push({subject:p,predicate:s,object:u,graph:n})}return d}(e["@list"],t,r,n,i,u);d.termType=o.termType,d.value=o.value}else{const t=s.isObject(e)?e["@id"]:e;d.termType=t.startsWith("_:")?"BlankNode":"NamedNode",d.value=t}return"NamedNode"!==d.termType||w(d.value)?d:(u.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative object reference",level:"warning",message:"Relative object reference found.",details:{object:d.value}},options:u}),null)}e.exports=A,A.toRDF=(e,t)=>{const r=new u.IdentifierIssuer("_:b"),i={"@default":{}};n(e,i,"@default",r);const o=[],a=Object.keys(i).sort();for(const e of a){let n;if("@default"===e)n={termType:"DefaultGraph",value:""};else{if(!w(e)){t.eventHandler&&c({event:{type:["JsonLdEvent"],code:"relative graph reference",level:"warning",message:"Relative graph reference found.",details:{graph:e}},options:t});continue}n=e.startsWith("_:")?{termType:"BlankNode"}:{termType:"NamedNode"},n.value=e}S(o,i[e],n,r,t)}return o}},30832:e=>{"use strict";const t={};e.exports=t,t.isArray=Array.isArray,t.isBoolean=e=>"boolean"==typeof e||"[object Boolean]"===Object.prototype.toString.call(e),t.isDouble=e=>t.isNumber(e)&&(-1!==String(e).indexOf(".")||Math.abs(e)>=1e21),t.isEmptyObject=e=>t.isObject(e)&&0===Object.keys(e).length,t.isNumber=e=>"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e),t.isNumeric=e=>!isNaN(parseFloat(e))&&isFinite(e),t.isObject=e=>"[object Object]"===Object.prototype.toString.call(e),t.isString=e=>"string"==typeof e||"[object String]"===Object.prototype.toString.call(e),t.isUndefined=e=>void 0===e},82278:(e,t,r)=>{"use strict";const n=r(30832),i={};e.exports=i,i.parsers={simple:{keys:["href","scheme","authority","path","query","fragment"],regex:/^(?:([^:\/?#]+):)?(?:\/\/([^\/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?/},full:{keys:["href","protocol","scheme","authority","auth","user","password","hostname","port","path","directory","file","query","fragment"],regex:/^(([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?(?:(((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/}},i.parse=(e,t)=>{const r={},n=i.parsers[t||"full"],o=n.regex.exec(e);let a=n.keys.length;for(;a--;)r[n.keys[a]]=void 0===o[a]?null:o[a];return("https"===r.scheme&&"443"===r.port||"http"===r.scheme&&"80"===r.port)&&(r.href=r.href.replace(":"+r.port,""),r.authority=r.authority.replace(":"+r.port,""),r.port=null),r.normalizedPath=i.removeDotSegments(r.path),r},i.prependBase=(e,t)=>{if(null===e)return t;if(i.isAbsolute(t))return t;e&&!n.isString(e)||(e=i.parse(e||""));const r=i.parse(t),o={protocol:e.protocol||""};if(null!==r.authority)o.authority=r.authority,o.path=r.path,o.query=r.query;else if(o.authority=e.authority,""===r.path)o.path=e.path,null!==r.query?o.query=r.query:o.query=e.query;else{if(0===r.path.indexOf("/"))o.path=r.path;else{let t=e.path;t=t.substr(0,t.lastIndexOf("/")+1),(t.length>0||e.authority)&&"/"!==t.substr(-1)&&(t+="/"),t+=r.path,o.path=t}o.query=r.query}""!==r.path&&(o.path=i.removeDotSegments(o.path));let a=o.protocol;return null!==o.authority&&(a+="//"+o.authority),a+=o.path,null!==o.query&&(a+="?"+o.query),null!==r.fragment&&(a+="#"+r.fragment),""===a&&(a="./"),a},i.removeBase=(e,t)=>{if(null===e)return t;e&&!n.isString(e)||(e=i.parse(e||""));let r="";if(""!==e.href?r+=(e.protocol||"")+"//"+(e.authority||""):t.indexOf("//")&&(r+="//"),0!==t.indexOf(r))return t;const o=i.parse(t.substr(r.length)),a=e.normalizedPath.split("/"),s=o.normalizedPath.split("/"),u=o.fragment||o.query?0:1;for(;a.length>0&&s.length>u&&a[0]===s[0];)a.shift(),s.shift();let c="";if(a.length>0){a.pop();for(let e=0;e{if(0===e.length)return"";const t=e.split("/"),r=[];for(;t.length>0;){const e=t.shift(),n=0===t.length;"."!==e?".."!==e?r.push(e):(r.pop(),n&&r.push("")):n&&r.push("")}return"/"===e[0]&&r.length>0&&""!==r[0]&&r.unshift(""),1===r.length&&""===r[0]?"/":r.join("/")};const o=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^\s]*$/;i.isAbsolute=e=>n.isString(e)&&o.test(e),i.isRelative=e=>n.isString(e)},51055:(e,t,r)=>{"use strict";const n=r(18463),i=r(30832),o=r(47055).IdentifierIssuer,a=r(54093),s=/(?:<[^>]*?>|"[^"]*?"|[^,])+/g,u=/\s*<([^>]*?)>\s*(?:;\s*(.*))?/,c=/(.*?)=(?:(?:"([^"]*?)")|([^"]*?))\s*(?:(?:;\s*)|$)/g,l={accept:"application/ld+json, application/json"},f={};function h(e,t){if(i.isArray(t))for(let r=0;r{if(Object.keys(e).some((e=>"accept"===e.toLowerCase())))throw new RangeError('Accept header may not be specified; only "'+l.accept+'" is supported.');return Object.assign({Accept:l.accept},e)},f.parseLinkHeader=e=>{const t={},r=e.match(s);for(let e=0;e{if(!(i.isString(e)||i.isArray(e)&&e.every((e=>i.isString(e))))){if(t&&i.isObject(e))switch(Object.keys(e).length){case 0:return;case 1:if("@default"in e&&f.asArray(e["@default"]).every((e=>i.isString(e))))return}throw new a('Invalid JSON-LD syntax; "@type" value must a string, an array of strings, an empty object, or a default object.',"jsonld.SyntaxError",{code:"invalid type value",value:e})}},f.hasProperty=(e,t)=>{if(e.hasOwnProperty(t)){const r=e[t];return!i.isArray(r)||r.length>0}return!1},f.hasValue=(e,t,r)=>{if(f.hasProperty(e,t)){let o=e[t];const a=n.isList(o);if(i.isArray(o)||a){a&&(o=o["@list"]);for(let e=0;e{if("propertyIsArray"in(n=n||{})||(n.propertyIsArray=!1),"valueIsArray"in n||(n.valueIsArray=!1),"allowDuplicate"in n||(n.allowDuplicate=!0),"prependValue"in n||(n.prependValue=!1),n.valueIsArray)e[t]=r;else if(i.isArray(r)){0===r.length&&n.propertyIsArray&&!e.hasOwnProperty(t)&&(e[t]=[]),n.prependValue&&(r=r.concat(e[t]),e[t]=[]);for(let i=0;i[].concat(e[t]||[]),f.removeProperty=(e,t)=>{delete e[t]},f.removeValue=(e,t,r,n)=>{"propertyIsArray"in(n=n||{})||(n.propertyIsArray=!1);const i=f.getValues(e,t).filter((e=>!f.compareValues(e,r)));0===i.length?f.removeProperty(e,t):1!==i.length||n.propertyIsArray?e[t]=i:e[t]=i[0]},f.relabelBlankNodes=(e,t)=>h((t=t||{}).issuer||new o("_:b"),e),f.compareValues=(e,t)=>e===t||(!(!n.isValue(e)||!n.isValue(t)||e["@value"]!==t["@value"]||e["@type"]!==t["@type"]||e["@language"]!==t["@language"]||e["@index"]!==t["@index"])||!!(i.isObject(e)&&"@id"in e&&i.isObject(t)&&"@id"in t)&&e["@id"]===t["@id"]),f.compareShortestLeast=(e,t)=>e.length{"use strict";const n=r(34411),i=Symbol("max"),o=Symbol("length"),a=Symbol("lengthCalculator"),s=Symbol("allowStale"),u=Symbol("maxAge"),c=Symbol("dispose"),l=Symbol("noDisposeOnSet"),f=Symbol("lruList"),h=Symbol("cache"),d=Symbol("updateAgeOnGet"),p=()=>1;const m=(e,t,r)=>{const n=e[h].get(t);if(n){const t=n.value;if(y(e,t)){if(b(e,n),!e[s])return}else r&&(e[d]&&(n.value.now=Date.now()),e[f].unshiftNode(n));return t.value}},y=(e,t)=>{if(!t||!t.maxAge&&!e[u])return!1;const r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[u]&&r>e[u]},g=e=>{if(e[o]>e[i])for(let t=e[f].tail;e[o]>e[i]&&null!==t;){const r=t.prev;b(e,t),t=r}},b=(e,t)=>{if(t){const r=t.value;e[c]&&e[c](r.key,r.value),e[o]-=r.length,e[h].delete(r.key),e[f].removeNode(t)}};class v{constructor(e,t,r,n,i){this.key=e,this.value=t,this.length=r,this.now=n,this.maxAge=i||0}}const w=(e,t,r,n)=>{let i=r.value;y(e,i)&&(b(e,r),e[s]||(i=void 0)),i&&t.call(n,i.value,i.key,e)};e.exports=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");this[i]=e.max||1/0;const t=e.length||p;if(this[a]="function"!=typeof t?p:t,this[s]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[u]=e.maxAge||0,this[c]=e.dispose,this[l]=e.noDisposeOnSet||!1,this[d]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[i]=e||1/0,g(this)}get max(){return this[i]}set allowStale(e){this[s]=!!e}get allowStale(){return this[s]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[u]=e,g(this)}get maxAge(){return this[u]}set lengthCalculator(e){"function"!=typeof e&&(e=p),e!==this[a]&&(this[a]=e,this[o]=0,this[f].forEach((e=>{e.length=this[a](e.value,e.key),this[o]+=e.length}))),g(this)}get lengthCalculator(){return this[a]}get length(){return this[o]}get itemCount(){return this[f].length}rforEach(e,t){t=t||this;for(let r=this[f].tail;null!==r;){const n=r.prev;w(this,e,r,t),r=n}}forEach(e,t){t=t||this;for(let r=this[f].head;null!==r;){const n=r.next;w(this,e,r,t),r=n}}keys(){return this[f].toArray().map((e=>e.key))}values(){return this[f].toArray().map((e=>e.value))}reset(){this[c]&&this[f]&&this[f].length&&this[f].forEach((e=>this[c](e.key,e.value))),this[h]=new Map,this[f]=new n,this[o]=0}dump(){return this[f].map((e=>!y(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)})).toArray().filter((e=>e))}dumpLru(){return this[f]}set(e,t,r){if((r=r||this[u])&&"number"!=typeof r)throw new TypeError("maxAge must be a number");const n=r?Date.now():0,s=this[a](t,e);if(this[h].has(e)){if(s>this[i])return b(this,this[h].get(e)),!1;const a=this[h].get(e).value;return this[c]&&(this[l]||this[c](e,a.value)),a.now=n,a.maxAge=r,a.value=t,this[o]+=s-a.length,a.length=s,this.get(e),g(this),!0}const d=new v(e,t,s,n,r);return d.length>this[i]?(this[c]&&this[c](e,t),!1):(this[o]+=d.length,this[f].unshift(d),this[h].set(e,this[f].head),g(this),!0)}has(e){if(!this[h].has(e))return!1;const t=this[h].get(e).value;return!y(this,t)}get(e){return m(this,e,!0)}peek(e){return m(this,e,!1)}pop(){const e=this[f].tail;return e?(b(this,e),e.value):null}del(e){b(this,this[h].get(e))}load(e){this.reset();const t=Date.now();for(let r=e.length-1;r>=0;r--){const n=e[r],i=n.e||0;if(0===i)this.set(n.k,n.v);else{const e=i-t;e>0&&this.set(n.k,n.v,e)}}}prune(){this[h].forEach(((e,t)=>m(this,t,!1)))}}},62318:(e,t,r)=>{"use strict";var n=r(35717),i=r(3349),o=r(89509).Buffer,a=new Array(16);function s(){i.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function u(e,t){return e<>>32-t}function c(e,t,r,n,i,o,a){return u(e+(t&r|~t&n)+i+o|0,a)+t|0}function l(e,t,r,n,i,o,a){return u(e+(t&n|r&~n)+i+o|0,a)+t|0}function f(e,t,r,n,i,o,a){return u(e+(t^r^n)+i+o|0,a)+t|0}function h(e,t,r,n,i,o,a){return u(e+(r^(t|~n))+i+o|0,a)+t|0}n(s,i),s.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,o=this._d;r=c(r,n,i,o,e[0],3614090360,7),o=c(o,r,n,i,e[1],3905402710,12),i=c(i,o,r,n,e[2],606105819,17),n=c(n,i,o,r,e[3],3250441966,22),r=c(r,n,i,o,e[4],4118548399,7),o=c(o,r,n,i,e[5],1200080426,12),i=c(i,o,r,n,e[6],2821735955,17),n=c(n,i,o,r,e[7],4249261313,22),r=c(r,n,i,o,e[8],1770035416,7),o=c(o,r,n,i,e[9],2336552879,12),i=c(i,o,r,n,e[10],4294925233,17),n=c(n,i,o,r,e[11],2304563134,22),r=c(r,n,i,o,e[12],1804603682,7),o=c(o,r,n,i,e[13],4254626195,12),i=c(i,o,r,n,e[14],2792965006,17),r=l(r,n=c(n,i,o,r,e[15],1236535329,22),i,o,e[1],4129170786,5),o=l(o,r,n,i,e[6],3225465664,9),i=l(i,o,r,n,e[11],643717713,14),n=l(n,i,o,r,e[0],3921069994,20),r=l(r,n,i,o,e[5],3593408605,5),o=l(o,r,n,i,e[10],38016083,9),i=l(i,o,r,n,e[15],3634488961,14),n=l(n,i,o,r,e[4],3889429448,20),r=l(r,n,i,o,e[9],568446438,5),o=l(o,r,n,i,e[14],3275163606,9),i=l(i,o,r,n,e[3],4107603335,14),n=l(n,i,o,r,e[8],1163531501,20),r=l(r,n,i,o,e[13],2850285829,5),o=l(o,r,n,i,e[2],4243563512,9),i=l(i,o,r,n,e[7],1735328473,14),r=f(r,n=l(n,i,o,r,e[12],2368359562,20),i,o,e[5],4294588738,4),o=f(o,r,n,i,e[8],2272392833,11),i=f(i,o,r,n,e[11],1839030562,16),n=f(n,i,o,r,e[14],4259657740,23),r=f(r,n,i,o,e[1],2763975236,4),o=f(o,r,n,i,e[4],1272893353,11),i=f(i,o,r,n,e[7],4139469664,16),n=f(n,i,o,r,e[10],3200236656,23),r=f(r,n,i,o,e[13],681279174,4),o=f(o,r,n,i,e[0],3936430074,11),i=f(i,o,r,n,e[3],3572445317,16),n=f(n,i,o,r,e[6],76029189,23),r=f(r,n,i,o,e[9],3654602809,4),o=f(o,r,n,i,e[12],3873151461,11),i=f(i,o,r,n,e[15],530742520,16),r=h(r,n=f(n,i,o,r,e[2],3299628645,23),i,o,e[0],4096336452,6),o=h(o,r,n,i,e[7],1126891415,10),i=h(i,o,r,n,e[14],2878612391,15),n=h(n,i,o,r,e[5],4237533241,21),r=h(r,n,i,o,e[12],1700485571,6),o=h(o,r,n,i,e[3],2399980690,10),i=h(i,o,r,n,e[10],4293915773,15),n=h(n,i,o,r,e[1],2240044497,21),r=h(r,n,i,o,e[8],1873313359,6),o=h(o,r,n,i,e[15],4264355552,10),i=h(i,o,r,n,e[6],2734768916,15),n=h(n,i,o,r,e[13],1309151649,21),r=h(r,n,i,o,e[4],4149444226,6),o=h(o,r,n,i,e[11],3174756917,10),i=h(i,o,r,n,e[2],718787259,15),n=h(n,i,o,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+o|0},s.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 e=o.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=s},75117:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Base=void 0;const i=r(48764),o=n(r(81354));class a{print(){a.print(this)}bufferIndexOf(e,t,r=!1){if(r)return this.binarySearch(e,t,i.Buffer.compare);return this.linearSearch(e,t,((e,t)=>e.equals(t)))}static binarySearch(e,t,r){let n=0,i=e.length-1;for(;n<=i;){const o=Math.floor((n+i)/2),a=r(e[o],t);if(0===a){for(let n=o-1;n>=0;n--)if(0!==r(e[n],t))return n+1;return 0}a<0?n=o+1:i=o-1}return-1}binarySearch(e,t,r){return a.binarySearch(e,t,r)}static linearSearch(e,t,r){for(let n=0;n{const r=e(t);return i.Buffer.isBuffer(r)?r:this.isHexString(r)?i.Buffer.from(r.replace("0x",""),"hex"):"string"==typeof r?i.Buffer.from(r):"bigint"==typeof r?i.Buffer.from(t.toString(16),"hex"):ArrayBuffer.isView(r)?i.Buffer.from(r.buffer,r.byteOffset,r.byteLength):i.Buffer.from(e(o.default.enc.Hex.parse(t.toString("hex"))).toString(o.default.enc.Hex),"hex")}}isHexString(e){return a.isHexString(e)}log2(e){return 1===e?0:1+this.log2(e/2|0)}zip(e,t){return e.map(((e,r)=>[e,t[r]]))}static hexZeroPad(e,t){return"0x"+e.replace("0x","").padStart(t,"0")}}t.Base=a,t.default=a},8659:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.IncrementalMerkleTree=void 0;const i=n(r(75117)),o=n(r(99269));class a extends i.default{constructor(e,t){if(super(),this.hashFn=e,t.depth&&(this.depth=t.depth),t.arity&&(this.arity=t.arity),this.depth<1)throw new Error("depth must be greater than 0");if(this.arity<1)throw new Error("arity must be greater than 0");const r=[];let n=t.zeroValue;if(this.zeroValue=n,this.zeroes=[],this.depth)for(let e=0;e=this.getMaxLeaves())throw new Error("tree is full");let t=e,r=this.nodes[0].length;for(let e=0;e=this.nodes[0].length)throw new Error("out of bounds");let r=t;for(let t=0;tBigInt(e)))}getLayers(){const e=[];for(const t of this.nodes)e.push(this.copyList(t));if(e[0].length=e[r].length&&(e[r][t]=this.zeroes[r]);t=Math.floor(t/this.arity)}}return e.push([this.root]),e}getHexLayers(){return this.getLayers().reduce(((e,t)=>(Array.isArray(t)?e.push(t.map((e=>this.bufferToHex(this.bufferify(e))))):e.push(t),e)),[])}getLayersAsObject(){const e=this.getLayers().map((e=>e.map((e=>this.bufferToHex(this.bufferify(e),!1))))),t=[];for(let r=0;r=this.nodes[0].length)throw new Error("The leaf does not exist in this tree");const t=[],r=[],n=e;for(let n=0;n0&&!(0!=(e&1<=t));o--);if(n!==r.length)throw new Error("invalid bit calculation");return r}numOfPeaks(e){let t=e,r=0;for(;t>0;)t%2==1&&r++,t>>=1;return r}peakBagging(e,t){const r=this.getSize(e);if(this.numOfPeaks(e)!==t.length)throw new Error("received invalid number of peaks");return 0!==e||t.length?this.peakBaggingFn?this.bufferify(this.peakBaggingFn(r,t)):this.hashFn(i.Buffer.concat([this.bufferify(r),...t.map(this.bufferify)])):i.Buffer.alloc(0)}getSize(e){return(e<<1)-this.numOfPeaks(e)}getRoot(){return this.root}getHexRoot(){return this.bufferToHex(this.getRoot())}getNode(e){return this.hashes[e]}mountainHeight(e){let t=1;for(;1<r;)t-=(1<this.size)throw new Error("out of range");if(!this.isLeaf(e))throw new Error("not a leaf");const t=this.root,r=this.width,n=this.getPeakIndexes(this.width),i=[];let o=0;for(let t=0;t=e&&0===o&&(o=n[t]);let a=0,s=0,u=this.heightAt(o);const c=[];for(;o!==e;)u--,[a,s]=this.getChildren(o),o=e<=a?a:s,c[u-1]=this.hashes[e<=a?s:a];return{root:t,width:r,peakBagging:i,siblings:c}}verify(e,t,r,n,i,o){n=this.bufferify(n);if(this.getSize(t)=r){a=i[e],s=u[e];break}if(!a)throw new Error("target not found");let c=o.length+1;const l=new Array(c);let f,h=0,d=0;for(;c>0&&(l[--c]=s,s!==r);)[h,d]=this.getChildren(s),s=r>h?d:h;for(;cthis.size)throw new Error("out of range");if(!this.hashes[e]){const[t,r]=this.getChildren(e),n=this._getOrCreateNode(t),i=this._getOrCreateNode(r);this.hashes[e]=this.hashBranch(e,n,i)}return this.hashes[e]}}t.MerkleMountainRange=s,"undefined"!=typeof window&&(window.MerkleMountainRange=s),t.default=s},75028:(e,t,r)=>{"use strict";var n=r(48764).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.MerkleSumTree=t.ProofStep=t.Leaf=t.Bucket=void 0;const i=r(75117);class o{constructor(e,t){this.size=BigInt(e),this.hashed=t,this.parent=null,this.left=null,this.right=null}}t.Bucket=o;t.Leaf=class{constructor(e,t,r){this.hashFn=e,this.rng=t.map((e=>BigInt(e))),this.data=r}getBucket(){let e;return e=this.data?this.hashFn(this.data):n.alloc(32),new o(BigInt(this.rng[1])-BigInt(this.rng[0]),e)}};class a{constructor(e,t){this.bucket=e,this.right=t}}t.ProofStep=a;class s extends i.Base{constructor(e,t){super(),this.leaves=e,this.hashFn=t,s.checkConsecutive(e),this.buckets=[];for(const t of e)this.buckets.push(t.getBucket());let r=[];for(const e of this.buckets)r.push(e);for(;1!==r.length;){const e=[];for(;r.length;)if(r.length>=2){const t=r.shift(),i=r.shift(),a=t.size+i.size,s=this.hashFn(n.concat([this.sizeToBuffer(t.size),this.bufferify(t.hashed),this.sizeToBuffer(i.size),this.bufferify(i.hashed)])),u=new o(a,s);i.parent=u,t.parent=i.parent,t.right=i,i.left=t,e.push(u)}else e.push(r.shift());r=e}this.root=r[0]}sizeToBuffer(e){const t=n.alloc(8);return new DataView(t.buffer).setBigInt64(0,BigInt(e),!1),t}static checkConsecutive(e){let t=BigInt(0);for(const r of e){if(r.rng[0]!==t)throw new Error("leaf ranges are invalid");t=BigInt(r.rng[1])}}getProof(e){let t=this.buckets[Number(e)];const r=[];for(;t&&t.parent;){const e=!!t.right,n=t.right?t.right:t.left;t=t.parent,r.push(new a(n,e))}return r}sum(e){let t=BigInt(0);for(const r of e)t+=BigInt(r);return t}verifyProof(e,t,r){const i=[this.sum(r.filter((e=>!e.right)).map((e=>e.bucket.size))),BigInt(e.size)-this.sum(r.filter((e=>e.right)).map((e=>e.bucket.size)))];if(i[0]!==t.rng[0]||i[1]!==t.rng[1])return!1;let a,s=t.getBucket();for(const e of r)a=e.right?this.hashFn(n.concat([this.sizeToBuffer(s.size),this.bufferify(s.hashed),this.sizeToBuffer(e.bucket.size),this.bufferify(e.bucket.hashed)])):this.hashFn(n.concat([this.sizeToBuffer(e.bucket.size),this.bufferify(e.bucket.hashed),this.sizeToBuffer(s.size),this.bufferify(s.hashed)])),s=new o(BigInt(s.size)+BigInt(e.bucket.size),a);return s.size===e.size&&s.hashed.toString("hex")===e.hashed.toString("hex")}}t.MerkleSumTree=s,"undefined"!=typeof window&&(window.MerkleSumTree=s),t.default=s},78493:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.MerkleTree=void 0;const i=r(48764),o=n(r(56351)),a=n(r(52153)),s=n(r(99269)),u=n(r(75117));class c extends u.default{constructor(e,t=a.default,r={}){if(super(),this.duplicateOdd=!1,this.concatenator=i.Buffer.concat,this.hashLeaves=!1,this.isBitcoinTree=!1,this.leaves=[],this.layers=[],this.sortLeaves=!1,this.sortPairs=!1,this.sort=!1,this.fillDefaultHash=null,this.complete=!1,r.complete){if(r.isBitcoinTree)throw new Error('option "complete" is incompatible with "isBitcoinTree"');if(r.duplicateOdd)throw new Error('option "complete" is incompatible with "duplicateOdd"')}if(this.isBitcoinTree=!!r.isBitcoinTree,this.hashLeaves=!!r.hashLeaves,this.sortLeaves=!!r.sortLeaves,this.sortPairs=!!r.sortPairs,this.complete=!!r.complete,r.fillDefaultHash)if("function"==typeof r.fillDefaultHash)this.fillDefaultHash=r.fillDefaultHash;else{if(!i.Buffer.isBuffer(r.fillDefaultHash)&&"string"!=typeof r.fillDefaultHash)throw new Error('method "fillDefaultHash" must be a function, Buffer, or string');this.fillDefaultHash=(e,t)=>r.fillDefaultHash}this.sort=!!r.sort,this.sort&&(this.sortLeaves=!0,this.sortPairs=!0),this.duplicateOdd=!!r.duplicateOdd,r.concatenator&&(this.concatenator=r.concatenator),this.hashFn=this.bufferifyFn(t),this.processLeaves(e)}getOptions(){var e,t;return{complete:this.complete,isBitcoinTree:this.isBitcoinTree,hashLeaves:this.hashLeaves,sortLeaves:this.sortLeaves,sortPairs:this.sortPairs,sort:this.sort,fillDefaultHash:null!==(t=null===(e=this.fillDefaultHash)||void 0===e?void 0:e.toString())&&void 0!==t?t:null,duplicateOdd:this.duplicateOdd}}processLeaves(e){if(this.hashLeaves&&(e=e.map(this.hashFn)),this.leaves=e.map(this.bufferify),this.sortLeaves&&(this.leaves=this.leaves.sort(i.Buffer.compare)),this.fillDefaultHash)for(let e=this.leaves.length;e1;){const t=this.layers.length;this.layers.push([]);const r=this.complete&&1===t&&!Number.isInteger(Math.log2(e.length))?2*e.length-Math.pow(2,Math.ceil(Math.log2(e.length))):e.length;for(let n=0;n=r){this.layers[t].push(...e.slice(r));break}if(n+1===e.length&&e.length%2==1){const r=e[e.length-1];let i=r;if(this.isBitcoinTree){i=this.hashFn(this.concatenator([o.default(r),o.default(r)])),i=o.default(this.hashFn(i)),this.layers[t].push(i);continue}if(!this.duplicateOdd){this.layers[t].push(e[n]);continue}}const a=e[n],s=n+1===e.length?a:e[n+1];let u=null;u=this.isBitcoinTree?[o.default(a),o.default(s)]:[a,s],this.sortPairs&&u.sort(i.Buffer.compare);let c=this.hashFn(this.concatenator(u));this.isBitcoinTree&&(c=o.default(this.hashFn(c))),this.layers[t].push(c)}e=this.layers[t]}}addLeaf(e,t=!1){t&&(e=this.hashFn(e)),this.processLeaves(this.leaves.concat(e))}addLeaves(e,t=!1){t&&(e=e.map(this.hashFn)),this.processLeaves(this.leaves.concat(e))}getLeaves(e){return Array.isArray(e)?(this.hashLeaves&&(e=e.map(this.hashFn),this.sortLeaves&&(e=e.sort(i.Buffer.compare))),this.leaves.filter((t=>-1!==this.bufferIndexOf(e,t,this.sortLeaves)))):this.leaves}getLeaf(e){return e<0||e>this.leaves.length-1?i.Buffer.from([]):this.leaves[e]}getLeafIndex(e){e=this.bufferify(e);const t=this.getLeaves();for(let r=0;rthis.bufferToHex(e)))}static marshalLeaves(e){return JSON.stringify(e.map((e=>c.bufferToHex(e))),null,2)}static unmarshalLeaves(e){let t=null;if("string"==typeof e)t=JSON.parse(e);else{if(!(e instanceof Object))throw new Error("Expected type of string or object");t=e}if(!t)return[];if(!Array.isArray(t))throw new Error("Expected JSON string to be array");return t.map(c.bufferify)}getLayers(){return this.layers}getHexLayers(){return this.layers.reduce(((e,t)=>(Array.isArray(t)?e.push(t.map((e=>this.bufferToHex(e)))):e.push(t),e)),[])}getLayersFlat(){const e=this.layers.reduce(((e,t)=>(Array.isArray(t)?e.unshift(...t):e.unshift(t),e)),[]);return e.unshift(i.Buffer.from([0])),e}getHexLayersFlat(){return this.getLayersFlat().map((e=>this.bufferToHex(e)))}getLayerCount(){return this.getLayers().length}getRoot(){return 0===this.layers.length?i.Buffer.from([]):this.layers[this.layers.length-1][0]||i.Buffer.from([])}getHexRoot(){return this.bufferToHex(this.getRoot())}getProof(e,t){if(void 0===e)throw new Error("leaf is required");e=this.bufferify(e);const r=[];if(!Number.isInteger(t)){t=-1;for(let r=0;rthis.bufferToHex(e.data)))}getProofs(){const e=[];return this.getProofsDFS(this.layers.length-1,0,[],e),e}getProofsDFS(e,t,r,n){const i=t%2;if(-1===e)return void(i||n.push([...r].reverse()));if(t>=this.layers[e].length)return;const o=this.layers[e],a=i?t-1:t+1;let s=!1;athis.bufferToHex(e.data)))}getPositionalHexProof(e,t){return this.getProof(e,t).map((e=>["left"===e.position?0:1,this.bufferToHex(e.data)]))}static marshalProof(e){const t=e.map((e=>"string"==typeof e?e:i.Buffer.isBuffer(e)?c.bufferToHex(e):{position:e.position,data:c.bufferToHex(e.data)}));return JSON.stringify(t,null,2)}static unmarshalProof(e){let t=null;if("string"==typeof e)t=JSON.parse(e);else{if(!(e instanceof Object))throw new Error("Expected type of string or object");t=e}if(!t)return[];if(!Array.isArray(t))throw new Error("Expected JSON string to be array");return t.map((e=>{if("string"==typeof e)return c.bufferify(e);if(e instanceof Object)return{position:e.position,data:c.bufferify(e.data)};throw new Error("Expected item to be of type string or object")}))}static marshalTree(e){const t=e.getHexRoot(),r=e.leaves.map((e=>c.bufferToHex(e))),n=e.getHexLayers(),i=e.getOptions();return JSON.stringify({options:i,root:t,layers:n,leaves:r},null,2)}static unmarshalTree(e,t=a.default,r={}){let n=null;if("string"==typeof e)n=JSON.parse(e);else{if(!(e instanceof Object))throw new Error("Expected type of string or object");n=e}if(!n)throw new Error("could not parse json");return r=Object.assign({},n.options||{},r),new c(n.leaves,t,r)}getProofIndices(e,t){const r=Math.pow(2,t);let n=new Set;for(const t of e){let e=r+t;for(;e>1;)n.add(1^e),e=e/2|0}const i=e.map((e=>r+e)),o=Array.from(n).sort(((e,t)=>e-t)).reverse();n=i.concat(o);const a=new Set,s=[];for(let e of n)if(!a.has(e))for(s.push(e);e>1&&(a.add(e),a.has(1^e));)e=e/2|0;return s.filter((t=>!e.includes(t-r)))}getProofIndicesForUnevenTree(e,t){const r=Math.ceil(Math.log2(t)),n=[];for(let e=0;ee%2==0?e+1:e-1)).filter((e=>!o.includes(e)));const r=n.find((({index:t})=>t===e));r&&o.includes(r.leavesCount-1)&&(t=t.slice(0,-1)),i.push(t),o=[...new Set(o.map((e=>e%2==0?e/2:e%2==0?(e+1)/2:(e-1)/2)))]}return i}getMultiProof(e,t){this.complete||console.warn("Warning: For correct multiProofs it's strongly recommended to set complete: true"),t||(t=e,e=this.getLayersFlat());if(this.isUnevenTree()&&t.every(Number.isInteger))return this.getMultiProofForUnevenTree(t);if(!t.every(Number.isInteger)){let e=t;this.sortPairs&&(e=e.sort(i.Buffer.compare));let r=e.map((e=>this.bufferIndexOf(this.leaves,e,this.sortLeaves))).sort(((e,t)=>e===t?0:e>t?1:-1));if(!r.every((e=>-1!==e)))throw new Error("Element does not exist in Merkle tree");const n=[],o=[];let a=[];for(let e=0;er.indexOf(e)===t)),a=[]}return o.filter((e=>!n.includes(e)))}return this.getProofIndices(t,Math.log2(e.length/2|0)).map((t=>e[t]))}getMultiProofForUnevenTree(e,t){t||(t=e,e=this.getLayers());let r=[],n=t;for(const t of e){const e=[];for(const r of n){if(r%2==0){const i=r+1;if(!n.includes(i)&&t[i]){e.push(t[i]);continue}}const i=r-1;n.includes(i)||!t[i]||e.push(t[i])}r=r.concat(e);const i=new Set;for(const e of n)e%2!=0?e%2!=0?i.add((e-1)/2):i.add((e+1)/2):i.add(e/2);n=Array.from(i)}return r}getHexMultiProof(e,t){return this.getMultiProof(e,t).map((e=>this.bufferToHex(e)))}getProofFlags(e,t){if(!Array.isArray(e)||e.length<=0)throw new Error("Invalid Inputs!");let r;if(r=e.every(Number.isInteger)?[...e].sort(((e,t)=>e===t?0:e>t?1:-1)):e.map((e=>this.bufferIndexOf(this.leaves,e,this.sortLeaves))).sort(((e,t)=>e===t?0:e>t?1:-1)),!r.every((e=>-1!==e)))throw new Error("Element does not exist in Merkle tree");const n=t.map((e=>this.bufferify(e))),i=[],o=[];for(let e=0;e{if(!i.includes(t[r])){const e=this.getPairNode(t,r),a=n.includes(t[r])||n.includes(e);e&&o.push(!a),i.push(t[r]),i.push(e)}return e.push(r/2|0),e}),[])}return o}verify(e,t,r){let n=this.bufferify(t);if(r=this.bufferify(r),!Array.isArray(e)||!t||!r)return!1;for(let t=0;tthis.bufferify(e))),o=o.map((e=>this.bufferify(e)));const s={};for(const[e,n]of this.zip(t,r))s[Math.pow(2,a)+e]=n;for(const[e,r]of this.zip(this.getProofIndices(t,a),o))s[e]=r;let u=Object.keys(s).map((e=>+e)).sort(((e,t)=>e-t));u=u.slice(0,u.length-1);let c=0;for(;c=2&&{}.hasOwnProperty.call(s,1^e)){let t=[s[e-e%2],s[e-e%2+1]];this.sortPairs&&(t=t.sort(i.Buffer.compare));const r=t[1]?this.hashFn(this.concatenator(t)):t[0];s[e/2|0]=r,u.push(e/2|0)}c+=1}return!t.length||{}.hasOwnProperty.call(s,1)&&s[1].equals(e)}verifyMultiProofWithFlags(e,t,r,n){e=this.bufferify(e),t=t.map(this.bufferify),r=r.map(this.bufferify);const o=t.length,a=n.length,s=[];let u=0,c=0,l=0;for(let e=0;ethis.bufferify(e))),i=i.map((e=>this.bufferify(e)));const o=this.calculateRootForUnevenTree(t,r,n,i);return e.equals(o)}getDepth(){return this.getLayers().length-1}getLayersAsObject(){const e=this.getLayers().map((e=>e.map((e=>this.bufferToHex(e,!1))))),t=[];for(let r=0;re-t)),o=i.map((([e])=>e)),a=this.getProofIndicesForUnevenTree(o,r);let s=0;const u=[];for(let e=0;ee-t)).map((([,e])=>e)),r=c[e].map((([e])=>e)),n=[...new Set(r.map((e=>e%2==0?e/2:e%2==0?(e+1)/2:(e-1)/2)))],i=[];for(let e=0;e{var n=r(96240),i=r(29931);function o(e){this.rand=e||new i.Rand}e.exports=o,o.create=function(e){return new o(e)},o.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var i=new n(this.rand.generate(r))}while(i.cmp(e)>=0);return i},o.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},o.prototype.test=function(e,t,r){var i=e.bitLength(),o=n.mont(e),a=new n(1).toRed(o);t||(t=Math.max(1,i/48|0));for(var s=e.subn(1),u=0;!s.testn(u);u++);for(var c=e.shrn(u),l=s.toRed(o);t>0;t--){var f=this._randrange(new n(2),s);r&&r(f);var h=f.toRed(o).redPow(c);if(0!==h.cmp(a)&&0!==h.cmp(l)){for(var d=1;d0;t--){var l=this._randrange(new n(2),a),f=e.gcd(l);if(0!==f.cmpn(1))return f;var h=l.toRed(i).redPow(u);if(0!==h.cmp(o)&&0!==h.cmp(c)){for(var d=1;d=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},79746:e=>{function t(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=t,t.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},34504:(e,t)=>{"use strict";var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}},19516:(e,t,r)=>{var n=r(34155),i=r(28325),o=r(84574),a=r(24753),s=require,u=n.config&&n.config.variables||{},c=!!n.env.PREBUILDS_ONLY,l=n.versions.modules,f=!(!n.versions||!n.versions.electron)||!!n.env.ELECTRON_RUN_AS_NODE||"undefined"!=typeof window&&window.process&&"renderer"===window.process.type?"electron":n.versions&&n.versions.nw?"node-webkit":"node",h=n.env.npm_config_arch||a.arch(),d=n.env.npm_config_platform||a.platform(),p=n.env.LIBC||(function(e){return"linux"===e&&i.existsSync("/etc/alpine-release")}(d)?"musl":"glibc"),m=n.env.ARM_VERSION||("arm64"===h?"8":u.arm_version)||"",y=(n.versions.uv||"").split(".")[0];function g(e){return s(g.path(e))}function b(e){try{return i.readdirSync(e)}catch(e){return[]}}function v(e,t){var r=b(e).filter(t);return r[0]&&o.join(e,r[0])}function w(e){return/\.node$/.test(e)}function A(e){var t=e.split("-");if(2===t.length){var r=t[0],n=t[1].split("+");if(r&&n.length&&n.every(Boolean))return{name:e,platform:r,architectures:n}}}function S(e,t){return function(r){return null!=r&&(r.platform===e&&r.architectures.includes(t))}}function k(e,t){return e.architectures.length-t.architectures.length}function E(e){var t=e.split("."),r={file:e,specificity:0};if("node"===t.pop()){for(var n=0;nr.specificity?-1:1:0}}e.exports=g,g.path=function(e){e=o.resolve(e||".");try{var t=s(o.join(e,"package.json")).name.toUpperCase().replace(/-/g,"_");n.env[t+"_PREBUILD"]&&(e=n.env[t+"_PREBUILD"])}catch(e){}if(!c){var r=v(o.join(e,"build/Release"),w);if(r)return r;var i=v(o.join(e,"build/Debug"),w);if(i)return i}var a=T(e);if(a)return a;var u=T(o.dirname(n.execPath));if(u)return u;var g=["platform="+d,"arch="+h,"runtime="+f,"abi="+l,"uv="+y,m?"armv="+m:"","libc="+p,"node="+n.versions.node,n.versions.electron?"electron="+n.versions.electron:"","webpack=true"].filter(Boolean).join(" ");throw new Error("No native build was found for "+g+"\n loaded from: "+e+"\n");function T(e){var t=b(o.join(e,"prebuilds")).map(A).filter(S(d,h)).sort(k)[0];if(t){var r=o.join(e,"prebuilds",t.name),n=b(r).map(E).filter(_(f,l)).sort(M(f))[0];return n?o.join(r,n.file):void 0}}},g.parseTags=E,g.matchTags=_,g.compareTags=M,g.parseTuple=A,g.matchTuple=S,g.compareTuples=k},70631:(e,t,r)=>{var n="function"==typeof Map&&Map.prototype,i=Object.getOwnPropertyDescriptor&&n?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,o=n&&i&&"function"==typeof i.get?i.get:null,a=n&&Map.prototype.forEach,s="function"==typeof Set&&Set.prototype,u=Object.getOwnPropertyDescriptor&&s?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,c=s&&u&&"function"==typeof u.get?u.get:null,l=s&&Set.prototype.forEach,f="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,h="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,d="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,p=Boolean.prototype.valueOf,m=Object.prototype.toString,y=Function.prototype.toString,g=String.prototype.match,b=String.prototype.slice,v=String.prototype.replace,w=String.prototype.toUpperCase,A=String.prototype.toLowerCase,S=RegExp.prototype.test,k=Array.prototype.concat,E=Array.prototype.join,_=Array.prototype.slice,M=Math.floor,T="function"==typeof BigInt?BigInt.prototype.valueOf:null,x=Object.getOwnPropertySymbols,P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,I="function"==typeof Symbol&&"object"==typeof Symbol.iterator,O="function"==typeof Symbol&&Symbol.toStringTag&&(typeof Symbol.toStringTag===I||"symbol")?Symbol.toStringTag:null,R=Object.prototype.propertyIsEnumerable,C=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function B(e,t){if(e===1/0||e===-1/0||e!=e||e&&e>-1e3&&e<1e3||S.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof e){var n=e<0?-M(-e):M(e);if(n!==e){var i=String(n),o=b.call(t,i.length+1);return v.call(i,r,"$&_")+"."+v.call(v.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return v.call(t,r,"$&_")}var N=r(24654),L=N.custom,U=J(L)?L:null;function F(e,t,r){var n="double"===(r.quoteStyle||t)?'"':"'";return n+e+n}function D(e){return v.call(String(e),/"/g,""")}function j(e){return!("[object Array]"!==q(e)||O&&"object"==typeof e&&O in e)}function H(e){return!("[object RegExp]"!==q(e)||O&&"object"==typeof e&&O in e)}function J(e){if(I)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!P)return!1;try{return P.call(e),!0}catch(e){}return!1}e.exports=function e(t,r,n,i){var s=r||{};if(G(s,"quoteStyle")&&"single"!==s.quoteStyle&&"double"!==s.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(G(s,"maxStringLength")&&("number"==typeof s.maxStringLength?s.maxStringLength<0&&s.maxStringLength!==1/0:null!==s.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var u=!G(s,"customInspect")||s.customInspect;if("boolean"!=typeof u&&"symbol"!==u)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(G(s,"indent")&&null!==s.indent&&"\t"!==s.indent&&!(parseInt(s.indent,10)===s.indent&&s.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(G(s,"numericSeparator")&&"boolean"!=typeof s.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var m=s.numericSeparator;if(void 0===t)return"undefined";if(null===t)return"null";if("boolean"==typeof t)return t?"true":"false";if("string"==typeof t)return V(t,s);if("number"==typeof t){if(0===t)return 1/0/t>0?"0":"-0";var w=String(t);return m?B(t,w):w}if("bigint"==typeof t){var S=String(t)+"n";return m?B(t,S):S}var M=void 0===s.depth?5:s.depth;if(void 0===n&&(n=0),n>=M&&M>0&&"object"==typeof t)return j(t)?"[Array]":"[Object]";var x=function(e,t){var r;if("\t"===e.indent)r="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;r=E.call(Array(e.indent+1)," ")}return{base:r,prev:E.call(Array(t+1),r)}}(s,n);if(void 0===i)i=[];else if(K(i,t)>=0)return"[Circular]";function L(t,r,o){if(r&&(i=_.call(i)).push(r),o){var a={depth:s.depth};return G(s,"quoteStyle")&&(a.quoteStyle=s.quoteStyle),e(t,a,n+1,i)}return e(t,s,n+1,i)}if("function"==typeof t&&!H(t)){var z=function(e){if(e.name)return e.name;var t=g.call(y.call(e),/^function\s*([\w$]+)/);if(t)return t[1];return null}(t),X=$(t,L);return"[Function"+(z?": "+z:" (anonymous)")+"]"+(X.length>0?" { "+E.call(X,", ")+" }":"")}if(J(t)){var ee=I?v.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):P.call(t);return"object"!=typeof t||I?ee:Q(ee)}if(function(e){if(!e||"object"!=typeof e)return!1;if("undefined"!=typeof HTMLElement&&e instanceof HTMLElement)return!0;return"string"==typeof e.nodeName&&"function"==typeof e.getAttribute}(t)){for(var te="<"+A.call(String(t.nodeName)),re=t.attributes||[],ne=0;ne"}if(j(t)){if(0===t.length)return"[]";var ie=$(t,L);return x&&!function(e){for(var t=0;t=0)return!1;return!0}(ie)?"["+Y(ie,x)+"]":"[ "+E.call(ie,", ")+" ]"}if(function(e){return!("[object Error]"!==q(e)||O&&"object"==typeof e&&O in e)}(t)){var oe=$(t,L);return"cause"in Error.prototype||!("cause"in t)||R.call(t,"cause")?0===oe.length?"["+String(t)+"]":"{ ["+String(t)+"] "+E.call(oe,", ")+" }":"{ ["+String(t)+"] "+E.call(k.call("[cause]: "+L(t.cause),oe),", ")+" }"}if("object"==typeof t&&u){if(U&&"function"==typeof t[U]&&N)return N(t,{depth:M-n});if("symbol"!==u&&"function"==typeof t.inspect)return t.inspect()}if(function(e){if(!o||!e||"object"!=typeof e)return!1;try{o.call(e);try{c.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(t)){var ae=[];return a.call(t,(function(e,r){ae.push(L(r,t,!0)+" => "+L(e,t))})),Z("Map",o.call(t),ae,x)}if(function(e){if(!c||!e||"object"!=typeof e)return!1;try{c.call(e);try{o.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(t)){var se=[];return l.call(t,(function(e){se.push(L(e,t))})),Z("Set",c.call(t),se,x)}if(function(e){if(!f||!e||"object"!=typeof e)return!1;try{f.call(e,f);try{h.call(e,h)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(t))return W("WeakMap");if(function(e){if(!h||!e||"object"!=typeof e)return!1;try{h.call(e,h);try{f.call(e,f)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(t))return W("WeakSet");if(function(e){if(!d||!e||"object"!=typeof e)return!1;try{return d.call(e),!0}catch(e){}return!1}(t))return W("WeakRef");if(function(e){return!("[object Number]"!==q(e)||O&&"object"==typeof e&&O in e)}(t))return Q(L(Number(t)));if(function(e){if(!e||"object"!=typeof e||!T)return!1;try{return T.call(e),!0}catch(e){}return!1}(t))return Q(L(T.call(t)));if(function(e){return!("[object Boolean]"!==q(e)||O&&"object"==typeof e&&O in e)}(t))return Q(p.call(t));if(function(e){return!("[object String]"!==q(e)||O&&"object"==typeof e&&O in e)}(t))return Q(L(String(t)));if(!function(e){return!("[object Date]"!==q(e)||O&&"object"==typeof e&&O in e)}(t)&&!H(t)){var ue=$(t,L),ce=C?C(t)===Object.prototype:t instanceof Object||t.constructor===Object,le=t instanceof Object?"":"null prototype",fe=!ce&&O&&Object(t)===t&&O in t?b.call(q(t),8,-1):le?"Object":"",he=(ce||"function"!=typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(fe||le?"["+E.call(k.call([],fe||[],le||[]),": ")+"] ":"");return 0===ue.length?he+"{}":x?he+"{"+Y(ue,x)+"}":he+"{ "+E.call(ue,", ")+" }"}return String(t)};var z=Object.prototype.hasOwnProperty||function(e){return e in this};function G(e,t){return z.call(e,t)}function q(e){return m.call(e)}function K(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;rt.maxStringLength){var r=e.length-t.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return V(b.call(e,0,t.maxStringLength),t)+n}return F(v.call(v.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,X),"single",t)}function X(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+w.call(t.toString(16))}function Q(e){return"Object("+e+")"}function W(e){return e+" { ? }"}function Z(e,t,r,n){return e+" ("+t+") {"+(n?Y(r,n):E.call(r,", "))+"}"}function Y(e,t){if(0===e.length)return"";var r="\n"+t.prev+t.base;return r+E.call(e,","+r)+"\n"+t.prev}function $(e,t){var r=j(e),n=[];if(r){n.length=e.length;for(var i=0;i{e.exports=r(24753)},52818:(e,t,r)=>{"use strict";var n=r(39809);t.certificate=r(41934);var i=n.define("RSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())}));t.RSAPrivateKey=i;var o=n.define("RSAPublicKey",(function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())}));t.RSAPublicKey=o;var a=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())}));t.PublicKey=a;var s=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())})),u=n.define("PrivateKeyInfo",(function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(s),this.key("subjectPrivateKey").octstr())}));t.PrivateKey=u;var c=n.define("EncryptedPrivateKeyInfo",(function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())}));t.EncryptedPrivateKey=c;var l=n.define("DSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())}));t.DSAPrivateKey=l,t.DSAparam=n.define("DSAparam",(function(){this.int()}));var f=n.define("ECPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(h),this.key("publicKey").optional().explicit(1).bitstr())}));t.ECPrivateKey=f;var h=n.define("ECParameters",(function(){this.choice({namedCurve:this.objid()})}));t.signature=n.define("signature",(function(){this.seq().obj(this.key("r").int(),this.key("s").int())}))},41934:(e,t,r)=>{"use strict";var n=r(39809),i=n.define("Time",(function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})})),o=n.define("AttributeTypeValue",(function(){this.seq().obj(this.key("type").objid(),this.key("value").any())})),a=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())})),s=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(a),this.key("subjectPublicKey").bitstr())})),u=n.define("RelativeDistinguishedName",(function(){this.setof(o)})),c=n.define("RDNSequence",(function(){this.seqof(u)})),l=n.define("Name",(function(){this.choice({rdnSequence:this.use(c)})})),f=n.define("Validity",(function(){this.seq().obj(this.key("notBefore").use(i),this.key("notAfter").use(i))})),h=n.define("Extension",(function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())})),d=n.define("TBSCertificate",(function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(a),this.key("issuer").use(l),this.key("validity").use(f),this.key("subject").use(l),this.key("subjectPublicKeyInfo").use(s),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(h).optional())})),p=n.define("X509Certificate",(function(){this.seq().obj(this.key("tbsCertificate").use(d),this.key("signatureAlgorithm").use(a),this.key("signatureValue").bitstr())}));e.exports=p},77631:(e,t,r)=>{var n=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,i=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,o=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,a=r(13048),s=r(44696),u=r(89509).Buffer;e.exports=function(e,t){var r,c=e.toString(),l=c.match(n);if(l){var f="aes"+l[1],h=u.from(l[2],"hex"),d=u.from(l[3].replace(/[\r\n]/g,""),"base64"),p=a(t,h.slice(0,8),parseInt(l[1],10)).key,m=[],y=s.createDecipheriv(f,p,h);m.push(y.update(d)),m.push(y.final()),r=u.concat(m)}else{var g=c.match(o);r=u.from(g[2].replace(/[\r\n]/g,""),"base64")}return{tag:c.match(i)[1],data:r}}},70980:(e,t,r)=>{var n=r(52818),i=r(22562),o=r(77631),a=r(44696),s=r(25632),u=r(89509).Buffer;function c(e){var t;"object"!=typeof e||u.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=u.from(e));var r,c,l=o(e,t),f=l.tag,h=l.data;switch(f){case"CERTIFICATE":c=n.certificate.decode(h,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(c||(c=n.PublicKey.decode(h,"der")),r=c.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPublicKey.decode(c.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return c.subjectPrivateKey=c.subjectPublicKey,{type:"ec",data:c};case"1.2.840.10040.4.1":return c.algorithm.params.pub_key=n.DSAparam.decode(c.subjectPublicKey.data,"der"),{type:"dsa",data:c.algorithm.params};default:throw new Error("unknown key id "+r)}case"ENCRYPTED PRIVATE KEY":h=function(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,n=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),o=i[e.algorithm.decrypt.cipher.algo.join(".")],c=e.algorithm.decrypt.cipher.iv,l=e.subjectPrivateKey,f=parseInt(o.split("-")[1],10)/8,h=s.pbkdf2Sync(t,r,n,f,"sha1"),d=a.createDecipheriv(o,h,c),p=[];return p.push(d.update(l)),p.push(d.final()),u.concat(p)}(h=n.EncryptedPrivateKey.decode(h,"der"),t);case"PRIVATE KEY":switch(r=(c=n.PrivateKey.decode(h,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPrivateKey.decode(c.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:c.algorithm.curve,privateKey:n.ECPrivateKey.decode(c.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return c.algorithm.params.priv_key=n.DSAparam.decode(c.subjectPrivateKey,"der"),{type:"dsa",params:c.algorithm.params};default:throw new Error("unknown key id "+r)}case"RSA PUBLIC KEY":return n.RSAPublicKey.decode(h,"der");case"RSA PRIVATE KEY":return n.RSAPrivateKey.decode(h,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:n.DSAPrivateKey.decode(h,"der")};case"EC PRIVATE KEY":return{curve:(h=n.ECPrivateKey.decode(h,"der")).parameters.value,privateKey:h.privateKey};default:throw new Error("unknown key type "+f)}}e.exports=c,c.signature=n.signature},25632:(e,t,r)=>{t.pbkdf2=r(88638),t.pbkdf2Sync=r(91257)},88638:(e,t,r)=>{var n,i,o=r(89509).Buffer,a=r(77357),s=r(12368),u=r(91257),c=r(57777),l=r.g.crypto&&r.g.crypto.subtle,f={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},h=[];function d(){return i||(i=r.g.process&&r.g.process.nextTick?r.g.process.nextTick:r.g.queueMicrotask?r.g.queueMicrotask:r.g.setImmediate?r.g.setImmediate:r.g.setTimeout)}function p(e,t,r,n,i){return l.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then((function(e){return l.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},e,n<<3)})).then((function(e){return o.from(e)}))}e.exports=function(e,t,i,m,y,g){"function"==typeof y&&(g=y,y=void 0);var b=f[(y=y||"sha1").toLowerCase()];if(b&&"function"==typeof r.g.Promise){if(a(i,m),e=c(e,s,"Password"),t=c(t,s,"Salt"),"function"!=typeof g)throw new Error("No callback provided to pbkdf2");!function(e,t){e.then((function(e){d()((function(){t(null,e)}))}),(function(e){d()((function(){t(e)}))}))}(function(e){if(r.g.process&&!r.g.process.browser)return Promise.resolve(!1);if(!l||!l.importKey||!l.deriveBits)return Promise.resolve(!1);if(void 0!==h[e])return h[e];var t=p(n=n||o.alloc(8),n,10,128,e).then((function(){return!0})).catch((function(){return!1}));return h[e]=t,t}(b).then((function(r){return r?p(e,t,i,m,b):u(e,t,i,m,y)})),g)}else d()((function(){var r;try{r=u(e,t,i,m,y)}catch(e){return g(e)}g(null,r)}))}},12368:(e,t,r)=>{var n,i=r(34155);if(r.g.process&&r.g.process.browser)n="utf-8";else if(r.g.process&&r.g.process.version){n=parseInt(i.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary"}else n="utf-8";e.exports=n},77357:e=>{var t=Math.pow(2,30)-1;e.exports=function(e,r){if("number"!=typeof e)throw new TypeError("Iterations not a number");if(e<0)throw new TypeError("Bad iterations");if("number"!=typeof r)throw new TypeError("Key length not a number");if(r<0||r>t||r!=r)throw new TypeError("Bad key length")}},91257:(e,t,r)=>{var n=r(78028),i=r(79785),o=r(89072),a=r(89509).Buffer,s=r(77357),u=r(12368),c=r(57777),l=a.alloc(128),f={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function h(e,t,r){var s=function(e){function t(t){return o(e).update(t).digest()}function r(e){return(new i).update(e).digest()}return"rmd160"===e||"ripemd160"===e?r:"md5"===e?n:t}(e),u="sha512"===e||"sha384"===e?128:64;t.length>u?t=s(t):t.length{var n=r(89509).Buffer;e.exports=function(e,t,r){if(n.isBuffer(e))return e;if("string"==typeof e)return n.from(e,t);if(ArrayBuffer.isView(e))return n.from(e.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")}},34155:e=>{var t,r,n=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===i||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:i}catch(e){t=i}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(e){r=o}}();var s,u=[],c=!1,l=-1;function f(){c&&s&&(c=!1,s.length?u=s.concat(u):l=-1,u.length&&h())}function h(){if(!c){var e=a(f);c=!0;for(var t=u.length;t;){for(s=u,u=[];++l1)for(var r=1;r{t.publicEncrypt=r(16559),t.privateDecrypt=r(26138),t.privateEncrypt=function(e,r){return t.publicEncrypt(e,r,!0)},t.publicDecrypt=function(e,r){return t.privateDecrypt(e,r,!0)}},99199:(e,t,r)=>{var n=r(23482),i=r(89509).Buffer;function o(e){var t=i.allocUnsafe(4);return t.writeUInt32BE(e,0),t}e.exports=function(e,t){for(var r,a=i.alloc(0),s=0;a.length=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=u(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,l=r;l1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],f=[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],h=[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 d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=f[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[c-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n(void 0!==a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,c=new e(o),l=this.clone();if(u){for(s=0;!l.isZero();s++)a=l.andln(255),l.iushrn(8),c[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function m(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):m(this,e,t),r},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=i);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(l),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var g={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(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)}b.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},b.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(e,t){e.iushrn(this.n,0,t)},b.prototype.imulK=function(e){return e.imul(this.k)},i(v,b),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(g[e])return g[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return g[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new o(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();n(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new E(e)},i(E,k),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},26138:(e,t,r)=>{var n=r(70980),i=r(99199),o=r(57859),a=r(92144),s=r(23663),u=r(23482),c=r(84818),l=r(89509).Buffer;e.exports=function(e,t,r){var f;f=e.padding?e.padding:r?1:4;var h,d=n(e),p=d.modulus.byteLength();if(t.length>p||new a(t).cmp(d.modulus)>=0)throw new Error("decryption error");h=r?c(new a(t),d):s(t,d);var m=l.alloc(p-h.length);if(h=l.concat([m,h],p),4===f)return function(e,t){var r=e.modulus.byteLength(),n=u("sha1").update(l.alloc(0)).digest(),a=n.length;if(0!==t[0])throw new Error("decryption error");var s=t.slice(1,a+1),c=t.slice(a+1),f=o(s,i(c,a)),h=o(c,i(f,r-a-1));if(function(e,t){e=l.from(e),t=l.from(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));var i=-1;for(;++i=t.length){o++;break}var a=t.slice(2,i-1);("0002"!==n.toString("hex")&&!r||"0001"!==n.toString("hex")&&r)&&o++;a.length<8&&o++;if(o)throw new Error("decryption error");return t.slice(i)}(0,h,r);if(3===f)return h;throw new Error("unknown padding")}},16559:(e,t,r)=>{var n=r(70980),i=r(61798),o=r(23482),a=r(99199),s=r(57859),u=r(92144),c=r(84818),l=r(23663),f=r(89509).Buffer;e.exports=function(e,t,r){var h;h=e.padding?e.padding:r?1:4;var d,p=n(e);if(4===h)d=function(e,t){var r=e.modulus.byteLength(),n=t.length,c=o("sha1").update(f.alloc(0)).digest(),l=c.length,h=2*l;if(n>r-h-2)throw new Error("message too long");var d=f.alloc(r-n-h-2),p=r-l-1,m=i(l),y=s(f.concat([c,d,f.alloc(1,1),t],p),a(m,p)),g=s(m,a(y,l));return new u(f.concat([f.alloc(1),g,y],r))}(p,t);else if(1===h)d=function(e,t,r){var n,o=t.length,a=e.modulus.byteLength();if(o>a-11)throw new Error("message too long");n=r?f.alloc(a-o-3,255):function(e){var t,r=f.allocUnsafe(e),n=0,o=i(2*e),a=0;for(;n=0)throw new Error("data too long for modulus")}return r?l(d,p):c(d,p)}},84818:(e,t,r)=>{var n=r(92144),i=r(89509).Buffer;e.exports=function(e,t){return i.from(e.toRed(n.mont(t.modulus)).redPow(new n(t.publicExponent)).fromRed().toArray())}},57859:e=>{e.exports=function(e,t){for(var r=e.length,n=-1;++n{"use strict";var t=String.prototype.replace,r=/%20/g,n="RFC1738",i="RFC3986";e.exports={default:i,formatters:{RFC1738:function(e){return t.call(e,r,"+")},RFC3986:function(e){return String(e)}},RFC1738:n,RFC3986:i}},80129:(e,t,r)=>{"use strict";var n=r(58261),i=r(55235),o=r(55798);e.exports={formats:o,parse:i,stringify:n}},55235:(e,t,r)=>{"use strict";var n=r(12769),i=Object.prototype.hasOwnProperty,o=Array.isArray,a={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:n.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},s=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},u=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},c=function(e,t,r,n){if(e){var o=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,a=/(\[[^[\]]*])/g,s=r.depth>0&&/(\[[^[\]]*])/.exec(o),c=s?o.slice(0,s.index):o,l=[];if(c){if(!r.plainObjects&&i.call(Object.prototype,c)&&!r.allowPrototypes)return;l.push(c)}for(var f=0;r.depth>0&&null!==(s=a.exec(o))&&f=0;--o){var a,s=e[o];if("[]"===s&&r.parseArrays)a=[].concat(i);else{a=r.plainObjects?Object.create(null):{};var c="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,l=parseInt(c,10);r.parseArrays||""!==c?!isNaN(l)&&s!==c&&String(l)===c&&l>=0&&r.parseArrays&&l<=r.arrayLimit?(a=[])[l]=i:"__proto__"!==c&&(a[c]=i):a={0:i}}i=a}return i}(l,t,r,n)}};e.exports=function(e,t){var r=function(e){if(!e)return a;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?a.charset:e.charset;return{allowDots:void 0===e.allowDots?a.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:a.allowPrototypes,allowSparse:"boolean"==typeof e.allowSparse?e.allowSparse:a.allowSparse,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:a.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:a.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:a.comma,decoder:"function"==typeof e.decoder?e.decoder:a.decoder,delimiter:"string"==typeof e.delimiter||n.isRegExp(e.delimiter)?e.delimiter:a.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:a.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:a.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:a.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:a.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var l="string"==typeof e?function(e,t){var r,c={},l=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,f=t.parameterLimit===1/0?void 0:t.parameterLimit,h=l.split(t.delimiter,f),d=-1,p=t.charset;if(t.charsetSentinel)for(r=0;r-1&&(y=o(y)?[y]:y),i.call(c,m)?c[m]=n.combine(c[m],y):c[m]=y}return c}(e,r):e,f=r.plainObjects?Object.create(null):{},h=Object.keys(l),d=0;d{"use strict";var n=r(37478),i=r(12769),o=r(55798),a=Object.prototype.hasOwnProperty,s={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},u=Array.isArray,c=String.prototype.split,l=Array.prototype.push,f=function(e,t){l.apply(e,u(t)?t:[t])},h=Date.prototype.toISOString,d=o.default,p={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:i.encode,encodeValuesOnly:!1,format:d,formatter:o.formatters[d],indices:!1,serializeDate:function(e){return h.call(e)},skipNulls:!1,strictNullHandling:!1},m={},y=function e(t,r,o,a,s,l,h,d,y,g,b,v,w,A,S,k){for(var E,_=t,M=k,T=0,x=!1;void 0!==(M=M.get(m))&&!x;){var P=M.get(t);if(T+=1,void 0!==P){if(P===T)throw new RangeError("Cyclic object value");x=!0}void 0===M.get(m)&&(T=0)}if("function"==typeof d?_=d(r,_):_ instanceof Date?_=b(_):"comma"===o&&u(_)&&(_=i.maybeMap(_,(function(e){return e instanceof Date?b(e):e}))),null===_){if(s)return h&&!A?h(r,p.encoder,S,"key",v):r;_=""}if("string"==typeof(E=_)||"number"==typeof E||"boolean"==typeof E||"symbol"==typeof E||"bigint"==typeof E||i.isBuffer(_)){if(h){var I=A?r:h(r,p.encoder,S,"key",v);if("comma"===o&&A){for(var O=c.call(String(_),","),R="",C=0;C0?_.join(",")||null:void 0}];else if(u(d))B=d;else{var L=Object.keys(_);B=y?L.sort(y):L}for(var U=a&&u(_)&&1===_.length?r+"[]":r,F=0;F0?A+w:""}},12769:(e,t,r)=>{"use strict";var n=r(55798),i=Object.prototype.hasOwnProperty,o=Array.isArray,a=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),s=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},n=0;n1;){var t=e.pop(),r=t.obj[t.prop];if(o(r)){for(var n=[],i=0;i=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||o===n.RFC1738&&(40===l||41===l)?u+=s.charAt(c):l<128?u+=a[l]:l<2048?u+=a[192|l>>6]+a[128|63&l]:l<55296||l>=57344?u+=a[224|l>>12]+a[128|l>>6&63]+a[128|63&l]:(c+=1,l=65536+((1023&l)<<10|1023&s.charCodeAt(c)),u+=a[240|l>>18]+a[128|l>>12&63]+a[128|l>>6&63]+a[128|63&l])}return u},isBuffer:function(e){return!(!e||"object"!=typeof e)&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(o(e)){for(var r=[],n=0;n{"use strict";var n=r(34155),i=65536,o=4294967295;var a=r(89509).Buffer,s=r.g.crypto||r.g.msCrypto;s&&s.getRandomValues?e.exports=function(e,t){if(e>o)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(e);if(e>0)if(e>i)for(var u=0;u{"use strict";var n=r(34155);function i(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var o=r(89509),a=r(61798),s=o.Buffer,u=o.kMaxLength,c=r.g.crypto||r.g.msCrypto,l=Math.pow(2,32)-1;function f(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(e>l||e<0)throw new TypeError("offset must be a uint32");if(e>u||e>t)throw new RangeError("offset out of range")}function h(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(e>l||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>u)throw new RangeError("buffer too small")}function d(e,t,r,i){if(n.browser){var o=e.buffer,s=new Uint8Array(o,t,r);return c.getRandomValues(s),i?void n.nextTick((function(){i(null,e)})):e}if(!i)return a(r).copy(e,t),e;a(r,(function(r,n){if(r)return i(r);n.copy(e,t),i(null,e)}))}c&&c.getRandomValues||!n.browser?(t.randomFill=function(e,t,n,i){if(!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof t)i=t,t=0,n=e.length;else if("function"==typeof n)i=n,n=e.length-t;else if("function"!=typeof i)throw new TypeError('"cb" argument must be a function');return f(t,e.length),h(n,t,e.length),d(e,t,n,i)},t.randomFillSync=function(e,t,n){void 0===t&&(t=0);if(!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');f(t,e.length),void 0===n&&(n=e.length-t);return h(n,t,e.length),d(e,t,n)}):(t.randomFill=i,t.randomFillSync=i)},47055:(e,t,r)=>{e.exports=r(29344)},12401:e=>{"use strict";e.exports=class e{constructor(e,t=new Map,r=0){this.prefix=e,this._existing=t,this.counter=r}clone(){const{prefix:t,_existing:r,counter:n}=this;return new e(t,new Map(r),n)}getId(e){const t=e&&this._existing.get(e);if(t)return t;const r=this.prefix+this.counter;return this.counter++,e&&this._existing.set(e,r),r}hasId(e){return this._existing.has(e)}getOldIds(){return[...this._existing.keys()]}}},75947:(e,t,r)=>{"use strict";r(24889);const n=self.crypto||self.msCrypto;e.exports=class{constructor(e){if(!n||!n.subtle)throw new Error("crypto.subtle not found.");if("sha256"===e)this.algorithm={name:"SHA-256"};else{if("sha1"!==e)throw new Error(`Unsupported algorithm "${e}".`);this.algorithm={name:"SHA-1"}}this._content=""}update(e){this._content+=e}async digest(){const e=(new TextEncoder).encode(this._content),t=new Uint8Array(await n.subtle.digest(this.algorithm,e));let r="";for(let e=0;e{"use strict";const t="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",r="http://www.w3.org/2001/XMLSchema#string",n="NamedNode",i="BlankNode",o="Literal",a="DefaultGraph",s={};function u(e,t){return e.subject.termType===t.subject.termType&&e.object.termType===t.object.termType&&(e.subject.value===t.subject.value&&e.predicate.value===t.predicate.value&&e.object.value===t.object.value&&(e.object.termType!==o||e.object.datatype.termType===t.object.datatype.termType&&e.object.language===t.object.language&&e.object.datatype.value===t.object.datatype.value))}s.eoln=/(?:\r\n)|(?:\n)|(?:\r)/g,s.empty=new RegExp("^[ \\t]*$"),s.quad=new RegExp('^[ \\t]*(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9])(?:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀.])*(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀]))?))[ \\t]+(?:<([^:]+:[^>]*)>)[ \\t]+(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9])(?:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀.])*(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀]))?)|(?:"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"(?:(?:\\^\\^(?:<([^:]+:[^>]*)>))|(?:@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)))?))[ \\t]*(?:\\.|(?:(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9])(?:(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀.])*(?:[A-Za-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�_0-9-·̀-ͯ‿-⁀]))?))[ \\t]*\\.))[ \\t]*$'),e.exports=class e{static parse(e){const c=[],f={},h=e.split(s.eoln);let d=0;for(const e of h){if(d++,s.empty.test(e))continue;const h=e.match(s.quad);if(null===h)throw new Error("N-Quads parse error on line "+d+".");const p={subject:null,predicate:null,object:null,graph:null};if(void 0!==h[1]?p.subject={termType:n,value:h[1]}:p.subject={termType:i,value:h[2]},p.predicate={termType:n,value:h[3]},void 0!==h[4]?p.object={termType:n,value:h[4]}:void 0!==h[5]?p.object={termType:i,value:h[5]}:(p.object={termType:o,value:void 0,datatype:{termType:n}},void 0!==h[7]?p.object.datatype.value=h[7]:void 0!==h[8]?(p.object.datatype.value=t,p.object.language=h[8]):p.object.datatype.value=r,p.object.value=h[6].replace(l,(function(e,t,r,n){if(t)switch(t){case"t":return"\t";case"b":return"\b";case"n":return"\n";case"r":return"\r";case"f":return"\f";case'"':return'"';case"'":return"'";case"\\":return"\\"}if(r)return String.fromCharCode(parseInt(r,16));if(n)throw new Error("Unsupported U escape")}))),void 0!==h[9]?p.graph={termType:n,value:h[9]}:void 0!==h[10]?p.graph={termType:i,value:h[10]}:p.graph={termType:a,value:""},p.graph.value in f){let e=!0;const t=f[p.graph.value];for(const r of t)if(u(r,p)){e=!1;break}e&&(t.push(p),c.push(p))}else f[p.graph.value]=[p],c.push(p)}return c}static serialize(t){Array.isArray(t)||(t=e.legacyDatasetToQuads(t));const r=[];for(const n of t)r.push(e.serializeQuad(n));return r.sort().join("")}static serializeQuadComponents(e,o,a,s){let u="";return e.termType===n?u+=`<${e.value}>`:u+=`${e.value}`,u+=` <${o.value}> `,a.termType===n?u+=`<${a.value}>`:a.termType===i?u+=a.value:(u+=`"${function(e){return e.replace(c,(function(e){switch(e){case'"':return'\\"';case"\\":return"\\\\";case"\n":return"\\n";case"\r":return"\\r"}}))}(a.value)}"`,a.datatype.value===t?a.language&&(u+=`@${a.language}`):a.datatype.value!==r&&(u+=`^^<${a.datatype.value}>`)),s.termType===n?u+=` <${s.value}>`:s.termType===i&&(u+=` ${s.value}`),u+=" .\n",u}static serializeQuad(t){return e.serializeQuadComponents(t.subject,t.predicate,t.object,t.graph)}static legacyDatasetToQuads(e){const s=[],u={"blank node":i,IRI:n,literal:o};for(const c in e){e[c].forEach((e=>{const l={};for(const i in e){const a=e[i],s={termType:u[a.type],value:a.value};s.termType===o&&(s.datatype={termType:n},"datatype"in a&&(s.datatype.value=a.datatype),"language"in a?("datatype"in a||(s.datatype.value=t),s.language=a.language):"datatype"in a||(s.datatype.value=r)),l[i]=s}l.graph="@default"===c?{termType:a,value:""}:{termType:c.startsWith("_:")?i:n,value:c},s.push(l)}))}return s}};const c=/["\\\n\r]/g;const l=/(?:\\([tbnrf"'\\]))|(?:\\u([0-9A-Fa-f]{4}))|(?:\\U([0-9A-Fa-f]{8}))/g},68326:e=>{"use strict";e.exports=class{constructor(e){this.current=e.sort(),this.done=!1,this.dir=new Map;for(let t=0;tn)&&(s&&r>0&&a>e[r-1]||!s&&re[r+1])&&(n=a,i=r)}if(null===n)this.done=!0;else{const r=t.get(n)?i-1:i+1;e[i]=e[r],e[r]=n;for(const r of e)r>n&&t.set(r,!t.get(r))}return r}}},23445:(e,t,r)=>{"use strict";const n=r(12401),i=r(75947),o=r(68326),a=r(69980);function s(e,t){return e.hasht.hash?1:0}e.exports=class{constructor({maxDeepIterations:e=1/0}={}){this.name="URDNA2015",this.blankNodeInfo=new Map,this.canonicalIssuer=new n("_:c14n"),this.hashAlgorithm="sha256",this.maxDeepIterations=e,this.quads=null,this.deepIterations=null}async main(e){this.deepIterations=new Map,this.quads=e;for(const t of e)this._addBlankNodeQuadInfo({quad:t,component:t.subject}),this._addBlankNodeQuadInfo({quad:t,component:t.object}),this._addBlankNodeQuadInfo({quad:t,component:t.graph});const t=new Map,r=[...this.blankNodeInfo.keys()];let i=0;for(const e of r)++i%100==0&&await this._yield(),await this._hashAndTrackBlankNode({id:e,hashToBlankNodes:t});const o=[...t.keys()].sort(),u=[];for(const e of o){const r=t.get(e);if(r.length>1){u.push(r);continue}const n=r[0];this.canonicalIssuer.getId(n)}for(const e of u){const t=[];for(const r of e){if(this.canonicalIssuer.hasId(r))continue;const e=new n("_:b");e.getId(r);const i=await this.hashNDegreeQuads(r,e);t.push(i)}t.sort(s);for(const e of t){const t=e.issuer.getOldIds();for(const e of t)this.canonicalIssuer.getId(e)}}const c=[];for(const e of this.quads){const t=a.serializeQuadComponents(this._componentWithCanonicalId(e.subject),e.predicate,this._componentWithCanonicalId(e.object),this._componentWithCanonicalId(e.graph));c.push(t)}return c.sort(),c.join("")}async hashFirstDegreeQuads(e){const t=[],r=this.blankNodeInfo.get(e),n=r.quads;for(const r of n){const n={subject:null,predicate:r.predicate,object:null,graph:null};n.subject=this.modifyFirstDegreeComponent(e,r.subject,"subject"),n.object=this.modifyFirstDegreeComponent(e,r.object,"object"),n.graph=this.modifyFirstDegreeComponent(e,r.graph,"graph"),t.push(a.serializeQuad(n))}t.sort();const o=new i(this.hashAlgorithm);for(const e of t)o.update(e);return r.hash=await o.digest(),r.hash}async hashRelatedBlankNode(e,t,r,n){let o;o=this.canonicalIssuer.hasId(e)?this.canonicalIssuer.getId(e):r.hasId(e)?r.getId(e):this.blankNodeInfo.get(e).hash;const a=new i(this.hashAlgorithm);return a.update(n),"g"!==n&&a.update(this.getRelatedPredicate(t)),a.update(o),a.digest()}async hashNDegreeQuads(e,t){const r=this.deepIterations.get(e)||0;if(r>this.maxDeepIterations)throw new Error(`Maximum deep iterations (${this.maxDeepIterations}) exceeded.`);this.deepIterations.set(e,r+1);const n=new i(this.hashAlgorithm),a=await this.createHashToRelated(e,t),s=[...a.keys()].sort();for(const e of s){n.update(e);let r,i="";const s=new o(a.get(e));let u=0;for(;s.hasNext();){const e=s.next();++u%3==0&&await this._yield();let n=t.clone(),o="";const a=[];let c=!1;for(const t of e)if(this.canonicalIssuer.hasId(t)?o+=this.canonicalIssuer.getId(t):(n.hasId(t)||a.push(t),o+=n.getId(t)),0!==i.length&&o>i){c=!0;break}if(!c){for(const e of a){const t=await this.hashNDegreeQuads(e,n);if(o+=n.getId(e),o+=`<${t.hash}>`,n=t.issuer,0!==i.length&&o>i){c=!0;break}}c||(0===i.length||o`}async createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;let i=0;for(const o of n)++i%100==0&&await this._yield(),await Promise.all([this._addRelatedBlankNodeHash({quad:o,component:o.subject,position:"s",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.object,position:"o",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:o,component:o.graph,position:"g",id:e,issuer:t,hashToRelated:r})]);return r}async _hashAndTrackBlankNode({id:e,hashToBlankNodes:t}){const r=await this.hashFirstDegreeQuads(e),n=t.get(r);n?n.push(e):t.set(r,[e])}_addBlankNodeQuadInfo({quad:e,component:t}){if("BlankNode"!==t.termType)return;const r=t.value,n=this.blankNodeInfo.get(r);n?n.quads.add(e):this.blankNodeInfo.set(r,{quads:new Set([e]),hash:null})}async _addRelatedBlankNodeHash({quad:e,component:t,position:r,id:n,issuer:i,hashToRelated:o}){if("BlankNode"!==t.termType||t.value===n)return;const a=t.value,s=await this.hashRelatedBlankNode(a,e,i,r),u=o.get(s);u?u.push(a):o.set(s,[a])}_componentWithCanonicalId(e){return"BlankNode"!==e.termType||e.value.startsWith(this.canonicalIssuer.prefix)?e:{termType:"BlankNode",value:this.canonicalIssuer.getId(e.value)}}async _yield(){return new Promise((e=>setImmediate(e)))}}},5643:(e,t,r)=>{"use strict";const n=r(12401),i=r(75947),o=r(68326),a=r(69980);function s(e,t){return e.hasht.hash?1:0}e.exports=class{constructor({maxDeepIterations:e=1/0}={}){this.name="URDNA2015",this.blankNodeInfo=new Map,this.canonicalIssuer=new n("_:c14n"),this.hashAlgorithm="sha256",this.maxDeepIterations=e,this.quads=null,this.deepIterations=null}main(e){this.deepIterations=new Map,this.quads=e;for(const t of e)this._addBlankNodeQuadInfo({quad:t,component:t.subject}),this._addBlankNodeQuadInfo({quad:t,component:t.object}),this._addBlankNodeQuadInfo({quad:t,component:t.graph});const t=new Map,r=[...this.blankNodeInfo.keys()];for(const e of r)this._hashAndTrackBlankNode({id:e,hashToBlankNodes:t});const i=[...t.keys()].sort(),o=[];for(const e of i){const r=t.get(e);if(r.length>1){o.push(r);continue}const n=r[0];this.canonicalIssuer.getId(n)}for(const e of o){const t=[];for(const r of e){if(this.canonicalIssuer.hasId(r))continue;const e=new n("_:b");e.getId(r);const i=this.hashNDegreeQuads(r,e);t.push(i)}t.sort(s);for(const e of t){const t=e.issuer.getOldIds();for(const e of t)this.canonicalIssuer.getId(e)}}const u=[];for(const e of this.quads){const t=a.serializeQuadComponents(this._componentWithCanonicalId({component:e.subject}),e.predicate,this._componentWithCanonicalId({component:e.object}),this._componentWithCanonicalId({component:e.graph}));u.push(t)}return u.sort(),u.join("")}hashFirstDegreeQuads(e){const t=[],r=this.blankNodeInfo.get(e),n=r.quads;for(const r of n){const n={subject:null,predicate:r.predicate,object:null,graph:null};n.subject=this.modifyFirstDegreeComponent(e,r.subject,"subject"),n.object=this.modifyFirstDegreeComponent(e,r.object,"object"),n.graph=this.modifyFirstDegreeComponent(e,r.graph,"graph"),t.push(a.serializeQuad(n))}t.sort();const o=new i(this.hashAlgorithm);for(const e of t)o.update(e);return r.hash=o.digest(),r.hash}hashRelatedBlankNode(e,t,r,n){let o;o=this.canonicalIssuer.hasId(e)?this.canonicalIssuer.getId(e):r.hasId(e)?r.getId(e):this.blankNodeInfo.get(e).hash;const a=new i(this.hashAlgorithm);return a.update(n),"g"!==n&&a.update(this.getRelatedPredicate(t)),a.update(o),a.digest()}hashNDegreeQuads(e,t){const r=this.deepIterations.get(e)||0;if(r>this.maxDeepIterations)throw new Error(`Maximum deep iterations (${this.maxDeepIterations}) exceeded.`);this.deepIterations.set(e,r+1);const n=new i(this.hashAlgorithm),a=this.createHashToRelated(e,t),s=[...a.keys()].sort();for(const e of s){n.update(e);let r,i="";const s=new o(a.get(e));for(;s.hasNext();){const e=s.next();let n=t.clone(),o="";const a=[];let u=!1;for(const t of e)if(this.canonicalIssuer.hasId(t)?o+=this.canonicalIssuer.getId(t):(n.hasId(t)||a.push(t),o+=n.getId(t)),0!==i.length&&o>i){u=!0;break}if(!u){for(const e of a){const t=this.hashNDegreeQuads(e,n);if(o+=n.getId(e),o+=`<${t.hash}>`,n=t.issuer,0!==i.length&&o>i){u=!0;break}}u||(0===i.length||o`}createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;for(const i of n)this._addRelatedBlankNodeHash({quad:i,component:i.subject,position:"s",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:i,component:i.object,position:"o",id:e,issuer:t,hashToRelated:r}),this._addRelatedBlankNodeHash({quad:i,component:i.graph,position:"g",id:e,issuer:t,hashToRelated:r});return r}_hashAndTrackBlankNode({id:e,hashToBlankNodes:t}){const r=this.hashFirstDegreeQuads(e),n=t.get(r);n?n.push(e):t.set(r,[e])}_addBlankNodeQuadInfo({quad:e,component:t}){if("BlankNode"!==t.termType)return;const r=t.value,n=this.blankNodeInfo.get(r);n?n.quads.add(e):this.blankNodeInfo.set(r,{quads:new Set([e]),hash:null})}_addRelatedBlankNodeHash({quad:e,component:t,position:r,id:n,issuer:i,hashToRelated:o}){if("BlankNode"!==t.termType||t.value===n)return;const a=t.value,s=this.hashRelatedBlankNode(a,e,i,r),u=o.get(s);u?u.push(a):o.set(s,[a])}_componentWithCanonicalId({component:e}){return"BlankNode"!==e.termType||e.value.startsWith(this.canonicalIssuer.prefix)?e:{termType:"BlankNode",value:this.canonicalIssuer.getId(e.value)}}}},89201:(e,t,r)=>{"use strict";const n=r(23445);e.exports=class extends n{constructor(){super(),this.name="URGNA2012",this.hashAlgorithm="sha1"}modifyFirstDegreeComponent(e,t,r){return"BlankNode"!==t.termType?t:"graph"===r?{termType:"BlankNode",value:"_:g"}:{termType:"BlankNode",value:t.value===e?"_:a":"_:z"}}getRelatedPredicate(e){return e.predicate.value}async createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;let i=0;for(const o of n){let n,a;if("BlankNode"===o.subject.termType&&o.subject.value!==e)a=o.subject.value,n="p";else{if("BlankNode"!==o.object.termType||o.object.value===e)continue;a=o.object.value,n="r"}++i%100==0&&await this._yield();const s=await this.hashRelatedBlankNode(a,o,t,n),u=r.get(s);u?u.push(a):r.set(s,[a])}return r}}},17702:(e,t,r)=>{"use strict";const n=r(5643);e.exports=class extends n{constructor(){super(),this.name="URGNA2012",this.hashAlgorithm="sha1"}modifyFirstDegreeComponent(e,t,r){return"BlankNode"!==t.termType?t:"graph"===r?{termType:"BlankNode",value:"_:g"}:{termType:"BlankNode",value:t.value===e?"_:a":"_:z"}}getRelatedPredicate(e){return e.predicate.value}createHashToRelated(e,t){const r=new Map,n=this.blankNodeInfo.get(e).quads;for(const i of n){let n,o;if("BlankNode"===i.subject.termType&&i.subject.value!==e)o=i.subject.value,n="p";else{if("BlankNode"!==i.object.termType||i.object.value===e)continue;o=i.object.value,n="r"}const a=this.hashRelatedBlankNode(o,i,t,n),s=r.get(a);s?s.push(o):r.set(a,[o])}return r}}},29344:(e,t,r)=>{"use strict";const n=r(23445),i=r(89201),o=r(5643),a=r(17702);let s;try{s=r(97670)}catch(e){}const u={};e.exports=u,u.NQuads=r(69980),u.IdentifierIssuer=r(12401),u._rdfCanonizeNative=function(e){return e&&(s=e),s},u.canonize=async function(e,t){if(Array.isArray(e)||(e=u.NQuads.legacyDatasetToQuads(e)),t.useNative){if(!s)throw new Error("rdf-canonize-native not available");return new Promise(((r,n)=>s.canonize(e,t,((e,t)=>e?n(e):r(t)))))}if("URDNA2015"===t.algorithm)return new n(t).main(e);if("URGNA2012"===t.algorithm)return new i(t).main(e);if(!("algorithm"in t))throw new Error("No RDF Dataset Canonicalization algorithm specified.");throw new Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)},u._canonizeSync=function(e,t){if(Array.isArray(e)||(e=u.NQuads.legacyDatasetToQuads(e)),t.useNative){if(s)return s.canonizeSync(e,t);throw new Error("rdf-canonize-native not available")}if("URDNA2015"===t.algorithm)return new o(t).main(e);if("URGNA2012"===t.algorithm)return new a(t).main(e);if(!("algorithm"in t))throw new Error("No RDF Dataset Canonicalization algorithm specified.");throw new Error("Invalid RDF Dataset Canonicalization algorithm: "+t.algorithm)}},94281:e=>{"use strict";var t={};function r(e,r,n){n||(n=Error);var i=function(e){var t,n;function i(t,n,i){return e.call(this,function(e,t,n){return"string"==typeof r?r:r(e,t,n)}(t,n,i))||this}return n=e,(t=i).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n,i}(n);i.prototype.name=n.name,i.prototype.code=e,t[e]=i}function n(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map((function(e){return String(e)})),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}r("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),r("ERR_INVALID_ARG_TYPE",(function(e,t,r){var i,o,a,s;if("string"==typeof t&&(o="not ",t.substr(!a||a<0?0:+a,o.length)===o)?(i="must not be",t=t.replace(/^not /,"")):i="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))s="The ".concat(e," ").concat(i," ").concat(n(t,"type"));else{var u=function(e,t,r){return"number"!=typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}(e,".")?"property":"argument";s='The "'.concat(e,'" ').concat(u," ").concat(i," ").concat(n(t,"type"))}return s+=". Received type ".concat(typeof r)}),TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.q=t},56753:(e,t,r)=>{"use strict";var n=r(34155),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=l;var o=r(79481),a=r(64229);r(35717)(l,o);for(var s=i(a.prototype),u=0;u{"use strict";e.exports=i;var n=r(74605);function i(e){if(!(this instanceof i))return new i(e);n.call(this,e)}r(35717)(i,n),i.prototype._transform=function(e,t,r){r(null,e)}},79481:(e,t,r)=>{"use strict";var n,i=r(34155);e.exports=_,_.ReadableState=E;r(17187).EventEmitter;var o=function(e,t){return e.listeners(t).length},a=r(22503),s=r(48764).Buffer,u=r.g.Uint8Array||function(){};var c,l=r(94616);c=l&&l.debuglog?l.debuglog("stream"):function(){};var f,h,d,p=r(57327),m=r(61195),y=r(82457).getHighWaterMark,g=r(94281).q,b=g.ERR_INVALID_ARG_TYPE,v=g.ERR_STREAM_PUSH_AFTER_EOF,w=g.ERR_METHOD_NOT_IMPLEMENTED,A=g.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(35717)(_,a);var S=m.errorOrDestroy,k=["error","close","destroy","pause","resume"];function E(e,t,i){n=n||r(56753),e=e||{},"boolean"!=typeof i&&(i=t instanceof n),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",i),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(f||(f=r(32553).s),this.decoder=new f(e.encoding),this.encoding=e.encoding)}function _(e){if(n=n||r(56753),!(this instanceof _))return new _(e);var t=this instanceof n;this._readableState=new E(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),a.call(this)}function M(e,t,r,n,i){c("readableAddChunk",t);var o,a=e._readableState;if(null===t)a.reading=!1,function(e,t){if(c("onEofChunk"),t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?I(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,O(e)))}(e,a);else if(i||(o=function(e,t){var r;n=t,s.isBuffer(n)||n instanceof u||"string"==typeof t||void 0===t||e.objectMode||(r=new b("chunk",["string","Buffer","Uint8Array"],t));var n;return r}(a,t)),o)S(e,o);else if(a.objectMode||t&&t.length>0)if("string"==typeof t||a.objectMode||Object.getPrototypeOf(t)===s.prototype||(t=function(e){return s.from(e)}(t)),n)a.endEmitted?S(e,new A):T(e,a,t,!0);else if(a.ended)S(e,new v);else{if(a.destroyed)return!1;a.reading=!1,a.decoder&&!r?(t=a.decoder.write(t),a.objectMode||0!==t.length?T(e,a,t,!1):R(e,a)):T(e,a,t,!1)}else n||(a.reading=!1,R(e,a));return!a.ended&&(a.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=x?e=x:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function I(e){var t=e._readableState;c("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(c("emitReadable",t.flowing),t.emittedReadable=!0,i.nextTick(O,e))}function O(e){var t=e._readableState;c("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,U(e)}function R(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(C,e,t))}function C(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function N(e){c("readable nexttick read 0"),e.read(0)}function L(e,t){c("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(c("flow",t.flowing);t.flowing&&null!==e.read(););}function F(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function D(e){var t=e._readableState;c("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,i.nextTick(j,t,e))}function j(e,t){if(c("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function H(e,t){for(var r=0,n=e.length;r=t.highWaterMark:t.length>0)||t.ended))return c("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?D(this):I(this),null;if(0===(e=P(e,t))&&t.ended)return 0===t.length&&D(this),null;var n,i=t.needReadable;return c("need readable",i),(0===t.length||t.length-e0?F(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&D(this)),null!==n&&this.emit("data",n),n},_.prototype._read=function(e){S(this,new w("_read()"))},_.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e)}n.pipesCount+=1,c("pipe count=%d opts=%j",n.pipesCount,t);var a=(!t||!1!==t.end)&&e!==i.stdout&&e!==i.stderr?u:y;function s(t,i){c("onunpipe"),t===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,c("cleanup"),e.removeListener("close",p),e.removeListener("finish",m),e.removeListener("drain",l),e.removeListener("error",d),e.removeListener("unpipe",s),r.removeListener("end",u),r.removeListener("end",y),r.removeListener("data",h),f=!0,!n.awaitDrain||e._writableState&&!e._writableState.needDrain||l())}function u(){c("onend"),e.end()}n.endEmitted?i.nextTick(a):r.once("end",a),e.on("unpipe",s);var l=function(e){return function(){var t=e._readableState;c("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&o(e,"data")&&(t.flowing=!0,U(e))}}(r);e.on("drain",l);var f=!1;function h(t){c("ondata");var i=e.write(t);c("dest.write",i),!1===i&&((1===n.pipesCount&&n.pipes===e||n.pipesCount>1&&-1!==H(n.pipes,e))&&!f&&(c("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function d(t){c("onerror",t),y(),e.removeListener("error",d),0===o(e,"error")&&S(e,t)}function p(){e.removeListener("finish",m),y()}function m(){c("onfinish"),e.removeListener("close",p),y()}function y(){c("unpipe"),r.unpipe(e)}return r.on("data",h),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",d),e.once("close",p),e.once("finish",m),e.emit("pipe",r),n.flowing||(c("pipe resume"),r.resume()),e},_.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0,!1!==n.flowing&&this.resume()):"readable"===e&&(n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,c("on readable",n.length,n.reading),n.length?I(this):n.reading||i.nextTick(N,this))),r},_.prototype.addListener=_.prototype.on,_.prototype.removeListener=function(e,t){var r=a.prototype.removeListener.call(this,e,t);return"readable"===e&&i.nextTick(B,this),r},_.prototype.removeAllListeners=function(e){var t=a.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||i.nextTick(B,this),t},_.prototype.resume=function(){var e=this._readableState;return e.flowing||(c("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}(this,e)),e.paused=!1,this},_.prototype.pause=function(){return c("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(c("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},_.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",(function(){if(c("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(i){(c("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))})),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o{"use strict";e.exports=l;var n=r(94281).q,i=n.ERR_METHOD_NOT_IMPLEMENTED,o=n.ERR_MULTIPLE_CALLBACK,a=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=n.ERR_TRANSFORM_WITH_LENGTH_0,u=r(56753);function c(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length{"use strict";var n,i=r(34155);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}e.exports=_,_.WritableState=E;var a={deprecate:r(94927)},s=r(22503),u=r(48764).Buffer,c=r.g.Uint8Array||function(){};var l,f=r(61195),h=r(82457).getHighWaterMark,d=r(94281).q,p=d.ERR_INVALID_ARG_TYPE,m=d.ERR_METHOD_NOT_IMPLEMENTED,y=d.ERR_MULTIPLE_CALLBACK,g=d.ERR_STREAM_CANNOT_PIPE,b=d.ERR_STREAM_DESTROYED,v=d.ERR_STREAM_NULL_VALUES,w=d.ERR_STREAM_WRITE_AFTER_END,A=d.ERR_UNKNOWN_ENCODING,S=f.errorOrDestroy;function k(){}function E(e,t,a){n=n||r(56753),e=e||{},"boolean"!=typeof a&&(a=t instanceof n),this.objectMode=!!e.objectMode,a&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=h(this,e,"writableHighWaterMark",a),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var s=!1===e.decodeStrings;this.decodeStrings=!s,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if("function"!=typeof o)throw new y;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,n,o){--t.pendingcb,r?(i.nextTick(o,n),i.nextTick(O,e,t),e._writableState.errorEmitted=!0,S(e,n)):(o(n),e._writableState.errorEmitted=!0,S(e,n),O(e,t))}(e,r,n,t,o);else{var a=P(r)||e.destroyed;a||r.corked||r.bufferProcessing||!r.bufferedRequest||x(e,r),n?i.nextTick(T,e,r,a,o):T(e,r,a,o)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function _(e){var t=this instanceof(n=n||r(56753));if(!t&&!l.call(_,this))return new _(e);this._writableState=new E(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),s.call(this)}function M(e,t,r,n,i,o,a){t.writelen=n,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new b("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function T(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),O(e,t)}function x(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),a=t.corkedRequestsFree;a.entry=r;for(var s=0,u=!0;r;)i[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;i.allBuffers=u,M(e,t,!0,t.length,i,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,l=r.encoding,f=r.callback;if(M(e,t,!1,t.objectMode?1:c.length,c,l,f),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function P(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function I(e,t){e._final((function(r){t.pendingcb--,r&&S(e,r),t.prefinished=!0,e.emit("prefinish"),O(e,t)}))}function O(e,t){var r=P(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,i.nextTick(I,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}r(35717)(_,s),E.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(E.prototype,"buffer",{get:a.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(l=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!l.call(this,e)||this===_&&(e&&e._writableState instanceof E)}})):l=function(e){return e instanceof this},_.prototype.pipe=function(){S(this,new g)},_.prototype.write=function(e,t,r){var n,o=this._writableState,a=!1,s=!o.objectMode&&(n=e,u.isBuffer(n)||n instanceof c);return s&&!u.isBuffer(e)&&(e=function(e){return u.from(e)}(e)),"function"==typeof t&&(r=t,t=null),s?t="buffer":t||(t=o.defaultEncoding),"function"!=typeof r&&(r=k),o.ending?function(e,t){var r=new w;S(e,r),i.nextTick(t,r)}(this,r):(s||function(e,t,r,n){var o;return null===r?o=new v:"string"==typeof r||t.objectMode||(o=new p("chunk",["string","Buffer"],r)),!o||(S(e,o),i.nextTick(n,o),!1)}(this,o,e,r))&&(o.pendingcb++,a=function(e,t,r,n,i,o){if(!r){var a=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=u.from(t,r));return t}(t,n,i);n!==a&&(r=!0,i="buffer",n=a)}var s=t.objectMode?1:n.length;t.length+=s;var c=t.length-1))throw new A(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(_.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,r){r(new m("_write()"))},_.prototype._writev=null,_.prototype.end=function(e,t,r){var n=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||function(e,t,r){t.ending=!0,O(e,t),r&&(t.finished?i.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,n,r),this},Object.defineProperty(_.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(_.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=f.destroy,_.prototype._undestroy=f.undestroy,_.prototype._destroy=function(e,t){t(e)}},45850:(e,t,r)=>{"use strict";var n,i=r(34155);function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var a=r(8610),s=Symbol("lastResolve"),u=Symbol("lastReject"),c=Symbol("error"),l=Symbol("ended"),f=Symbol("lastPromise"),h=Symbol("handlePromise"),d=Symbol("stream");function p(e,t){return{value:e,done:t}}function m(e){var t=e[s];if(null!==t){var r=e[d].read();null!==r&&(e[f]=null,e[s]=null,e[u]=null,t(p(r,!1)))}}function y(e){i.nextTick(m,e)}var g=Object.getPrototypeOf((function(){})),b=Object.setPrototypeOf((o(n={get stream(){return this[d]},next:function(){var e=this,t=this[c];if(null!==t)return Promise.reject(t);if(this[l])return Promise.resolve(p(void 0,!0));if(this[d].destroyed)return new Promise((function(t,r){i.nextTick((function(){e[c]?r(e[c]):t(p(void 0,!0))}))}));var r,n=this[f];if(n)r=new Promise(function(e,t){return function(r,n){e.then((function(){t[l]?r(p(void 0,!0)):t[h](r,n)}),n)}}(n,this));else{var o=this[d].read();if(null!==o)return Promise.resolve(p(o,!1));r=new Promise(this[h])}return this[f]=r,r}},Symbol.asyncIterator,(function(){return this})),o(n,"return",(function(){var e=this;return new Promise((function(t,r){e[d].destroy(null,(function(e){e?r(e):t(p(void 0,!0))}))}))})),n),g);e.exports=function(e){var t,r=Object.create(b,(o(t={},d,{value:e,writable:!0}),o(t,s,{value:null,writable:!0}),o(t,u,{value:null,writable:!0}),o(t,c,{value:null,writable:!0}),o(t,l,{value:e._readableState.endEmitted,writable:!0}),o(t,h,{value:function(e,t){var n=r[d].read();n?(r[f]=null,r[s]=null,r[u]=null,e(p(n,!1))):(r[s]=e,r[u]=t)},writable:!0}),t));return r[f]=null,a(e,(function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[u];return null!==t&&(r[f]=null,r[s]=null,r[u]=null,t(e)),void(r[c]=e)}var n=r[s];null!==n&&(r[f]=null,r[s]=null,r[u]=null,n(p(void 0,!0))),r[l]=!0})),e.on("readable",y.bind(null,r)),r}},57327:(e,t,r)=>{"use strict";function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function o(e,t){for(var r=0;r0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return a.alloc(0);for(var t,r,n,i=a.allocUnsafe(e>>>0),o=this.head,s=0;o;)t=o.data,r=i,n=s,a.prototype.copy.call(t,r,n),s+=o.data.length,o=o.next;return i}},{key:"consume",value:function(e,t){var r;return ei.length?i.length:e;if(o===i.length?n+=i:n+=i.slice(0,e),0==(e-=o)){o===i.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(e){var t=a.allocUnsafe(e),r=this.head,n=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var i=r.data,o=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,o),0==(e-=o)){o===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(o));break}++n}return this.length-=n,t}},{key:u,value:function(e,t){return s(this,function(e){for(var t=1;t{"use strict";var n=r(34155);function i(e,t){a(e,t),o(e)}function o(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function a(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,s=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return s||u?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,n.nextTick(a,this,e)):n.nextTick(a,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!t&&e?r._writableState?r._writableState.errorEmitted?n.nextTick(o,r):(r._writableState.errorEmitted=!0,n.nextTick(i,r,e)):n.nextTick(i,r,e):t?(n.nextTick(o,r),t(e)):n.nextTick(o,r)})),this)},undestroy:function(){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)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}},8610:(e,t,r)=>{"use strict";var n=r(94281).q.ERR_STREAM_PREMATURE_CLOSE;function i(){}e.exports=function e(t,r,o){if("function"==typeof r)return e(t,null,r);r||(r={}),o=function(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i{e.exports=function(){throw new Error("Readable.from is not available in the browser")}},59946:(e,t,r)=>{"use strict";var n;var i=r(94281).q,o=i.ERR_MISSING_ARGS,a=i.ERR_STREAM_DESTROYED;function s(e){if(e)throw e}function u(e,t,i,o){o=function(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}(o);var s=!1;e.on("close",(function(){s=!0})),void 0===n&&(n=r(8610)),n(e,{readable:t,writable:i},(function(e){if(e)return o(e);s=!0,o()}));var u=!1;return function(t){if(!s&&!u)return u=!0,function(e){return e.setHeader&&"function"==typeof e.abort}(e)?e.abort():"function"==typeof e.destroy?e.destroy():void o(t||new a("pipe"))}}function c(e){e()}function l(e,t){return e.pipe(t)}function f(e){return e.length?"function"!=typeof e[e.length-1]?s:e.pop():s}e.exports=function(){for(var e=arguments.length,t=new Array(e),r=0;r0,(function(e){n||(n=e),e&&a.forEach(c),o||(a.forEach(c),i(n))}))}));return t.reduce(l)}},82457:(e,t,r)=>{"use strict";var n=r(94281).q.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,i){var o=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,i,r);if(null!=o){if(!isFinite(o)||Math.floor(o)!==o||o<0)throw new n(i?r:"highWaterMark",o);return Math.floor(o)}return e.objectMode?16:16384}}},22503:(e,t,r)=>{e.exports=r(17187).EventEmitter},88473:(e,t,r)=>{(t=e.exports=r(79481)).Stream=t,t.Readable=t,t.Writable=r(64229),t.Duplex=r(56753),t.Transform=r(74605),t.PassThrough=r(82725),t.finished=r(8610),t.pipeline=r(59946)},79785:(e,t,r)=>{"use strict";var n=r(48764).Buffer,i=r(35717),o=r(3349),a=new Array(16),s=[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],u=[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],c=[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],l=[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],f=[0,1518500249,1859775393,2400959708,2840853838],h=[1352829926,1548603684,1836072691,2053994217,0];function d(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(e,t){return e<>>32-t}function m(e,t,r,n,i,o,a,s){return p(e+(t^r^n)+o+a|0,s)+i|0}function y(e,t,r,n,i,o,a,s){return p(e+(t&r|~t&n)+o+a|0,s)+i|0}function g(e,t,r,n,i,o,a,s){return p(e+((t|~r)^n)+o+a|0,s)+i|0}function b(e,t,r,n,i,o,a,s){return p(e+(t&n|r&~n)+o+a|0,s)+i|0}function v(e,t,r,n,i,o,a,s){return p(e+(t^(r|~n))+o+a|0,s)+i|0}i(d,o),d.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,A=0|this._b,S=0|this._c,k=0|this._d,E=0|this._e,_=0;_<80;_+=1){var M,T;_<16?(M=m(r,n,i,o,d,e[s[_]],f[0],c[_]),T=v(w,A,S,k,E,e[u[_]],h[0],l[_])):_<32?(M=y(r,n,i,o,d,e[s[_]],f[1],c[_]),T=b(w,A,S,k,E,e[u[_]],h[1],l[_])):_<48?(M=g(r,n,i,o,d,e[s[_]],f[2],c[_]),T=g(w,A,S,k,E,e[u[_]],h[2],l[_])):_<64?(M=b(r,n,i,o,d,e[s[_]],f[3],c[_]),T=y(w,A,S,k,E,e[u[_]],h[3],l[_])):(M=v(r,n,i,o,d,e[s[_]],f[4],c[_]),T=m(w,A,S,k,E,e[u[_]],h[4],l[_])),r=d,d=o,o=p(i,10),i=n,n=M,w=E,E=k,k=p(S,10),S=A,A=T}var x=this._b+i+k|0;this._b=this._c+o+E|0,this._c=this._d+d+w|0,this._d=this._e+r+A|0,this._e=this._a+n+S|0,this._a=x},d.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 e=n.alloc?n.alloc(20):new n(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=d},89509:(e,t,r)=>{var n=r(48764),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=a),a.prototype=Object.create(i.prototype),o(i,a),a.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},2399:(e,t,r)=>{"use strict";var n,i=r(34155),o=r(48764),a=o.Buffer,s={};for(n in o)o.hasOwnProperty(n)&&"SlowBuffer"!==n&&"Buffer"!==n&&(s[n]=o[n]);var u=s.Buffer={};for(n in a)a.hasOwnProperty(n)&&"allocUnsafe"!==n&&"allocUnsafeSlow"!==n&&(u[n]=a[n]);if(s.Buffer.prototype=a.prototype,u.from&&u.from!==Uint8Array.from||(u.from=function(e,t,r){if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type '+typeof e);if(e&&void 0===e.length)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);return a(e,t,r)}),u.alloc||(u.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError('The "size" argument must be of type number. Received type '+typeof e);if(e<0||e>=2*(1<<30))throw new RangeError('The value "'+e+'" is invalid for option "size"');var n=a(e);return t&&0!==t.length?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n}),!s.kStringMaxLength)try{s.kStringMaxLength=i.binding("buffer").kStringMaxLength}catch(e){}s.constants||(s.constants={MAX_LENGTH:s.kMaxLength},s.kStringMaxLength&&(s.constants.MAX_STRING_LENGTH=s.kStringMaxLength)),e.exports=s},17635:function(e){"use strict";!function(t){const r=2147483647;function n(e){const t=new Uint32Array([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]);let r=1779033703,n=3144134277,i=1013904242,o=2773480762,a=1359893119,s=2600822924,u=528734635,c=1541459225;const l=new Uint32Array(64);function f(e){let f=0,h=e.length;for(;h>=64;){let d,p,m,y,g,b=r,v=n,w=i,A=o,S=a,k=s,E=u,_=c;for(p=0;p<16;p++)m=f+4*p,l[p]=(255&e[m])<<24|(255&e[m+1])<<16|(255&e[m+2])<<8|255&e[m+3];for(p=16;p<64;p++)d=l[p-2],y=(d>>>17|d<<15)^(d>>>19|d<<13)^d>>>10,d=l[p-15],g=(d>>>7|d<<25)^(d>>>18|d<<14)^d>>>3,l[p]=(y+l[p-7]|0)+(g+l[p-16]|0)|0;for(p=0;p<64;p++)y=(((S>>>6|S<<26)^(S>>>11|S<<21)^(S>>>25|S<<7))+(S&k^~S&E)|0)+(_+(t[p]+l[p]|0)|0)|0,g=((b>>>2|b<<30)^(b>>>13|b<<19)^(b>>>22|b<<10))+(b&v^b&w^v&w)|0,_=E,E=k,k=S,S=A+y|0,A=w,w=v,v=b,b=y+g|0;r=r+b|0,n=n+v|0,i=i+w|0,o=o+A|0,a=a+S|0,s=s+k|0,u=u+E|0,c=c+_|0,f+=64,h-=64}}f(e);let h,d=e.length%64,p=e.length/536870912|0,m=e.length<<3,y=d<56?56:120,g=e.slice(e.length-d,e.length);for(g.push(128),h=d+1;h>>24&255),g.push(p>>>16&255),g.push(p>>>8&255),g.push(p>>>0&255),g.push(m>>>24&255),g.push(m>>>16&255),g.push(m>>>8&255),g.push(m>>>0&255),f(g),[r>>>24&255,r>>>16&255,r>>>8&255,r>>>0&255,n>>>24&255,n>>>16&255,n>>>8&255,n>>>0&255,i>>>24&255,i>>>16&255,i>>>8&255,i>>>0&255,o>>>24&255,o>>>16&255,o>>>8&255,o>>>0&255,a>>>24&255,a>>>16&255,a>>>8&255,a>>>0&255,s>>>24&255,s>>>16&255,s>>>8&255,s>>>0&255,u>>>24&255,u>>>16&255,u>>>8&255,u>>>0&255,c>>>24&255,c>>>16&255,c>>>8&255,c>>>0&255]}function i(e,t,r){e=e.length<=64?e:n(e);const i=64+t.length+4,o=new Array(i),a=new Array(64);let s,u=[];for(s=0;s<64;s++)o[s]=54;for(s=0;s=i-4;e--){if(o[e]++,o[e]<=255)return;o[e]=0}}for(;r>=32;)c(),u=u.concat(n(a.concat(n(o)))),r-=32;return r>0&&(c(),u=u.concat(n(a.concat(n(o))).slice(0,r))),u}function o(e,t,r,n,i){let o;for(c(e,16*(2*r-1),i,0,16),o=0;o<2*r;o++)u(e,16*o,i,16),s(i,n),c(i,0,e,t+16*o,16);for(o=0;o>>32-t}function s(e,t){c(e,0,t,0,16);for(let e=8;e>0;e-=2)t[4]^=a(t[0]+t[12],7),t[8]^=a(t[4]+t[0],9),t[12]^=a(t[8]+t[4],13),t[0]^=a(t[12]+t[8],18),t[9]^=a(t[5]+t[1],7),t[13]^=a(t[9]+t[5],9),t[1]^=a(t[13]+t[9],13),t[5]^=a(t[1]+t[13],18),t[14]^=a(t[10]+t[6],7),t[2]^=a(t[14]+t[10],9),t[6]^=a(t[2]+t[14],13),t[10]^=a(t[6]+t[2],18),t[3]^=a(t[15]+t[11],7),t[7]^=a(t[3]+t[15],9),t[11]^=a(t[7]+t[3],13),t[15]^=a(t[11]+t[7],18),t[1]^=a(t[0]+t[3],7),t[2]^=a(t[1]+t[0],9),t[3]^=a(t[2]+t[1],13),t[0]^=a(t[3]+t[2],18),t[6]^=a(t[5]+t[4],7),t[7]^=a(t[6]+t[5],9),t[4]^=a(t[7]+t[6],13),t[5]^=a(t[4]+t[7],18),t[11]^=a(t[10]+t[9],7),t[8]^=a(t[11]+t[10],9),t[9]^=a(t[8]+t[11],13),t[10]^=a(t[9]+t[8],18),t[12]^=a(t[15]+t[14],7),t[13]^=a(t[12]+t[15],9),t[14]^=a(t[13]+t[12],13),t[15]^=a(t[14]+t[13],18);for(let r=0;r<16;++r)e[r]+=t[r]}function u(e,t,r,n){for(let i=0;i=256)return!1}return!0}function f(e,t){if("number"!=typeof e||e%1)throw new Error("invalid "+t);return e}function h(e,t,n,a,s,h,d){if(n=f(n,"N"),a=f(a,"r"),s=f(s,"p"),h=f(h,"dkLen"),0===n||0!=(n&n-1))throw new Error("N must be power of 2");if(n>r/128/a)throw new Error("N too large");if(a>r/128/s)throw new Error("r too large");if(!l(e))throw new Error("password must be an array or buffer");if(e=Array.prototype.slice.call(e),!l(t))throw new Error("salt must be an array or buffer");t=Array.prototype.slice.call(t);let p=i(e,t,128*s*a);const m=new Uint32Array(32*s*a);for(let e=0;eP&&(t=P);for(let e=0;eP&&(t=P);for(let e=0;e>0&255),p.push(m[e]>>8&255),p.push(m[e]>>16&255),p.push(m[e]>>24&255);const r=i(e,p,h);return d&&d(null,1,r),r}d&&I(O)};if(!d)for(;;){const e=O();if(null!=e)return e}O()}const d={scrypt:function(e,t,r,n,i,o,a){return new Promise((function(s,u){let c=0;a&&a(0),h(e,t,r,n,i,o,(function(e,t,r){if(e)u(e);else if(r)a&&1!==c&&a(1),s(new Uint8Array(r));else if(a&&t!==c)return c=t,a(t)}))}))},syncScrypt:function(e,t,r,n,i,o){return new Uint8Array(h(e,t,r,n,i,o))}};e.exports=d}()},24889:function(e,t,r){var n=r(34155);!function(e,t){"use strict";if(!e.setImmediate){var r,i,o,a,s,u=1,c={},l=!1,f=e.document,h=Object.getPrototypeOf&&Object.getPrototypeOf(e);h=h&&h.setTimeout?h:e,"[object process]"==={}.toString.call(e.process)?r=function(e){n.nextTick((function(){p(e)}))}:!function(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}()?e.MessageChannel?((o=new MessageChannel).port1.onmessage=function(e){p(e.data)},r=function(e){o.port2.postMessage(e)}):f&&"onreadystatechange"in f.createElement("script")?(i=f.documentElement,r=function(e){var t=f.createElement("script");t.onreadystatechange=function(){p(e),t.onreadystatechange=null,i.removeChild(t),t=null},i.appendChild(t)}):r=function(e){setTimeout(p,0,e)}:(a="setImmediate$"+Math.random()+"$",s=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(a)&&p(+t.data.slice(a.length))},e.addEventListener?e.addEventListener("message",s,!1):e.attachEvent("onmessage",s),r=function(t){e.postMessage(a+t,"*")}),h.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),n=0;n{var n=r(89509).Buffer;function i(e,t){this._block=n.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}i.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=n.from(e,t));for(var r=this._block,i=this._blockSize,o=e.length,a=this._len,s=0;s=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},89072:(e,t,r)=>{var n=e.exports=function(e){e=e.toLowerCase();var t=n[e];if(!t)throw new Error(e+" is not supported (we accept pull requests)");return new t};n.sha=r(74448),n.sha1=r(18336),n.sha224=r(48432),n.sha256=r(67499),n.sha384=r(51686),n.sha512=r(87816)},74448:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<30|e>>>2}function l(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,f=0;f<16;++f)r[f]=e.readInt32BE(4*f);for(;f<80;++f)r[f]=r[f-3]^r[f-8]^r[f-14]^r[f-16];for(var h=0;h<80;++h){var d=~~(h/20),p=0|((t=n)<<5|t>>>27)+l(d,i,o,s)+u+r[h]+a[d];u=s,s=o,o=c(i),i=n,n=p}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},18336:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<5|e>>>27}function l(e){return e<<30|e>>>2}function f(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,h=0;h<16;++h)r[h]=e.readInt32BE(4*h);for(;h<80;++h)r[h]=(t=r[h-3]^r[h-8]^r[h-14]^r[h-16])<<1|t>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=c(n)+f(p,i,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=l(i),i=n,n=m}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},48432:(e,t,r)=>{var n=r(35717),i=r(67499),o=r(24189),a=r(89509).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}n(u,i),u.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=u},67499:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[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],s=new Array(64);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function h(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function d(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}n(u,i),u.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,y=0|this._h,g=0;g<16;++g)r[g]=e.readInt32BE(4*g);for(;g<64;++g)r[g]=0|(((t=r[g-2])>>>17|t<<15)^(t>>>19|t<<13)^t>>>10)+r[g-7]+d(r[g-15])+r[g-16];for(var b=0;b<64;++b){var v=y+h(u)+c(u,p,m)+a[b]+r[b]|0,w=f(n)+l(n,i,o)|0;y=m,m=p,p=u,u=s+v|0,s=o,o=i,i=n,n=v+w|0}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=y+this._h|0},u.prototype._hash=function(){var e=o.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=u},51686:(e,t,r)=>{var n=r(35717),i=r(87816),o=r(24189),a=r(89509).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}n(u,i),u.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(48);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e},e.exports=u},87816:(e,t,r)=>{var n=r(35717),i=r(24189),o=r(89509).Buffer,a=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],s=new Array(160);function u(){this.init(),this._w=s,i.call(this,128,112)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function h(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function d(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function p(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function y(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function g(e,t){return e>>>0>>0?1:0}n(u,i),u.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},u.prototype._update=function(e){for(var t=this._w,r=0|this._ah,n=0|this._bh,i=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,b=0|this._gh,v=0|this._hh,w=0|this._al,A=0|this._bl,S=0|this._cl,k=0|this._dl,E=0|this._el,_=0|this._fl,M=0|this._gl,T=0|this._hl,x=0;x<32;x+=2)t[x]=e.readInt32BE(4*x),t[x+1]=e.readInt32BE(4*x+4);for(;x<160;x+=2){var P=t[x-30],I=t[x-30+1],O=d(P,I),R=p(I,P),C=m(P=t[x-4],I=t[x-4+1]),B=y(I,P),N=t[x-14],L=t[x-14+1],U=t[x-32],F=t[x-32+1],D=R+L|0,j=O+N+g(D,R)|0;j=(j=j+C+g(D=D+B|0,B)|0)+U+g(D=D+F|0,F)|0,t[x]=j,t[x+1]=D}for(var H=0;H<160;H+=2){j=t[H],D=t[H+1];var J=l(r,n,i),z=l(w,A,S),G=f(r,w),q=f(w,r),K=h(s,E),V=h(E,s),X=a[H],Q=a[H+1],W=c(s,u,b),Z=c(E,_,M),Y=T+V|0,$=v+K+g(Y,T)|0;$=($=($=$+W+g(Y=Y+Z|0,Z)|0)+X+g(Y=Y+Q|0,Q)|0)+j+g(Y=Y+D|0,D)|0;var ee=q+z|0,te=G+J+g(ee,q)|0;v=b,T=M,b=u,M=_,u=s,_=E,s=o+$+g(E=k+Y|0,k)|0,o=i,k=S,i=n,S=A,n=r,A=w,r=$+te+g(w=Y+ee|0,Y)|0}this._al=this._al+w|0,this._bl=this._bl+A|0,this._cl=this._cl+S|0,this._dl=this._dl+k|0,this._el=this._el+E|0,this._fl=this._fl+_|0,this._gl=this._gl+M|0,this._hl=this._hl+T|0,this._ah=this._ah+r+g(this._al,w)|0,this._bh=this._bh+n+g(this._bl,A)|0,this._ch=this._ch+i+g(this._cl,S)|0,this._dh=this._dh+o+g(this._dl,k)|0,this._eh=this._eh+s+g(this._el,E)|0,this._fh=this._fh+u+g(this._fl,_)|0,this._gh=this._gh+b+g(this._gl,M)|0,this._hh=this._hh+v+g(this._hl,T)|0},u.prototype._hash=function(){var e=o.allocUnsafe(64);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=u},37478:(e,t,r)=>{"use strict";var n=r(40210),i=r(21924),o=r(70631),a=n("%TypeError%"),s=n("%WeakMap%",!0),u=n("%Map%",!0),c=i("WeakMap.prototype.get",!0),l=i("WeakMap.prototype.set",!0),f=i("WeakMap.prototype.has",!0),h=i("Map.prototype.get",!0),d=i("Map.prototype.set",!0),p=i("Map.prototype.has",!0),m=function(e,t){for(var r,n=e;null!==(r=n.next);n=r)if(r.key===t)return n.next=r.next,r.next=e.next,e.next=r,r};e.exports=function(){var e,t,r,n={assert:function(e){if(!n.has(e))throw new a("Side channel does not contain "+o(e))},get:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(e)return c(e,n)}else if(u){if(t)return h(t,n)}else if(r)return function(e,t){var r=m(e,t);return r&&r.value}(r,n)},has:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(e)return f(e,n)}else if(u){if(t)return p(t,n)}else if(r)return function(e,t){return!!m(e,t)}(r,n);return!1},set:function(n,i){s&&n&&("object"==typeof n||"function"==typeof n)?(e||(e=new s),l(e,n,i)):u?(t||(t=new u),d(t,n,i)):(r||(r={key:{},next:null}),function(e,t,r){var n=m(e,t);n?n.value=r:e.next={key:t,next:e.next,value:r}}(r,n,i))}};return n}},42830:(e,t,r)=>{e.exports=i;var n=r(17187).EventEmitter;function i(){n.call(this)}r(35717)(i,n),i.Readable=r(79481),i.Writable=r(64229),i.Duplex=r(56753),i.Transform=r(74605),i.PassThrough=r(82725),i.finished=r(8610),i.pipeline=r(59946),i.Stream=i,i.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",i),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",s),r.on("close",u));var a=!1;function s(){a||(a=!0,e.end())}function u(){a||(a=!0,"function"==typeof e.destroy&&e.destroy())}function c(e){if(l(),0===n.listenerCount(this,"error"))throw e}function l(){r.removeListener("data",i),e.removeListener("drain",o),r.removeListener("end",s),r.removeListener("close",u),r.removeListener("error",c),e.removeListener("error",c),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return r.on("error",c),e.on("error",c),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e}},8501:(e,t,r)=>{var n=r(11989),i=r(55676),o=r(47529),a=r(50584),s=r(8575),u=t;u.request=function(e,t){e="string"==typeof e?s.parse(e):o(e);var i=-1===r.g.location.protocol.search(/^https?:$/)?"http:":"",a=e.protocol||i,u=e.hostname||e.host,c=e.port,l=e.path||"/";u&&-1!==u.indexOf(":")&&(u="["+u+"]"),e.url=(u?a+"//"+u:"")+(c?":"+c:"")+l,e.method=(e.method||"GET").toUpperCase(),e.headers=e.headers||{};var f=new n(e);return t&&f.on("response",t),f},u.get=function(e,t){var r=u.request(e,t);return r.end(),r},u.ClientRequest=n,u.IncomingMessage=i.IncomingMessage,u.Agent=function(){},u.Agent.defaultMaxSockets=4,u.globalAgent=new u.Agent,u.STATUS_CODES=a,u.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]},8725:(e,t,r)=>{var n;function i(){if(void 0!==n)return n;if(r.g.XMLHttpRequest){n=new r.g.XMLHttpRequest;try{n.open("GET",r.g.XDomainRequest?"/":"https://example.com")}catch(e){n=null}}else n=null;return n}function o(e){var t=i();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}function a(e){return"function"==typeof e}t.fetch=a(r.g.fetch)&&a(r.g.ReadableStream),t.writableStream=a(r.g.WritableStream),t.abortController=a(r.g.AbortController),t.arraybuffer=t.fetch||o("arraybuffer"),t.msstream=!t.fetch&&o("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&o("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!i()&&a(i().overrideMimeType),n=null},11989:(e,t,r)=>{var n=r(48764).Buffer,i=r(34155),o=r(8725),a=r(35717),s=r(55676),u=r(88473),c=s.IncomingMessage,l=s.readyStates;var f=e.exports=function(e){var t,r=this;u.Writable.call(r),r._opts=e,r._body=[],r._headers={},e.auth&&r.setHeader("Authorization","Basic "+n.from(e.auth).toString("base64")),Object.keys(e.headers).forEach((function(t){r.setHeader(t,e.headers[t])}));var i=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!o.abortController)i=!1,t=!0;else if("prefer-streaming"===e.mode)t=!1;else if("allow-wrong-content-type"===e.mode)t=!o.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");t=!0}r._mode=function(e,t){return o.fetch&&t?"fetch":o.mozchunkedarraybuffer?"moz-chunked-arraybuffer":o.msstream?"ms-stream":o.arraybuffer&&e?"arraybuffer":"text"}(t,i),r._fetchTimer=null,r._socketTimeout=null,r._socketTimer=null,r.on("finish",(function(){r._onFinish()}))};a(f,u.Writable),f.prototype.setHeader=function(e,t){var r=e.toLowerCase();-1===h.indexOf(r)&&(this._headers[r]={name:e,value:t})},f.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},f.prototype.removeHeader=function(e){delete this._headers[e.toLowerCase()]},f.prototype._onFinish=function(){var e=this;if(!e._destroyed){var t=e._opts;"timeout"in t&&0!==t.timeout&&e.setTimeout(t.timeout);var n=e._headers,a=null;"GET"!==t.method&&"HEAD"!==t.method&&(a=new Blob(e._body,{type:(n["content-type"]||{}).value||""}));var s=[];if(Object.keys(n).forEach((function(e){var t=n[e].name,r=n[e].value;Array.isArray(r)?r.forEach((function(e){s.push([t,e])})):s.push([t,r])})),"fetch"===e._mode){var u=null;if(o.abortController){var c=new AbortController;u=c.signal,e._fetchAbortController=c,"requestTimeout"in t&&0!==t.requestTimeout&&(e._fetchTimer=r.g.setTimeout((function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()}),t.requestTimeout))}r.g.fetch(e._opts.url,{method:e._opts.method,headers:s,body:a||void 0,mode:"cors",credentials:t.withCredentials?"include":"same-origin",signal:u}).then((function(t){e._fetchResponse=t,e._resetTimers(!1),e._connect()}),(function(t){e._resetTimers(!0),e._destroyed||e.emit("error",t)}))}else{var f=e._xhr=new r.g.XMLHttpRequest;try{f.open(e._opts.method,e._opts.url,!0)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}"responseType"in f&&(f.responseType=e._mode),"withCredentials"in f&&(f.withCredentials=!!t.withCredentials),"text"===e._mode&&"overrideMimeType"in f&&f.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in t&&(f.timeout=t.requestTimeout,f.ontimeout=function(){e.emit("requestTimeout")}),s.forEach((function(e){f.setRequestHeader(e[0],e[1])})),e._response=null,f.onreadystatechange=function(){switch(f.readyState){case l.LOADING:case l.DONE:e._onXHRProgress()}},"moz-chunked-arraybuffer"===e._mode&&(f.onprogress=function(){e._onXHRProgress()}),f.onerror=function(){e._destroyed||(e._resetTimers(!0),e.emit("error",new Error("XHR error")))};try{f.send(a)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}}}},f.prototype._onXHRProgress=function(){var e=this;e._resetTimers(!1),function(e){try{var t=e.status;return null!==t&&0!==t}catch(e){return!1}}(e._xhr)&&!e._destroyed&&(e._response||e._connect(),e._response._onXHRProgress(e._resetTimers.bind(e)))},f.prototype._connect=function(){var e=this;e._destroyed||(e._response=new c(e._xhr,e._fetchResponse,e._mode,e._resetTimers.bind(e)),e._response.on("error",(function(t){e.emit("error",t)})),e.emit("response",e._response))},f.prototype._write=function(e,t,r){this._body.push(e),r()},f.prototype._resetTimers=function(e){var t=this;r.g.clearTimeout(t._socketTimer),t._socketTimer=null,e?(r.g.clearTimeout(t._fetchTimer),t._fetchTimer=null):t._socketTimeout&&(t._socketTimer=r.g.setTimeout((function(){t.emit("timeout")}),t._socketTimeout))},f.prototype.abort=f.prototype.destroy=function(e){var t=this;t._destroyed=!0,t._resetTimers(!0),t._response&&(t._response._destroyed=!0),t._xhr?t._xhr.abort():t._fetchAbortController&&t._fetchAbortController.abort(),e&&t.emit("error",e)},f.prototype.end=function(e,t,r){"function"==typeof e&&(r=e,e=void 0),u.Writable.prototype.end.call(this,e,t,r)},f.prototype.setTimeout=function(e,t){var r=this;t&&r.once("timeout",t),r._socketTimeout=e,r._resetTimers(!1)},f.prototype.flushHeaders=function(){},f.prototype.setNoDelay=function(){},f.prototype.setSocketKeepAlive=function(){};var h=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]},55676:(e,t,r)=>{var n=r(34155),i=r(48764).Buffer,o=r(8725),a=r(35717),s=r(88473),u=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},c=t.IncomingMessage=function(e,t,r,a){var u=this;if(s.Readable.call(u),u._mode=r,u.headers={},u.rawHeaders=[],u.trailers={},u.rawTrailers=[],u.on("end",(function(){n.nextTick((function(){u.emit("close")}))})),"fetch"===r){if(u._fetchResponse=t,u.url=t.url,u.statusCode=t.status,u.statusMessage=t.statusText,t.headers.forEach((function(e,t){u.headers[t.toLowerCase()]=e,u.rawHeaders.push(t,e)})),o.writableStream){var c=new WritableStream({write:function(e){return a(!1),new Promise((function(t,r){u._destroyed?r():u.push(i.from(e))?t():u._resumeFetch=t}))},close:function(){a(!0),u._destroyed||u.push(null)},abort:function(e){a(!0),u._destroyed||u.emit("error",e)}});try{return void t.body.pipeTo(c).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}catch(e){}}var l=t.body.getReader();!function e(){l.read().then((function(t){u._destroyed||(a(t.done),t.done?u.push(null):(u.push(i.from(t.value)),e()))})).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}()}else{if(u._xhr=e,u._pos=0,u.url=e.responseURL,u.statusCode=e.status,u.statusMessage=e.statusText,e.getAllResponseHeaders().split(/\r?\n/).forEach((function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var r=t[1].toLowerCase();"set-cookie"===r?(void 0===u.headers[r]&&(u.headers[r]=[]),u.headers[r].push(t[2])):void 0!==u.headers[r]?u.headers[r]+=", "+t[2]:u.headers[r]=t[2],u.rawHeaders.push(t[1],t[2])}})),u._charset="x-user-defined",!o.overrideMimeType){var f=u.rawHeaders["mime-type"];if(f){var h=f.match(/;\s*charset=([^;])(;|$)/);h&&(u._charset=h[1].toLowerCase())}u._charset||(u._charset="utf-8")}}};a(c,s.Readable),c.prototype._read=function(){var e=this._resumeFetch;e&&(this._resumeFetch=null,e())},c.prototype._onXHRProgress=function(e){var t=this,n=t._xhr,o=null;switch(t._mode){case"text":if((o=n.responseText).length>t._pos){var a=o.substr(t._pos);if("x-user-defined"===t._charset){for(var s=i.alloc(a.length),c=0;ct._pos&&(t.push(i.from(new Uint8Array(l.result.slice(t._pos)))),t._pos=l.result.byteLength)},l.onload=function(){e(!0),t.push(null)},l.readAsArrayBuffer(o)}t._xhr.readyState===u.DONE&&"ms-stream"!==t._mode&&(e(!0),t.push(null))}},32553:(e,t,r)=>{"use strict";var n=r(89509).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.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 o(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){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 e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=u,this.end=c,t=4;break;case"utf8":this.fillLast=s,t=4;break;case"base64":this.text=l,this.end=f,t=3;break;default:return this.write=h,void(this.end=d)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function a(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function u(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function c(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function l(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function h(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}t.s=o,o.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0)return i>0&&(e.lastNeed=i-1),i;if(--n=0)return i>0&&(e.lastNeed=i-2),i;if(--n=0)return i>0&&(2===i?i=0:e.lastNeed=i-3),i;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},o.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},99269:function(e){e.exports=function(){function e(e,t){var r=t?"└":"├";return r+=e?"─ ":"──┐"}function t(e,t){var r=[];for(var n in e)e.hasOwnProperty(n)&&(t&&"function"==typeof e[n]||r.push(n));return r}function r(n,i,o,a,s,u,c){var l,f,h="",d=0,p=a.slice(0);if(p.push([i,o])&&a.length>0&&(a.forEach((function(e,t){t>0&&(h+=(e[1]?" ":"│")+" "),f||e[0]!==i||(f=!0)})),h+=e(n,o)+n,s&&("object"!=typeof i||i instanceof Date)&&(h+=": "+i),f&&(h+=" (circular ref.)"),c(h)),!f&&"object"==typeof i){var m=t(i,u);m.forEach((function(e){l=++d===m.length,r(e,i[e],l,p,s,u,c)}))}}var n={asLines:function(e,t,n,i){r(".",e,!1,[],t,"function"!=typeof n&&n,i||n)},asTree:function(e,t,n){var i="";return r(".",e,!1,[],t,n,(function(e){i+=e+"\n"})),i}};return n}()},52511:function(e,t,r){var n;e=r.nmd(e),function(i){t&&t.nodeType,e&&e.nodeType;var o="object"==typeof r.g&&r.g;o.global!==o&&o.window!==o&&o.self;var a,s=2147483647,u=36,c=/^xn--/,l=/[^\x20-\x7E]/,f=/[\x2E\u3002\uFF0E\uFF61]/g,h={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},d=Math.floor,p=String.fromCharCode;function m(e){throw new RangeError(h[e])}function y(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function g(e,t){var r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+y((e=e.replace(f,".")).split("."),t).join(".")}function b(e){for(var t,r,n=[],i=0,o=e.length;i=55296&&t<=56319&&i65535&&(t+=p((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+=p(e)})).join("")}function w(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function A(e,t,r){var n=0;for(e=r?d(e/700):e>>1,e+=d(e/t);e>455;n+=u)e=d(e/35);return d(n+36*e/(e+38))}function S(e){var t,r,n,i,o,a,c,l,f,h,p,y=[],g=e.length,b=0,w=128,S=72;for((r=e.lastIndexOf("-"))<0&&(r=0),n=0;n=128&&m("not-basic"),y.push(e.charCodeAt(n));for(i=r>0?r+1:0;i=g&&m("invalid-input"),((l=(p=e.charCodeAt(i++))-48<10?p-22:p-65<26?p-65:p-97<26?p-97:u)>=u||l>d((s-b)/a))&&m("overflow"),b+=l*a,!(l<(f=c<=S?1:c>=S+26?26:c-S));c+=u)a>d(s/(h=u-f))&&m("overflow"),a*=h;S=A(b-o,t=y.length+1,0==o),d(b/t)>s-w&&m("overflow"),w+=d(b/t),b%=t,y.splice(b++,0,w)}return v(y)}function k(e){var t,r,n,i,o,a,c,l,f,h,y,g,v,S,k,E=[];for(g=(e=b(e)).length,t=128,r=0,o=72,a=0;a=t&&yd((s-r)/(v=n+1))&&m("overflow"),r+=(c-t)*v,t=c,a=0;as&&m("overflow"),y==t){for(l=r,f=u;!(l<(h=f<=o?1:f>=o+26?26:f-o));f+=u)k=l-h,S=u-h,E.push(p(w(h+k%S,0))),l=d(k/S);E.push(p(w(l,0))),o=A(r,v,n==i),r=0,++n}++r,++t}return E.join("")}a={version:"1.4.1",ucs2:{decode:b,encode:v},decode:S,encode:k,toASCII:function(e){return g(e,(function(e){return l.test(e)?"xn--"+k(e):e}))},toUnicode:function(e){return g(e,(function(e){return c.test(e)?S(e.slice(4).toLowerCase()):e}))}},void 0===(n=function(){return a}.call(t,r,t,e))||(e.exports=n)}()},8575:(e,t,r)=>{"use strict";var n=r(52511);function i(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var o=/^([a-z0-9.+-]+:)/i,a=/:[0-9]*$/,s=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,u=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),c=["'"].concat(u),l=["%","/","?",";","#"].concat(c),f=["/","?","#"],h=/^[+a-z0-9A-Z_-]{0,63}$/,d=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,p={javascript:!0,"javascript:":!0},m={javascript:!0,"javascript:":!0},y={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},g=r(80129);function b(e,t,r){if(e&&"object"==typeof e&&e instanceof i)return e;var n=new i;return n.parse(e,t,r),n}i.prototype.parse=function(e,t,r){if("string"!=typeof e)throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var i=e.indexOf("?"),a=-1!==i&&i127?R+="x":R+=O[C];if(!R.match(h)){var N=P.slice(0,M),L=P.slice(M+1),U=O.match(d);U&&(N.push(U[1]),L.unshift(U[2])),L.length&&(b="/"+L.join(".")+b),this.hostname=N.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),x||(this.hostname=n.toASCII(this.hostname));var F=this.port?":"+this.port:"",D=this.hostname||"";this.host=D+F,this.href+=this.host,x&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==b[0]&&(b="/"+b))}if(!p[A])for(M=0,I=c.length;M0)&&r.host.split("@"))&&(r.auth=x.shift(),r.hostname=x.shift(),r.host=r.hostname);return r.search=e.search,r.query=e.query,null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!S.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var E=S.slice(-1)[0],_=(r.host||e.host||S.length>1)&&("."===E||".."===E)||""===E,M=0,T=S.length;T>=0;T--)"."===(E=S[T])?S.splice(T,1):".."===E?(S.splice(T,1),M++):M&&(S.splice(T,1),M--);if(!w&&!A)for(;M--;M)S.unshift("..");!w||""===S[0]||S[0]&&"/"===S[0].charAt(0)||S.unshift(""),_&&"/"!==S.join("/").substr(-1)&&S.push("");var x,P=""===S[0]||S[0]&&"/"===S[0].charAt(0);k&&(r.hostname=P?"":S.length?S.shift():"",r.host=r.hostname,(x=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=x.shift(),r.hostname=x.shift(),r.host=r.hostname));return(w=w||r.host&&S.length)&&!P&&S.unshift(""),S.length>0?r.pathname=S.join("/"):(r.pathname=null,r.path=null),null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},i.prototype.parseHost=function(){var e=this.host,t=a.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},t.parse=b,t.resolve=function(e,t){return b(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?b(e,!1,!0).resolveObject(t):t},t.format=function(e){return"string"==typeof e&&(e=b(e)),e instanceof i?e.format():i.prototype.format.call(e)},t.Url=i},60137:e=>{"use strict";e.exports=function(e){const t=e.length;let r=0;for(;r=t||128!=(192&e[r+1])||128!=(192&e[r+2])||224===e[r]&&128==(224&e[r+1])||237===e[r]&&160==(224&e[r+1]))return!1;r+=3}else{if(240!=(248&e[r]))return!1;if(r+3>=t||128!=(192&e[r+1])||128!=(192&e[r+2])||128!=(192&e[r+3])||240===e[r]&&128==(240&e[r+1])||244===e[r]&&e[r+1]>143||e[r]>244)return!1;r+=4}return!0}},70311:(e,t,r)=>{"use strict";try{e.exports=r(19516)("/")}catch(t){e.exports=r(60137)}},94927:(e,t,r)=>{function n(e){try{if(!r.g.localStorage)return!1}catch(e){return!1}var t=r.g.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=function(e,t){if(n("noDeprecation"))return e;var r=!1;return function(){if(!r){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}},37918:e=>{var t;self,t=()=>(()=>{var e={1645:(e,t,r)=>{"use strict";var n=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.chains=t._getInitializedChains=void 0;var i=n(r(7295)),o=n(r(1227)),a=n(r(439)),s=n(r(7098)),u=n(r(7687));function c(e){var t,r,n={1:"mainnet",3:"ropsten",4:"rinkeby",42:"kovan",5:"goerli"},c={mainnet:i.default,ropsten:o.default,rinkeby:a.default,kovan:s.default,goerli:u.default};if(e)try{for(var l=function(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),f=l.next();!f.done;f=l.next()){var h=f.value,d=h.name;n[h.chainId.toString()]=d,c[d]=h}}catch(e){t={error:e}}finally{try{f&&!f.done&&(r=l.return)&&r.call(l)}finally{if(t)throw t.error}}return c.names=n,c}t._getInitializedChains=c,t.chains=c()},425:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EIPs=void 0,t.EIPs={1559:r(7523),2315:r(3339),2537:r(6769),2565:r(7897),2718:r(2170),2929:r(8436),2930:r(6213),3198:r(5491),3529:r(7852),3541:r(1871),3554:r(7225),3675:r(8571)}},7002:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hardforks=void 0,t.hardforks=[["chainstart",r(114)],["homestead",r(2800)],["dao",r(7197)],["tangerineWhistle",r(2302)],["spuriousDragon",r(716)],["byzantium",r(6985)],["constantinople",r(5993)],["petersburg",r(4064)],["istanbul",r(3166)],["muirGlacier",r(2946)],["berlin",r(15)],["london",r(1250)],["shanghai",r(5553)],["merge",r(8648)]]},3863:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=r(8847)(r(3355)),a=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),s=function(){return s=Object.assign||function(e){for(var t,r=1,n=arguments.length;r=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0}),t.ConsensusAlgorithm=t.ConsensusType=t.Hardfork=t.Chain=t.CustomChain=void 0;var c,l,f,h,d,p=r(8291),m=r(4628),y=r(3062),g=r(1645),b=r(7002),v=r(425);!function(e){e.PolygonMainnet="polygon-mainnet",e.PolygonMumbai="polygon-mumbai",e.ArbitrumRinkebyTestnet="arbitrum-rinkeby-testnet",e.xDaiChain="x-dai-chain"}(c=t.CustomChain||(t.CustomChain={})),(d=t.Chain||(t.Chain={}))[d.Mainnet=1]="Mainnet",d[d.Ropsten=3]="Ropsten",d[d.Rinkeby=4]="Rinkeby",d[d.Kovan=42]="Kovan",d[d.Goerli=5]="Goerli",function(e){e.Chainstart="chainstart",e.Homestead="homestead",e.Dao="dao",e.TangerineWhistle="tangerineWhistle",e.SpuriousDragon="spuriousDragon",e.Byzantium="byzantium",e.Constantinople="constantinople",e.Petersburg="petersburg",e.Istanbul="istanbul",e.MuirGlacier="muirGlacier",e.Berlin="berlin",e.London="london",e.Shanghai="shanghai",e.Merge="merge"}(l=t.Hardfork||(t.Hardfork={})),(h=t.ConsensusType||(t.ConsensusType={})).ProofOfStake="pos",h.ProofOfWork="pow",h.ProofOfAuthority="poa",(f=t.ConsensusAlgorithm||(t.ConsensusAlgorithm={})).Ethash="ethash",f.Clique="clique",f.Casper="casper";var w=function(e){function t(t){var r,n,i,o,a=e.call(this)||this;a._supportedHardforks=[],a._eips=[],a._customChains=null!==(i=t.customChains)&&void 0!==i?i:[],a._chainParams=a.setChain(t.chain),a.DEFAULT_HARDFORK=null!==(o=a._chainParams.defaultHardfork)&&void 0!==o?o:l.Istanbul;try{for(var s=u(a._chainParams.hardforks),c=s.next();!c.done;c=s.next()){var f=c.value;f.forkHash||(f.forkHash=a._calcForkHash(f.name))}}catch(e){r={error:e}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(r)throw r.error}}return a._hardfork=a.DEFAULT_HARDFORK,t.supportedHardforks&&(a._supportedHardforks=t.supportedHardforks),t.hardfork&&a.setHardfork(t.hardfork),t.eips&&a.setEIPs(t.eips),a}return a(t,e),t.custom=function(e,r){var n;void 0===r&&(r={});var i=null!==(n=r.baseChain)&&void 0!==n?n:"mainnet",o=s({},t._getChainParams(i));if(o.name="custom-chain","string"!=typeof e)return new t(s({chain:s(s({},o),e)},r));if(e===c.PolygonMainnet)return t.custom({name:c.PolygonMainnet,chainId:137,networkId:137});if(e===c.PolygonMumbai)return t.custom({name:c.PolygonMumbai,chainId:80001,networkId:80001});if(e===c.ArbitrumRinkebyTestnet)return t.custom({name:c.ArbitrumRinkebyTestnet,chainId:421611,networkId:421611});if(e===c.xDaiChain)return t.custom({name:c.xDaiChain,chainId:100,networkId:100});throw new Error("Custom chain "+e+" not supported")},t.forCustomChain=function(e,r,n,i){var o=t._getChainParams(e);return new t({chain:s(s({},o),r),hardfork:n,supportedHardforks:i})},t.isSupportedChainId=function(e){var t=(0,g._getInitializedChains)();return Boolean(t.names[e.toString()])},t._getChainParams=function(e,t){var r=(0,g._getInitializedChains)(t);if("number"==typeof e||y.BN.isBN(e)){if(e=e.toString(),r.names[e])return r[r.names[e]];throw new Error("Chain with ID "+e+" not supported")}if(r[e])return r[e];throw new Error("Chain with name "+e+" not supported")},t.prototype.setChain=function(e){var r,n;if("number"==typeof e||"string"==typeof e||y.BN.isBN(e)){var i;i=this._customChains&&this._customChains.length>0&&Array.isArray(this._customChains[0])?this._customChains.map((function(e){return e[0]})):this._customChains,this._chainParams=t._getChainParams(e,i)}else{if("object"!==(0,o.default)(e))throw new Error("Wrong input format");if(this._customChains.length>0)throw new Error("Chain must be a string, number, or BN when initialized with customChains passed in");try{for(var a=u(["networkId","genesis","hardforks","bootstrapNodes"]),s=a.next();!s.done;s=a.next()){var c=s.value;if(void 0===e[c])throw new Error("Missing required chain parameter: "+c)}}catch(e){r={error:e}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}this._chainParams=e}return this._chainParams},t.prototype.setHardfork=function(e){var t,r;if(!this._isSupportedHardfork(e))throw new Error("Hardfork "+e+" not set as supported in supportedHardforks");var n=!1;try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next())o.value[0]===e&&(this._hardfork!==e&&(this._hardfork=e,this.emit("hardforkChanged",e)),n=!0)}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}if(!n)throw new Error("Hardfork with name "+e+" not supported")},t.prototype.getHardforkByBlockNumber=function(e,t){var r,n;e=(0,y.toType)(e,y.TypeOutput.BN),t=t?(0,y.toType)(t,y.TypeOutput.BN):void 0;var i,o,a,s=l.Chainstart;try{for(var c=u(this.hardforks()),f=c.next();!f.done;f=c.next()){var h=f.value;if(null!==h.block)e.gte(new y.BN(h.block))&&(s=h.name),t&&h.td&&(t.gten(h.td)?i=h.name:o=a),a=h.name;else if(t&&h.td&&t.gten(h.td))return h.name}}catch(e){r={error:e}}finally{try{f&&!f.done&&(n=c.return)&&n.call(c)}finally{if(r)throw r.error}}if(t){var d="block number: "+e+" (-> "+s+"), ";if(i&&!this.hardforkGteHardfork(s,i)){var p="HF determined by block number is lower than the minimum total difficulty HF";throw d+="total difficulty: "+t+" (-> "+i+")",new Error(p+": "+d)}if(o&&!this.hardforkGteHardfork(o,s))throw p="Maximum HF determined by total difficulty is lower than the block number HF",d+="total difficulty: "+t+" (-> "+o+")",new Error(p+": "+d)}return s},t.prototype.setHardforkByBlockNumber=function(e,t){var r=this.getHardforkByBlockNumber(e,t);return this.setHardfork(r),r},t.prototype._chooseHardfork=function(e,t){if(void 0===t&&(t=!0),e){if(t&&!this._isSupportedHardfork(e))throw new Error("Hardfork "+e+" not set as supported in supportedHardforks")}else e=this._hardfork;return e},t.prototype._getHardfork=function(e){var t,r,n=this.hardforks();try{for(var i=u(n),o=i.next();!o.done;o=i.next()){var a=o.value;if(a.name===e)return a}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}throw new Error("Hardfork "+e+" not defined for chain "+this.chainName())},t.prototype._isSupportedHardfork=function(e){var t,r;if(!(this._supportedHardforks.length>0))return!0;try{for(var n=u(this._supportedHardforks),i=n.next();!i.done;i=n.next())if(e===i.value)return!0}catch(e){t={error:e}}finally{try{i&&!i.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}return!1},t.prototype.setEIPs=function(e){var t,r,n=this;void 0===e&&(e=[]);var i=function(t){if(!(t in v.EIPs))throw new Error(t+" not supported");var r=o.gteHardfork(v.EIPs[t].minimumHardfork);if(!r)throw new Error(t+" cannot be activated on hardfork "+o.hardfork()+", minimumHardfork: "+r);v.EIPs[t].requiredEIPs&&v.EIPs[t].requiredEIPs.forEach((function(r){if(!e.includes(r)&&!n.isActivatedEIP(r))throw new Error(t+" requires EIP "+r+", but is not included in the EIP list")}))},o=this;try{for(var a=u(e),s=a.next();!s.done;s=a.next())i(s.value)}catch(e){t={error:e}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}this._eips=e},t.prototype.param=function(e,t){var r,n,i=null;try{for(var o=u(this._eips),a=o.next();!a.done;a=o.next()){var s=a.value;if(null!==(i=this.paramByEIP(e,t,s)))return i}}catch(e){r={error:e}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return this.paramByHardfork(e,t,this._hardfork)},t.prototype.paramByHardfork=function(e,t,r){var n,i,o,a;r=this._chooseHardfork(r);var s=null;try{for(var c=u(b.hardforks),l=c.next();!l.done;l=c.next()){var f=l.value;if("eips"in f[1]){var h=f[1].eips;try{for(var d=(o=void 0,u(h)),p=d.next();!p.done;p=d.next()){var m=p.value,y=this.paramByEIP(e,t,m);s=null!==y?y:s}}catch(e){o={error:e}}finally{try{p&&!p.done&&(a=d.return)&&a.call(d)}finally{if(o)throw o.error}}}else{if(!f[1][e])throw new Error("Topic "+e+" not defined");void 0!==f[1][e][t]&&(s=f[1][e][t].v)}if(f[0]===r)break}}catch(e){n={error:e}}finally{try{l&&!l.done&&(i=c.return)&&i.call(c)}finally{if(n)throw n.error}}return s},t.prototype.paramByEIP=function(e,t,r){if(!(r in v.EIPs))throw new Error(r+" not supported");var n=v.EIPs[r];if(!(e in n))throw new Error("Topic "+e+" not defined");return void 0===n[e][t]?null:n[e][t].v},t.prototype.paramByBlock=function(e,t,r){var n=this.activeHardforks(r),i=n[n.length-1].name;return this.paramByHardfork(e,t,i)},t.prototype.isActivatedEIP=function(e){var t,r;if(this.eips().includes(e))return!0;try{for(var n=u(b.hardforks),i=n.next();!i.done;i=n.next()){var o=i.value[1];if(this.gteHardfork(o.name)&&"eips"in o&&o.eips.includes(e))return!0}}catch(e){t={error:e}}finally{try{i&&!i.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}return!1},t.prototype.hardforkIsActiveOnBlock=function(e,t,r){var n;void 0===r&&(r={}),t=(0,y.toType)(t,y.TypeOutput.BN);var i=null!==(n=r.onlySupported)&&void 0!==n&&n;e=this._chooseHardfork(e,i);var o=this.hardforkBlockBN(e);return!(!o||!t.gte(o))},t.prototype.activeOnBlock=function(e,t){return this.hardforkIsActiveOnBlock(null,e,t)},t.prototype.hardforkGteHardfork=function(e,t,r){var n,i;void 0===r&&(r={});var o,a=void 0!==r.onlyActive&&r.onlyActive;e=this._chooseHardfork(e,r.onlySupported),o=a?this.activeHardforks(null,r):this.hardforks();var s=-1,c=-1,l=0;try{for(var f=u(o),h=f.next();!h.done;h=f.next()){var d=h.value;d.name===e&&(s=l),d.name===t&&(c=l),l+=1}}catch(e){n={error:e}}finally{try{h&&!h.done&&(i=f.return)&&i.call(f)}finally{if(n)throw n.error}}return s>=c&&-1!==c},t.prototype.gteHardfork=function(e,t){return this.hardforkGteHardfork(null,e,t)},t.prototype.hardforkIsActiveOnChain=function(e,t){var r,n,i;void 0===t&&(t={});var o=null!==(i=t.onlySupported)&&void 0!==i&&i;e=this._chooseHardfork(e,o);try{for(var a=u(this.hardforks()),s=a.next();!s.done;s=a.next()){var c=s.value;if(c.name===e&&null!==c.block)return!0}}catch(e){r={error:e}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}return!1},t.prototype.activeHardforks=function(e,t){var r,n;void 0===t&&(t={});var i=[],o=this.hardforks();try{for(var a=u(o),s=a.next();!s.done;s=a.next()){var c=s.value;if(null!==c.block){if(null!=e&&e0)return r[r.length-1].name;throw new Error("No (supported) active hardfork found")},t.prototype.hardforkBlock=function(e){var t=this.hardforkBlockBN(e);return t?(0,y.toType)(t,y.TypeOutput.Number):null},t.prototype.hardforkBlockBN=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e).block;return null==t?null:new y.BN(t)},t.prototype.hardforkTD=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e).td;return null==t?null:new y.BN(t)},t.prototype.isHardforkBlock=function(e,t){e=(0,y.toType)(e,y.TypeOutput.BN),t=this._chooseHardfork(t,!1);var r=this.hardforkBlockBN(t);return!!r&&r.eq(e)},t.prototype.nextHardforkBlock=function(e){var t=this.nextHardforkBlockBN(e);return null===t?null:(0,y.toType)(t,y.TypeOutput.Number)},t.prototype.nextHardforkBlockBN=function(e){e=this._chooseHardfork(e,!1);var t=this.hardforkBlockBN(e);return null===t?null:this.hardforks().reduce((function(e,r){var n=new y.BN(r.block);return n.gt(t)&&null===e?n:e}),null)},t.prototype.isNextHardforkBlock=function(e,t){e=(0,y.toType)(e,y.TypeOutput.BN),t=this._chooseHardfork(t,!1);var r=this.nextHardforkBlockBN(t);return null!==r&&r.eq(e)},t.prototype._calcForkHash=function(e){var t,r,n=i.from(this.genesis().hash.substr(2),"hex"),o=i.alloc(0),a=0;try{for(var s=u(this.hardforks()),c=s.next();!c.done;c=s.next()){var l=c.value,f=l.block;if(0!==f&&null!==f&&f!==a){var h=i.from(f.toString(16).padStart(16,"0"),"hex");o=i.concat([o,h])}if(l.name===e)break;null!==f&&(a=f)}}catch(e){t={error:e}}finally{try{c&&!c.done&&(r=s.return)&&r.call(s)}finally{if(t)throw t.error}}var d=i.concat([n,o]);return"0x"+(0,y.intToBuffer)((0,m.buf)(d)>>>0).toString("hex")},t.prototype.forkHash=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e);if(null===t.block)throw new Error("No fork hash calculation possible for non-applied or future hardfork");return void 0!==t.forkHash?t.forkHash:this._calcForkHash(e)},t.prototype.hardforkForForkHash=function(e){var t=this.hardforks().filter((function(t){return t.forkHash===e}));return t.length>=1?t[t.length-1]:null},t.prototype.genesis=function(){return this._chainParams.genesis},t.prototype.genesisState=function(){var e,t;switch(this.chainName()){case"mainnet":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/mainnet.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"ropsten":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/ropsten.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"rinkeby":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/rinkeby.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"kovan":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/kovan.json'");throw e.code="MODULE_NOT_FOUND",e}()));case"goerli":return r(Object(function(){var e=new Error("Cannot find module './genesisStates/goerli.json'");throw e.code="MODULE_NOT_FOUND",e}()))}if(this._customChains&&this._customChains.length>0&&Array.isArray(this._customChains[0]))try{for(var n=u(this._customChains),i=n.next();!i.done;i=n.next()){var o=i.value;if(o[0].name===this.chainName())return o[1]}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return{}},t.prototype.hardforks=function(){return this._chainParams.hardforks},t.prototype.bootstrapNodes=function(){return this._chainParams.bootstrapNodes},t.prototype.dnsNetworks=function(){return this._chainParams.dnsNetworks},t.prototype.hardfork=function(){return this._hardfork},t.prototype.chainId=function(){return(0,y.toType)(this.chainIdBN(),y.TypeOutput.Number)},t.prototype.chainIdBN=function(){return new y.BN(this._chainParams.chainId)},t.prototype.chainName=function(){return this._chainParams.name},t.prototype.networkId=function(){return(0,y.toType)(this.networkIdBN(),y.TypeOutput.Number)},t.prototype.networkIdBN=function(){return new y.BN(this._chainParams.networkId)},t.prototype.eips=function(){return this._eips},t.prototype.consensusType=function(){var e,t,r,n=this.hardfork();try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next()){var a=o.value;if("consensus"in a[1]&&(r=a[1].consensus.type),a[0]===n)break}}catch(t){e={error:t}}finally{try{o&&!o.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}return r||this._chainParams.consensus.type},t.prototype.consensusAlgorithm=function(){var e,t,r,n=this.hardfork();try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next()){var a=o.value;if("consensus"in a[1]&&(r=a[1].consensus.algorithm),a[0]===n)break}}catch(t){e={error:t}}finally{try{o&&!o.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}return r||this._chainParams.consensus.algorithm},t.prototype.consensusConfig=function(){var e,t,r,n=this.hardfork();try{for(var i=u(b.hardforks),o=i.next();!o.done;o=i.next()){var a=o.value;if("consensus"in a[1]&&(r=a[1].consensus[a[1].consensus.algorithm]),a[0]===n)break}}catch(t){e={error:t}}finally{try{o&&!o.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}if(r)return r;var s=this.consensusAlgorithm();return this._chainParams.consensus[s]},t.prototype.copy=function(){return Object.assign(Object.create(Object.getPrototypeOf(this)),this)},t}(p.EventEmitter);t.default=w},4383:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t},o=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a};Object.defineProperty(t,"__esModule",{value:!0}),t.BaseTransaction=void 0;var a=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t}(r(3863)),s=r(3062),u=r(7325),c=function(){function e(e){this.cache={hash:void 0},this.activeCapabilities=[],this.DEFAULT_CHAIN=a.Chain.Mainnet,this.DEFAULT_HARDFORK=a.Hardfork.Istanbul;var t=e.nonce,r=e.gasLimit,n=e.to,i=e.value,o=e.data,u=e.v,c=e.r,l=e.s,f=e.type;this._type=new s.BN((0,s.toBuffer)(f)).toNumber();var h=(0,s.toBuffer)(""===n?"0x":n),d=(0,s.toBuffer)(""===u?"0x":u),p=(0,s.toBuffer)(""===c?"0x":c),m=(0,s.toBuffer)(""===l?"0x":l);this.nonce=new s.BN((0,s.toBuffer)(""===t?"0x":t)),this.gasLimit=new s.BN((0,s.toBuffer)(""===r?"0x":r)),this.to=h.length>0?new s.Address(h):void 0,this.value=new s.BN((0,s.toBuffer)(""===i?"0x":i)),this.data=(0,s.toBuffer)(""===o?"0x":o),this.v=d.length>0?new s.BN(d):void 0,this.r=p.length>0?new s.BN(p):void 0,this.s=m.length>0?new s.BN(m):void 0,this._validateCannotExceedMaxInteger({nonce:this.nonce,gasLimit:this.gasLimit,value:this.value,r:this.r,s:this.s})}return Object.defineProperty(e.prototype,"transactionType",{get:function(){return this.type},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"type",{get:function(){return this._type},enumerable:!1,configurable:!0}),e.prototype.supports=function(e){return this.activeCapabilities.includes(e)},e.prototype.validate=function(e){void 0===e&&(e=!1);var t=[];return this.getBaseFee().gt(this.gasLimit)&&t.push("gasLimit is too low. given "+this.gasLimit+", need at least "+this.getBaseFee()),this.isSigned()&&!this.verifySignature()&&t.push("Invalid Signature"),e?t:0===t.length},e.prototype.getBaseFee=function(){var e=this.getDataFee().addn(this.common.param("gasPrices","tx"));return this.common.gteHardfork("homestead")&&this.toCreationAddress()&&e.iaddn(this.common.param("gasPrices","txCreation")),e},e.prototype.getDataFee=function(){for(var e=this.common.param("gasPrices","txDataZero"),t=this.common.param("gasPrices","txDataNonZero"),r=0,n=0;n-1&&this.activeCapabilities.splice(l,1)}return c},e.prototype._getCommon=function(e,t){var r;if(t){var n=new s.BN((0,s.toBuffer)(t));if(e){if(!e.chainIdBN().eq(n))throw new Error("The chain ID does not match the chain ID of Common");return e.copy()}return a.default.isSupportedChainId(n)?new a.default({chain:n,hardfork:this.DEFAULT_HARDFORK}):a.default.forCustomChain(this.DEFAULT_CHAIN,{name:"custom-chain",networkId:n,chainId:n},this.DEFAULT_HARDFORK)}return null!==(r=null==e?void 0:e.copy())&&void 0!==r?r:new a.default({chain:this.DEFAULT_CHAIN,hardfork:this.DEFAULT_HARDFORK})},e.prototype._validateCannotExceedMaxInteger=function(e,t){var r,n;void 0===t&&(t=53);try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),a=i.next();!a.done;a=i.next()){var u=o(a.value,2),c=u[0],l=u[1];if(53===t){if(null==l?void 0:l.gt(s.MAX_INTEGER))throw new Error(c+" cannot exceed MAX_INTEGER, given "+l)}else{if(256!==t)throw new Error("unimplemented bits value");if(null==l?void 0:l.gte(s.TWO_POW256))throw new Error(c+" must be less than 2^256, given "+l)}}}catch(e){r={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}},e}();t.BaseTransaction=c},660:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(e,12),i=n[0],o=n[1],a=n[2],u=n[3],c=n[4],l=n[5],f=n[6],h=n[7],d=n[8],p=n[9],m=n[10],y=n[11];return new t({chainId:new s.BN(i),nonce:o,maxPriorityFeePerGas:a,maxFeePerGas:u,gasLimit:c,to:l,value:f,data:h,accessList:null!=d?d:[],v:void 0!==p?new s.BN(p):void 0,r:m,s:y},r)},t.prototype.getDataFee=function(){var t=e.prototype.getDataFee.call(this);return t.iaddn(l.AccessLists.getDataFeeEIP2930(this.accessList,this.common)),t},t.prototype.getUpfrontCost=function(e){void 0===e&&(e=new s.BN(0));var t=s.BN.min(this.maxPriorityFeePerGas,this.maxFeePerGas.sub(e)).add(e);return this.gasLimit.mul(t).add(this.value)},t.prototype.raw=function(){return[(0,s.bnToUnpaddedBuffer)(this.chainId),(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.maxPriorityFeePerGas),(0,s.bnToUnpaddedBuffer)(this.maxFeePerGas),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data,this.accessList,void 0!==this.v?(0,s.bnToUnpaddedBuffer)(this.v):i.from([]),void 0!==this.r?(0,s.bnToUnpaddedBuffer)(this.r):i.from([]),void 0!==this.s?(0,s.bnToUnpaddedBuffer)(this.s):i.from([])]},t.prototype.serialize=function(){var e=this.raw();return i.concat([f,s.rlp.encode(e)])},t.prototype.getMessageToSign=function(e){void 0===e&&(e=!0);var t=this.raw().slice(0,9),r=i.concat([f,s.rlp.encode(t)]);return e?(0,s.keccak256)(r):r},t.prototype.hash=function(){if(!this.isSigned())throw new Error("Cannot call hash method if transaction is not signed");return Object.isFrozen(this)?(this.cache.hash||(this.cache.hash=(0,s.keccak256)(this.serialize())),this.cache.hash):(0,s.keccak256)(this.serialize())},t.prototype.getMessageToVerifySignature=function(){return this.getMessageToSign()},t.prototype.getSenderPublicKey=function(){var e;if(!this.isSigned())throw new Error("Cannot call this method if transaction is not signed");var t=this.getMessageToVerifySignature();if(this.common.gteHardfork("homestead")&&(null===(e=this.s)||void 0===e?void 0:e.gt(c.N_DIV_2)))throw new Error("Invalid Signature: s-values greater than secp256k1n/2 are considered invalid");var r=this,n=r.v,i=r.r,o=r.s;try{return(0,s.ecrecover)(t,n.addn(27),(0,s.bnToUnpaddedBuffer)(i),(0,s.bnToUnpaddedBuffer)(o))}catch(e){throw new Error("Invalid Signature")}},t.prototype._processSignature=function(e,r,n){var i={common:this.common};return t.fromTxData({chainId:this.chainId,nonce:this.nonce,maxPriorityFeePerGas:this.maxPriorityFeePerGas,maxFeePerGas:this.maxFeePerGas,gasLimit:this.gasLimit,to:this.to,value:this.value,data:this.data,accessList:this.accessList,v:new s.BN(e-27),r:new s.BN(r),s:new s.BN(n)},i)},t.prototype.toJSON=function(){var e=l.AccessLists.getAccessListJSON(this.accessList);return{chainId:(0,s.bnToHex)(this.chainId),nonce:(0,s.bnToHex)(this.nonce),maxPriorityFeePerGas:(0,s.bnToHex)(this.maxPriorityFeePerGas),maxFeePerGas:(0,s.bnToHex)(this.maxFeePerGas),gasLimit:(0,s.bnToHex)(this.gasLimit),to:void 0!==this.to?this.to.toString():void 0,value:(0,s.bnToHex)(this.value),data:"0x"+this.data.toString("hex"),accessList:e,v:void 0!==this.v?(0,s.bnToHex)(this.v):void 0,r:void 0!==this.r?(0,s.bnToHex)(this.r):void 0,s:void 0!==this.s?(0,s.bnToHex)(this.s):void 0}},t}(u.BaseTransaction);t.default=h},7613:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(e,11),i=n[0],o=n[1],a=n[2],u=n[3],c=n[4],l=n[5],f=n[6],h=n[7],d=n[8],p=n[9],m=n[10];return new t({chainId:new s.BN(i),nonce:o,gasPrice:a,gasLimit:u,to:c,value:l,data:f,accessList:null!=h?h:[],v:void 0!==d?new s.BN(d):void 0,r:p,s:m},r)},t.prototype.getDataFee=function(){var t=e.prototype.getDataFee.call(this);return t.iaddn(l.AccessLists.getDataFeeEIP2930(this.accessList,this.common)),t},t.prototype.getUpfrontCost=function(){return this.gasLimit.mul(this.gasPrice).add(this.value)},t.prototype.raw=function(){return[(0,s.bnToUnpaddedBuffer)(this.chainId),(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.gasPrice),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data,this.accessList,void 0!==this.v?(0,s.bnToUnpaddedBuffer)(this.v):i.from([]),void 0!==this.r?(0,s.bnToUnpaddedBuffer)(this.r):i.from([]),void 0!==this.s?(0,s.bnToUnpaddedBuffer)(this.s):i.from([])]},t.prototype.serialize=function(){var e=this.raw();return i.concat([f,s.rlp.encode(e)])},t.prototype.getMessageToSign=function(e){void 0===e&&(e=!0);var t=this.raw().slice(0,8),r=i.concat([f,s.rlp.encode(t)]);return e?(0,s.keccak256)(r):r},t.prototype.hash=function(){if(!this.isSigned())throw new Error("Cannot call hash method if transaction is not signed");return Object.isFrozen(this)?(this.cache.hash||(this.cache.hash=(0,s.keccak256)(this.serialize())),this.cache.hash):(0,s.keccak256)(this.serialize())},t.prototype.getMessageToVerifySignature=function(){return this.getMessageToSign()},t.prototype.getSenderPublicKey=function(){var e;if(!this.isSigned())throw new Error("Cannot call this method if transaction is not signed");var t=this.getMessageToVerifySignature();if(this.common.gteHardfork("homestead")&&(null===(e=this.s)||void 0===e?void 0:e.gt(c.N_DIV_2)))throw new Error("Invalid Signature: s-values greater than secp256k1n/2 are considered invalid");var r=this,n=r.yParity,i=r.r,o=r.s;try{return(0,s.ecrecover)(t,n.addn(27),(0,s.bnToUnpaddedBuffer)(i),(0,s.bnToUnpaddedBuffer)(o))}catch(e){throw new Error("Invalid Signature")}},t.prototype._processSignature=function(e,r,n){var i={common:this.common};return t.fromTxData({chainId:this.chainId,nonce:this.nonce,gasPrice:this.gasPrice,gasLimit:this.gasLimit,to:this.to,value:this.value,data:this.data,accessList:this.accessList,v:new s.BN(e-27),r:new s.BN(r),s:new s.BN(n)},i)},t.prototype.toJSON=function(){var e=l.AccessLists.getAccessListJSON(this.accessList);return{chainId:(0,s.bnToHex)(this.chainId),nonce:(0,s.bnToHex)(this.nonce),gasPrice:(0,s.bnToHex)(this.gasPrice),gasLimit:(0,s.bnToHex)(this.gasLimit),to:void 0!==this.to?this.to.toString():void 0,value:(0,s.bnToHex)(this.value),data:"0x"+this.data.toString("hex"),accessList:e,v:void 0!==this.v?(0,s.bnToHex)(this.v):void 0,r:void 0!==this.r?(0,s.bnToHex)(this.r):void 0,s:void 0!==this.s?(0,s.bnToHex)(this.s):void 0}},t}(u.BaseTransaction);t.default=h},2339:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.FeeMarketEIP1559Transaction=t.TransactionFactory=t.AccessListEIP2930Transaction=t.Transaction=void 0;var o=r(3088);Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return i(o).default}});var a=r(7613);Object.defineProperty(t,"AccessListEIP2930Transaction",{enumerable:!0,get:function(){return i(a).default}});var s=r(9562);Object.defineProperty(t,"TransactionFactory",{enumerable:!0,get:function(){return i(s).default}});var u=r(660);Object.defineProperty(t,"FeeMarketEIP1559Transaction",{enumerable:!0,get:function(){return i(u).default}}),function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)}(r(7325),t)},3088:(e,t,r)=>{"use strict";var n,i=r(9033).Buffer,o=(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(e,9);return new t({nonce:n[0],gasPrice:n[1],gasLimit:n[2],to:n[3],value:n[4],data:n[5],v:n[6],r:n[7],s:n[8]},r)},t.prototype.raw=function(){return[(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.gasPrice),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data,void 0!==this.v?(0,s.bnToUnpaddedBuffer)(this.v):i.from([]),void 0!==this.r?(0,s.bnToUnpaddedBuffer)(this.r):i.from([]),void 0!==this.s?(0,s.bnToUnpaddedBuffer)(this.s):i.from([])]},t.prototype.serialize=function(){return s.rlp.encode(this.raw())},t.prototype._getMessageToSign=function(){var e=[(0,s.bnToUnpaddedBuffer)(this.nonce),(0,s.bnToUnpaddedBuffer)(this.gasPrice),(0,s.bnToUnpaddedBuffer)(this.gasLimit),void 0!==this.to?this.to.buf:i.from([]),(0,s.bnToUnpaddedBuffer)(this.value),this.data];return this.supports(u.Capability.EIP155ReplayProtection)&&(e.push((0,s.toBuffer)(this.common.chainIdBN())),e.push((0,s.unpadBuffer)((0,s.toBuffer)(0))),e.push((0,s.unpadBuffer)((0,s.toBuffer)(0)))),e},t.prototype.getMessageToSign=function(e){void 0===e&&(e=!0);var t=this._getMessageToSign();return e?(0,s.rlphash)(t):t},t.prototype.getUpfrontCost=function(){return this.gasLimit.mul(this.gasPrice).add(this.value)},t.prototype.hash=function(){return Object.isFrozen(this)?(this.cache.hash||(this.cache.hash=(0,s.rlphash)(this.raw())),this.cache.hash):(0,s.rlphash)(this.raw())},t.prototype.getMessageToVerifySignature=function(){if(!this.isSigned())throw Error("This transaction is not signed");var e=this._getMessageToSign();return(0,s.rlphash)(e)},t.prototype.getSenderPublicKey=function(){var e,t=this.getMessageToVerifySignature();if(this.common.gteHardfork("homestead")&&(null===(e=this.s)||void 0===e?void 0:e.gt(u.N_DIV_2)))throw new Error("Invalid Signature: s-values greater than secp256k1n/2 are considered invalid");var r=this,n=r.v,i=r.r,o=r.s;try{return(0,s.ecrecover)(t,n,(0,s.bnToUnpaddedBuffer)(i),(0,s.bnToUnpaddedBuffer)(o),this.supports(u.Capability.EIP155ReplayProtection)?this.common.chainIdBN():void 0)}catch(e){throw new Error("Invalid Signature")}},t.prototype._processSignature=function(e,r,n){var i=new s.BN(e);this.supports(u.Capability.EIP155ReplayProtection)&&i.iadd(this.common.chainIdBN().muln(2).addn(8));var o={common:this.common};return t.fromTxData({nonce:this.nonce,gasPrice:this.gasPrice,gasLimit:this.gasLimit,to:this.to,value:this.value,data:this.data,v:i,r:new s.BN(r),s:new s.BN(n)},o)},t.prototype.toJSON=function(){return{nonce:(0,s.bnToHex)(this.nonce),gasPrice:(0,s.bnToHex)(this.gasPrice),gasLimit:(0,s.bnToHex)(this.gasLimit),to:void 0!==this.to?this.to.toString():void 0,value:(0,s.bnToHex)(this.value),data:"0x"+this.data.toString("hex"),v:void 0!==this.v?(0,s.bnToHex)(this.v):void 0,r:void 0!==this.r?(0,s.bnToHex)(this.r):void 0,s:void 0!==this.s?(0,s.bnToHex)(this.s):void 0}},t.prototype._validateTxV=function(e,t){var r;if(void 0!==e&&!e.eqn(0)&&(!t||t.gteHardfork("spuriousDragon"))&&!e.eqn(27)&&!e.eqn(28))if(t){var n=t.chainIdBN().muln(2);if(!e.eq(n.addn(35))&&!e.eq(n.addn(36)))throw new Error("Incompatible EIP155-based V "+e.toString()+" and chain id "+t.chainIdBN().toString()+". See the Common parameter of the Transaction constructor to set the chain id.")}else{var i;i=e.subn(35).isEven()?35:36,r=e.subn(i).divn(2)}return this._getCommon(t,r)},t.prototype._unsignedTxImplementsEIP155=function(){return this.common.gteHardfork("spuriousDragon")},t.prototype._signedTxImplementsEIP155=function(){if(!this.isSigned())throw Error("This transaction is not signed");var e=this.common.gteHardfork("spuriousDragon"),t=this.v,r=this.common.chainIdBN().muln(2);return(t.eq(r.addn(35))||t.eq(r.addn(36)))&&e},t}(r(4383).BaseTransaction);t.default=c},9562:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0});var i=r(3062),o=r(2339),a=function(){function e(){}return e.fromTxData=function(e,t){if(void 0===t&&(t={}),"type"in e&&void 0!==e.type){var r=new i.BN((0,i.toBuffer)(e.type)).toNumber();if(0===r)return o.Transaction.fromTxData(e,t);if(1===r)return o.AccessListEIP2930Transaction.fromTxData(e,t);if(2===r)return o.FeeMarketEIP1559Transaction.fromTxData(e,t);throw new Error("Tx instantiation with type "+r+" not supported")}return o.Transaction.fromTxData(e,t)},e.fromSerializedData=function(e,t){if(void 0===t&&(t={}),e[0]<=127){var r=void 0;switch(e[0]){case 1:r=2930;break;case 2:r=1559;break;default:throw new Error("TypedTransaction with ID "+e[0]+" unknown")}return 1559===r?o.FeeMarketEIP1559Transaction.fromSerializedTx(e,t):o.AccessListEIP2930Transaction.fromSerializedTx(e,t)}return o.Transaction.fromSerializedTx(e,t)},e.fromBlockBodyData=function(e,t){if(void 0===t&&(t={}),n.isBuffer(e))return this.fromSerializedData(e,t);if(Array.isArray(e))return o.Transaction.fromValuesArray(e,t);throw new Error("Cannot decode transaction: unknown type input")},e.getTransactionClass=function(e,t){if(void 0===e&&(e=0),0==e||e>=128&&e<=255)return o.Transaction;switch(e){case 1:return o.AccessListEIP2930Transaction;case 2:return o.FeeMarketEIP1559Transaction;default:throw new Error("TypedTransaction with ID "+e+" unknown")}},e}();t.default=a},7325:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.N_DIV_2=t.isAccessList=t.isAccessListBuffer=t.Capability=void 0;var n,i=r(3062);function o(e){if(0===e.length)return!0;var t=e[0];return!!Array.isArray(t)}(n=t.Capability||(t.Capability={}))[n.EIP155ReplayProtection=155]="EIP155ReplayProtection",n[n.EIP1559FeeMarket=1559]="EIP1559FeeMarket",n[n.EIP2718TypedTransaction=2718]="EIP2718TypedTransaction",n[n.EIP2930AccessLists=2930]="EIP2930AccessLists",t.isAccessListBuffer=o,t.isAccessList=function(e){return!o(e)},t.N_DIV_2=new i.BN("7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0",16)},3789:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AccessLists=void 0;var n=r(3062),i=r(7325),o=function(){function e(){}return e.getAccessListData=function(e){var t,r;if(e&&(0,i.isAccessList)(e)){t=e;for(var o=[],a=0;a{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="abi/5.7.0"},4937:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.defaultAbiCoder=t.AbiCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=r(908),s=r(3694),u=r(4327),c=r(8067),l=r(7316),f=r(9146),h=r(4341),d=r(24),p=r(3861),m=r(28),y=r(4522),g=r(8287),b=r(8040),v=r(2010),w=r(800),A=new u.Logger(c.version),S=new RegExp(/^bytes([0-9]*)$/),k=new RegExp(/^(u?int)([0-9]*)$/),E=function(){function e(t){(0,i.default)(this,e),(0,s.defineReadOnly)(this,"coerceFunc",t||null)}return(0,o.default)(e,[{key:"_getCoder",value:function(e){var t=this;switch(e.baseType){case"address":return new f.AddressCoder(e.name);case"bool":return new d.BooleanCoder(e.name);case"string":return new b.StringCoder(e.name);case"bytes":return new p.BytesCoder(e.name);case"array":return new h.ArrayCoder(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new v.TupleCoder((e.components||[]).map((function(e){return t._getCoder(e)})),e.name);case"":return new y.NullCoder(e.name)}var r=e.type.match(k);if(r){var n=parseInt(r[2]||"256");return(0===n||n>256||n%8!=0)&&A.throwArgumentError("invalid "+r[1]+" bit length","param",e),new g.NumberCoder(n/8,"int"===r[1],e.name)}if(r=e.type.match(S)){var i=parseInt(r[1]);return(0===i||i>32)&&A.throwArgumentError("invalid bytes length","param",e),new m.FixedBytesCoder(i,e.name)}return A.throwArgumentError("invalid type","type",e.type)}},{key:"_getWordSize",value:function(){return 32}},{key:"_getReader",value:function(e,t){return new l.Reader(e,this._getWordSize(),this.coerceFunc,t)}},{key:"_getWriter",value:function(){return new l.Writer(this._getWordSize())}},{key:"getDefaultValue",value:function(e){var t=this,r=e.map((function(e){return t._getCoder(w.ParamType.from(e))}));return new v.TupleCoder(r,"_").defaultValue()}},{key:"encode",value:function(e,t){var r=this;e.length!==t.length&&A.throwError("types/values length mismatch",u.Logger.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});var n=e.map((function(e){return r._getCoder(w.ParamType.from(e))})),i=new v.TupleCoder(n,"_"),o=this._getWriter();return i.encode(o,t),o.data}},{key:"decode",value:function(e,t,r){var n=this,i=e.map((function(e){return n._getCoder(w.ParamType.from(e))}));return new v.TupleCoder(i,"_").decode(this._getReader((0,a.arrayify)(t),r))}}]),e}();t.AbiCoder=E;var _=new E;t.defaultAbiCoder=_},7316:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.Writer=t.Reader=t.Coder=void 0,t.checkResultErrors=function(e){var t=[];return function e(r,n){if(Array.isArray(n))for(var i in n){var o=r.slice();o.push(i);try{e(o,n[i])}catch(e){t.push({path:o,error:e})}}}([],e),t};var i=n(r(9721)),o=n(r(8985)),a=r(908),s=r(4952),u=r(3694),c=r(4327),l=r(8067),f=new c.Logger(l.version),h=function(){function e(t,r,n,o){(0,i.default)(this,e),this.name=t,this.type=r,this.localName=n,this.dynamic=o}return(0,o.default)(e,[{key:"_throwError",value:function(e,t){f.throwArgumentError(e,this.localName,t)}}]),e}();t.Coder=h;var d=function(){function e(t){(0,i.default)(this,e),(0,u.defineReadOnly)(this,"wordSize",t||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(t)}return(0,o.default)(e,[{key:"data",get:function(){return(0,a.hexConcat)(this._data)}},{key:"length",get:function(){return this._dataLength}},{key:"_writeData",value:function(e){return this._data.push(e),this._dataLength+=e.length,e.length}},{key:"appendWriter",value:function(e){return this._writeData((0,a.concat)(e._data))}},{key:"writeBytes",value:function(e){var t=(0,a.arrayify)(e),r=t.length%this.wordSize;return r&&(t=(0,a.concat)([t,this._padding.slice(r)])),this._writeData(t)}},{key:"_getValue",value:function(e){var t=(0,a.arrayify)(s.BigNumber.from(e));return t.length>this.wordSize&&f.throwError("value out-of-bounds",c.Logger.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=(0,a.concat)([this._padding.slice(t.length%this.wordSize),t])),t}},{key:"writeValue",value:function(e){return this._writeData(this._getValue(e))}},{key:"writeUpdatableValue",value:function(){var e=this,t=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,function(r){e._data[t]=e._getValue(r)}}}]),e}();t.Writer=d;var p=function(){function e(t,r,n,o){(0,i.default)(this,e),(0,u.defineReadOnly)(this,"_data",(0,a.arrayify)(t)),(0,u.defineReadOnly)(this,"wordSize",r||32),(0,u.defineReadOnly)(this,"_coerceFunc",n),(0,u.defineReadOnly)(this,"allowLoose",o),this._offset=0}return(0,o.default)(e,[{key:"data",get:function(){return(0,a.hexlify)(this._data)}},{key:"consumed",get:function(){return this._offset}},{key:"coerce",value:function(t,r){return this._coerceFunc?this._coerceFunc(t,r):e.coerce(t,r)}},{key:"_peekBytes",value:function(e,t,r){var n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:f.throwError("data out-of-bounds",c.Logger.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}},{key:"subReader",value:function(t){return new e(this._data.slice(this._offset+t),this.wordSize,this._coerceFunc,this.allowLoose)}},{key:"readBytes",value:function(e,t){var r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}},{key:"readValue",value:function(){return s.BigNumber.from(this.readBytes(this.wordSize))}}],[{key:"coerce",value:function(e,t){var r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}}]),e}();t.Reader=p},9146:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.AddressCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(7921),l=r(908),f=function(e){(0,a.default)(f,e);var t,r,n=(t=f,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function f(e){return(0,i.default)(this,f),n.call(this,"address","address",e,!1)}return(0,o.default)(f,[{key:"defaultValue",value:function(){return"0x0000000000000000000000000000000000000000"}},{key:"encode",value:function(e,t){try{t=(0,c.getAddress)(t)}catch(e){this._throwError(e.message,t)}return e.writeValue(t)}},{key:"decode",value:function(e){return(0,c.getAddress)((0,l.hexZeroPad)(e.readValue().toHexString(),20))}}]),f}(r(7316).Coder);t.AddressCoder=f},8090:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.AnonymousCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e){var t;return(0,i.default)(this,c),(t=n.call(this,e.name,e.type,void 0,e.dynamic)).coder=e,t}return(0,o.default)(c,[{key:"defaultValue",value:function(){return this.coder.defaultValue()}},{key:"encode",value:function(e,t){return this.coder.encode(e,t)}},{key:"decode",value:function(e){return this.coder.decode(e)}}]),c}(r(7316).Coder);t.AnonymousCoder=c},4341:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.ArrayCoder=void 0,t.pack=m,t.unpack=y;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=n(r(3355)),l=r(4327),f=r(8067),h=r(7316),d=r(8090),p=new l.Logger(f.version);function m(e,t,r){var n=null;if(Array.isArray(r))n=r;else if(r&&"object"===(0,c.default)(r)){var i={};n=t.map((function(e){var t=e.localName;return t||p.throwError("cannot encode object for signature with missing names",l.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),i[t]&&p.throwError("cannot encode object for signature with duplicate names",l.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),i[t]=!0,r[t]}))}else p.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&p.throwArgumentError("types/value length mismatch","tuple",r);var o=new h.Writer(e.wordSize),a=new h.Writer(e.wordSize),s=[];return t.forEach((function(e,t){var r=n[t];if(e.dynamic){var i=a.length;e.encode(a,r);var u=o.writeUpdatableValue();s.push((function(e){u(e+i)}))}else e.encode(o,r)})),s.forEach((function(e){e(o.length)})),e.appendWriter(o)+e.appendWriter(a)}function y(e,t){var r=[],n=e.subReader(0);t.forEach((function(t){var i=null;if(t.dynamic){var o=e.readValue(),a=n.subReader(o.toNumber());try{i=t.decode(a)}catch(e){if(e.code===l.Logger.errors.BUFFER_OVERRUN)throw e;(i=e).baseType=t.name,i.name=t.localName,i.type=t.type}}else try{i=t.decode(e)}catch(e){if(e.code===l.Logger.errors.BUFFER_OVERRUN)throw e;(i=e).baseType=t.name,i.name=t.localName,i.type=t.type}null!=i&&r.push(i)}));var i=t.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach((function(e,t){var n=e.localName;if(n&&1===i[n]&&("length"===n&&(n="_length"),null==r[n])){var o=r[t];o instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:function(){throw o}}):r[n]=o}}));for(var o=function(e){var t=r[e];t instanceof Error&&Object.defineProperty(r,e,{enumerable:!0,get:function(){throw t}})},a=0;a=0?t:"")+"]",s=-1===t||e.dynamic;return(o=n.call(this,"array",a,r,s)).coder=e,o.length=t,o}return(0,o.default)(c,[{key:"defaultValue",value:function(){for(var e=this.coder.defaultValue(),t=[],r=0;re._data.length&&p.throwError("insufficient data length",l.Logger.errors.BUFFER_OVERRUN,{length:e._data.length,count:t});for(var r=[],n=0;n{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.BooleanCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e){return(0,i.default)(this,c),n.call(this,"bool","bool",e,!1)}return(0,o.default)(c,[{key:"defaultValue",value:function(){return!1}},{key:"encode",value:function(e,t){return e.writeValue(t?1:0)}},{key:"decode",value:function(e){return e.coerce(this.type,!e.readValue().isZero())}}]),c}(r(7316).Coder);t.BooleanCoder=c},3861:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.DynamicBytesCoder=t.BytesCoder=void 0;var i=n(r(119)),o=n(r(9721)),a=n(r(8985)),s=n(r(5163)),u=n(r(4650)),c=n(r(1949)),l=r(908);function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,u.default)(this,r)}}var h=function(e){(0,s.default)(r,e);var t=f(r);function r(e,n){return(0,o.default)(this,r),t.call(this,e,e,n,!0)}return(0,a.default)(r,[{key:"defaultValue",value:function(){return"0x"}},{key:"encode",value:function(e,t){return t=(0,l.arrayify)(t),e.writeValue(t.length)+e.writeBytes(t)}},{key:"decode",value:function(e){return e.readBytes(e.readValue().toNumber(),!0)}}]),r}(r(7316).Coder);t.DynamicBytesCoder=h;var d=function(e){(0,s.default)(r,e);var t=f(r);function r(e){return(0,o.default)(this,r),t.call(this,"bytes",e)}return(0,a.default)(r,[{key:"decode",value:function(e){return e.coerce(this.name,(0,l.hexlify)((0,i.default)((0,c.default)(r.prototype),"decode",this).call(this,e)))}}]),r}(h);t.BytesCoder=d},28:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.FixedBytesCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(908),l=function(e){(0,a.default)(l,e);var t,r,n=(t=l,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function l(e,t){var r;(0,i.default)(this,l);var o="bytes"+String(e);return(r=n.call(this,o,o,t,!1)).size=e,r}return(0,o.default)(l,[{key:"defaultValue",value:function(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+2*this.size)}},{key:"encode",value:function(e,t){var r=(0,c.arrayify)(t);return r.length!==this.size&&this._throwError("incorrect data length",t),e.writeBytes(r)}},{key:"decode",value:function(e){return e.coerce(this.name,(0,c.hexlify)(e.readBytes(this.size)))}}]),l}(r(7316).Coder);t.FixedBytesCoder=l},4522:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.NullCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e){return(0,i.default)(this,c),n.call(this,"null","",e,!1)}return(0,o.default)(c,[{key:"defaultValue",value:function(){return null}},{key:"encode",value:function(e,t){return null!=t&&this._throwError("not null",t),e.writeBytes([])}},{key:"decode",value:function(e){return e.readBytes(0),e.coerce(this.name,null)}}]),c}(r(7316).Coder);t.NullCoder=c},8287:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.NumberCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(4952),l=r(5465),f=function(e){(0,a.default)(f,e);var t,r,n=(t=f,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function f(e,t,r){var o;(0,i.default)(this,f);var a=(t?"int":"uint")+8*e;return(o=n.call(this,a,a,r,!1)).size=e,o.signed=t,o}return(0,o.default)(f,[{key:"defaultValue",value:function(){return 0}},{key:"encode",value:function(e,t){var r=c.BigNumber.from(t),n=l.MaxUint256.mask(8*e.wordSize);if(this.signed){var i=n.mask(8*this.size-1);(r.gt(i)||r.lt(i.add(l.One).mul(l.NegativeOne)))&&this._throwError("value out-of-bounds",t)}else(r.lt(l.Zero)||r.gt(n.mask(8*this.size)))&&this._throwError("value out-of-bounds",t);return r=r.toTwos(8*this.size).mask(8*this.size),this.signed&&(r=r.fromTwos(8*this.size).toTwos(8*e.wordSize)),e.writeValue(r)}},{key:"decode",value:function(e){var t=e.readValue().mask(8*this.size);return this.signed&&(t=t.fromTwos(8*this.size)),e.coerce(this.name,t)}}]),f}(r(7316).Coder);t.NumberCoder=f},8040:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.StringCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(119)),s=n(r(5163)),u=n(r(4650)),c=n(r(1949)),l=r(8627),f=function(e){(0,s.default)(f,e);var t,r,n=(t=f,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,c.default)(t);if(r){var i=(0,c.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,u.default)(this,e)});function f(e){return(0,i.default)(this,f),n.call(this,"string",e)}return(0,o.default)(f,[{key:"defaultValue",value:function(){return""}},{key:"encode",value:function(e,t){return(0,a.default)((0,c.default)(f.prototype),"encode",this).call(this,e,(0,l.toUtf8Bytes)(t))}},{key:"decode",value:function(e){return(0,l.toUtf8String)((0,a.default)((0,c.default)(f.prototype),"decode",this).call(this,e))}}]),f}(r(3861).DynamicBytesCoder);t.StringCoder=f},2010:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.TupleCoder=void 0;var i=n(r(9721)),o=n(r(8985)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(7316),l=r(4341),f=function(e){(0,a.default)(c,e);var t,r,n=(t=c,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,n=(0,u.default)(t);if(r){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)});function c(e,t){var r;(0,i.default)(this,c);var o=!1,a=[];e.forEach((function(e){e.dynamic&&(o=!0),a.push(e.type)}));var s="tuple("+a.join(",")+")";return(r=n.call(this,"tuple",s,t,o)).coders=e,r}return(0,o.default)(c,[{key:"defaultValue",value:function(){var e=[];this.coders.forEach((function(t){e.push(t.defaultValue())}));var t=this.coders.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach((function(r,n){var i=r.localName;i&&1===t[i]&&("length"===i&&(i="_length"),null==e[i]&&(e[i]=e[n]))})),Object.freeze(e)}},{key:"encode",value:function(e,t){return(0,l.pack)(e,this.coders,t)}},{key:"decode",value:function(e){return e.coerce(this.name,(0,l.unpack)(e,this.coders))}}]),c}(c.Coder);t.TupleCoder=f},800:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.ParamType=t.FunctionFragment=t.Fragment=t.FormatTypes=t.EventFragment=t.ErrorFragment=t.ConstructorFragment=void 0;var i=n(r(5163)),o=n(r(4650)),a=n(r(1949)),s=n(r(9721)),u=n(r(8985)),c=r(4952),l=r(3694),f=r(4327),h=r(8067);function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,a.default)(e);if(t){var i=(0,a.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,o.default)(this,r)}}var p=new f.Logger(h.version),m={},y={calldata:!0,memory:!0,storage:!0},g={calldata:!0,memory:!0};function b(e,t){if("bytes"===e||"string"===e){if(y[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&g[t])return!0;return(y[t]||"payable"===t)&&p.throwArgumentError("invalid modifier","name",t),!1}function v(e,t){for(var r in t)(0,l.defineReadOnly)(e,r,t[r])}var w=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"});t.FormatTypes=w;var A=new RegExp(/^(.*)\[([0-9]*)\]$/),S=function(){function e(t,r){(0,s.default)(this,e),t!==m&&p.throwError("use fromString",f.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),v(this,r);var n=this.type.match(A);v(this,n?{arrayLength:parseInt(n[2]||"-1"),arrayChildren:e.fromObject({type:n[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}return(0,u.default)(e,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json){var t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((function(t){return JSON.parse(t.format(e))}))),JSON.stringify(t)}var r="";return"array"===this.baseType?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==w.sighash&&(r+=this.type),r+="("+this.components.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+")"):r+=this.type,e!==w.sighash&&(!0===this.indexed&&(r+=" indexed"),e===w.full&&this.name&&(r+=" "+this.name)),r}}],[{key:"from",value:function(t,r){return"string"==typeof t?e.fromString(t,r):e.fromObject(t)}},{key:"fromObject",value:function(t){return e.isParamType(t)?t:new e(m,{name:t.name||null,type:C(t.type),indexed:null==t.indexed?null:!!t.indexed,components:t.components?t.components.map(e.fromObject):null})}},{key:"fromString",value:function(t,r){return n=function(e,t){var r=e;function n(t){p.throwArgumentError("unexpected character at position ".concat(t),"param",e)}function i(e){var r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");for(var o={type:"",name:"",state:{allowType:!0}},a=o,s=0;s2&&p.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||p.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=c.BigNumber.from(r[1]),r[0]):e}function T(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((function(e){switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function x(e){var t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&p.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&p.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||p.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&p.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&p.throwArgumentError("unable to determine stateMutability","value",e),t}t.EventFragment=_;var P=function(e){(0,i.default)(r,e);var t=d(r);function r(){return(0,s.default)(this,r),t.apply(this,arguments)}return(0,u.default)(r,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});e===w.sighash&&p.throwError("cannot format a constructor for sighash",f.Logger.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});var t="constructor("+this.inputs.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}}],[{key:"from",value:function(e){return"string"==typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isConstructorFragment(e))return e;"constructor"!==e.type&&p.throwArgumentError("invalid constructor object","value",e);var t=x(e);t.constant&&p.throwArgumentError("constructor cannot be constant","value",e);var n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(S.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.BigNumber.from(e.gas):null};return new r(m,n)}},{key:"fromString",value:function(e){var t={type:"constructor"},n=(e=M(e,t)).match(L);return n&&"constructor"===n[1].trim()||p.throwArgumentError("invalid constructor string","value",e),t.inputs=k(n[2].trim(),!1),T(n[3].trim(),t),r.fromObject(t)}},{key:"isConstructorFragment",value:function(e){return e&&e._isFragment&&"constructor"===e.type}}]),r}(E);t.ConstructorFragment=P;var I=function(e){(0,i.default)(r,e);var t=d(r);function r(){return(0,s.default)(this,r),t.apply(this,arguments)}return(0,u.default)(r,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))})),outputs:this.outputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==w.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+") ",e!==w.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((function(t){return t.format(e)})).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}}],[{key:"from",value:function(e){return"string"==typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isFunctionFragment(e))return e;"function"!==e.type&&p.throwArgumentError("invalid function object","value",e);var t=x(e),n={type:e.type,name:N(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(S.fromObject):[],outputs:e.outputs?e.outputs.map(S.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.BigNumber.from(e.gas):null};return new r(m,n)}},{key:"fromString",value:function(e){var t={type:"function"},n=(e=M(e,t)).split(" returns ");n.length>2&&p.throwArgumentError("invalid function string","value",e);var i=n[0].match(L);if(i||p.throwArgumentError("invalid function signature","value",e),t.name=i[1].trim(),t.name&&N(t.name),t.inputs=k(i[2],!1),T(i[3].trim(),t),n.length>1){var o=n[1].match(L);""==o[1].trim()&&""==o[3].trim()||p.throwArgumentError("unexpected tokens","value",e),t.outputs=k(o[2],!1)}else t.outputs=[];return r.fromObject(t)}},{key:"isFunctionFragment",value:function(e){return e&&e._isFragment&&"function"===e.type}}]),r}(P);function O(e){var t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||p.throwArgumentError("cannot specify user defined ".concat(t," error"),"fragment",e),e}t.FunctionFragment=I;var R=function(e){(0,i.default)(r,e);var t=d(r);function r(){return(0,s.default)(this,r),t.apply(this,arguments)}return(0,u.default)(r,[{key:"format",value:function(e){if(e||(e=w.sighash),w[e]||p.throwArgumentError("invalid format type","format",e),e===w.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==w.sighash&&(t+="error "),(t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===w.full?", ":",")+") ").trim()}}],[{key:"from",value:function(e){return"string"==typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isErrorFragment(e))return e;"error"!==e.type&&p.throwArgumentError("invalid error object","value",e);var t={type:e.type,name:N(e.name),inputs:e.inputs?e.inputs.map(S.fromObject):[]};return O(new r(m,t))}},{key:"fromString",value:function(e){var t={type:"error"},n=e.match(L);return n||p.throwArgumentError("invalid error signature","value",e),t.name=n[1].trim(),t.name&&N(t.name),t.inputs=k(n[2],!1),O(r.fromObject(t))}},{key:"isErrorFragment",value:function(e){return e&&e._isFragment&&"error"===e.type}}]),r}(E);function C(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}t.ErrorFragment=R;var B=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function N(e){return e&&e.match(B)||p.throwArgumentError('invalid identifier "'.concat(e,'"'),"value",e),e}var L=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$")},2914:(e,t,r)=>{"use strict";Object.defineProperty(t,"RQ",{enumerable:!0,get:function(){return i.AbiCoder}}),Object.defineProperty(t,"_R",{enumerable:!0,get:function(){return n.ParamType}});var n=r(800),i=r(4937);r(9044)},9044:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionDescription=t.LogDescription=t.Interface=t.Indexed=t.ErrorDescription=void 0,Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return y.checkResultErrors}});var i=n(r(8985)),o=n(r(9721)),a=n(r(5163)),s=n(r(4650)),u=n(r(1949)),c=r(7921),l=r(4952),f=r(908),h=r(7515),d=r(4642),p=r(3694),m=r(4937),y=r(7316),g=r(800),b=r(4327),v=r(8067);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,s.default)(this,r)}}var A=new b.Logger(v.version),S=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r)}(p.Description);t.LogDescription=S;var k=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r)}(p.Description);t.TransactionDescription=k;var E=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r)}(p.Description);t.ErrorDescription=E;var _=function(e){(0,a.default)(r,e);var t=w(r);function r(){return(0,o.default)(this,r),t.apply(this,arguments)}return(0,i.default)(r,null,[{key:"isIndexed",value:function(e){return!(!e||!e._isIndexed)}}]),r}(p.Description);t.Indexed=_;var M={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function T(e,t){var r=new Error("deferred error during ABI decoding triggered accessing ".concat(e));return r.error=t,r}var x=function(){function e(t){var r=this;(0,o.default)(this,e);var n=[];n="string"==typeof t?JSON.parse(t):t,(0,p.defineReadOnly)(this,"fragments",n.map((function(e){return g.Fragment.from(e)})).filter((function(e){return null!=e}))),(0,p.defineReadOnly)(this,"_abiCoder",(0,p.getStatic)(this instanceof e?this.constructor:void 0,"getAbiCoder")()),(0,p.defineReadOnly)(this,"functions",{}),(0,p.defineReadOnly)(this,"errors",{}),(0,p.defineReadOnly)(this,"events",{}),(0,p.defineReadOnly)(this,"structs",{}),this.fragments.forEach((function(e){var t=null;switch(e.type){case"constructor":return r.deploy?void A.warn("duplicate definition - constructor"):void(0,p.defineReadOnly)(r,"deploy",e);case"function":t=r.functions;break;case"event":t=r.events;break;case"error":t=r.errors;break;default:return}var n=e.format();t[n]?A.warn("duplicate definition - "+n):t[n]=e})),this.deploy||(0,p.defineReadOnly)(this,"deploy",g.ConstructorFragment.from({payable:!1,type:"constructor"})),(0,p.defineReadOnly)(this,"_isInterface",!0)}return(0,i.default)(e,[{key:"format",value:function(e){e||(e=g.FormatTypes.full),e===g.FormatTypes.sighash&&A.throwArgumentError("interface does not support formatting sighash","format",e);var t=this.fragments.map((function(t){return t.format(e)}));return e===g.FormatTypes.json?JSON.stringify(t.map((function(e){return JSON.parse(e)}))):t}},{key:"getFunction",value:function(e){if((0,f.isHexString)(e)){for(var t in this.functions)if(e===this.getSighash(t))return this.functions[t];A.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){var r=e.trim(),n=Object.keys(this.functions).filter((function(e){return e.split("(")[0]===r}));return 0===n.length?A.throwArgumentError("no matching function","name",r):n.length>1&&A.throwArgumentError("multiple matching functions","name",r),this.functions[n[0]]}var i=this.functions[g.FunctionFragment.fromString(e).format()];return i||A.throwArgumentError("no matching function","signature",e),i}},{key:"getEvent",value:function(e){if((0,f.isHexString)(e)){var t=e.toLowerCase();for(var r in this.events)if(t===this.getEventTopic(r))return this.events[r];A.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){var n=e.trim(),i=Object.keys(this.events).filter((function(e){return e.split("(")[0]===n}));return 0===i.length?A.throwArgumentError("no matching event","name",n):i.length>1&&A.throwArgumentError("multiple matching events","name",n),this.events[i[0]]}var o=this.events[g.EventFragment.fromString(e).format()];return o||A.throwArgumentError("no matching event","signature",e),o}},{key:"getError",value:function(e){if((0,f.isHexString)(e)){var t=(0,p.getStatic)(this.constructor,"getSighash");for(var r in this.errors)if(e===t(this.errors[r]))return this.errors[r];A.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){var n=e.trim(),i=Object.keys(this.errors).filter((function(e){return e.split("(")[0]===n}));return 0===i.length?A.throwArgumentError("no matching error","name",n):i.length>1&&A.throwArgumentError("multiple matching errors","name",n),this.errors[i[0]]}var o=this.errors[g.FunctionFragment.fromString(e).format()];return o||A.throwArgumentError("no matching error","signature",e),o}},{key:"getSighash",value:function(e){if("string"==typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(e){throw t}}return(0,p.getStatic)(this.constructor,"getSighash")(e)}},{key:"getEventTopic",value:function(e){return"string"==typeof e&&(e=this.getEvent(e)),(0,p.getStatic)(this.constructor,"getEventTopic")(e)}},{key:"_decodeParams",value:function(e,t){return this._abiCoder.decode(e,t)}},{key:"_encodeParams",value:function(e,t){return this._abiCoder.encode(e,t)}},{key:"encodeDeploy",value:function(e){return this._encodeParams(this.deploy.inputs,e||[])}},{key:"decodeErrorResult",value:function(e,t){"string"==typeof e&&(e=this.getError(e));var r=(0,f.arrayify)(t);return(0,f.hexlify)(r.slice(0,4))!==this.getSighash(e)&&A.throwArgumentError("data signature does not match error ".concat(e.name,"."),"data",(0,f.hexlify)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeErrorResult",value:function(e,t){return"string"==typeof e&&(e=this.getError(e)),(0,f.hexlify)((0,f.concat)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionData",value:function(e,t){"string"==typeof e&&(e=this.getFunction(e));var r=(0,f.arrayify)(t);return(0,f.hexlify)(r.slice(0,4))!==this.getSighash(e)&&A.throwArgumentError("data signature does not match function ".concat(e.name,"."),"data",(0,f.hexlify)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeFunctionData",value:function(e,t){return"string"==typeof e&&(e=this.getFunction(e)),(0,f.hexlify)((0,f.concat)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionResult",value:function(e,t){"string"==typeof e&&(e=this.getFunction(e));var r=(0,f.arrayify)(t),n=null,i="",o=null,a=null,s=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(l){}break;case 4:var u=(0,f.hexlify)(r.slice(0,4)),c=M[u];if(c)o=this._abiCoder.decode(c.inputs,r.slice(4)),a=c.name,s=c.signature,c.reason&&(n=o[0]),"Error"===a?i="; VM Exception while processing transaction: reverted with reason string ".concat(JSON.stringify(o[0])):"Panic"===a&&(i="; VM Exception while processing transaction: reverted with panic code ".concat(o[0]));else try{var l=this.getError(u);o=this._abiCoder.decode(l.inputs,r.slice(4)),a=l.name,s=l.format()}catch(l){}}return A.throwError("call revert exception"+i,b.Logger.errors.CALL_EXCEPTION,{method:e.format(),data:(0,f.hexlify)(t),errorArgs:o,errorName:a,errorSignature:s,reason:n})}},{key:"encodeFunctionResult",value:function(e,t){return"string"==typeof e&&(e=this.getFunction(e)),(0,f.hexlify)(this._abiCoder.encode(e.outputs,t||[]))}},{key:"encodeFilterTopics",value:function(e,t){var r=this;"string"==typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&A.throwError("too many arguments for "+e.format(),b.Logger.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});var n=[];e.anonymous||n.push(this.getEventTopic(e));var i=function(e,t){return"string"===e.type?(0,h.id)(t):"bytes"===e.type?(0,d.keccak256)((0,f.hexlify)(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=l.BigNumber.from(t).toHexString()),"address"===e.type&&r._abiCoder.encode(["address"],[t]),(0,f.hexZeroPad)((0,f.hexlify)(t),32))};for(t.forEach((function(t,r){var o=e.inputs[r];o.indexed?null==t?n.push(null):"array"===o.baseType||"tuple"===o.baseType?A.throwArgumentError("filtering with tuples or arrays not supported","contract."+o.name,t):Array.isArray(t)?n.push(t.map((function(e){return i(o,e)}))):n.push(i(o,t)):null!=t&&A.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+o.name,t)}));n.length&&null===n[n.length-1];)n.pop();return n}},{key:"encodeEventLog",value:function(e,t){var r=this;"string"==typeof e&&(e=this.getEvent(e));var n=[],i=[],o=[];return e.anonymous||n.push(this.getEventTopic(e)),t.length!==e.inputs.length&&A.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach((function(e,a){var s=t[a];if(e.indexed)if("string"===e.type)n.push((0,h.id)(s));else if("bytes"===e.type)n.push((0,d.keccak256)(s));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");n.push(r._abiCoder.encode([e.type],[s]))}else i.push(e),o.push(s)})),{data:this._abiCoder.encode(i,o),topics:n}}},{key:"decodeEventLog",value:function(e,t,r){if("string"==typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){var n=this.getEventTopic(e);(0,f.isHexString)(r[0],32)&&r[0].toLowerCase()===n||A.throwError("fragment/topic mismatch",b.Logger.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:n,value:r[0]}),r=r.slice(1)}var i=[],o=[],a=[];e.inputs.forEach((function(e,t){e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(i.push(g.ParamType.fromObject({type:"bytes32",name:e.name})),a.push(!0)):(i.push(e),a.push(!1)):(o.push(e),a.push(!1))}));var s=null!=r?this._abiCoder.decode(i,(0,f.concat)(r)):null,u=this._abiCoder.decode(o,t,!0),c=[],l=0,h=0;e.inputs.forEach((function(e,t){if(e.indexed)if(null==s)c[t]=new _({_isIndexed:!0,hash:null});else if(a[t])c[t]=new _({_isIndexed:!0,hash:s[h++]});else try{c[t]=s[h++]}catch(e){c[t]=e}else try{c[t]=u[l++]}catch(e){c[t]=e}if(e.name&&null==c[e.name]){var r=c[t];r instanceof Error?Object.defineProperty(c,e.name,{enumerable:!0,get:function(){throw T("property ".concat(JSON.stringify(e.name)),r)}}):c[e.name]=r}}));for(var d=function(e){var t=c[e];t instanceof Error&&Object.defineProperty(c,e,{enumerable:!0,get:function(){throw T("index ".concat(e),t)}})},p=0;p{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="address/5.7.0"},7921:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAddress=g,t.getContractAddress=function(e){var t=null;try{t=g(e.from)}catch(t){c.throwArgumentError("missing from address","transaction",e)}var r=(0,n.stripZeros)((0,n.arrayify)(i.BigNumber.from(e.nonce).toHexString()));return g((0,n.hexDataSlice)((0,o.keccak256)((0,a.encode)([t,r])),12))},t.getCreate2Address=function(e,t,r){return 32!==(0,n.hexDataLength)(t)&&c.throwArgumentError("salt must be 32 bytes","salt",t),32!==(0,n.hexDataLength)(r)&&c.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),g((0,n.hexDataSlice)((0,o.keccak256)((0,n.concat)(["0xff",g(e),t,r])),12))},t.getIcapAddress=function(e){for(var t=(0,i._base16To36)(g(e).substring(2)).toUpperCase();t.length<30;)t="0"+t;return"XE"+y("XE00"+t)+t},t.isAddress=function(e){try{return g(e),!0}catch(e){}return!1};var n=r(908),i=r(4952),o=r(4642),a=r(5265),s=r(4327),u=r(8222),c=new s.Logger(u.version);function l(e){(0,n.isHexString)(e,20)||c.throwArgumentError("invalid address","address",e);for(var t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40),i=0;i<40;i++)r[i]=t[i].charCodeAt(0);for(var a=(0,n.arrayify)((0,o.keccak256)(r)),s=0;s<40;s+=2)a[s>>1]>>4>=8&&(t[s]=t[s].toUpperCase()),(15&a[s>>1])>=8&&(t[s+1]=t[s+1].toUpperCase());return"0x"+t.join("")}for(var f={},h=0;h<10;h++)f[String(h)]=String(h);for(var d=0;d<26;d++)f[String.fromCharCode(65+d)]=String(10+d);var p,m=Math.floor((p=9007199254740991,Math.log10?Math.log10(p):Math.log(p)/Math.LN10));function y(e){for(var t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((function(e){return f[e]})).join("");t.length>=m;){var r=t.substring(0,m);t=parseInt(r,10)%97+t.substring(r.length)}for(var n=String(98-parseInt(t,10)%97);n.length<2;)n="0"+n;return n}function g(e){var t=null;if("string"!=typeof e&&c.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=l(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&c.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==y(e)&&c.throwArgumentError("bad icap checksum","address",e),t=(0,i._base36To16)(e.substring(4));t.length<40;)t="0"+t;t=l("0x"+t)}else c.throwArgumentError("invalid address","address",e);return t}},5798:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decode=function(e){e=atob(e);for(var t=[],r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"decode",{enumerable:!0,get:function(){return n.decode}}),Object.defineProperty(t,"encode",{enumerable:!0,get:function(){return n.encode}});var n=r(5798)},3042:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="bignumber/5.7.0"},1872:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.BigNumber=void 0,t._base16To36=function(e){return new l(e,16).toString(36)},t._base36To16=function(e){return new l(e,36).toString(16)},t.isBigNumberish=function(e){return null!=e&&(m.isBigNumber(e)||"number"==typeof e&&e%1==0||"string"==typeof e&&!!e.match(/^-?[0-9]+$/)||(0,s.isHexString)(e)||"bigint"==typeof e||(0,s.isBytes)(e))};var i=n(r(9721)),o=n(r(8985)),a=n(r(1734)),s=r(908),u=r(4327),c=r(3042),l=a.default.BN,f=new u.Logger(c.version),h={},d=9007199254740991,p=!1,m=function(){function e(t,r){(0,i.default)(this,e),t!==h&&f.throwError("cannot call constructor directly; use BigNumber.from",u.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=r,this._isBigNumber=!0,Object.freeze(this)}return(0,o.default)(e,[{key:"fromTwos",value:function(e){return g(b(this).fromTwos(e))}},{key:"toTwos",value:function(e){return g(b(this).toTwos(e))}},{key:"abs",value:function(){return"-"===this._hex[0]?e.from(this._hex.substring(1)):this}},{key:"add",value:function(e){return g(b(this).add(b(e)))}},{key:"sub",value:function(e){return g(b(this).sub(b(e)))}},{key:"div",value:function(t){return e.from(t).isZero()&&v("division-by-zero","div"),g(b(this).div(b(t)))}},{key:"mul",value:function(e){return g(b(this).mul(b(e)))}},{key:"mod",value:function(e){var t=b(e);return t.isNeg()&&v("division-by-zero","mod"),g(b(this).umod(t))}},{key:"pow",value:function(e){var t=b(e);return t.isNeg()&&v("negative-power","pow"),g(b(this).pow(t))}},{key:"and",value:function(e){var t=b(e);return(this.isNegative()||t.isNeg())&&v("unbound-bitwise-result","and"),g(b(this).and(t))}},{key:"or",value:function(e){var t=b(e);return(this.isNegative()||t.isNeg())&&v("unbound-bitwise-result","or"),g(b(this).or(t))}},{key:"xor",value:function(e){var t=b(e);return(this.isNegative()||t.isNeg())&&v("unbound-bitwise-result","xor"),g(b(this).xor(t))}},{key:"mask",value:function(e){return(this.isNegative()||e<0)&&v("negative-width","mask"),g(b(this).maskn(e))}},{key:"shl",value:function(e){return(this.isNegative()||e<0)&&v("negative-width","shl"),g(b(this).shln(e))}},{key:"shr",value:function(e){return(this.isNegative()||e<0)&&v("negative-width","shr"),g(b(this).shrn(e))}},{key:"eq",value:function(e){return b(this).eq(b(e))}},{key:"lt",value:function(e){return b(this).lt(b(e))}},{key:"lte",value:function(e){return b(this).lte(b(e))}},{key:"gt",value:function(e){return b(this).gt(b(e))}},{key:"gte",value:function(e){return b(this).gte(b(e))}},{key:"isNegative",value:function(){return"-"===this._hex[0]}},{key:"isZero",value:function(){return b(this).isZero()}},{key:"toNumber",value:function(){try{return b(this).toNumber()}catch(e){v("overflow","toNumber",this.toString())}return null}},{key:"toBigInt",value:function(){try{return BigInt(this.toString())}catch(e){}return f.throwError("this platform does not support BigInt",u.Logger.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}},{key:"toString",value:function(){return arguments.length>0&&(10===arguments[0]?p||(p=!0,f.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?f.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",u.Logger.errors.UNEXPECTED_ARGUMENT,{}):f.throwError("BigNumber.toString does not accept parameters",u.Logger.errors.UNEXPECTED_ARGUMENT,{})),b(this).toString(10)}},{key:"toHexString",value:function(){return this._hex}},{key:"toJSON",value:function(e){return{type:"BigNumber",hex:this.toHexString()}}}],[{key:"from",value:function(t){if(t instanceof e)return t;if("string"==typeof t)return t.match(/^-?0x[0-9a-f]+$/i)?new e(h,y(t)):t.match(/^-?[0-9]+$/)?new e(h,y(new l(t))):f.throwArgumentError("invalid BigNumber string","value",t);if("number"==typeof t)return t%1&&v("underflow","BigNumber.from",t),(t>=d||t<=-d)&&v("overflow","BigNumber.from",t),e.from(String(t));var r=t;if("bigint"==typeof r)return e.from(r.toString());if((0,s.isBytes)(r))return e.from((0,s.hexlify)(r));if(r)if(r.toHexString){var n=r.toHexString();if("string"==typeof n)return e.from(n)}else{var i=r._hex;if(null==i&&"BigNumber"===r.type&&(i=r.hex),"string"==typeof i&&((0,s.isHexString)(i)||"-"===i[0]&&(0,s.isHexString)(i.substring(1))))return e.from(i)}return f.throwArgumentError("invalid BigNumber value","value",t)}},{key:"isBigNumber",value:function(e){return!(!e||!e._isBigNumber)}}]),e}();function y(e){if("string"!=typeof e)return y(e.toString(16));if("-"===e[0])return"-"===(e=e.substring(1))[0]&&f.throwArgumentError("invalid hex","value",e),"0x00"===(e=y(e))?e:"-"+e;if("0x"!==e.substring(0,2)&&(e="0x"+e),"0x"===e)return"0x00";for(e.length%2&&(e="0x0"+e.substring(2));e.length>4&&"0x00"===e.substring(0,4);)e="0x"+e.substring(4);return e}function g(e){return m.from(y(e))}function b(e){var t=m.from(e).toHexString();return"-"===t[0]?new l("-"+t.substring(3),16):new l(t.substring(2),16)}function v(e,t,r){var n={fault:e,operation:t};return null!=r&&(n.value=r),f.throwError(e,u.Logger.errors.NUMERIC_FAULT,n)}t.BigNumber=m},8390:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.FixedNumber=t.FixedFormat=void 0,t.formatFixed=b,t.parseFixed=v;var i=n(r(3355)),o=n(r(9721)),a=n(r(8985)),s=r(908),u=r(4327),c=r(3042),l=r(1872),f=new u.Logger(c.version),h={},d=l.BigNumber.from(0),p=l.BigNumber.from(-1);function m(e,t,r,n){var i={fault:t,operation:r};return void 0!==n&&(i.value=n),f.throwError(e,u.Logger.errors.NUMERIC_FAULT,i)}for(var y="0";y.length<256;)y+=y;function g(e){if("number"!=typeof e)try{e=l.BigNumber.from(e).toNumber()}catch(e){}return"number"==typeof e&&e>=0&&e<=256&&!(e%1)?"1"+y.substring(0,e):f.throwArgumentError("invalid decimal size","decimals",e)}function b(e,t){null==t&&(t=0);var r=g(t),n=(e=l.BigNumber.from(e)).lt(d);n&&(e=e.mul(p));for(var i=e.mod(r).toString();i.length2&&f.throwArgumentError("too many decimal points","value",e);var o=i[0],a=i[1];for(o||(o="0"),a||(a="0");"0"===a[a.length-1];)a=a.substring(0,a.length-1);for(a.length>r.length-1&&m("fractional component exceeds decimals","underflow","parseFixed"),""===a&&(a="0");a.length80&&f.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",o),new e(h,r,n,o)}}]),e}();t.FixedFormat=w;var A=function(){function e(t,r,n,i){(0,o.default)(this,e),t!==h&&f.throwError("cannot use FixedNumber constructor; use FixedNumber.from",u.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=i,this._hex=r,this._value=n,this._isFixedNumber=!0,Object.freeze(this)}return(0,a.default)(e,[{key:"_checkFormat",value:function(e){this.format.name!==e.format.name&&f.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}},{key:"addUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.add(n),this.format.decimals,this.format)}},{key:"subUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.sub(n),this.format.decimals,this.format)}},{key:"mulUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(n).div(this.format._multiplier),this.format.decimals,this.format)}},{key:"divUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(this.format._multiplier).div(n),this.format.decimals,this.format)}},{key:"floor",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return this.isNegative()&&n&&(r=r.subUnsafe(S.toFormat(r.format))),r}},{key:"ceiling",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return!this.isNegative()&&n&&(r=r.addUnsafe(S.toFormat(r.format))),r}},{key:"round",value:function(t){null==t&&(t=0);var r=this.toString().split(".");if(1===r.length&&r.push("0"),(t<0||t>80||t%1)&&f.throwArgumentError("invalid decimal count","decimals",t),r[1].length<=t)return this;var n=e.from("1"+y.substring(0,t),this.format),i=k.toFormat(this.format);return this.mulUnsafe(n).addUnsafe(i).floor().divUnsafe(n)}},{key:"isZero",value:function(){return"0.0"===this._value||"0"===this._value}},{key:"isNegative",value:function(){return"-"===this._value[0]}},{key:"toString",value:function(){return this._value}},{key:"toHexString",value:function(e){if(null==e)return this._hex;e%8&&f.throwArgumentError("invalid byte width","width",e);var t=l.BigNumber.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString();return(0,s.hexZeroPad)(t,e/8)}},{key:"toUnsafeFloat",value:function(){return parseFloat(this.toString())}},{key:"toFormat",value:function(t){return e.fromString(this._value,t)}}],[{key:"fromValue",value:function(t,r,n){return null!=n||null==r||(0,l.isBigNumberish)(r)||(n=r,r=null),null==r&&(r=0),null==n&&(n="fixed"),e.fromString(b(t,r),w.from(n))}},{key:"fromString",value:function(t,r){null==r&&(r="fixed");var n=w.from(r),i=v(t,n.decimals);!n.signed&&i.lt(d)&&m("unsigned value cannot be negative","overflow","value",t);var o=null;n.signed?o=i.toTwos(n.width).toHexString():(o=i.toHexString(),o=(0,s.hexZeroPad)(o,n.width/8));var a=b(i,n.decimals);return new e(h,o,a,n)}},{key:"fromBytes",value:function(t,r){null==r&&(r="fixed");var n=w.from(r);if((0,s.arrayify)(t).length>n.width/8)throw new Error("overflow");var i=l.BigNumber.from(t);n.signed&&(i=i.fromTwos(n.width));var o=i.toTwos((n.signed?0:1)+n.width).toHexString(),a=b(i,n.decimals);return new e(h,o,a,n)}},{key:"from",value:function(t,r){if("string"==typeof t)return e.fromString(t,r);if((0,s.isBytes)(t))return e.fromBytes(t,r);try{return e.fromValue(t,0,r)}catch(e){if(e.code!==u.Logger.errors.INVALID_ARGUMENT)throw e}return f.throwArgumentError("invalid FixedNumber value","value",t)}},{key:"isFixedNumber",value:function(e){return!(!e||!e._isFixedNumber)}}]),e}();t.FixedNumber=A;var S=A.from(1),k=A.from("0.5")},4952:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"BigNumber",{enumerable:!0,get:function(){return n.BigNumber}}),Object.defineProperty(t,"FixedFormat",{enumerable:!0,get:function(){return i.FixedFormat}}),Object.defineProperty(t,"FixedNumber",{enumerable:!0,get:function(){return i.FixedNumber}}),Object.defineProperty(t,"_base16To36",{enumerable:!0,get:function(){return n._base16To36}}),Object.defineProperty(t,"_base36To16",{enumerable:!0,get:function(){return n._base36To16}}),Object.defineProperty(t,"formatFixed",{enumerable:!0,get:function(){return i.formatFixed}}),Object.defineProperty(t,"parseFixed",{enumerable:!0,get:function(){return i.parseFixed}});var n=r(1872),i=r(8390)},8729:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="bytes/5.7.0"},908:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.arrayify=f,t.concat=h,t.hexConcat=function(e){var t="0x";return e.forEach((function(e){t+=y(e).substring(2)})),t},t.hexDataLength=function(e){if("string"!=typeof e)e=y(e);else if(!p(e)||e.length%2)return null;return(e.length-2)/2},t.hexDataSlice=function(e,t,r){return"string"!=typeof e?e=y(e):(!p(e)||e.length%2)&&o.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)},t.hexStripZeros=g,t.hexValue=function(e){var t=g(y(e,{hexPad:"left"}));return"0x"===t?"0x0":t},t.hexZeroPad=b,t.hexlify=y,t.isBytes=l,t.isBytesLike=u,t.isHexString=p,t.joinSignature=function(e){return y(h([(e=v(e)).r,e.s,e.recoveryParam?"0x1c":"0x1b"]))},t.splitSignature=v,t.stripZeros=function(e){var t=f(e);if(0===t.length)return t;for(var r=0;r=256)return!1}return!0}function f(e,t){if(t||(t={}),"number"==typeof e){o.checkSafeUint53(e,"invalid arrayify value");for(var r=[];e;)r.unshift(255&e),e=parseInt(String(e/256));return 0===r.length&&r.push(0),s(new Uint8Array(r))}if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e)&&(e=e.toHexString()),p(e)){var n=e.substring(2);n.length%2&&("left"===t.hexPad?n="0"+n:"right"===t.hexPad?n+="0":o.throwArgumentError("hex data is odd-length","value",e));for(var i=[],u=0;ut&&o.throwArgumentError("value out of range","value",arguments[0]);var r=new Uint8Array(t);return r.set(e,t-e.length),s(r)}function p(e,t){return!("string"!=typeof e||!e.match(/^0x[0-9A-Fa-f]*$/)||t&&e.length!==2+2*t)}var m="0123456789abcdef";function y(e,t){if(t||(t={}),"number"==typeof e){o.checkSafeUint53(e,"invalid hexlify value");for(var r="";e;)r=m[15&e]+r,e=Math.floor(e/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if("bigint"==typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e))return e.toHexString();if(p(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":o.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(l(e)){for(var n="0x",i=0;i>4]+m[15&s]}return n}return o.throwArgumentError("invalid hexlify value","value",e)}function g(e){"string"!=typeof e&&(e=y(e)),p(e)||o.throwArgumentError("invalid hex string","value",e),e=e.substring(2);for(var t=0;t2*t+2&&o.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function v(e){var t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(u(e)){var r=f(e);64===r.length?(t.v=27+(r[32]>>7),r[32]&=127,t.r=y(r.slice(0,32)),t.s=y(r.slice(32,64))):65===r.length?(t.r=y(r.slice(0,32)),t.s=y(r.slice(32,64)),t.v=r[64]):o.throwArgumentError("invalid signature string","signature",e),t.v<27&&(0===t.v||1===t.v?t.v+=27:o.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=y(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){var n=d(f(t._vs),32);t._vs=y(n);var i=n[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=i:t.recoveryParam!==i&&o.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),n[0]&=127;var a=y(n);null==t.s?t.s=a:t.s!==a&&o.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?o.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{var s=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==s&&o.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&p(t.r)?t.r=b(t.r,32):o.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&p(t.s)?t.s=b(t.s,32):o.throwArgumentError("signature missing or invalid s","signature",e);var c=f(t.s);c[0]>=128&&o.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(c[0]|=128);var l=y(c);t._vs&&(p(t._vs)||o.throwArgumentError("signature invalid _vs","signature",e),t._vs=b(t._vs,32)),null==t._vs?t._vs=l:t._vs!==l&&o.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t.yParityAndS=t._vs,t.compact=t.r+t.yParityAndS.substring(2),t}},8721:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AddressZero=void 0,t.AddressZero="0x0000000000000000000000000000000000000000"},2997:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Zero=t.WeiPerEther=t.Two=t.One=t.NegativeOne=t.MinInt256=t.MaxUint256=t.MaxInt256=void 0;var n=r(4952),i=n.BigNumber.from(-1);t.NegativeOne=i;var o=n.BigNumber.from(0);t.Zero=o;var a=n.BigNumber.from(1);t.One=a;var s=n.BigNumber.from(2);t.Two=s;var u=n.BigNumber.from("1000000000000000000");t.WeiPerEther=u;var c=n.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");t.MaxUint256=c;var l=n.BigNumber.from("-0x8000000000000000000000000000000000000000000000000000000000000000");t.MinInt256=l;var f=n.BigNumber.from("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");t.MaxInt256=f},396:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.HashZero=void 0,t.HashZero="0x0000000000000000000000000000000000000000000000000000000000000000"},5465:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AddressZero",{enumerable:!0,get:function(){return n.AddressZero}}),Object.defineProperty(t,"EtherSymbol",{enumerable:!0,get:function(){return a.EtherSymbol}}),Object.defineProperty(t,"HashZero",{enumerable:!0,get:function(){return o.HashZero}}),Object.defineProperty(t,"MaxInt256",{enumerable:!0,get:function(){return i.MaxInt256}}),Object.defineProperty(t,"MaxUint256",{enumerable:!0,get:function(){return i.MaxUint256}}),Object.defineProperty(t,"MinInt256",{enumerable:!0,get:function(){return i.MinInt256}}),Object.defineProperty(t,"NegativeOne",{enumerable:!0,get:function(){return i.NegativeOne}}),Object.defineProperty(t,"One",{enumerable:!0,get:function(){return i.One}}),Object.defineProperty(t,"Two",{enumerable:!0,get:function(){return i.Two}}),Object.defineProperty(t,"WeiPerEther",{enumerable:!0,get:function(){return i.WeiPerEther}}),Object.defineProperty(t,"Zero",{enumerable:!0,get:function(){return i.Zero}});var n=r(8721),i=r(2997),o=r(396),a=r(8347)},8347:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EtherSymbol=void 0,t.EtherSymbol="Ξ"},3989:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="hash/5.7.0"},3731:(e,t)=>{"use strict";function r(e,t){null==t&&(t=1);var r=[],n=r.forEach;return function e(t,i){n.call(t,(function(t){i>0&&Array.isArray(t)?e(t,i-1):r.push(t)}))}(e,t),r}function n(e){var t=0;function r(){return e[t++]<<8|e[t++]}for(var n=r(),i=1,o=[0,1],a=1;a>--c&1}for(var h=Math.pow(2,31),d=h>>>1,p=d>>1,m=h-1,y=0,g=0;g<31;g++)y=y<<1|f();for(var b=[],v=0,w=h;;){for(var A=Math.floor(((y-v+1)*i-1)/w),S=0,k=n;k-S>1;){var E=S+k>>>1;A>>1|f(),_=_<<1^d,M=(M^d)<<1|d|1;v=_,w=1+M-_}var T=n-4;return b.map((function(t){switch(t-T){case 3:return T+65792+(e[u++]<<16|e[u++]<<8|e[u++]);case 2:return T+256+(e[u++]<<8|e[u++]);case 1:return T+e[u++];default:return t-1}}))}function i(e){var t=0;return function(){return e[t++]}}function o(e){return 1&e?~e>>1:e>>1}function a(e,t){for(var r=Array(e),n=0,i=-1;n>=1),check:2==o}}()},t.read_mapped_map=function(e){for(var t=[];;){var n=e();if(0==n)break;t.push(f(n,e))}for(;;){var i=e()-1;if(i<0)break;t.push(h(i,e))}return function(e){for(var t={},r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getData=function(){return(0,i.read_compressed_payload)((0,n.decode)("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA=="))};var n=r(997),i=r(3731)},7032:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.ens_normalize=function(e){return y(function(e,t){for(var r=p(e).reverse(),n=[];r.length;){var o=g(r);if(o)n.push.apply(n,(0,i.default)(t(o)));else{var a=r.pop();if(l.has(a))n.push(a);else if(!f.has(a)){var s=h[a];if(!s)throw new Error("Disallowed codepoint: 0x".concat(a.toString(16).toUpperCase()));n.push.apply(n,(0,i.default)(s))}}}return y(String.fromCodePoint.apply(String,n).normalize("NFC"))}(e,m))},t.ens_normalize_post_check=y;var i=n(r(3106)),o=r(8627),a=r(3961),s=r(3731);function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}(e.split("."));try{for(r.s();!(t=r.n()).done;){var n=t.value,i=p(n);try{for(var o=i.lastIndexOf(95)-1;o>=0;o--)if(95!==i[o])throw new Error("underscore only allowed at start");if(i.length>=4&&i.every((function(e){return e<128}))&&45===i[2]&&45===i[3])throw new Error("invalid label extension")}catch(e){throw new Error('Invalid label "'.concat(n,'": ').concat(e.message))}}}catch(e){r.e(e)}finally{r.f()}return e}function g(e,t){var r,n,o,a=d,s=[],u=e.length;t&&(t.length=0);for(var c=function(){var c=e[--u];if(!(a=null===(r=a.branches.find((function(e){return e.set.has(c)})))||void 0===r?void 0:r.node))return"break";if(a.save)o=c;else if(a.check&&c===o)return"break";s.push(c),a.fe0f&&(s.push(65039),u>0&&65039==e[u-1]&&u--),a.valid&&(n=s.slice(),2==a.valid&&n.splice(1,1),t&&t.push.apply(t,(0,i.default)(e.slice(u).reverse())),e.length=u)};u&&"break"!==c(););return n}},7901:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.id=function(e){return(0,n.keccak256)((0,i.toUtf8Bytes)(e))};var n=r(4642),i=r(8627)},7515:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"_TypedDataEncoder",{enumerable:!0,get:function(){return a.TypedDataEncoder}}),Object.defineProperty(t,"dnsEncode",{enumerable:!0,get:function(){return i.dnsEncode}}),Object.defineProperty(t,"ensNormalize",{enumerable:!0,get:function(){return i.ensNormalize}}),Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return o.hashMessage}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return n.id}}),Object.defineProperty(t,"isValidName",{enumerable:!0,get:function(){return i.isValidName}}),Object.defineProperty(t,"messagePrefix",{enumerable:!0,get:function(){return o.messagePrefix}}),Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return i.namehash}});var n=r(7901),i=r(4898),o=r(4443),a=r(2171)},4443:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hashMessage=function(e){return"string"==typeof e&&(e=(0,o.toUtf8Bytes)(e)),(0,i.keccak256)((0,n.concat)([(0,o.toUtf8Bytes)(a),(0,o.toUtf8Bytes)(String(e.length)),e]))},t.messagePrefix=void 0;var n=r(908),i=r(4642),o=r(8627),a="Ethereum Signed Message:\n";t.messagePrefix=a},4898:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dnsEncode=function(e){return(0,n.hexlify)((0,n.concat)(h(e).map((function(e){if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");var t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"},t.ensNormalize=function(e){return h(e).map((function(e){return(0,i.toUtf8String)(e)})).join(".")},t.isValidName=function(e){try{return 0!==h(e).length}catch(e){}return!1},t.namehash=function(e){"string"!=typeof e&&c.throwArgumentError("invalid ENS name; not a string","name",e);for(var t=l,r=h(e);r.length;)t=(0,o.keccak256)((0,n.concat)([t,(0,o.keccak256)(r.pop())]));return(0,n.hexlify)(t)};var n=r(908),i=r(8627),o=r(4642),a=r(4327),s=r(3989),u=r(7032),c=new a.Logger(s.version),l=new Uint8Array(32);function f(e){if(0===e.length)throw new Error("invalid ENS name; empty component");return e}function h(e){var t=(0,i.toUtf8Bytes)((0,u.ens_normalize)(e)),r=[];if(0===e.length)return r;for(var n=0,o=0;o=t.length)throw new Error("invalid ENS name; empty component");return r.push(f(t.slice(n))),r}l.fill(0)},2171:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.TypedDataEncoder=void 0;var i=n(r(2247)),o=n(r(9721)),a=n(r(8985)),s=r(7921),u=r(4952),c=r(908),l=r(4642),f=r(3694),h=r(4327),d=r(3989),p=r(7901),m=new h.Logger(d.version),y=new Uint8Array(32);y.fill(0);var g=u.BigNumber.from(-1),b=u.BigNumber.from(0),v=u.BigNumber.from(1),w=u.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),A=(0,c.hexZeroPad)(v.toHexString(),32),S=(0,c.hexZeroPad)(b.toHexString(),32),k={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},E=["name","version","chainId","verifyingContract","salt"];function _(e){return function(t){return"string"!=typeof t&&m.throwArgumentError("invalid domain value for ".concat(JSON.stringify(e)),"domain.".concat(e),t),t}}var M={name:_("name"),version:_("version"),chainId:function(e){try{return u.BigNumber.from(e).toString()}catch(e){}return m.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",e)},verifyingContract:function(e){try{return(0,s.getAddress)(e).toLowerCase()}catch(e){}return m.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){try{var t=(0,c.arrayify)(e);if(32!==t.length)throw new Error("bad length");return(0,c.hexlify)(t)}catch(e){}return m.throwArgumentError('invalid domain value "salt"',"domain.salt",e)}};function T(e){var t=e.match(/^(u?)int(\d*)$/);if(t){var r=""===t[1],n=parseInt(t[2]||"256");(n%8!=0||n>256||t[2]&&t[2]!==String(n))&&m.throwArgumentError("invalid numeric width","type",e);var i=w.mask(r?n-1:n),o=r?i.add(v).mul(g):b;return function(t){var r=u.BigNumber.from(t);return(r.lt(o)||r.gt(i))&&m.throwArgumentError("value out-of-bounds for ".concat(e),"value",t),(0,c.hexZeroPad)(r.toTwos(256).toHexString(),32)}}var a=e.match(/^bytes(\d+)$/);if(a){var f=parseInt(a[1]);return(0===f||f>32||a[1]!==String(f))&&m.throwArgumentError("invalid bytes width","type",e),function(t){return(0,c.arrayify)(t).length!==f&&m.throwArgumentError("invalid length for ".concat(e),"value",t),function(e){var t=(0,c.arrayify)(e),r=t.length%32;return r?(0,c.hexConcat)([t,y.slice(r)]):(0,c.hexlify)(t)}(t)}}switch(e){case"address":return function(e){return(0,c.hexZeroPad)((0,s.getAddress)(e),32)};case"bool":return function(e){return e?A:S};case"bytes":return function(e){return(0,l.keccak256)(e)};case"string":return function(e){return(0,p.id)(e)}}return null}function x(e,t){return"".concat(e,"(").concat(t.map((function(e){var t=e.name;return e.type+" "+t})).join(","),")")}var P=function(){function e(t){(0,o.default)(this,e),(0,f.defineReadOnly)(this,"types",Object.freeze((0,f.deepCopy)(t))),(0,f.defineReadOnly)(this,"_encoderCache",{}),(0,f.defineReadOnly)(this,"_types",{});var r={},n={},i={};Object.keys(t).forEach((function(e){r[e]={},n[e]=[],i[e]={}}));var a=function(e){var i={};t[e].forEach((function(o){i[o.name]&&m.throwArgumentError("duplicate variable name ".concat(JSON.stringify(o.name)," in ").concat(JSON.stringify(e)),"types",t),i[o.name]=!0;var a=o.type.match(/^([^\x5b]*)(\x5b|$)/)[1];a===e&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(a)),"types",t),T(a)||(n[a]||m.throwArgumentError("unknown type ".concat(JSON.stringify(a)),"types",t),n[a].push(e),r[e][a]=!0)}))};for(var s in t)a(s);var u=Object.keys(n).filter((function(e){return 0===n[e].length}));for(var c in 0===u.length?m.throwArgumentError("missing primary type","types",t):u.length>1&&m.throwArgumentError("ambiguous primary types or unused types: ".concat(u.map((function(e){return JSON.stringify(e)})).join(", ")),"types",t),(0,f.defineReadOnly)(this,"primaryType",u[0]),function e(o,a){a[o]&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(o)),"types",t),a[o]=!0,Object.keys(r[o]).forEach((function(t){n[t]&&(e(t,a),Object.keys(a).forEach((function(e){i[e][t]=!0})))})),delete a[o]}(this.primaryType,{}),i){var l=Object.keys(i[c]);l.sort(),this._types[c]=x(c,t[c])+l.map((function(e){return x(e,t[e])})).join("")}}return(0,a.default)(e,[{key:"getEncoder",value:function(e){var t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}},{key:"_getEncoder",value:function(e){var t=this,r=T(e);if(r)return r;var n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){var i=n[1],o=this.getEncoder(i),a=parseInt(n[3]);return function(e){a>=0&&e.length!==a&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",e);var r=e.map(o);return t._types[i]&&(r=r.map(l.keccak256)),(0,l.keccak256)((0,c.hexConcat)(r))}}var s=this.types[e];if(s){var u=(0,p.id)(this._types[e]);return function(e){var r=s.map((function(r){var n=r.name,i=r.type,o=t.getEncoder(i)(e[n]);return t._types[i]?(0,l.keccak256)(o):o}));return r.unshift(u),(0,c.hexConcat)(r)}}return m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"encodeType",value:function(e){var t=this._types[e];return t||m.throwArgumentError("unknown type: ".concat(JSON.stringify(e)),"name",e),t}},{key:"encodeData",value:function(e,t){return this.getEncoder(e)(t)}},{key:"hashStruct",value:function(e,t){return(0,l.keccak256)(this.encodeData(e,t))}},{key:"encode",value:function(e){return this.encodeData(this.primaryType,e)}},{key:"hash",value:function(e){return this.hashStruct(this.primaryType,e)}},{key:"_visit",value:function(e,t,r){var n=this;if(T(e))return r(e,t);var i=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(i){var o=i[1],a=parseInt(i[3]);return a>=0&&t.length!==a&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((function(e){return n._visit(o,e,r)}))}var s=this.types[e];return s?s.reduce((function(e,i){var o=i.name,a=i.type;return e[o]=n._visit(a,t[o],r),e}),{}):m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"visit",value:function(e,t){return this._visit(this.primaryType,e,t)}}],[{key:"from",value:function(t){return new e(t)}},{key:"getPrimaryType",value:function(t){return e.from(t).primaryType}},{key:"hashStruct",value:function(t,r,n){return e.from(r).hashStruct(t,n)}},{key:"hashDomain",value:function(t){var r=[];for(var n in t){var i=k[n];i||m.throwArgumentError("invalid typed-data domain key: ".concat(JSON.stringify(n)),"domain",t),r.push({name:n,type:i})}return r.sort((function(e,t){return E.indexOf(e.name)-E.indexOf(t.name)})),e.hashStruct("EIP712Domain",{EIP712Domain:r},t)}},{key:"encode",value:function(t,r,n){return(0,c.hexConcat)(["0x1901",e.hashDomain(t),e.from(r).hash(n)])}},{key:"hash",value:function(t,r,n){return(0,l.keccak256)(e.encode(t,r,n))}},{key:"resolveNames",value:function(t,r,n,o){return a=this,s=void 0,u=i.default.mark((function a(){var s,u,l;return i.default.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:t=(0,f.shallowCopy)(t),s={},t.verifyingContract&&!(0,c.isHexString)(t.verifyingContract,20)&&(s[t.verifyingContract]="0x"),(u=e.from(r)).visit(n,(function(e,t){return"address"!==e||(0,c.isHexString)(t,20)||(s[t]="0x"),t})),a.t0=i.default.keys(s);case 6:if((a.t1=a.t0()).done){a.next=13;break}return l=a.t1.value,a.next=10,o(l);case 10:s[l]=a.sent,a.next=6;break;case 13:return t.verifyingContract&&s[t.verifyingContract]&&(t.verifyingContract=s[t.verifyingContract]),n=u.visit(n,(function(e,t){return"address"===e&&s[t]?s[t]:t})),a.abrupt("return",{domain:t,value:n});case 16:case"end":return a.stop()}}),a)})),new(s||(s=Promise))((function(e,t){function r(e){try{i(u.next(e))}catch(e){t(e)}}function n(e){try{i(u.throw(e))}catch(e){t(e)}}function i(t){var i;t.done?e(t.value):(i=t.value,i instanceof s?i:new s((function(e){e(i)}))).then(r,n)}i((u=u.apply(a,[])).next())}));var a,s,u}},{key:"getPayload",value:function(t,r,n){e.hashDomain(t);var i={},o=[];E.forEach((function(e){var r=t[e];null!=r&&(i[e]=M[e](r),o.push({name:e,type:k[e]}))}));var a=e.from(r),s=(0,f.shallowCopy)(r);return s.EIP712Domain?m.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",r):s.EIP712Domain=o,a.encode(n),{types:s,domain:i,primaryType:a.primaryType,message:a.visit(n,(function(e,t){if(e.match(/^bytes(\d*)/))return(0,c.hexlify)((0,c.arrayify)(t));if(e.match(/^u?int/))return u.BigNumber.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!=typeof t&&m.throwArgumentError("invalid string","value",t),t}return m.throwArgumentError("unsupported type","type",e)}))}}}]),e}();t.TypedDataEncoder=P},4642:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.keccak256=function(e){return"0x"+i.default.keccak_256((0,o.arrayify)(e))};var i=n(r(5975)),o=r(908)},5975:(e,t,r)=>{"use strict";e=r.nmd(e);var n,i=r(9142),o=r(8847)(r(3355));!function(){var a="input is invalid type",s="object"===("undefined"==typeof window?"undefined":(0,o.default)(window)),u=s?window:{};u.JS_SHA3_NO_WINDOW&&(s=!1);var c=!s&&"object"===("undefined"==typeof self?"undefined":(0,o.default)(self));!u.JS_SHA3_NO_NODE_JS&&"object"===(void 0===i?"undefined":(0,o.default)(i))&&i.versions&&i.versions.node?u=r.g:c&&(u=self);var l=!u.JS_SHA3_NO_COMMON_JS&&"object"===(0,o.default)(e)&&e.exports,f=r.amdO,h=!u.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,d="0123456789abcdef".split(""),p=[4,1024,262144,67108864],m=[0,8,16,24],y=[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],g=[224,256,384,512],b=[128,256],v=["hex","buffer","arrayBuffer","array","digest"],w={128:168,256:136};!u.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!h||!u.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===(0,o.default)(e)&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var A=function(e,t,r){return function(n){return new L(e,t,e).update(n)[r]()}},S=function(e,t,r){return function(n,i){return new L(e,t,i).update(n)[r]()}},k=function(e,t,r){return function(t,n,i,o){return x["cshake"+e].update(t,n,i,o)[r]()}},E=function(e,t,r){return function(t,n,i,o){return x["kmac"+e].update(t,n,i,o)[r]()}},_=function(e,t,r,n){for(var i=0;i>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function U(e,t,r){L.call(this,e,t,r)}L.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}for(var n,i,s=this.blocks,u=this.byteCount,c=e.length,l=this.blockCount,f=0,d=this.s;f>2]|=e[f]<>2]|=i<>2]|=(192|i>>6)<>2]|=(128|63&i)<=57344?(s[n>>2]|=(224|i>>12)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<>2]|=(240|i>>18)<>2]|=(128|i>>12&63)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<=u){for(this.start=n-u,this.block=s[l],n=0;n>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},L.prototype.encodeString=function(e){var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}var n=0,i=e.length;if(t)n=i;else for(var s=0;s=57344?n+=3:(u=65536+((1023&u)<<10|1023&e.charCodeAt(++s)),n+=4)}return n+=this.encode(8*n),this.update(e),n},L.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+d[15&e]+d[e>>12&15]+d[e>>8&15]+d[e>>20&15]+d[e>>16&15]+d[e>>28&15]+d[e>>24&15];a%t==0&&(F(r),o=0)}return i&&(e=r[o],s+=d[e>>4&15]+d[15&e],i>1&&(s+=d[e>>12&15]+d[e>>8&15]),i>2&&(s+=d[e>>20&15]+d[e>>16&15])),s},L.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&F(n)}return o&&(e=s<<2,t=n[a],u[e]=255&t,o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u},U.prototype=new L,U.prototype.finalize=function(){return this.encode(this.outputBits,!0),L.prototype.finalize.call(this)};var F=function(e){var t,r,n,i,o,a,s,u,c,l,f,h,d,p,m,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],u=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],l=e[6]^e[16]^e[26]^e[36]^e[46],f=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(d=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|c>>>31),r=o^(c<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(l<<1|f>>>31),r=s^(f<<1|l>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(h<<1|d>>>31),r=c^(d<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=l^(i<<1|o>>>31),r=f^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],m=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=p^~g&v,e[1]=m^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&p,e[7]=S^~E&m,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~p&g,e[9]=E^~m&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=y[n],e[1]^=y[n+1]};if(l)e.exports=x;else{for(I=0;I{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="logger/5.7.0"},4327:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.Logger=t.LogLevel=t.ErrorCode=void 0;var i,o,a=n(r(9721)),s=n(r(8985)),u=r(7252),c=!1,l=!1,f={debug:1,default:2,info:2,warning:3,error:4,off:5},h=f.default,d=null,p=function(){try{var e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((function(t){try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(e){return e.message}return null}();t.LogLevel=i,function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(i||(t.LogLevel=i={})),t.ErrorCode=o,function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED",e.ACTION_REJECTED="ACTION_REJECTED"}(o||(t.ErrorCode=o={}));var m="0123456789abcdef",y=function(){function e(t){(0,a.default)(this,e),Object.defineProperty(this,"version",{enumerable:!0,value:t,writable:!1})}return(0,s.default)(e,[{key:"_log",value:function(e,t){var r=e.toLowerCase();null==f[r]&&this.throwArgumentError("invalid log level name","logLevel",e),h>f[r]||console.log.apply(console,t)}},{key:"debug",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n>4],r+=m[15&t[o]];i.push(e+"=Uint8Array(0x"+r+")")}else i.push(e+"="+JSON.stringify(t))}catch(t){i.push(e+"="+JSON.stringify(n[e].toString()))}})),i.push("code=".concat(r)),i.push("version=".concat(this.version));var a=t,s="";switch(r){case o.NUMERIC_FAULT:s="NUMERIC_FAULT";var u=t;switch(u){case"overflow":case"underflow":case"division-by-zero":s+="-"+u;break;case"negative-power":case"negative-width":s+="-unsupported";break;case"unbound-bitwise-result":s+="-unbound-result"}break;case o.CALL_EXCEPTION:case o.INSUFFICIENT_FUNDS:case o.MISSING_NEW:case o.NONCE_EXPIRED:case o.REPLACEMENT_UNDERPRICED:case o.TRANSACTION_REPLACED:case o.UNPREDICTABLE_GAS_LIMIT:s=r}s&&(t+=" [ See: https://links.ethers.org/v5-errors-"+s+" ]"),i.length&&(t+=" ("+i.join(", ")+")");var c=new Error(t);return c.reason=a,c.code=r,Object.keys(n).forEach((function(e){c[e]=n[e]})),c}},{key:"throwError",value:function(e,t,r){throw this.makeError(e,t,r)}},{key:"throwArgumentError",value:function(t,r,n){return this.throwError(t,e.errors.INVALID_ARGUMENT,{argument:r,value:n})}},{key:"assert",value:function(e,t,r,n){e||this.throwError(t,r,n)}},{key:"assertArgument",value:function(e,t,r,n){e||this.throwArgumentError(t,r,n)}},{key:"checkNormalize",value:function(t){null==t&&(t="platform missing String.prototype.normalize"),p&&this.throwError("platform missing String.prototype.normalize",e.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:p})}},{key:"checkSafeUint53",value:function(t,r){"number"==typeof t&&(null==r&&(r="value not safe"),(t<0||t>=9007199254740991)&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}},{key:"checkArgumentCount",value:function(t,r,n){n=n?": "+n:"",tr&&this.throwError("too many arguments"+n,e.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:r})}},{key:"checkNew",value:function(t,r){t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}},{key:"checkAbstract",value:function(t,r){t===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",e.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}}],[{key:"globalLogger",value:function(){return d||(d=new e(u.version)),d}},{key:"setCensorship",value:function(t,r){if(!t&&r&&this.globalLogger().throwError("cannot permanently disable censorship",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),c){if(!t)return;this.globalLogger().throwError("error censorship permanent",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}l=!!t,c=!!r}},{key:"setLogLevel",value:function(t){var r=f[t.toLowerCase()];null!=r?h=r:e.globalLogger().warn("invalid log level - "+t)}},{key:"from",value:function(t){return new e(t)}}]),e}();t.Logger=y,y.errors=o,y.levels=i},4071:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="properties/5.7.0"},3694:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.Description=void 0,t.checkProperties=function(e,t){e&&"object"===(0,s.default)(e)||f.throwArgumentError("invalid object","object",e),Object.keys(e).forEach((function(r){t[r]||f.throwArgumentError("invalid object key - "+r,"transaction:"+r,e)}))},t.deepCopy=y,t.defineReadOnly=h,t.getStatic=function(e,t){for(var r=0;r<32;r++){if(e[t])return e[t];if(!e.prototype||"object"!==(0,s.default)(e.prototype))break;e=Object.getPrototypeOf(e.prototype).constructor}return null},t.resolveProperties=function(e){return l(this,void 0,void 0,i.default.mark((function t(){var r,n;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=Object.keys(e).map((function(t){var r=e[t];return Promise.resolve(r).then((function(e){return{key:t,value:e}}))})),t.next=3,Promise.all(r);case 3:return n=t.sent,t.abrupt("return",n.reduce((function(e,t){return e[t.key]=t.value,e}),{}));case 5:case"end":return t.stop()}}),t)})))},t.shallowCopy=function(e){var t={};for(var r in e)t[r]=e[r];return t};var i=n(r(2247)),o=n(r(8985)),a=n(r(9721)),s=n(r(3355)),u=r(4327),c=r(4071),l=function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}u((n=n.apply(e,t||[])).next())}))},f=new u.Logger(c.version);function h(e,t,r){Object.defineProperty(e,t,{enumerable:!0,value:r,writable:!1})}var d={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function p(e){if(null==e||d[(0,s.default)(e)])return!0;if(Array.isArray(e)||"object"===(0,s.default)(e)){if(!Object.isFrozen(e))return!1;for(var t=Object.keys(e),r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="rlp/5.7.0"},5265:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decode=function(e){var t=(0,n.arrayify)(e),r=f(t,0);return r.consumed!==t.length&&a.throwArgumentError("invalid rlp data","data",e),r.result},t.encode=function(e){return(0,n.hexlify)(c(e))};var n=r(908),i=r(4327),o=r(1466),a=new i.Logger(o.version);function s(e){for(var t=[];e;)t.unshift(255&e),e>>=8;return t}function u(e,t,r){for(var n=0,i=0;it+1+n&&a.throwError("child data too short",i.Logger.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:o}}function f(e,t){if(0===e.length&&a.throwError("data too short",i.Logger.errors.BUFFER_OVERRUN,{}),e[t]>=248){var r=e[t]-247;t+1+r>e.length&&a.throwError("data short segment too short",i.Logger.errors.BUFFER_OVERRUN,{});var o=u(e,t+1,r);return t+1+r+o>e.length&&a.throwError("data long segment too short",i.Logger.errors.BUFFER_OVERRUN,{}),l(e,t,t+1+r,r+o)}if(e[t]>=192){var s=e[t]-192;return t+1+s>e.length&&a.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{}),l(e,t,t+1,s)}if(e[t]>=184){var c=e[t]-183;t+1+c>e.length&&a.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{});var f=u(e,t+1,c);return t+1+c+f>e.length&&a.throwError("data array too short",i.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+c+f,result:(0,n.hexlify)(e.slice(t+1+c,t+1+c+f))}}if(e[t]>=128){var h=e[t]-128;return t+1+h>e.length&&a.throwError("data too short",i.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+h,result:(0,n.hexlify)(e.slice(t+1,t+1+h))}}return{consumed:1,result:(0,n.hexlify)(e[t])}}},8100:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="signing-key/5.7.0"},6918:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.EC=void 0;var i=n(r(3355)),o=n(r(1734)),a=n(r(7198));function s(e,t,r){return r={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&r.path)}},e(r,r.exports),r.exports}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==r.g?r.g:"undefined"!=typeof self&&self;var u=c;function c(e,t){if(!e)throw new Error(t||"Assertion failed")}c.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var l=s((function(e,t){var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}})),f=s((function(e,t){var r=t;r.assert=u,r.toArray=l.toArray,r.zero2=l.zero2,r.toHex=l.toHex,r.encode=l.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!=(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!=(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"==typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new o.default(e,"hex","le")}})),h=f.getNAF,d=f.getJSF,p=f.assert;function m(e,t){this.type=e,this.p=new o.default(t.p,16),this.red=t.prime?o.default.red(t.prime):o.default.mont(this.p),this.zero=new o.default(0).toRed(this.red),this.one=new o.default(1).toRed(this.red),this.two=new o.default(2).toRed(this.red),this.n=t.n&&new o.default(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var y=m;function g(e,t){this.curve=e,this.type=t,this.precomputed=null}m.prototype.point=function(){throw new Error("Not implemented")},m.prototype.validate=function(){throw new Error("Not implemented")},m.prototype._fixedNafMul=function(e,t){p(e.precomputed);var r=e._getDoubles(),n=h(t,1,this._bitLength),i=(1<=o;u--)a=(a<<1)+n[u];s.push(a)}for(var c=this.jpoint(null,null,null),l=this.jpoint(null,null,null),f=i;f>0;f--){for(o=0;o=0;s--){for(var u=0;s>=0&&0===o[s];s--)u++;if(s>=0&&u++,a=a.dblp(u),s<0)break;var c=o[s];p(0!==c),a="affine"===e.type?c>0?a.mixedAdd(i[c-1>>1]):a.mixedAdd(i[-c-1>>1].neg()):c>0?a.add(i[c-1>>1]):a.add(i[-c-1>>1].neg())}return"affine"===e.type?a.toP():a},m.prototype._wnafMulAdd=function(e,t,r,n,i){var o,a,s,u=this._wnafT1,c=this._wnafT2,l=this._wnafT3,f=0;for(o=0;o=1;o-=2){var m=o-1,y=o;if(1===u[m]&&1===u[y]){var g=[t[m],null,null,t[y]];0===t[m].y.cmp(t[y].y)?(g[1]=t[m].add(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg())):0===t[m].y.cmp(t[y].y.redNeg())?(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].add(t[y].neg())):(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg()));var b=[-3,-1,-5,-7,0,7,5,1,3],v=d(r[m],r[y]);for(f=Math.max(v[0].length,f),l[m]=new Array(f),l[y]=new Array(f),a=0;a=0;o--){for(var E=0;o>=0;){var _=!0;for(a=0;a=0&&E++,S=S.dblp(E),o<0)break;for(a=0;a0?s=c[a][M-1>>1]:M<0&&(s=c[a][-M-1>>1].neg()),S="affine"===s.type?S.mixedAdd(s):S.add(s))}}for(o=0;o=Math.ceil((e.bitLength()+1)/t.step)},g.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i=0&&(a=t,s=r),n.negative&&(n=n.neg(),i=i.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:n,b:i},{a,b:s}]},w.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},w.prototype.pointFromX=function(e,t){(e=new o.default(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},w.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},w.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},S.prototype.isInfinity=function(){return this.inf},S.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},S.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},S.prototype.getX=function(){return this.x.fromRed()},S.prototype.getY=function(){return this.y.fromRed()},S.prototype.mul=function(e){return e=new o.default(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},S.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},S.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},S.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},S.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},S.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},b(k,y.BasePoint),w.prototype.jpoint=function(e,t,r){return new k(this,e,t,r)},k.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},k.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},k.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},k.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},k.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},k.prototype.inspect=function(){return this.isInfinity()?"":""},k.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var E=s((function(e,t){var r=t;r.base=y,r.short=A,r.mont=null,r.edwards=null})),_=s((function(e,t){var r,n=t,i=f.assert;function o(e){"short"===e.type?this.curve=new E.short(e):"edwards"===e.type?this.curve=new E.edwards(e):this.curve=new E.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,i(this.g.validate(),"Invalid curve"),i(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function s(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new o(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=o,s("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:a.default.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),s("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:a.default.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),s("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:a.default.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),s("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:a.default.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"]}),s("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:a.default.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"]}),s("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:a.default.sha256,gRed:!1,g:["9"]}),s("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:a.default.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(e){r=void 0}s("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:a.default.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function M(e){if(!(this instanceof M))return new M(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=l.toArray(e.entropy,e.entropyEnc||"hex"),r=l.toArray(e.nonce,e.nonceEnc||"hex"),n=l.toArray(e.pers,e.persEnc||"hex");u(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var T=M;M.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},M.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=l.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length"};var O=f.assert;function R(e,t){if(e instanceof R)return e;this._importDER(e,t)||(O(e.r&&e.s,"Signature without r or s"),this.r=new o.default(e.r,16),this.s=new o.default(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var C=R;function B(){this.place=0}function N(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function L(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}R.prototype._importDER=function(e,t){e=f.toArray(e,t);var r=new B;if(48!==e[r.place++])return!1;var n=N(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var i=N(e,r);if(!1===i)return!1;var a=e.slice(r.place,i+r.place);if(r.place+=i,2!==e[r.place++])return!1;var s=N(e,r);if(!1===s)return!1;if(e.length!==s+r.place)return!1;var u=e.slice(r.place,s+r.place);if(0===a[0]){if(!(128&a[1]))return!1;a=a.slice(1)}if(0===u[0]){if(!(128&u[1]))return!1;u=u.slice(1)}return this.r=new o.default(a),this.s=new o.default(u),this.recoveryParam=null,!0},R.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=L(t),r=L(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];U(n,t.length),(n=n.concat(t)).push(2),U(n,r.length);var i=n.concat(r),o=[48];return U(o,i.length),o=o.concat(i),f.encode(o,e)};var F=function(){throw new Error("unsupported")},D=f.assert;function j(e){if(!(this instanceof j))return new j(e);"string"==typeof e&&(D(Object.prototype.hasOwnProperty.call(_,e),"Unknown curve "+e),e=_[e]),e instanceof _.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var H=j;j.prototype.keyPair=function(e){return new I(this,e)},j.prototype.keyFromPrivate=function(e,t){return I.fromPrivate(this,e,t)},j.prototype.keyFromPublic=function(e,t){return I.fromPublic(this,e,t)},j.prototype.genKeyPair=function(e){e||(e={});for(var t=new T({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||F(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new o.default(2));;){var i=new o.default(t.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},j.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},j.prototype.sign=function(e,t,r,n){"object"===(0,i.default)(r)&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new o.default(e,16));for(var a=this.n.byteLength(),s=t.getPrivate().toArray("be",a),u=e.toArray("be",a),c=new T({hash:this.hash,entropy:s,nonce:u,pers:n.pers,persEnc:n.persEnc||"utf8"}),l=this.n.sub(new o.default(1)),f=0;;f++){var h=n.k?n.k(f):new o.default(c.generate(this.n.byteLength()));if(!((h=this._truncateToN(h,!0)).cmpn(1)<=0||h.cmp(l)>=0)){var d=this.g.mul(h);if(!d.isInfinity()){var p=d.getX(),m=p.umod(this.n);if(0!==m.cmpn(0)){var y=h.invm(this.n).mul(m.mul(t.getPrivate()).iadd(e));if(0!==(y=y.umod(this.n)).cmpn(0)){var g=(d.getY().isOdd()?1:0)|(0!==p.cmp(m)?2:0);return n.canonical&&y.cmp(this.nh)>0&&(y=this.n.sub(y),g^=1),new C({r:m,s:y,recoveryParam:g})}}}}}},j.prototype.verify=function(e,t,r,n){e=this._truncateToN(new o.default(e,16)),r=this.keyFromPublic(r,n);var i=(t=new C(t,"hex")).r,a=t.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),c=u.mul(e).umod(this.n),l=u.mul(i).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(c,r.getPublic(),l)).isInfinity()&&s.eqXToP(i):!(s=this.g.mulAdd(c,r.getPublic(),l)).isInfinity()&&0===s.getX().umod(this.n).cmp(i)},j.prototype.recoverPubKey=function(e,t,r,n){D((3&r)===r,"The recovery param is more than two bits"),t=new C(t,n);var i=this.n,a=new o.default(e),s=t.r,u=t.s,c=1&r,l=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&l)throw new Error("Unable to find sencond key candinate");s=l?this.curve.pointFromX(s.add(this.curve.n),c):this.curve.pointFromX(s,c);var f=t.r.invm(i),h=i.sub(a).mul(f).umod(i),d=u.mul(f).umod(i);return this.g.mulAdd(h,s,d)},j.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new C(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")};var J=s((function(e,t){var r=t;r.version="6.5.4",r.utils=f,r.rand=function(){throw new Error("unsupported")},r.curve=E,r.curves=_,r.ec=H,r.eddsa=null})),z=J.ec;t.EC=z},7612:(e,t,r)=>{"use strict";var n=r(8847);Object.defineProperty(t,"__esModule",{value:!0}),t.SigningKey=void 0,t.computePublicKey=m,t.recoverPublicKey=function(e,t){var r=(0,s.splitSignature)(t),n={r:(0,s.arrayify)(r.r),s:(0,s.arrayify)(r.s)};return"0x"+d().recoverPubKey((0,s.arrayify)(e),n,r.recoveryParam).encode("hex",!1)};var i=n(r(9721)),o=n(r(8985)),a=r(6918),s=r(908),u=r(3694),c=r(4327),l=r(8100),f=new c.Logger(l.version),h=null;function d(){return h||(h=new a.EC("secp256k1")),h}var p=function(){function e(t){(0,i.default)(this,e),(0,u.defineReadOnly)(this,"curve","secp256k1"),(0,u.defineReadOnly)(this,"privateKey",(0,s.hexlify)(t)),32!==(0,s.hexDataLength)(this.privateKey)&&f.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");var r=d().keyFromPrivate((0,s.arrayify)(this.privateKey));(0,u.defineReadOnly)(this,"publicKey","0x"+r.getPublic(!1,"hex")),(0,u.defineReadOnly)(this,"compressedPublicKey","0x"+r.getPublic(!0,"hex")),(0,u.defineReadOnly)(this,"_isSigningKey",!0)}return(0,o.default)(e,[{key:"_addPoint",value:function(e){var t=d().keyFromPublic((0,s.arrayify)(this.publicKey)),r=d().keyFromPublic((0,s.arrayify)(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}},{key:"signDigest",value:function(e){var t=d().keyFromPrivate((0,s.arrayify)(this.privateKey)),r=(0,s.arrayify)(e);32!==r.length&&f.throwArgumentError("bad digest length","digest",e);var n=t.sign(r,{canonical:!0});return(0,s.splitSignature)({recoveryParam:n.recoveryParam,r:(0,s.hexZeroPad)("0x"+n.r.toString(16),32),s:(0,s.hexZeroPad)("0x"+n.s.toString(16),32)})}},{key:"computeSharedSecret",value:function(e){var t=d().keyFromPrivate((0,s.arrayify)(this.privateKey)),r=d().keyFromPublic((0,s.arrayify)(m(e)));return(0,s.hexZeroPad)("0x"+t.derive(r.getPublic()).toString(16),32)}}],[{key:"isSigningKey",value:function(e){return!(!e||!e._isSigningKey)}}]),e}();function m(e,t){var r=(0,s.arrayify)(e);if(32===r.length){var n=new p(r);return t?"0x"+d().keyFromPrivate(r).getPublic(!0,"hex"):n.publicKey}return 33===r.length?t?(0,s.hexlify)(r):"0x"+d().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+d().keyFromPublic(r).getPublic(!0,"hex"):(0,s.hexlify)(r):f.throwArgumentError("invalid public or private key","key","[REDACTED]")}t.SigningKey=p},6518:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="strings/5.7.0"},5856:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatBytes32String=function(e){var t=(0,o.toUtf8Bytes)(e);if(t.length>31)throw new Error("bytes32 string must be less than 32 bytes");return(0,i.hexlify)((0,i.concat)([t,n.HashZero]).slice(0,32))},t.parseBytes32String=function(e){var t=(0,i.arrayify)(e);if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");for(var r=31;0===t[r-1];)r--;return(0,o.toUtf8String)(t.slice(0,r))};var n=r(5465),i=r(908),o=r(4997)},8645:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t._nameprepTableA1=p,t._nameprepTableB2=m,t._nameprepTableC=y,t.nameprep=function(e){if(e.match(/^[a-z0-9-]*$/i)&&e.length<=59)return e.toLowerCase();var t,r=(0,n.toUtf8CodePoints)(e);t=r.map((function(e){return u.indexOf(e)>=0||e>=65024&&e<=65039?[]:m(e)||[e]})),r=t.reduce((function(e,t){return t.forEach((function(t){e.push(t)})),e}),[]),(r=(0,n.toUtf8CodePoints)((0,n._toUtf8String)(r),n.UnicodeNormalizationForm.NFKC)).forEach((function(e){if(y(e))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),r.forEach((function(e){if(p(e))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));var i=(0,n._toUtf8String)(r);if("-"===i.substring(0,1)||"--"===i.substring(2,4)||"-"===i.substring(i.length-1))throw new Error("invalid hyphen");return i};var n=r(4997);function i(e,t){t||(t=function(e){return[parseInt(e,16)]});var r=0,n={};return e.split(",").forEach((function(e){var i=e.split(":");r+=parseInt(i[0],16),n[r]=t(i[1])})),n}function o(e){var t=0;return e.split(",").map((function(e){var r=e.split("-");return 1===r.length?r[1]="0":""===r[1]&&(r[1]="1"),{l:t+parseInt(r[0],16),h:t=parseInt(r[1],16)}}))}function a(e,t){for(var r=0,n=0;n=(r+=i.l)&&e<=r+i.h&&(e-r)%(i.d||1)==0){if(i.e&&-1!==i.e.indexOf(e-r))continue;return i}}return null}var s=o("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),u="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((function(e){return parseInt(e,16)})),c=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],l=i("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),f=i("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),h=i("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",(function(e){if(e.length%4!=0)throw new Error("bad data");for(var t=[],r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"UnicodeNormalizationForm",{enumerable:!0,get:function(){return o.UnicodeNormalizationForm}}),Object.defineProperty(t,"Utf8ErrorFuncs",{enumerable:!0,get:function(){return o.Utf8ErrorFuncs}}),Object.defineProperty(t,"Utf8ErrorReason",{enumerable:!0,get:function(){return o.Utf8ErrorReason}}),Object.defineProperty(t,"_toEscapedUtf8String",{enumerable:!0,get:function(){return o._toEscapedUtf8String}}),Object.defineProperty(t,"formatBytes32String",{enumerable:!0,get:function(){return n.formatBytes32String}}),Object.defineProperty(t,"nameprep",{enumerable:!0,get:function(){return i.nameprep}}),Object.defineProperty(t,"parseBytes32String",{enumerable:!0,get:function(){return n.parseBytes32String}}),Object.defineProperty(t,"toUtf8Bytes",{enumerable:!0,get:function(){return o.toUtf8Bytes}}),Object.defineProperty(t,"toUtf8CodePoints",{enumerable:!0,get:function(){return o.toUtf8CodePoints}}),Object.defineProperty(t,"toUtf8String",{enumerable:!0,get:function(){return o.toUtf8String}});var n=r(5856),i=r(8645),o=r(4997)},4997:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Utf8ErrorReason=t.Utf8ErrorFuncs=t.UnicodeNormalizationForm=void 0,t._toEscapedUtf8String=function(e,t){return'"'+f(e,t).map((function(e){if(e<256){switch(e){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(e>=32&&e<127)return String.fromCharCode(e)}return e<=65535?d(e):d(55296+((e-=65536)>>10&1023))+d(56320+(1023&e))})).join("")+'"'},t._toUtf8String=p,t.toUtf8Bytes=h,t.toUtf8CodePoints=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;return f(h(e,t))},t.toUtf8String=function(e,t){return p(f(e,t))};var n,i,o=r(908),a=r(4327),s=r(6518),u=new a.Logger(s.version);function c(e,t,r,n,o){if(e===i.BAD_PREFIX||e===i.UNEXPECTED_CONTINUE){for(var a=0,s=t+1;s>6==2;s++)a++;return a}return e===i.OVERRUN?r.length-t-1:0}t.UnicodeNormalizationForm=n,function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(n||(t.UnicodeNormalizationForm=n={})),t.Utf8ErrorReason=i,function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(i||(t.Utf8ErrorReason=i={}));var l=Object.freeze({error:function(e,t,r,n,i){return u.throwArgumentError("invalid codepoint at offset ".concat(t,"; ").concat(e),"bytes",r)},ignore:c,replace:function(e,t,r,n,o){return e===i.OVERLONG?(n.push(o),0):(n.push(65533),c(e,t,r))}});function f(e,t){null==t&&(t=l.error),e=(0,o.arrayify)(e);for(var r=[],n=0;n>7!=0){var s=null,u=null;if(192==(224&a))s=1,u=127;else if(224==(240&a))s=2,u=2047;else{if(240!=(248&a)){n+=t(128==(192&a)?i.UNEXPECTED_CONTINUE:i.BAD_PREFIX,n-1,e,r);continue}s=3,u=65535}if(n-1+s>=e.length)n+=t(i.OVERRUN,n-1,e,r);else{for(var c=a&(1<<8-s-1)-1,f=0;f1114111?n+=t(i.OUT_OF_RANGE,n-1-s,e,r,c):c>=55296&&c<=57343?n+=t(i.UTF16_SURROGATE,n-1-s,e,r,c):c<=u?n+=t(i.OVERLONG,n-1-s,e,r,c):r.push(c))}}else r.push(a)}return r}function h(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;t!=n.current&&(u.checkNormalize(),e=e.normalize(t));for(var r=[],i=0;i>6|192),r.push(63&a|128);else if(55296==(64512&a)){i++;var s=e.charCodeAt(i);if(i>=e.length||56320!=(64512&s))throw new Error("invalid utf-8 string");var c=65536+((1023&a)<<10)+(1023&s);r.push(c>>18|240),r.push(c>>12&63|128),r.push(c>>6&63|128),r.push(63&c|128)}else r.push(a>>12|224),r.push(a>>6&63|128),r.push(63&a|128)}return(0,o.arrayify)(r)}function d(e){var t="0000"+e.toString(16);return"\\u"+t.substring(t.length-4)}function p(e){return e.map((function(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e)))})).join("")}t.Utf8ErrorFuncs=l},6783:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="transactions/5.7.0"},1936:(e,t,r)=>{"use strict";var n=r(3355);Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionTypes=void 0,t.accessListify=_,t.computeAddress=A,t.parse=function(e){var t=(0,a.arrayify)(e);if(t[0]>127)return function(e){var t=l.decode(e);9!==t.length&&6!==t.length&&y.throwArgumentError("invalid raw transaction","rawTransaction",e);var r={nonce:b(t[0]).toNumber(),gasPrice:b(t[1]),gasLimit:b(t[2]),to:g(t[3]),value:b(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=o.BigNumber.from(t[6]).toNumber()}catch(e){return r}if(r.r=(0,a.hexZeroPad)(t[7],32),r.s=(0,a.hexZeroPad)(t[8],32),o.BigNumber.from(r.r).isZero()&&o.BigNumber.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);var n=r.v-27,i=t.slice(0,6);0!==r.chainId&&(i.push((0,a.hexlify)(r.chainId)),i.push("0x"),i.push("0x"),n-=2*r.chainId+8);var s=(0,u.keccak256)(l.encode(i));try{r.from=S(s,{r:(0,a.hexlify)(r.r),s:(0,a.hexlify)(r.s),recoveryParam:n})}catch(e){}r.hash=(0,u.keccak256)(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){var t=l.decode(e.slice(1));8!==t.length&&11!==t.length&&y.throwArgumentError("invalid component count for transaction type: 1","payload",(0,a.hexlify)(e));var r={type:1,chainId:b(t[0]).toNumber(),nonce:b(t[1]).toNumber(),gasPrice:b(t[2]),gasLimit:b(t[3]),to:g(t[4]),value:b(t[5]),data:t[6],accessList:_(t[7])};return 8===t.length||(r.hash=(0,u.keccak256)(e),P(r,t.slice(8),x)),r}(t);case 2:return function(e){var t=l.decode(e.slice(1));9!==t.length&&12!==t.length&&y.throwArgumentError("invalid component count for transaction type: 2","payload",(0,a.hexlify)(e));var r=b(t[2]),n=b(t[3]),i={type:2,chainId:b(t[0]).toNumber(),nonce:b(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:b(t[4]),to:g(t[5]),value:b(t[6]),data:t[7],accessList:_(t[8])};return 9===t.length||(i.hash=(0,u.keccak256)(e),P(i,t.slice(9),T)),i}(t)}return y.throwError("unsupported transaction type: ".concat(t[0]),h.Logger.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})},t.recoverAddress=S,t.serialize=function(e,t){if(null==e.type||0===e.type)return null!=e.accessList&&y.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",e),function(e,t){(0,c.checkProperties)(e,w);var r=[];v.forEach((function(t){var n=e[t.name]||[],i={};t.numeric&&(i.hexPad="left"),n=(0,a.arrayify)((0,a.hexlify)(n,i)),t.length&&n.length!==t.length&&n.length>0&&y.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),t.maxLength&&(n=(0,a.stripZeros)(n)).length>t.maxLength&&y.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),r.push((0,a.hexlify)(n))}));var n=0;if(null!=e.chainId?"number"!=typeof(n=e.chainId)&&y.throwArgumentError("invalid transaction.chainId","transaction",e):t&&!(0,a.isBytesLike)(t)&&t.v>28&&(n=Math.floor((t.v-35)/2)),0!==n&&(r.push((0,a.hexlify)(n)),r.push("0x"),r.push("0x")),!t)return l.encode(r);var i=(0,a.splitSignature)(t),o=27+i.recoveryParam;return 0!==n?(r.pop(),r.pop(),r.pop(),o+=2*n+8,i.v>28&&i.v!==o&&y.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t)):i.v!==o&&y.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t),r.push((0,a.hexlify)(o)),r.push((0,a.stripZeros)((0,a.arrayify)(i.r))),r.push((0,a.stripZeros)((0,a.arrayify)(i.s))),l.encode(r)}(e,t);switch(e.type){case 1:return x(e,t);case 2:return T(e,t)}return y.throwError("unsupported transaction type: ".concat(e.type),h.Logger.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:e.type})};var i=r(7921),o=r(4952),a=r(908),s=r(5465),u=r(4642),c=r(3694),l=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var r=p(void 0);if(r&&r.has(e))return r.get(e);var i={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(i,a,s):i[a]=e[a]}return i.default=e,r&&r.set(e,i),i}(r(5265)),f=r(7612),h=r(4327),d=r(6783);function p(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(p=function(e){return e?r:t})(e)}var m,y=new h.Logger(d.version);function g(e){return"0x"===e?null:(0,i.getAddress)(e)}function b(e){return"0x"===e?s.Zero:o.BigNumber.from(e)}t.TransactionTypes=m,function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(m||(t.TransactionTypes=m={}));var v=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],w={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function A(e){var t=(0,f.computePublicKey)(e);return(0,i.getAddress)((0,a.hexDataSlice)((0,u.keccak256)((0,a.hexDataSlice)(t,1)),12))}function S(e,t){return A((0,f.recoverPublicKey)((0,a.arrayify)(e),t))}function k(e,t){var r=(0,a.stripZeros)(o.BigNumber.from(e).toHexString());return r.length>32&&y.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function E(e,t){return{address:(0,i.getAddress)(e),storageKeys:(t||[]).map((function(t,r){return 32!==(0,a.hexDataLength)(t)&&y.throwArgumentError("invalid access list storageKey","accessList[".concat(e,":").concat(r,"]"),t),t.toLowerCase()}))}}function _(e){if(Array.isArray(e))return e.map((function(e,t){return Array.isArray(e)?(e.length>2&&y.throwArgumentError("access list expected to be [ address, storageKeys[] ]","value[".concat(t,"]"),e),E(e[0],e[1])):E(e.address,e.storageKeys)}));var t=Object.keys(e).map((function(t){var r=e[t].reduce((function(e,t){return e[t]=!0,e}),{});return E(t,Object.keys(r).sort())}));return t.sort((function(e,t){return e.address.localeCompare(t.address)})),t}function M(e){return _(e).map((function(e){return[e.address,e.storageKeys]}))}function T(e,t){if(null!=e.gasPrice){var r=o.BigNumber.from(e.gasPrice),n=o.BigNumber.from(e.maxFeePerGas||0);r.eq(n)||y.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:r,maxFeePerGas:n})}var s=[k(e.chainId||0,"chainId"),k(e.nonce||0,"nonce"),k(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),k(e.maxFeePerGas||0,"maxFeePerGas"),k(e.gasLimit||0,"gasLimit"),null!=e.to?(0,i.getAddress)(e.to):"0x",k(e.value||0,"value"),e.data||"0x",M(e.accessList||[])];if(t){var u=(0,a.splitSignature)(t);s.push(k(u.recoveryParam,"recoveryParam")),s.push((0,a.stripZeros)(u.r)),s.push((0,a.stripZeros)(u.s))}return(0,a.hexConcat)(["0x02",l.encode(s)])}function x(e,t){var r=[k(e.chainId||0,"chainId"),k(e.nonce||0,"nonce"),k(e.gasPrice||0,"gasPrice"),k(e.gasLimit||0,"gasLimit"),null!=e.to?(0,i.getAddress)(e.to):"0x",k(e.value||0,"value"),e.data||"0x",M(e.accessList||[])];if(t){var n=(0,a.splitSignature)(t);r.push(k(n.recoveryParam,"recoveryParam")),r.push((0,a.stripZeros)(n.r)),r.push((0,a.stripZeros)(n.s))}return(0,a.hexConcat)(["0x01",l.encode(r)])}function P(e,t,r){try{var n=b(t[0]).toNumber();if(0!==n&&1!==n)throw new Error("bad recid");e.v=n}catch(e){y.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=(0,a.hexZeroPad)(t[1],32),e.s=(0,a.hexZeroPad)(t[2],32);try{var i=(0,u.keccak256)(r(e));e.from=S(i,{r:e.r,s:e.s,recoveryParam:e.v})}catch(e){}}},3368:(e,t,r)=>{"use strict";var n,i,o=r(8847)(r(3355));void 0===(i="function"==typeof(n=function(){function e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function t(e,t){for(var r=0;r{"use strict";var n=t;n.bignum=r(1734),n.define=r(1568).define,n.base=r(2412),n.constants=r(9387),n.decoders=r(1500),n.encoders=r(7506)},1568:(e,t,r)=>{"use strict";var n=r(7506),i=r(1500),o=r(1736);function a(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}t.define=function(e,t){return new a(e,t)},a.prototype._createNamed=function(e){var t=this.name;function r(e){this._initNamed(e,t)}return o(r,e),r.prototype._initNamed=function(t,r){e.call(this,t,r)},new r(this)},a.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(i[e])),this.decoders[e]},a.prototype.decode=function(e,t,r){return this._getDecoder(t).decode(e,r)},a.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(n[e])),this.encoders[e]},a.prototype.encode=function(e,t,r){return this._getEncoder(t).encode(e,r)}},585:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1736),o=r(2719).b,a=r(1755).Buffer;function s(e,t){o.call(this,t),a.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function u(e,t){if(Array.isArray(e))this.length=0,this.value=e.map((function(e){return u.isEncoderBuffer(e)||(e=new u(e,t)),this.length+=e.length,e}),this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=a.byteLength(e);else{if(!a.isBuffer(e))return t.error("Unsupported type: "+(0,n.default)(e));this.value=e,this.length=e.length}}i(s,o),t.C=s,s.isDecoderBuffer=function(e){return e instanceof s||"object"===(0,n.default)(e)&&a.isBuffer(e.base)&&"DecoderBuffer"===e.constructor.name&&"number"==typeof e.offset&&"number"==typeof e.length&&"function"==typeof e.save&&"function"==typeof e.restore&&"function"==typeof e.isEmpty&&"function"==typeof e.readUInt8&&"function"==typeof e.skip&&"function"==typeof e.raw},s.prototype.save=function(){return{offset:this.offset,reporter:o.prototype.save.call(this)}},s.prototype.restore=function(e){var t=new s(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,o.prototype.restore.call(this,e.reporter),t},s.prototype.isEmpty=function(){return this.offset===this.length},s.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},s.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");var r=new s(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+e,this.offset+=e,r},s.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},t.R=u,u.isEncoderBuffer=function(e){return e instanceof u||"object"===(0,n.default)(e)&&"EncoderBuffer"===e.constructor.name&&"number"==typeof e.length&&"function"==typeof e.join},u.prototype.join=function(e,t){return e||(e=a.alloc(this.length)),t||(t=0),0===this.length||(Array.isArray(this.value)?this.value.forEach((function(r){r.join(e,t),t+=r.length})):("number"==typeof this.value?e[t]=this.value:"string"==typeof this.value?e.write(this.value,t):a.isBuffer(this.value)&&this.value.copy(e,t),t+=this.length)),e}},2412:(e,t,r)=>{"use strict";var n=t;n.Reporter=r(2719).b,n.DecoderBuffer=r(585).C,n.EncoderBuffer=r(585).R,n.Node=r(1371)},1371:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(2719).b,o=r(585).R,a=r(585).C,s=r(4504),u=["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"],c=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(u);function l(e,t,r){var n={};this._baseState=n,n.name=r,n.enc=e,n.parent=t||null,n.children=null,n.tag=null,n.args=null,n.reverseArgs=null,n.choice=null,n.optional=!1,n.any=!1,n.obj=!1,n.use=null,n.useDecoder=null,n.key=null,n.default=null,n.explicit=null,n.implicit=null,n.contains=null,n.parent||(n.children=[],this._wrap())}e.exports=l;var f=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];l.prototype.clone=function(){var e=this._baseState,t={};f.forEach((function(r){t[r]=e[r]}));var r=new this.constructor(t.parent);return r._baseState=t,r},l.prototype._wrap=function(){var e=this._baseState;c.forEach((function(t){this[t]=function(){var r=new this.constructor(this);return e.children.push(r),r[t].apply(r,arguments)}}),this)},l.prototype._init=function(e){var t=this._baseState;s(null===t.parent),e.call(this),t.children=t.children.filter((function(e){return e._baseState.parent===this}),this),s.equal(t.children.length,1,"Root node can have only one child")},l.prototype._useArgs=function(e){var t=this._baseState,r=e.filter((function(e){return e instanceof this.constructor}),this);e=e.filter((function(e){return!(e instanceof this.constructor)}),this),0!==r.length&&(s(null===t.children),t.children=r,r.forEach((function(e){e._baseState.parent=this}),this)),0!==e.length&&(s(null===t.args),t.args=e,t.reverseArgs=e.map((function(e){if("object"!==(0,n.default)(e)||e.constructor!==Object)return e;var t={};return Object.keys(e).forEach((function(r){r==(0|r)&&(r|=0);var n=e[r];t[n]=r})),t})))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach((function(e){l.prototype[e]=function(){var t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}})),u.forEach((function(e){l.prototype[e]=function(){var t=this._baseState,r=Array.prototype.slice.call(arguments);return s(null===t.tag),t.tag=e,this._useArgs(r),this}})),l.prototype.use=function(e){s(e);var t=this._baseState;return s(null===t.use),t.use=e,this},l.prototype.optional=function(){return this._baseState.optional=!0,this},l.prototype.def=function(e){var t=this._baseState;return s(null===t.default),t.default=e,t.optional=!0,this},l.prototype.explicit=function(e){var t=this._baseState;return s(null===t.explicit&&null===t.implicit),t.explicit=e,this},l.prototype.implicit=function(e){var t=this._baseState;return s(null===t.explicit&&null===t.implicit),t.implicit=e,this},l.prototype.obj=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},l.prototype.key=function(e){var t=this._baseState;return s(null===t.key),t.key=e,this},l.prototype.any=function(){return this._baseState.any=!0,this},l.prototype.choice=function(e){var t=this._baseState;return s(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map((function(t){return e[t]}))),this},l.prototype.contains=function(e){var t=this._baseState;return s(null===t.use),t.contains=e,this},l.prototype._decode=function(e,t){var r=this._baseState;if(null===r.parent)return e.wrapResult(r.children[0]._decode(e,t));var n,i=r.default,o=!0,s=null;if(null!==r.key&&(s=e.enterKey(r.key)),r.optional){var u=null;if(null!==r.explicit?u=r.explicit:null!==r.implicit?u=r.implicit:null!==r.tag&&(u=r.tag),null!==u||r.any){if(o=this._peekTag(e,u,r.any),e.isError(o))return o}else{var c=e.save();try{null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),o=!0}catch(e){o=!1}e.restore(c)}}if(r.obj&&o&&(n=e.enterObject()),o){if(null!==r.explicit){var l=this._decodeTag(e,r.explicit);if(e.isError(l))return l;e=l}var f=e.offset;if(null===r.use&&null===r.choice){var h;r.any&&(h=e.save());var d=this._decodeTag(e,null!==r.implicit?r.implicit:r.tag,r.any);if(e.isError(d))return d;r.any?i=e.raw(h):e=d}if(t&&t.track&&null!==r.tag&&t.track(e.path(),f,e.length,"tagged"),t&&t.track&&null!==r.tag&&t.track(e.path(),e.offset,e.length,"content"),r.any||(i=null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t)),e.isError(i))return i;if(r.any||null!==r.choice||null===r.children||r.children.forEach((function(r){r._decode(e,t)})),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){var p=new a(i);i=this._getUse(r.contains,e._reporterState.obj)._decode(p,t)}}return r.obj&&o&&(i=e.leaveObject(n)),null===r.key||null===i&&!0!==o?null!==s&&e.exitKey(s):e.leaveKey(s,r.key,i),i},l.prototype._decodeGeneric=function(e,t,r){var n=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,n.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&n.args?this._decodeObjid(t,n.args[0],n.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,n.args&&n.args[0],r):null!==n.use?this._getUse(n.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},l.prototype._getUse=function(e,t){var r=this._baseState;return r.useDecoder=this._use(e,t),s(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},l.prototype._decodeChoice=function(e,t){var r=this._baseState,n=null,i=!1;return Object.keys(r.choice).some((function(o){var a=e.save(),s=r.choice[o];try{var u=s._decode(e,t);if(e.isError(u))return!1;n={type:o,value:u},i=!0}catch(t){return e.restore(a),!1}return!0}),this),i?n:e.error("Choice not matched")},l.prototype._createEncoderBuffer=function(e){return new o(e,this.reporter)},l.prototype._encode=function(e,t,r){var n=this._baseState;if(null===n.default||n.default!==e){var i=this._encodeValue(e,t,r);if(void 0!==i&&!this._skipDefault(i,t,r))return i}},l.prototype._encodeValue=function(e,t,r){var o=this._baseState;if(null===o.parent)return o.children[0]._encode(e,t||new i);var a=null;if(this.reporter=t,o.optional&&void 0===e){if(null===o.default)return;e=o.default}var s=null,u=!1;if(o.any)a=this._createEncoderBuffer(e);else if(o.choice)a=this._encodeChoice(e,t);else if(o.contains)s=this._getUse(o.contains,r)._encode(e,t),u=!0;else if(o.children)s=o.children.map((function(r){if("null_"===r._baseState.tag)return r._encode(null,t,e);if(null===r._baseState.key)return t.error("Child should have a key");var i=t.enterKey(r._baseState.key);if("object"!==(0,n.default)(e))return t.error("Child expected, but input is not object");var o=r._encode(e[r._baseState.key],t,e);return t.leaveKey(i),o}),this).filter((function(e){return e})),s=this._createEncoderBuffer(s);else if("seqof"===o.tag||"setof"===o.tag){if(!o.args||1!==o.args.length)return t.error("Too many args for : "+o.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");var c=this.clone();c._baseState.implicit=null,s=this._createEncoderBuffer(e.map((function(r){var n=this._baseState;return this._getUse(n.args[0],e)._encode(r,t)}),c))}else null!==o.use?a=this._getUse(o.use,r)._encode(e,t):(s=this._encodePrimitive(o.tag,e),u=!0);if(!o.any&&null===o.choice){var l=null!==o.implicit?o.implicit:o.tag,f=null===o.implicit?"universal":"context";null===l?null===o.use&&t.error("Tag could be omitted only for .use()"):null===o.use&&(a=this._encodeComposite(l,u,f,s))}return null!==o.explicit&&(a=this._encodeComposite(o.explicit,!1,"context",a)),a},l.prototype._encodeChoice=function(e,t){var r=this._baseState,n=r.choice[e.type];return n||s(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),n._encode(e.value,t)},l.prototype._encodePrimitive=function(e,t){var r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},l.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},l.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(e)}},2719:(e,t,r)=>{"use strict";var n=r(1736);function i(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function o(e,t){this.path=e,this.rethrow(t)}t.b=i,i.prototype.isError=function(e){return e instanceof o},i.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},i.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},i.prototype.enterKey=function(e){return this._reporterState.path.push(e)},i.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},i.prototype.leaveKey=function(e,t,r){var n=this._reporterState;this.exitKey(e),null!==n.obj&&(n.obj[t]=r)},i.prototype.path=function(){return this._reporterState.path.join("/")},i.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},i.prototype.leaveObject=function(e){var t=this._reporterState,r=t.obj;return t.obj=e,r},i.prototype.error=function(e){var t,r=this._reporterState,n=e instanceof o;if(t=n?e:new o(r.path.map((function(e){return"["+JSON.stringify(e)+"]"})).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},i.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},n(o,Error),o.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,o),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},6520:(e,t)=>{"use strict";function r(e){var t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);var n=e[r];t[n]=r})),t}t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=r(t.tagClass),t.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"},t.tagByName=r(t.tag)},9387:(e,t,r)=>{"use strict";var n=t;n._reverse=function(e){var t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);var n=e[r];t[n]=r})),t},n.der=r(6520)},2387:(e,t,r)=>{"use strict";var n=r(1736),i=r(1734),o=r(585).C,a=r(1371),s=r(6520);function u(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new c,this.tree._init(e.body)}function c(e){a.call(this,"der",e)}function l(e,t){var r=e.readUInt8(t);if(e.isError(r))return r;var n=s.tagClass[r>>6],i=0==(32&r);if(31==(31&r)){var o=r;for(r=0;128==(128&o);){if(o=e.readUInt8(t),e.isError(o))return o;r<<=7,r|=127&o}}else r&=31;return{cls:n,primitive:i,tag:r,tagStr:s.tag[r]}}function f(e,t,r){var n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&128===n)return null;if(0==(128&n))return n;var i=127&n;if(i>4)return e.error("length octect is too long");n=0;for(var o=0;o{"use strict";var n=t;n.der=r(2387),n.pem=r(529)},529:(e,t,r)=>{"use strict";var n=r(1736),i=r(1755).Buffer,o=r(2387);function a(e){o.call(this,e),this.enc="pem"}n(a,o),e.exports=a,a.prototype.decode=function(e,t){for(var r=e.toString().split(/[\r\n]+/g),n=t.label.toUpperCase(),a=/^-----(BEGIN|END) ([^-]+)-----$/,s=-1,u=-1,c=0;c{"use strict";var n=r(1736),i=r(1755).Buffer,o=r(1371),a=r(6520);function s(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){o.call(this,"der",e)}function c(e){return e<10?"0"+e:e}e.exports=s,s.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},n(u,o),u.prototype._encodeComposite=function(e,t,r,n){var o=function(e,t,r,n){var i;if("seqof"===e?e="seq":"setof"===e&&(e="set"),a.tagByName.hasOwnProperty(e))i=a.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return n.error("Unknown tag: "+e);i=e}return i>=31?n.error("Multi-octet tag encoding unsupported"):(t||(i|=32),i|=a.tagClassByName[r||"universal"]<<6)}(e,t,r,this.reporter);if(n.length<128){var s=i.alloc(2);return s[0]=o,s[1]=n.length,this._createEncoderBuffer([s,n])}for(var u=1,c=n.length;c>=256;c>>=8)u++;var l=i.alloc(2+u);l[0]=o,l[1]=128|u;for(var f=1+u,h=n.length;h>0;f--,h>>=8)l[f]=255&h;return this._createEncoderBuffer([l,n])},u.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){for(var r=i.alloc(2*e.length),n=0;n=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}for(var a=0,s=0;s=128;u>>=7)a++}for(var c=i.alloc(a),l=c.length-1,f=e.length-1;f>=0;f--){var h=e[f];for(c[l--]=127&h;(h>>=7)>0;)c[l--]=128|127&h}return this._createEncoderBuffer(c)},u.prototype._encodeTime=function(e,t){var r,n=new Date(e);return"gentime"===t?r=[c(n.getUTCFullYear()),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[c(n.getUTCFullYear()%100),c(n.getUTCMonth()+1),c(n.getUTCDate()),c(n.getUTCHours()),c(n.getUTCMinutes()),c(n.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},u.prototype._encodeNull=function(){return this._createEncoderBuffer("")},u.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!i.isBuffer(e)){var r=e.toArray();!e.sign&&128&r[0]&&r.unshift(0),e=i.from(r)}if(i.isBuffer(e)){var n=e.length;0===e.length&&n++;var o=i.alloc(n);return e.copy(o),0===e.length&&(o[0]=0),this._createEncoderBuffer(o)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);for(var a=1,s=e;s>=256;s>>=8)a++;for(var u=new Array(a),c=u.length-1;c>=0;c--)u[c]=255&e,e>>=8;return 128&u[0]&&u.unshift(0),this._createEncoderBuffer(i.from(u))},u.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},u.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},u.prototype._skipDefault=function(e,t,r){var n,i=this._baseState;if(null===i.default)return!1;var o=e.join();if(void 0===i.defaultBuffer&&(i.defaultBuffer=this._encodeValue(i.default,t,r).join()),o.length!==i.defaultBuffer.length)return!1;for(n=0;n{"use strict";var n=t;n.der=r(1068),n.pem=r(8520)},8520:(e,t,r)=>{"use strict";var n=r(1736),i=r(1068);function o(e){i.call(this,e),this.enc="pem"}n(o,i),e.exports=o,o.prototype.encode=function(e,t){for(var r=i.prototype.encode.call(this,e).toString("base64"),n=["-----BEGIN "+t.label+"-----"],o=0;o{"use strict";var n=r(8847)(r(3355)),i=r(3103);function o(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i=0;u--)if(l[u]!==f[u])return!1;for(u=l.length-1;u>=0;u--)if(!w(e[a=l[u]],t[a],r,n))return!1;return!0}(e,t,r,i))}return r?e===t:e==t}function A(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function S(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function k(e,t,r,n){var i;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof r&&(n=r,r=null),i=function(e){var t;try{e()}catch(e){t=e}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!i&&b(i,r,"Missing expected exception"+n);var o="string"==typeof n,a=!e&&i&&!r;if((!e&&s.isError(i)&&o&&S(i,r)||a)&&b(i,r,"Got unwanted exception"+n),e&&i&&r&&!S(i,r)||!e&&i)throw i}d.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return y(g(e.actual),128)+" "+e.operator+" "+y(g(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||b;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,i=m(t),o=n.indexOf("\n"+i);if(o>=0){var a=n.indexOf("\n",o+1);n=n.substring(a+1)}this.stack=n}}},s.inherits(d.AssertionError,Error),d.fail=b,d.ok=v,d.equal=function(e,t,r){e!=t&&b(e,t,r,"==",d.equal)},d.notEqual=function(e,t,r){e==t&&b(e,t,r,"!=",d.notEqual)},d.deepEqual=function(e,t,r){w(e,t,!1)||b(e,t,r,"deepEqual",d.deepEqual)},d.deepStrictEqual=function(e,t,r){w(e,t,!0)||b(e,t,r,"deepStrictEqual",d.deepStrictEqual)},d.notDeepEqual=function(e,t,r){w(e,t,!1)&&b(e,t,r,"notDeepEqual",d.notDeepEqual)},d.notDeepStrictEqual=function e(t,r,n){w(t,r,!0)&&b(t,r,n,"notDeepStrictEqual",e)},d.strictEqual=function(e,t,r){e!==t&&b(e,t,r,"===",d.strictEqual)},d.notStrictEqual=function(e,t,r){e===t&&b(e,t,r,"!==",d.notStrictEqual)},d.throws=function(e,t,r){k(!0,e,t,r)},d.doesNotThrow=function(e,t,r){k(!1,e,t,r)},d.ifError=function(e){if(e)throw e},d.strict=i((function e(t,r){t||b(t,!0,r,"==",e)}),d,{equal:d.strictEqual,deepEqual:d.deepStrictEqual,notEqual:d.notStrictEqual,notDeepEqual:d.notDeepStrictEqual}),d.strict.strict=d.strict;var E=Object.keys||function(e){var t=[];for(var r in e)u.call(e,r)&&t.push(r);return t}},4074:e=>{"use strict";"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},6732:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(e){return e&&"object"===(0,n.default)(e)&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},9954:(e,t,r)=>{"use strict";var n=r(9142),i=r(8847)(r(3355)),o=/%[sdj%]/g;t.format=function(e){if(!b(e)){for(var t=[],r=0;r=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}})),s=n[r];r=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),m(r)?n.showHidden=r:r&&t._extend(n,r),v(n.showHidden)&&(n.showHidden=!1),v(n.depth)&&(n.depth=2),v(n.colors)&&(n.colors=!1),v(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=c),f(n,e,n.depth)}function c(e,t){var r=u.styles[t];return r?"["+u.colors[r][0]+"m"+e+"["+u.colors[r][1]+"m":e}function l(e,t){return e}function f(e,r,n){if(e.customInspect&&r&&E(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var i=r.inspect(n,e);return b(i)||(i=f(e,i,n)),i}var o=function(e,t){if(v(t))return e.stylize("undefined","undefined");if(b(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return g(t)?e.stylize(""+t,"number"):m(t)?e.stylize(""+t,"boolean"):y(t)?e.stylize("null","null"):void 0}(e,r);if(o)return o;var a=Object.keys(r),s=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),k(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return h(r);if(0===a.length){if(E(r)){var u=r.name?": "+r.name:"";return e.stylize("[Function"+u+"]","special")}if(w(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(S(r))return e.stylize(Date.prototype.toString.call(r),"date");if(k(r))return h(r)}var c,l="",A=!1,_=["{","}"];return p(r)&&(A=!0,_=["[","]"]),E(r)&&(l=" [Function"+(r.name?": "+r.name:"")+"]"),w(r)&&(l=" "+RegExp.prototype.toString.call(r)),S(r)&&(l=" "+Date.prototype.toUTCString.call(r)),k(r)&&(l=" "+h(r)),0!==a.length||A&&0!=r.length?n<0?w(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),c=A?function(e,t,r,n,i){for(var o=[],a=0,s=t.length;a60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}(c,l,_)):_[0]+l+_[1]}function h(e){return"["+Error.prototype.toString.call(e)+"]"}function d(e,t,r,n,i,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?s=u.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):u.set&&(s=e.stylize("[Setter]","special")),P(n,i)||(a="["+i+"]"),s||(e.seen.indexOf(u.value)<0?(s=y(r)?f(e,u.value,null):f(e,u.value,r-1)).indexOf("\n")>-1&&(s=o?s.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),v(a)){if(o&&i.match(/^\d+$/))return s;(a=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function p(e){return Array.isArray(e)}function m(e){return"boolean"==typeof e}function y(e){return null===e}function g(e){return"number"==typeof e}function b(e){return"string"==typeof e}function v(e){return void 0===e}function w(e){return A(e)&&"[object RegExp]"===_(e)}function A(e){return"object"===(0,i.default)(e)&&null!==e}function S(e){return A(e)&&"[object Date]"===_(e)}function k(e){return A(e)&&("[object Error]"===_(e)||e instanceof Error)}function E(e){return"function"==typeof e}function _(e){return Object.prototype.toString.call(e)}function M(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(v(a)&&(a=n.env.NODE_DEBUG||""),e=e.toUpperCase(),!s[e])if(new RegExp("\\b"+e+"\\b","i").test(a)){var r=n.pid;s[e]=function(){var n=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,n)}}else s[e]=function(){};return s[e]},t.inspect=u,u.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=p,t.isBoolean=m,t.isNull=y,t.isNullOrUndefined=function(e){return null==e},t.isNumber=g,t.isString=b,t.isSymbol=function(e){return"symbol"===(0,i.default)(e)},t.isUndefined=v,t.isRegExp=w,t.isObject=A,t.isDate=S,t.isError=k,t.isFunction=E,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"===(0,i.default)(e)||void 0===e},t.isBuffer=r(6732);var T=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function x(){var e=new Date,t=[M(e.getHours()),M(e.getMinutes()),M(e.getSeconds())].join(":");return[e.getDate(),T[e.getMonth()],t].join(" ")}function P(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",x(),t.format.apply(t,arguments))},t.inherits=r(4074),t._extend=function(e,t){if(!t||!A(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}},7548:(e,t,r)=>{"use strict";var n=r(8850).Buffer;e.exports=function(e){if(e.length>=255)throw new TypeError("Alphabet too long");for(var t=new Uint8Array(256),r=0;r>>0,l=new Uint8Array(a);e[r];){var f=t[e.charCodeAt(r)];if(255===f)return;for(var h=0,d=a-1;(0!==f||h>>0,l[d]=f%256>>>0,f=f/256>>>0;if(0!==f)throw new Error("Non-zero carry");o=h,r++}for(var p=a-o;p!==a&&0===l[p];)p++;var m=n.allocUnsafe(i+(a-p));m.fill(0,0,i);for(var y=i;p!==a;)m[y++]=l[p++];return m}return{encode:function(t){if((Array.isArray(t)||t instanceof Uint8Array)&&(t=n.from(t)),!n.isBuffer(t))throw new TypeError("Expected Buffer");if(0===t.length)return"";for(var r=0,i=0,o=0,a=t.length;o!==a&&0===t[o];)o++,r++;for(var c=(a-o)*l+1>>>0,f=new Uint8Array(c);o!==a;){for(var h=t[o],d=0,p=c-1;(0!==h||d>>0,f[p]=h%s>>>0,h=h/s>>>0;if(0!==h)throw new Error("Non-zero carry");i=d,o++}for(var m=c-i;m!==c&&0===f[m];)m++;for(var y=u.repeat(r);m{"use strict";t.byteLength=function(e){var t=u(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,o=u(e),a=o[0],s=o[1],c=new i(function(e,t,r){return 3*(t+r)/4-r}(0,a,s)),l=0,f=s>0?a-4:a;for(r=0;r>16&255,c[l++]=t>>8&255,c[l++]=255&t;return 2===s&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,c[l++]=255&t),1===s&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t),c},t.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],a=16383,s=0,u=n-i;su?u:s+a));return 1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),o.join("")};for(var r=[],n=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=o.length;a0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function c(e,t,n){for(var i,o,a=[],s=t;s>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},1734:(e,t,r)=>{"use strict";e=r.nmd(e);var n=r(8847)(r(3355));!function(e,t){function i(e,t){if(!e)throw new Error(t||"Assertion failed")}function o(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function a(e,t,r){if(a.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var s;"object"===(0,n.default)(e)?e.exports=a:(void 0).BN=a,a.BN=a,a.wordSize=26;try{s="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(9033).Buffer}catch(e){}function u(e,t){var r=e.charCodeAt(t);return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void i(!1,"Invalid character in "+e)}function c(e,t,r){var n=u(e,r);return r-1>=t&&(n|=u(e,r-1)<<4),n}function l(e,t,r,n){for(var o=0,a=0,s=Math.min(e.length,r),u=t;u=49?c-49+10:c>=17?c-17+10:c,i(c>=0&&a0?e:t},a.min=function(e,t){return e.cmp(t)<0?e:t},a.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"===(0,n.default)(e))return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var o=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(o++,this.negative=1),o=0;n-=3)a=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this._strip()},a.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)i=c(e,t,n)<=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2==0?t+1:t;n=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this._strip()},a.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,u=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},a.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=h}catch(e){a.prototype.inspect=h}else a.prototype.inspect=h;function h(){return(this.red?""}var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],p=[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],m=[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 y(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var c=1;c>>26,f=67108863&u,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;l+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[c]=0|f,u=0|l}return 0!==u?r.words[c]=0|u:r.length--,r._strip()}a.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,a=0;a>>24-n&16777215,(n+=2)>=26&&(n-=26,a--),r=0!==o||a!==this.length-1?d[6-u.length]+u+r:u+r}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=p[e],l=m[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var h=f.modrn(l).toString(e);r=(f=f.idivn(l)).isZero()?h+r:d[c-h.length]+h+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},a.prototype.toJSON=function(){return this.toString(16,2)},s&&(a.prototype.toBuffer=function(e,t){return this.toArrayLike(s,e,t)}),a.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},a.prototype.toArrayLike=function(e,t,r){this._strip();var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0");var a=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,o);return this["_toArrayLike"+("le"===t?"LE":"BE")](a,n),a},a.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,i=0,o=0;i>8&255),r>16&255),6===o?(r>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r=0&&(e[r--]=a>>8&255),r>=0&&(e[r--]=a>>16&255),6===o?(r>=0&&(e[r--]=a>>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?a.prototype._countBits=function(e){return 32-Math.clz32(e)}:a.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},a.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},a.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},a.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},a.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},a.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},a.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},a.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},a.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this._strip()},a.prototype.notn=function(e){return this.clone().inotn(e)},a.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},a.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,y=0|a[2],g=8191&y,b=y>>>13,v=0|a[3],w=8191&v,A=v>>>13,S=0|a[4],k=8191&S,E=S>>>13,_=0|a[5],M=8191&_,T=_>>>13,x=0|a[6],P=8191&x,I=x>>>13,O=0|a[7],R=8191&O,C=O>>>13,B=0|a[8],N=8191&B,L=B>>>13,U=0|a[9],F=8191&U,D=U>>>13,j=0|s[0],H=8191&j,J=j>>>13,z=0|s[1],G=8191&z,q=z>>>13,K=0|s[2],V=8191&K,X=K>>>13,Q=0|s[3],W=8191&Q,Z=Q>>>13,Y=0|s[4],$=8191&Y,ee=Y>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,ce=se>>>13,le=0|s[8],fe=8191&le,he=le>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ye=(c+(n=Math.imul(f,H))|0)+((8191&(i=(i=Math.imul(f,J))+Math.imul(h,H)|0))<<13)|0;c=((o=Math.imul(h,J))+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(p,H),i=(i=Math.imul(p,J))+Math.imul(m,H)|0,o=Math.imul(m,J);var ge=(c+(n=n+Math.imul(f,G)|0)|0)+((8191&(i=(i=i+Math.imul(f,q)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,H),i=(i=Math.imul(g,J))+Math.imul(b,H)|0,o=Math.imul(b,J),n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,q)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,q)|0;var be=(c+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,X)|0)+Math.imul(h,V)|0))<<13)|0;c=((o=o+Math.imul(h,X)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(w,H),i=(i=Math.imul(w,J))+Math.imul(A,H)|0,o=Math.imul(A,J),n=n+Math.imul(g,G)|0,i=(i=i+Math.imul(g,q)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,q)|0,n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,X)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Z)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,Z)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(k,H),i=(i=Math.imul(k,J))+Math.imul(E,H)|0,o=Math.imul(E,J),n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,q)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,q)|0,n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,X)|0)+Math.imul(b,V)|0,o=o+Math.imul(b,X)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Z)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Z)|0;var we=(c+(n=n+Math.imul(f,$)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,$)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(M,H),i=(i=Math.imul(M,J))+Math.imul(T,H)|0,o=Math.imul(T,J),n=n+Math.imul(k,G)|0,i=(i=i+Math.imul(k,q)|0)+Math.imul(E,G)|0,o=o+Math.imul(E,q)|0,n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,X)|0)+Math.imul(A,V)|0,o=o+Math.imul(A,X)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Z)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,Z)|0,n=n+Math.imul(p,$)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,ee)|0;var Ae=(c+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(P,H),i=(i=Math.imul(P,J))+Math.imul(I,H)|0,o=Math.imul(I,J),n=n+Math.imul(M,G)|0,i=(i=i+Math.imul(M,q)|0)+Math.imul(T,G)|0,o=o+Math.imul(T,q)|0,n=n+Math.imul(k,V)|0,i=(i=i+Math.imul(k,X)|0)+Math.imul(E,V)|0,o=o+Math.imul(E,X)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Z)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,Z)|0,n=n+Math.imul(g,$)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,$)|0,o=o+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Se=(c+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(R,H),i=(i=Math.imul(R,J))+Math.imul(C,H)|0,o=Math.imul(C,J),n=n+Math.imul(P,G)|0,i=(i=i+Math.imul(P,q)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,q)|0,n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,X)|0)+Math.imul(T,V)|0,o=o+Math.imul(T,X)|0,n=n+Math.imul(k,W)|0,i=(i=i+Math.imul(k,Z)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,Z)|0,n=n+Math.imul(w,$)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var ke=(c+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,ce)|0)+Math.imul(h,ue)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(N,H),i=(i=Math.imul(N,J))+Math.imul(L,H)|0,o=Math.imul(L,J),n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,q)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,q)|0,n=n+Math.imul(P,V)|0,i=(i=i+Math.imul(P,X)|0)+Math.imul(I,V)|0,o=o+Math.imul(I,X)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Z)|0)+Math.imul(T,W)|0,o=o+Math.imul(T,Z)|0,n=n+Math.imul(k,$)|0,i=(i=i+Math.imul(k,ee)|0)+Math.imul(E,$)|0,o=o+Math.imul(E,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,ce)|0;var Ee=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,H),i=(i=Math.imul(F,J))+Math.imul(D,H)|0,o=Math.imul(D,J),n=n+Math.imul(N,G)|0,i=(i=i+Math.imul(N,q)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,q)|0,n=n+Math.imul(R,V)|0,i=(i=i+Math.imul(R,X)|0)+Math.imul(C,V)|0,o=o+Math.imul(C,X)|0,n=n+Math.imul(P,W)|0,i=(i=i+Math.imul(P,Z)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,Z)|0,n=n+Math.imul(M,$)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(T,$)|0,o=o+Math.imul(T,ee)|0,n=n+Math.imul(k,re)|0,i=(i=i+Math.imul(k,ne)|0)+Math.imul(E,re)|0,o=o+Math.imul(E,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,ce)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,ce)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var _e=(c+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(F,G),i=(i=Math.imul(F,q))+Math.imul(D,G)|0,o=Math.imul(D,q),n=n+Math.imul(N,V)|0,i=(i=i+Math.imul(N,X)|0)+Math.imul(L,V)|0,o=o+Math.imul(L,X)|0,n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,Z)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,Z)|0,n=n+Math.imul(P,$)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(T,re)|0,o=o+Math.imul(T,ne)|0,n=n+Math.imul(k,oe)|0,i=(i=i+Math.imul(k,ae)|0)+Math.imul(E,oe)|0,o=o+Math.imul(E,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(b,fe)|0,o=o+Math.imul(b,he)|0;var Me=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,X))+Math.imul(D,V)|0,o=Math.imul(D,X),n=n+Math.imul(N,W)|0,i=(i=i+Math.imul(N,Z)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,Z)|0,n=n+Math.imul(R,$)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(T,oe)|0,o=o+Math.imul(T,ae)|0,n=n+Math.imul(k,ue)|0,i=(i=i+Math.imul(k,ce)|0)+Math.imul(E,ue)|0,o=o+Math.imul(E,ce)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(A,fe)|0,o=o+Math.imul(A,he)|0;var Te=(c+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Z))+Math.imul(D,W)|0,o=Math.imul(D,Z),n=n+Math.imul(N,$)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(L,$)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(P,oe)|0,i=(i=i+Math.imul(P,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,ce)|0)+Math.imul(T,ue)|0,o=o+Math.imul(T,ce)|0,n=n+Math.imul(k,fe)|0,i=(i=i+Math.imul(k,he)|0)+Math.imul(E,fe)|0,o=o+Math.imul(E,he)|0;var xe=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,me)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,$),i=(i=Math.imul(F,ee))+Math.imul(D,$)|0,o=Math.imul(D,ee),n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(P,ue)|0,i=(i=i+Math.imul(P,ce)|0)+Math.imul(I,ue)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(T,fe)|0,o=o+Math.imul(T,he)|0;var Pe=(c+(n=n+Math.imul(k,pe)|0)|0)+((8191&(i=(i=i+Math.imul(k,me)|0)+Math.imul(E,pe)|0))<<13)|0;c=((o=o+Math.imul(E,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(N,oe)|0,i=(i=i+Math.imul(N,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,ue)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,ue)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,he)|0)+Math.imul(I,fe)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(T,pe)|0))<<13)|0;c=((o=o+Math.imul(T,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(D,oe)|0,o=Math.imul(D,ae),n=n+Math.imul(N,ue)|0,i=(i=i+Math.imul(N,ce)|0)+Math.imul(L,ue)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,fe)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,fe)|0,o=o+Math.imul(C,he)|0;var Oe=(c+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,me)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,ce))+Math.imul(D,ue)|0,o=Math.imul(D,ce),n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,he)|0)+Math.imul(L,fe)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,me)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,me)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(D,fe)|0,o=Math.imul(D,he);var Ce=(c+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,me)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,me)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Be=(c+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(D,pe)|0))<<13)|0;return c=((o=Math.imul(D,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ye,u[1]=ge,u[2]=be,u[3]=ve,u[4]=we,u[5]=Ae,u[6]=Se,u[7]=ke,u[8]=Ee,u[9]=_e,u[10]=Me,u[11]=Te,u[12]=xe,u[13]=Pe,u[14]=Ie,u[15]=Oe,u[16]=Re,u[17]=Ce,u[18]=Be,0!==c&&(u[19]=c,r.length++),r};function b(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r._strip()}function v(e,t,r){return b(e,t,r)}function w(e,t){this.x=e,this.y=t}Math.imul||(g=y),a.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?g(this,e,t):r<63?y(this,e,t):r<1024?b(this,e,t):v(this,e,t)},w.prototype.makeRBT=function(e){for(var t=new Array(e),r=a.prototype._countBits(e)-1,n=0;n>=1;return n},w.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,r+=o/67108864|0,r+=a>>>26,this.words[n]=67108863&a}return 0!==r&&(this.words[n]=r,this.length++),t?this.ineg():this},a.prototype.muln=function(e){return this.clone().imuln(e)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i&1}return t}(e);if(0===t.length)return new a(1);for(var r=this,n=0;n=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,c=0;c=0&&(0!==l||c>=n);c--){var f=0|this.words[c];this.words[c]=l<<26-o|f>>>o,l=f&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},a.prototype.shln=function(e){return this.clone().ishln(e)},a.prototype.ushln=function(e){return this.clone().iushln(e)},a.prototype.shrn=function(e){return this.clone().ishrn(e)},a.prototype.ushrn=function(e){return this.clone().iushrn(e)},a.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},a.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this._strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this._strip()},a.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,o=0|i.words[i.length-1];0!=(r=26-this._countBits(o))&&(i=i.ushln(r),n.iushln(r),o=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new a(null)).length=u+1,s.words=new Array(s.length);for(var c=0;c=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/o|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},a.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new a(0),mod:new a(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(n=s.div.neg()),"div"!==t&&(o=s.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:n,mod:o}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(n=s.div.neg()),{div:n,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(o=s.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:s.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new a(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new a(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new a(this.modrn(e.words[0]))}:this._wordDiv(e,t);var n,o,s},a.prototype.div=function(e){return this.divmod(e,"div",!1).div},a.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},a.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},a.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},a.prototype.modrn=function(e){var t=e<0;t&&(e=-e),i(e<=67108863);for(var r=(1<<26)%e,n=0,o=this.length-1;o>=0;o--)n=(r*n+(0|this.words[o]))%e;return t?-n:n},a.prototype.modn=function(e){return this.modrn(e)},a.prototype.idivn=function(e){var t=e<0;t&&(e=-e),i(e<=67108863);for(var r=0,n=this.length-1;n>=0;n--){var o=(0|this.words[n])+67108864*r;this.words[n]=o/e|0,r=o%e}return this._strip(),t?this.ineg():this},a.prototype.divn=function(e){return this.clone().idivn(e)},a.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new a(1),o=new a(0),s=new a(0),u=new a(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0==(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(n.isOdd()||o.isOdd())&&(n.iadd(l),o.isub(f)),n.iushrn(1),o.iushrn(1);for(var p=0,m=1;0==(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(s),o.isub(u)):(r.isub(t),s.isub(n),u.isub(o))}return{a:s,b:u,gcd:r.iushln(c)}},a.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,o=new a(1),s=new a(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,l=1;0==(t.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(t.iushrn(c);c-- >0;)o.isOdd()&&o.iadd(u),o.iushrn(1);for(var f=0,h=1;0==(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(s)):(r.isub(t),s.isub(o))}return(n=0===t.cmpn(1)?o:s).cmpn(0)<0&&n.iadd(e),n},a.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},a.prototype.invm=function(e){return this.egcd(e).a.umod(e)},a.prototype.isEven=function(){return 0==(1&this.words[0])},a.prototype.isOdd=function(){return 1==(1&this.words[0])},a.prototype.andln=function(e){return this.words[0]&e},a.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},a.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},a.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},a.prototype.gtn=function(e){return 1===this.cmpn(e)},a.prototype.gt=function(e){return 1===this.cmp(e)},a.prototype.gten=function(e){return this.cmpn(e)>=0},a.prototype.gte=function(e){return this.cmp(e)>=0},a.prototype.ltn=function(e){return-1===this.cmpn(e)},a.prototype.lt=function(e){return-1===this.cmp(e)},a.prototype.lten=function(e){return this.cmpn(e)<=0},a.prototype.lte=function(e){return this.cmp(e)<=0},a.prototype.eqn=function(e){return 0===this.cmpn(e)},a.prototype.eq=function(e){return 0===this.cmp(e)},a.red=function(e){return new T(e)},a.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},a.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(e){return this.red=e,this},a.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},a.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},a.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},a.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},a.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},a.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},a.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},a.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},a.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var A={k256:null,p224:null,p192:null,p25519:null};function S(e,t){this.name=e,this.p=new a(t,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function k(){S.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function E(){S.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){S.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function M(){S.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function T(e){if("string"==typeof e){var t=a._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function x(e){T.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S.prototype._tmp=function(){var e=new a(null);return e.words=new Array(Math.ceil(this.n/13)),e},S.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},S.prototype.split=function(e,t){e.iushrn(this.n,0,t)},S.prototype.imulK=function(e){return e.imul(this.k)},o(k,S),k.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},k.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},a._prime=function(e){if(A[e])return A[e];var t;if("k256"===e)t=new k;else if("p224"===e)t=new E;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new M}return A[e]=t,t},T.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},T.prototype._verify2=function(e,t){i(0==(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},T.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(f(e,e.umod(this.m)._forceRed(this)),e)},T.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},T.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},T.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},T.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},T.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},T.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},T.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},T.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},T.prototype.isqr=function(e){return this.imul(e,e.clone())},T.prototype.sqr=function(e){return this.mul(e,e)},T.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new a(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),o=0;!n.isZero()&&0===n.andln(1);)o++,n.iushrn(1);i(!n.isZero());var s=new a(1).toRed(this),u=s.redNeg(),c=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);0!==this.pow(l,c).cmp(u);)l.redIAdd(u);for(var f=this.pow(l,n),h=this.pow(e,n.addn(1).iushrn(1)),d=this.pow(e,n),p=o;0!==d.cmp(s);){for(var m=d,y=0;0!==m.cmp(s);y++)m=m.redSqr();i(y=0;n--){for(var c=t.words[n],l=u-1;l>=0;l--){var f=c>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==o?(o<<=1,o|=f,(4==++s||0===n&&0===l)&&(i=this.mul(i,r[o]),s=0,o=0)):s=0}u=26}return i},T.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},T.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},a.mont=function(e){return new x(e)},o(x,T),x.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},x.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},x.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},x.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new a(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},x.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e)},2202:(e,t,r)=>{"use strict";var n,i=r(8847)(r(3355));function o(e){this.rand=e}if(e.exports=function(e){return n||(n=new o(null)),n.generate(e)},e.exports.Rand=o,o.prototype.generate=function(e){return this._rand(e)},o.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r{"use strict";var n=r(8850).Buffer;function i(e){n.isBuffer(e)||(e=n.from(e));for(var t=e.length/4|0,r=new Array(t),i=0;i>>24]^l[p>>>16&255]^f[m>>>8&255]^h[255&y]^t[g++],a=c[p>>>24]^l[m>>>16&255]^f[y>>>8&255]^h[255&d]^t[g++],s=c[m>>>24]^l[y>>>16&255]^f[d>>>8&255]^h[255&p]^t[g++],u=c[y>>>24]^l[d>>>16&255]^f[p>>>8&255]^h[255&m]^t[g++],d=o,p=a,m=s,y=u;return o=(n[d>>>24]<<24|n[p>>>16&255]<<16|n[m>>>8&255]<<8|n[255&y])^t[g++],a=(n[p>>>24]<<24|n[m>>>16&255]<<16|n[y>>>8&255]<<8|n[255&d])^t[g++],s=(n[m>>>24]<<24|n[y>>>16&255]<<16|n[d>>>8&255]<<8|n[255&p])^t[g++],u=(n[y>>>24]<<24|n[d>>>16&255]<<16|n[p>>>8&255]<<8|n[255&m])^t[g++],[o>>>=0,a>>>=0,s>>>=0,u>>>=0]}var s=[0,1,2,4,8,16,32,64,128,27,54],u=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],o=[[],[],[],[]],a=0,s=0,u=0;u<256;++u){var c=s^s<<1^s<<2^s<<3^s<<4;c=c>>>8^255&c^99,r[a]=c,n[c]=a;var l=e[a],f=e[l],h=e[f],d=257*e[c]^16843008*c;i[0][a]=d<<24|d>>>8,i[1][a]=d<<16|d>>>16,i[2][a]=d<<8|d>>>24,i[3][a]=d,d=16843009*h^65537*f^257*l^16843008*a,o[0][c]=d<<24|d>>>8,o[1][c]=d<<16|d>>>16,o[2][c]=d<<8|d>>>24,o[3][c]=d,0===a?a=s=1:(a=l^e[e[e[h^l]]],s^=e[e[s]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:o}}();function c(e){this._key=i(e),this._reset()}c.blockSize=16,c.keySize=32,c.prototype.blockSize=c.blockSize,c.prototype.keySize=c.keySize,c.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=4*(r+1),i=[],o=0;o>>24,a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a],a^=s[o/t|0]<<24):t>6&&o%t==4&&(a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a]),i[o]=i[o-t]^a}for(var c=[],l=0;l>>24]]^u.INV_SUB_MIX[1][u.SBOX[h>>>16&255]]^u.INV_SUB_MIX[2][u.SBOX[h>>>8&255]]^u.INV_SUB_MIX[3][u.SBOX[255&h]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=c},c.prototype.encryptBlockRaw=function(e){return a(e=i(e),this._keySchedule,u.SUB_MIX,u.SBOX,this._nRounds)},c.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=n.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},c.prototype.decryptBlock=function(e){var t=(e=i(e))[1];e[1]=e[3],e[3]=t;var r=a(e,this._invKeySchedule,u.INV_SUB_MIX,u.INV_SBOX,this._nRounds),o=n.allocUnsafe(16);return o.writeUInt32BE(r[0],0),o.writeUInt32BE(r[3],4),o.writeUInt32BE(r[2],8),o.writeUInt32BE(r[1],12),o},c.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},e.exports.AES=c},426:(e,t,r)=>{"use strict";var n=r(7494),i=r(8850).Buffer,o=r(3013),a=r(1736),s=r(6626),u=r(6316),c=r(7557);function l(e,t,r,a){o.call(this);var u=i.alloc(4,0);this._cipher=new n.AES(t);var l=this._cipher.encryptBlock(u);this._ghash=new s(l),r=function(e,t,r){if(12===t.length)return e._finID=i.concat([t,i.from([0,0,0,1])]),i.concat([t,i.from([0,0,0,2])]);var n=new s(r),o=t.length,a=o%16;n.update(t),a&&(a=16-a,n.update(i.alloc(a,0))),n.update(i.alloc(8,0));var u=8*o,l=i.alloc(8);l.writeUIntBE(u,0,8),n.update(l),e._finID=n.state;var f=i.from(e._finID);return c(f),f}(this,r,l),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}a(l,o),l.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=i.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},l.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=u(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i{"use strict";var n=r(5478),i=r(2184),o=r(4946);t.createCipher=t.Cipher=n.createCipher,t.createCipheriv=t.Cipheriv=n.createCipheriv,t.createDecipher=t.Decipher=i.createDecipher,t.createDecipheriv=t.Decipheriv=i.createDecipheriv,t.listCiphers=t.getCiphers=function(){return Object.keys(o)}},2184:(e,t,r)=>{"use strict";var n=r(426),i=r(8850).Buffer,o=r(8408),a=r(1408),s=r(3013),u=r(7494),c=r(7085);function l(e,t,r){s.call(this),this._cache=new f,this._last=void 0,this._cipher=new u.AES(t),this._prev=i.from(r),this._mode=e,this._autopadding=!0}function f(){this.cache=i.allocUnsafe(0)}function h(e,t,r){var s=o[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=i.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=i.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===s.type?new a(s.module,t,r,!0):"auth"===s.type?new n(s.module,t,r,!0):new l(s.module,t,r)}r(1736)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return i.concat(n)},l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");for(var r=-1;++r16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},f.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=function(e,t){var r=o[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=c(t,!1,r.key,r.iv);return h(e,n.key,n.iv)},t.createDecipheriv=h},5478:(e,t,r)=>{"use strict";var n=r(8408),i=r(426),o=r(8850).Buffer,a=r(1408),s=r(3013),u=r(7494),c=r(7085);function l(e,t,r){s.call(this),this._cache=new h,this._cipher=new u.AES(t),this._prev=o.from(r),this._mode=e,this._autopadding=!0}r(1736)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return o.concat(n)};var f=o.alloc(16,16);function h(){this.cache=o.allocUnsafe(0)}function d(e,t,r){var s=n[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=o.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof r&&(r=o.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);return"stream"===s.type?new a(s.module,t,r):"auth"===s.type?new i(s.module,t,r):new l(s.module,t,r)}l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(f))throw this._cipher.scrub(),new Error("data not multiple of block length")},l.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},h.prototype.add=function(e){this.cache=o.concat([this.cache,e])},h.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},h.prototype.flush=function(){for(var e=16-this.cache.length,t=o.allocUnsafe(e),r=-1;++r{"use strict";var n=r(8850).Buffer,i=n.alloc(16,0);function o(e){var t=n.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function a(e){this.h=e,this.state=n.alloc(16,0),this.cache=n.allocUnsafe(0)}a.prototype.ghash=function(e){for(var t=-1;++t0;t--)n[t]=n[t]>>>1|(1&n[t-1])<<31;n[0]=n[0]>>>1,r&&(n[0]=n[0]^225<<24)}this.state=o(i)},a.prototype.update=function(e){var t;for(this.cache=n.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},a.prototype.final=function(e,t){return this.cache.length&&this.ghash(n.concat([this.cache,i],16)),this.ghash(o([0,e,0,t])),this.state},e.exports=a},7557:e=>{"use strict";e.exports=function(e){for(var t,r=e.length;r--;){if(255!==(t=e.readUInt8(r))){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}},7427:(e,t,r)=>{"use strict";var n=r(6316);t.encrypt=function(e,t){var r=n(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},t.decrypt=function(e,t){var r=e._prev;e._prev=t;var i=e._cipher.decryptBlock(t);return n(i,r)}},4030:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(6316);function o(e,t,r){var o=t.length,a=i(t,e._cache);return e._cache=e._cache.slice(o),e._prev=n.concat([e._prev,r?t:a]),a}t.encrypt=function(e,t,r){for(var i,a=n.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=n.allocUnsafe(0)),!(e._cache.length<=t.length)){a=n.concat([a,o(e,t,r)]);break}i=e._cache.length,a=n.concat([a,o(e,t.slice(0,i),r)]),t=t.slice(i)}return a}},3206:(e,t,r)=>{"use strict";var n=r(8850).Buffer;function i(e,t,r){for(var n,i,a=-1,s=0;++a<8;)n=t&1<<7-a?128:0,s+=(128&(i=e._cipher.encryptBlock(e._prev)[0]^n))>>a%8,e._prev=o(e._prev,r?n:i);return s}function o(e,t){var r=e.length,i=-1,o=n.allocUnsafe(e.length);for(e=n.concat([e,n.from([t])]);++i>7;return o}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{"use strict";var n=r(8850).Buffer;function i(e,t,r){var i=e._cipher.encryptBlock(e._prev)[0]^t;return e._prev=n.concat([e._prev.slice(1),n.from([r?t:i])]),i}t.encrypt=function(e,t,r){for(var o=t.length,a=n.allocUnsafe(o),s=-1;++s{"use strict";var n=r(6316),i=r(8850).Buffer,o=r(7557);function a(e){var t=e._cipher.encryptBlockRaw(e._prev);return o(e._prev),t}t.encrypt=function(e,t){var r=Math.ceil(t.length/16),o=e._cache.length;e._cache=i.concat([e._cache,i.allocUnsafe(16*r)]);for(var s=0;s{"use strict";t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},8408:(e,t,r)=>{"use strict";var n={ECB:r(9297),CBC:r(7427),CFB:r(4030),CFB8:r(4726),CFB1:r(3206),OFB:r(1962),CTR:r(2802),GCM:r(2802)},i=r(4946);for(var o in i)i[o].module=n[i[o].mode];e.exports=i},1962:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(6316);function o(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(e,t){for(;e._cache.length{"use strict";var n=r(7494),i=r(8850).Buffer,o=r(3013);function a(e,t,r,a){o.call(this),this._cipher=new n.AES(t),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=a,this._mode=e}r(1736)(a,o),a.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},a.prototype._final=function(){this._cipher.scrub()},e.exports=a},6805:(e,t,r)=>{"use strict";var n=r(9120),i=r(8073),o=r(8408),a=r(867),s=r(7085);function u(e,t,r){if(e=e.toLowerCase(),o[e])return i.createCipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function c(e,t,r){if(e=e.toLowerCase(),o[e])return i.createDecipheriv(e,t,r);if(a[e])return new n({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}t.createCipher=t.Cipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return u(e,i.key,i.iv)},t.createCipheriv=t.Cipheriv=u,t.createDecipher=t.Decipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!a[e])throw new TypeError("invalid suite type");r=8*a[e].key,n=a[e].iv}var i=s(t,!1,r,n);return c(e,i.key,i.iv)},t.createDecipheriv=t.Decipheriv=c,t.listCiphers=t.getCiphers=function(){return Object.keys(a).concat(i.getCiphers())}},9120:(e,t,r)=>{"use strict";var n=r(3013),i=r(5626),o=r(1736),a=r(8850).Buffer,s={"des-ede3-cbc":i.CBC.instantiate(i.EDE),"des-ede3":i.EDE,"des-ede-cbc":i.CBC.instantiate(i.EDE),"des-ede":i.EDE,"des-cbc":i.CBC.instantiate(i.DES),"des-ecb":i.DES};function u(e){n.call(this);var t,r=e.mode.toLowerCase(),i=s[r];t=e.decrypt?"decrypt":"encrypt";var o=e.key;a.isBuffer(o)||(o=a.from(o)),"des-ede"!==r&&"des-ede-cbc"!==r||(o=a.concat([o,o.slice(0,8)]));var u=e.iv;a.isBuffer(u)||(u=a.from(u)),this._des=i.create({key:o,iv:u,type:t})}s.des=s["des-cbc"],s.des3=s["des-ede3-cbc"],e.exports=u,o(u,n),u.prototype._update=function(e){return a.from(this._des.update(e))},u.prototype._final=function(){return a.from(this._des.final())}},867:(e,t)=>{"use strict";t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}},9782:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(1734),o=r(5010);function a(e){var t,r=e.modulus.byteLength();do{t=new i(o(r))}while(t.cmp(e.modulus)>=0||!t.umod(e.prime1)||!t.umod(e.prime2));return t}function s(e,t){var r=function(e){var t=a(e);return{blinder:t.toRed(i.mont(e.modulus)).redPow(new i(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(t),o=t.modulus.byteLength(),s=new i(e).mul(r.blinder).umod(t.modulus),u=s.toRed(i.mont(t.prime1)),c=s.toRed(i.mont(t.prime2)),l=t.coefficient,f=t.prime1,h=t.prime2,d=u.redPow(t.exponent1).fromRed(),p=c.redPow(t.exponent2).fromRed(),m=d.isub(p).imul(l).umod(f).imul(h);return p.iadd(m).imul(r.unblinder).umod(t.modulus).toArrayLike(n,"be",o)}s.getr=a,e.exports=s},6561:(e,t,r)=>{"use strict";e.exports=r(5207)},9527:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(5866),o=r(6505),a=r(1736),s=r(1628),u=r(5410),c=r(5207);function l(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function f(e){o.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hash=i(t.hash),this._tag=t.id,this._signType=t.sign}function h(e){return new l(e)}function d(e){return new f(e)}Object.keys(c).forEach((function(e){c[e].id=n.from(c[e].id,"hex"),c[e.toLowerCase()]=c[e]})),a(l,o.Writable),l.prototype._write=function(e,t,r){this._hash.update(e),r()},l.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},l.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),n=s(r,e,this._hashType,this._signType,this._tag);return t?n.toString(t):n},a(f,o.Writable),f.prototype._write=function(e,t,r){this._hash.update(e),r()},f.prototype.update=function(e,t){return"string"==typeof e&&(e=n.from(e,t)),this._hash.update(e),this},f.prototype.verify=function(e,t,r){"string"==typeof t&&(t=n.from(t,r)),this.end();var i=this._hash.digest();return u(t,i,e,this._signType,this._tag)},e.exports={Sign:h,Verify:d,createSign:h,createVerify:d}},1628:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(4424),o=r(9782),a=r(6597).ec,s=r(1734),u=r(7552),c=r(1308);function l(e,t,r,o){if((e=n.from(e.toArray())).length0&&r.ishrn(n),r}function h(e,t,r){var o,a;do{for(o=n.alloc(0);8*o.length{"use strict";var n=r(8850).Buffer,i=r(1734),o=r(6597).ec,a=r(7552),s=r(1308);function u(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=t)throw new Error("invalid sig")}e.exports=function(e,t,r,c,l){var f=a(r);if("ec"===f.type){if("ecdsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=s[r.data.algorithm.curve.join(".")];if(!n)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var i=new o(n),a=r.data.subjectPrivateKey.data;return i.verify(t,e,a)}(e,t,f)}if("dsa"===f.type){if("dsa"!==c)throw new Error("wrong public key type");return function(e,t,r){var n=r.data.p,o=r.data.q,s=r.data.g,c=r.data.pub_key,l=a.signature.decode(e,"der"),f=l.s,h=l.r;u(f,o),u(h,o);var d=i.mont(n),p=f.invm(o);return 0===s.toRed(d).redPow(new i(t).mul(p).mod(o)).fromRed().mul(c.toRed(d).redPow(h.mul(p).mod(o)).fromRed()).mod(n).mod(o).cmp(h)}(e,t,f)}if("rsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");t=n.concat([l,t]);for(var h=f.modulus.byteLength(),d=[1],p=0;t.length+d.length+2{"use strict";var n=r(9033).Buffer;e.exports=function(e,t){for(var r=Math.min(e.length,t.length),i=new n(r),o=0;o{"use strict";var n=r(4919),i=r(3226),o=r(9484);function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function p(e,t){if(u.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return j(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return H(e).length;default:if(n)return j(e).length;t=(""+t).toLowerCase(),n=!0}}function m(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return I(this,t,r);case"utf8":case"utf-8":return M(this,t,r);case"ascii":return x(this,t,r);case"latin1":case"binary":return P(this,t,r);case"base64":return _(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function y(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function g(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=u.from(t,n)),u.isBuffer(t))return 0===t.length?-1:b(e,t,r,n,i);if("number"==typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):b(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function b(e,t,r,n,i){var o,a=1,s=e.length,u=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,r/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var l=-1;for(o=r;os&&(r=s-u),o=r;o>=0;o--){for(var f=!0,h=0;hi&&(n=i):n=i;var o=t.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var a=0;a>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function _(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function M(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i239?4:c>223?3:c>191?2:1;if(i+f<=r)switch(f){case 1:c<128&&(l=c);break;case 2:128==(192&(o=e[i+1]))&&(u=(31&c)<<6|63&o)>127&&(l=u);break;case 3:o=e[i+1],a=e[i+2],128==(192&o)&&128==(192&a)&&(u=(15&c)<<12|(63&o)<<6|63&a)>2047&&(u<55296||u>57343)&&(l=u);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(u=(15&c)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(l=u)}null===l?(l=65533,f=1):l>65535&&(l-=65536,n.push(l>>>10&1023|55296),l=56320|1023&l),n.push(l),i+=f}return function(e){var t=e.length;if(t<=T)return String.fromCharCode.apply(String,e);for(var r="",n=0;n0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),""},u.prototype.compare=function(e,t,r,n,i){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0),s=Math.min(o,a),c=this.slice(n,i),l=e.slice(t,r),f=0;fi)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return v(this,e,t,r);case"utf8":case"utf-8":return w(this,e,t,r);case"ascii":return A(this,e,t,r);case"latin1":case"binary":return S(this,e,t,r);case"base64":return k(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var T=4096;function x(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;ii)&&(r=i);for(var o="",a=t;ar)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,r,n,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function B(e,t,r,n){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-r,2);i>>8*(n?i:1-i)}function N(e,t,r,n){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-r,4);i>>8*(n?i:3-i)&255}function L(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function U(e,t,r,n,o){return o||L(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function F(e,t,r,n,o){return o||L(e,0,r,8),i.write(e,t,r,n,52,8),r+8}u.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t0&&(i*=256);)n+=this[e+--t]*i;return n},u.prototype.readUInt8=function(e,t){return t||R(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||R(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||R(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||R(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||R(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=this[e],i=1,o=0;++o=(i*=128)&&(n-=Math.pow(2,8*t)),n},u.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=t,i=1,o=this[e+--n];n>0&&(i*=256);)o+=this[e+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return t||R(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||R(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(e,t){t||R(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(e,t){return t||R(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||R(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||R(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||R(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||R(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||R(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,r,n){e=+e,t|=0,r|=0,n||C(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[t]=255&e;++o=0&&(o*=256);)this[t+i]=e/o&255;return t+r},u.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):N(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);C(this,e,t,r,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+r},u.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);C(this,e,t,r,i-1,-i)}var o=r-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+r},u.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):N(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,r){return U(this,e,t,!0,r)},u.prototype.writeFloatBE=function(e,t,r){return U(this,e,t,!1,r)},u.prototype.writeDoubleLE=function(e,t,r){return F(this,e,t,!0,r)},u.prototype.writeDoubleBE=function(e,t,r){return F(this,e,t,!1,r)},u.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t=0;--i)e[i+t]=this[i+r];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function H(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(D,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function J(e,t,r,n){for(var i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}},3675:e=>{"use strict";e.exports={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}},593:(e,t,r)=>{"use strict";var n=r(7701),i=r(4373),o=i(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&o(e,".prototype.")>-1?i(r):r}},4373:(e,t,r)=>{"use strict";var n=r(3767),i=r(7701),o=i("%Function.prototype.apply%"),a=i("%Function.prototype.call%"),s=i("%Reflect.apply%",!0)||n.call(a,o),u=i("%Object.getOwnPropertyDescriptor%",!0),c=i("%Object.defineProperty%",!0),l=i("%Math.max%");if(c)try{c({},"a",{value:1})}catch(e){c=null}e.exports=function(e){var t=s(n,a,arguments);if(u&&c){var r=u(t,"length");r.configurable&&c(t,"length",{value:1+l(0,e.length-(arguments.length-1))})}return t};var f=function(){return s(n,o,arguments)};c?c(e.exports,"apply",{value:f}):e.exports.apply=f},7759:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(3630),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(9033).Buffer,i=r(6657),o=r(5262),a=r(1842),s=r(779);(t=e.exports).addPrefix=function(e,t){var r;if(n.isBuffer(e))r=s.varintBufferEncode(e);else{if(!a[e])throw new Error("multicodec not recognized");r=a[e]}return n.concat([r,t])},t.rmPrefix=function(e){return i.decode(e),e.slice(i.decode.bytes)},t.getCodec=function(e){var t=i.decode(e),r=o.get(t);if(void 0===r)throw new Error("Code ".concat(t," not found"));return r},t.getName=function(e){return o.get(e)},t.getNumber=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return s.varintBufferDecode(t)[0]},t.getCode=function(e){return i.decode(e)},t.getCodeVarint=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return t},t.getVarint=function(e){return i.encode(e)};var u=r(7759);Object.assign(t,u),t.print=r(9268)},5262:(e,t,r)=>{"use strict";var n=r(3630),i=new Map;for(var o in n){var a=n[o];i.set(a,o)}e.exports=Object.freeze(i)},9268:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(3630),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(6657),i=r(9033).Buffer;function o(e){return parseInt(e.toString("hex"),16)}function a(e){var t=e.toString(16);return t.length%2==1&&(t="0"+t),i.from(t,"hex")}e.exports={numberToBuffer:a,bufferToNumber:o,varintBufferEncode:function(e){return i.from(n.encode(o(e)))},varintBufferDecode:function(e){return a(n.decode(e))},varintEncode:function(e){return i.from(n.encode(e))}}},1842:(e,t,r)=>{"use strict";var n=r(3630),i=r(779).varintEncode,o={};for(var a in n){var s=n[a];o[a]=i(s)}e.exports=Object.freeze(o)},9976:(e,t,r)=>{"use strict";var n=r(7748),i=r(9033).Buffer,o={checkCIDComponents:function(e){if(null==e)return"null values are not valid CIDs";if(0!==e.version&&1!==e.version)return"Invalid version, must be a number equal to 1 or 0";if("string"!=typeof e.codec)return"codec must be string";if(0===e.version){if("dag-pb"!==e.codec)return"codec must be 'dag-pb' for CIDv0";if("base58btc"!==e.multibaseName)return"multibaseName must be 'base58btc' for CIDv0"}if(!i.isBuffer(e.multihash))return"multihash must be a Buffer";try{n.validate(e.multihash)}catch(e){var t=e.message;return t||(t="Multihash validation failed"),t}}};e.exports=o},2753:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=r(9033).Buffer,s=r(7748),u=r(6086),c=r(7223),l=r(3630),f=r(9976),h=r(3162)(function(e){function t(e,r,n,o){if((0,i.default)(this,t),h.isCID(e)){var l=e;return this.version=l.version,this.codec=l.codec,this.multihash=a.from(l.multihash),void(this.multibaseName=l.multibaseName||(0===l.version?"base58btc":"base32"))}if("string"==typeof e){var f=u.isEncoded(e);if(f){var d=u.decode(e);this.version=parseInt(d.slice(0,1).toString("hex"),16),this.codec=c.getCodec(d.slice(1)),this.multihash=c.rmPrefix(d.slice(1)),this.multibaseName=f}else this.version=0,this.codec="dag-pb",this.multihash=s.fromB58String(e),this.multibaseName="base58btc";return t.validateCID(this),void Object.defineProperty(this,"string",{value:e})}if(a.isBuffer(e)){var p=e.slice(0,1),m=parseInt(p.toString("hex"),16);if(1===m){var y=e;this.version=m,this.codec=c.getCodec(y.slice(1)),this.multihash=c.rmPrefix(y.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=e,this.multibaseName="base58btc";t.validateCID(this)}else this.version=e,this.codec=r,this.multihash=n,this.multibaseName=o||(0===e?"base58btc":"base32"),t.validateCID(this)}return(0,o.default)(t,[{key:"buffer",get:function(){var e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=a.concat([a.from("01","hex"),c.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}},{key:"prefix",get:function(){return a.concat([a.from("0".concat(this.version),"hex"),c.getCodeVarint(this.codec),s.prefix(this.multihash)])}},{key:"toV0",value:function(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");var e=s.decode(this.multihash),t=e.name,r=e.length;if("sha2-256"!==t)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==r)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new h(0,this.codec,this.multihash)}},{key:"toV1",value:function(){return new h(1,this.codec,this.multihash)}},{key:"toBaseEncodedString",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.multibaseName;if(this.string&&e===this.multibaseName)return this.string;var t=null;if(0===this.version){if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");t=s.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");t=u.encode(e,this.buffer).toString()}return e===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}},{key:e,value:function(){return"CID("+this.toString()+")"}},{key:"toString",value:function(e){return this.toBaseEncodedString(e)}},{key:"toJSON",value:function(){return{codec:this.codec,version:this.version,hash:this.multihash}}},{key:"equals",value:function(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}}],[{key:"validateCID",value:function(e){var t=f.checkCIDComponents(e);if(t)throw new Error(t)}}]),t}(Symbol.for("nodejs.util.inspect.custom")),{className:"CID",symbolName:"@ipld/js-cid/CID"});h.codecs=l,e.exports=h},3013:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(7245).Transform,o=r(3462).s;function a(e){i.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(1736)(a,i),a.prototype.update=function(e,t,r){"string"==typeof e&&(e=n.from(e,t));var i=this._update(e);return this.hashMode?this:(r&&(i=this._toString(i,r)),i)},a.prototype.setAutoPadding=function(){},a.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},a.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},a.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},a.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){n=e}finally{r(n)}},a.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},a.prototype._finalOrDigest=function(e){var t=this.__final()||n.alloc(0);return e&&(t=this._toString(t,e,!0)),t},a.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new o(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n},e.exports=a},3162:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(4727)),o=n(r(775)),a=n(r(9721)),s=n(r(8985)),u=n(r(8975)),c=n(r(5163)),l=n(r(4650)),f=n(r(1949));e.exports=function(e,t){var r=t.className,n=t.symbolName,i=Symbol.for(n),h=(0,o.default)({},r,function(e,t){(0,c.default)(d,e);var n,o,h=(n=d,o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=(0,f.default)(n);if(o){var r=(0,f.default)(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return(0,l.default)(this,e)});function d(){var e;(0,a.default)(this,d);for(var t=arguments.length,r=new Array(t),n=0;n{"use strict";var n=r(2753);t.cidV0ToV1Base32=function(e){var t=new n(e);return 0===t.version&&(t=t.toV1()),t.toString("base32")}},4308:(e,t,r)=>{"use strict";var n=r(9206),i=r(9512),o=i.hexStringToBuffer,a=i.profiles,s=r(6834).cidV0ToV1Base32;e.exports={helpers:{cidV0ToV1Base32:s},decode:function(e){var t=o(e),r=n.getCodec(t),i=n.rmPrefix(t),s=a[r];return s||(s=a.default),s.decode(i)},fromIpfs:function(e){return this.encode("ipfs-ns",e)},fromSwarm:function(e){return this.encode("swarm-ns",e)},encode:function(e,t){var r=a[e];r||(r=a.default);var i=r.encode(t);return n.addPrefix(e,i).toString("hex")},getCodec:function(e){var t=o(e);return n.getCodec(t)}}},9512:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(2753),o=r(7748),a=function(e){var t,r=e.slice(0,2),n=e.slice(2);return t="0x"===r?n:e,o.fromHexString(t)},s={swarm:function(e){var t=o.encode(a(e),"keccak-256");return new i(1,"swarm-manifest",t).buffer},ipfs:function(e){var t=o.fromB58String(e);return new i(1,"dag-pb",t).buffer},utf8:function(e){return n.from(e,"utf8")}},u={hexMultiHash:function(e){var t=new i(e);return o.decode(t.multihash).digest.toString("hex")},b58MultiHash:function(e){var t=new i(e);return o.toB58String(t.multihash)},utf8:function(e){return e.toString("utf8")}},c={"swarm-ns":{encode:s.swarm,decode:u.hexMultiHash},"ipfs-ns":{encode:s.ipfs,decode:u.b58MultiHash},"ipns-ns":{encode:s.ipfs,decode:u.b58MultiHash},default:{encode:s.utf8,decode:u.utf8}};t.hexStringToBuffer=a,t.profiles=c},4628:(e,t,r)=>{"use strict";var n,i,o=r(8847)(r(3355));i=function(e){e.version="1.2.2";var t=function(){for(var e=0,t=new Array(256),r=0;256!=r;++r)e=1&(e=1&(e=1&(e=1&(e=1&(e=1&(e=1&(e=1&(e=r)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1)?-306674912^e>>>1:e>>>1,t[r]=e;return"undefined"!=typeof Int32Array?new Int32Array(t):t}(),r=function(e){var t=0,r=0,n=0,i="undefined"!=typeof Int32Array?new Int32Array(4096):new Array(4096);for(n=0;256!=n;++n)i[n]=e[n];for(n=0;256!=n;++n)for(r=e[n],t=256+n;t<4096;t+=256)r=i[t]=r>>>8^e[255&r];var o=[];for(n=1;16!=n;++n)o[n-1]="undefined"!=typeof Int32Array?i.subarray(256*n,256*n+256):i.slice(256*n,256*n+256);return o}(t),n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],u=r[5],c=r[6],l=r[7],f=r[8],h=r[9],d=r[10],p=r[11],m=r[12],y=r[13],g=r[14];e.table=t,e.bstr=function(e,r){for(var n=-1^r,i=0,o=e.length;i>>8^t[255&(n^e.charCodeAt(i++))];return~n},e.buf=function(e,r){for(var b=-1^r,v=e.length-15,w=0;w>8&255]^m[e[w++]^b>>16&255]^p[e[w++]^b>>>24]^d[e[w++]]^h[e[w++]]^f[e[w++]]^l[e[w++]]^c[e[w++]]^u[e[w++]]^s[e[w++]]^a[e[w++]]^o[e[w++]]^i[e[w++]]^n[e[w++]]^t[e[w++]];for(v+=15;w>>8^t[255&(b^e[w++])];return~b},e.str=function(e,r){for(var n=-1^r,i=0,o=e.length,a=0,s=0;i>>8^t[255&(n^a)]:a<2048?n=(n=n>>>8^t[255&(n^(192|a>>6&31))])>>>8^t[255&(n^(128|63&a))]:a>=55296&&a<57344?(a=64+(1023&a),s=1023&e.charCodeAt(i++),n=(n=(n=(n=n>>>8^t[255&(n^(240|a>>8&7))])>>>8^t[255&(n^(128|a>>2&63))])>>>8^t[255&(n^(128|s>>6&15|(3&a)<<4))])>>>8^t[255&(n^(128|63&s))]):n=(n=(n=n>>>8^t[255&(n^(224|a>>12&15))])>>>8^t[255&(n^(128|a>>6&63))])>>>8^t[255&(n^(128|63&a))];return~n}},"undefined"==typeof DO_NOT_EXPORT_CRC?"object"===(0,o.default)(t)?i(t):(n=function(){var e={};return i(e),e}.call(t,r,t,e),void 0===n||(e.exports=n)):i({})},5102:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(6597),o=r(1734);e.exports=function(e){return new s(e)};var a={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function s(e){this.curveType=a[e],this.curveType||(this.curveType={name:e}),this.curve=new i.ec(this.curveType.name),this.keys=void 0}function u(e,t,r){Array.isArray(e)||(e=e.toArray());var i=new n(e);if(r&&i.length{"use strict";var n=r(1736),i=r(807),o=r(6707),a=r(1708),s=r(3013);function u(e){s.call(this,"digest"),this._hash=e}n(u,s),u.prototype._update=function(e){this._hash.update(e)},u.prototype._final=function(){return this._hash.digest()},e.exports=function(e){return"md5"===(e=e.toLowerCase())?new i:"rmd160"===e||"ripemd160"===e?new o:new u(a(e))}},5349:(e,t,r)=>{"use strict";var n=r(807);e.exports=function(e){return(new n).update(e).digest()}},4424:(e,t,r)=>{"use strict";var n=r(1736),i=r(9956),o=r(3013),a=r(8850).Buffer,s=r(5349),u=r(6707),c=r(1708),l=a.alloc(128);function f(e,t){o.call(this,"digest"),"string"==typeof t&&(t=a.from(t));var r="sha512"===e||"sha384"===e?128:64;this._alg=e,this._key=t,t.length>r?t=("rmd160"===e?new u:c(e)).update(t).digest():t.length{"use strict";var n=r(1736),i=r(8850).Buffer,o=r(3013),a=i.alloc(128),s=64;function u(e,t){o.call(this,"digest"),"string"==typeof t&&(t=i.from(t)),this._alg=e,this._key=t,t.length>s?t=e(t):t.length{"use strict";!function(e){!function(t){var r="URLSearchParams"in e,n="Symbol"in e&&"iterator"in Symbol,i="FileReader"in e&&"Blob"in e&&function(){try{return new Blob,!0}catch(e){return!1}}(),o="FormData"in e,a="ArrayBuffer"in e;if(a)var s=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],u=ArrayBuffer.isView||function(e){return e&&s.indexOf(Object.prototype.toString.call(e))>-1};function c(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(e))throw new TypeError("Invalid character in header field name");return e.toLowerCase()}function l(e){return"string"!=typeof e&&(e=String(e)),e}function f(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return n&&(t[Symbol.iterator]=function(){return t}),t}function h(e){this.map={},e instanceof h?e.forEach((function(e,t){this.append(t,e)}),this):Array.isArray(e)?e.forEach((function(e){this.append(e[0],e[1])}),this):e&&Object.getOwnPropertyNames(e).forEach((function(t){this.append(t,e[t])}),this)}function d(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function p(e){return new Promise((function(t,r){e.onload=function(){t(e.result)},e.onerror=function(){r(e.error)}}))}function m(e){var t=new FileReader,r=p(t);return t.readAsArrayBuffer(e),r}function y(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function g(){return this.bodyUsed=!1,this._initBody=function(e){var t;this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:i&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:o&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:r&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():a&&i&&(t=e)&&DataView.prototype.isPrototypeOf(t)?(this._bodyArrayBuffer=y(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):a&&(ArrayBuffer.prototype.isPrototypeOf(e)||u(e))?this._bodyArrayBuffer=y(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):r&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},i&&(this.blob=function(){var e=d(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?d(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(m)}),this.text=function(){var e,t,r,n=d(this);if(n)return n;if(this._bodyBlob)return e=this._bodyBlob,r=p(t=new FileReader),t.readAsText(e),r;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),r=new Array(t.length),n=0;n-1?n:r),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(i)}function w(e){var t=new FormData;return e.trim().split("&").forEach((function(e){if(e){var r=e.split("="),n=r.shift().replace(/\+/g," "),i=r.join("=").replace(/\+/g," ");t.append(decodeURIComponent(n),decodeURIComponent(i))}})),t}function A(e,t){t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"OK",this.headers=new h(t.headers),this.url=t.url||"",this._initBody(e)}v.prototype.clone=function(){return new v(this,{body:this._bodyInit})},g.call(v.prototype),g.call(A.prototype),A.prototype.clone=function(){return new A(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},A.error=function(){var e=new A(null,{status:0,statusText:""});return e.type="error",e};var S=[301,302,303,307,308];A.redirect=function(e,t){if(-1===S.indexOf(t))throw new RangeError("Invalid status code");return new A(null,{status:t,headers:{location:e}})},t.DOMException=e.DOMException;try{new t.DOMException}catch(e){t.DOMException=function(e,t){this.message=e,this.name=t;var r=Error(e);this.stack=r.stack},t.DOMException.prototype=Object.create(Error.prototype),t.DOMException.prototype.constructor=t.DOMException}function k(e,r){return new Promise((function(n,o){var a=new v(e,r);if(a.signal&&a.signal.aborted)return o(new t.DOMException("Aborted","AbortError"));var s=new XMLHttpRequest;function u(){s.abort()}s.onload=function(){var e,t,r={status:s.status,statusText:s.statusText,headers:(e=s.getAllResponseHeaders()||"",t=new h,e.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(e){var r=e.split(":"),n=r.shift().trim();if(n){var i=r.join(":").trim();t.append(n,i)}})),t)};r.url="responseURL"in s?s.responseURL:r.headers.get("X-Request-URL");var i="response"in s?s.response:s.responseText;n(new A(i,r))},s.onerror=function(){o(new TypeError("Network request failed"))},s.ontimeout=function(){o(new TypeError("Network request failed"))},s.onabort=function(){o(new t.DOMException("Aborted","AbortError"))},s.open(a.method,a.url,!0),"include"===a.credentials?s.withCredentials=!0:"omit"===a.credentials&&(s.withCredentials=!1),"responseType"in s&&i&&(s.responseType="blob"),a.headers.forEach((function(e,t){s.setRequestHeader(t,e)})),a.signal&&(a.signal.addEventListener("abort",u),s.onreadystatechange=function(){4===s.readyState&&a.signal.removeEventListener("abort",u)}),s.send(void 0===a._bodyInit?null:a._bodyInit)}))}k.polyfill=!0,e.fetch||(e.fetch=k,e.Headers=h,e.Request=v,e.Response=A),t.Headers=h,t.Request=v,t.Response=A,t.fetch=k,Object.defineProperty(t,"__esModule",{value:!0})}({})}("undefined"!=typeof self?self:void 0)},4293:(e,t,r)=>{"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=r(5010),t.createHash=t.Hash=r(5866),t.createHmac=t.Hmac=r(4424);var n=r(6561),i=Object.keys(n),o=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(i);t.getHashes=function(){return o};var a=r(4192);t.pbkdf2=a.pbkdf2,t.pbkdf2Sync=a.pbkdf2Sync;var s=r(6805);t.Cipher=s.Cipher,t.createCipher=s.createCipher,t.Cipheriv=s.Cipheriv,t.createCipheriv=s.createCipheriv,t.Decipher=s.Decipher,t.createDecipher=s.createDecipher,t.Decipheriv=s.Decipheriv,t.createDecipheriv=s.createDecipheriv,t.getCiphers=s.getCiphers,t.listCiphers=s.listCiphers;var u=r(8333);t.DiffieHellmanGroup=u.DiffieHellmanGroup,t.createDiffieHellmanGroup=u.createDiffieHellmanGroup,t.getDiffieHellman=u.getDiffieHellman,t.createDiffieHellman=u.createDiffieHellman,t.DiffieHellman=u.DiffieHellman;var c=r(9527);t.createSign=c.createSign,t.Sign=c.Sign,t.createVerify=c.createVerify,t.Verify=c.Verify,t.createECDH=r(5102);var l=r(6991);t.publicEncrypt=l.publicEncrypt,t.privateEncrypt=l.privateEncrypt,t.publicDecrypt=l.publicDecrypt,t.privateDecrypt=l.privateDecrypt;var f=r(6509);t.randomFill=f.randomFill,t.randomFillSync=f.randomFillSync,t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},34:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i="%[a-f0-9]{2}",o=new RegExp("("+i+")|([^%]+?)","gi"),a=new RegExp("("+i+")+","gi");function s(e,t){try{return[decodeURIComponent(e.join(""))]}catch(e){}if(1===e.length)return e;t=t||1;var r=e.slice(0,t),n=e.slice(t);return Array.prototype.concat.call([],s(r),s(n))}function u(e){try{return decodeURIComponent(e)}catch(n){for(var t=e.match(o)||[],r=1;r{"use strict";t.utils=r(319),t.Cipher=r(9591),t.DES=r(3049),t.CBC=r(4375),t.EDE=r(9413)},4375:(e,t,r)=>{"use strict";var n=r(4504),i=r(1736),o={};function a(e){n.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t{"use strict";var n=r(4504);function i(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}e.exports=i,i.prototype._init=function(){},i.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},i.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n0;n--)t+=this._buffer(e,t),r+=this._flushBuffer(i,r);return t+=this._buffer(e,t),i},i.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},i.prototype._pad=function(e,t){if(0===t)return!1;for(;t{"use strict";var n=r(4504),i=r(1736),o=r(319),a=r(9591);function s(){this.tmp=new Array(2),this.keys=null}function u(e){a.call(this,e);var t=new s;this._desState=t,this.deriveKeys(t,e.key)}i(u,a),e.exports=u,u.create=function(e){return new u(e)};var c=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];u.prototype.deriveKeys=function(e,t){e.keys=new Array(32),n.equal(t.length,this.blockSize,"Invalid key length");var r=o.readUInt32BE(t,0),i=o.readUInt32BE(t,4);o.pc1(r,i,e.tmp,0),r=e.tmp[0],i=e.tmp[1];for(var a=0;a>>1];r=o.r28shl(r,s),i=o.r28shl(i,s),o.pc2(r,i,e.keys,a)}},u.prototype._update=function(e,t,r,n){var i=this._desState,a=o.readUInt32BE(e,t),s=o.readUInt32BE(e,t+4);o.ip(a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],"encrypt"===this.type?this._encrypt(i,a,s,i.tmp,0):this._decrypt(i,a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],o.writeUInt32BE(r,a,n),o.writeUInt32BE(r,s,n+4)},u.prototype._pad=function(e,t){for(var r=e.length-t,n=t;n>>0,a=h}o.rip(s,a,n,i)},u.prototype._decrypt=function(e,t,r,n,i){for(var a=r,s=t,u=e.keys.length-2;u>=0;u-=2){var c=e.keys[u],l=e.keys[u+1];o.expand(a,e.tmp,0),c^=e.tmp[0],l^=e.tmp[1];var f=o.substitute(c,l),h=a;a=(s^o.permute(f))>>>0,s=h}o.rip(a,s,n,i)}},9413:(e,t,r)=>{"use strict";var n=r(4504),i=r(1736),o=r(9591),a=r(3049);function s(e,t){n.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),i=t.slice(8,16),o=t.slice(16,24);this.ciphers="encrypt"===e?[a.create({type:"encrypt",key:r}),a.create({type:"decrypt",key:i}),a.create({type:"encrypt",key:o})]:[a.create({type:"decrypt",key:o}),a.create({type:"encrypt",key:i}),a.create({type:"decrypt",key:r})]}function u(e){o.call(this,e);var t=new s(this.type,this.options.key);this._edeState=t}i(u,o),e.exports=u,u.create=function(e){return new u(e)},u.prototype._update=function(e,t,r,n){var i=this._edeState;i.ciphers[0]._update(e,t,r,n),i.ciphers[1]._update(r,n,r,n),i.ciphers[2]._update(r,n,r,n)},u.prototype._pad=a.prototype._pad,u.prototype._unpad=a.prototype._unpad},319:(e,t)=>{"use strict";t.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},t.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},t.ip=function(e,t,r,n){for(var i=0,o=0,a=6;a>=0;a-=2){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>>s+a&1}for(a=6;a>=0;a-=2){for(s=1;s<=25;s+=8)o<<=1,o|=t>>>s+a&1;for(s=1;s<=25;s+=8)o<<=1,o|=e>>>s+a&1}r[n+0]=i>>>0,r[n+1]=o>>>0},t.rip=function(e,t,r,n){for(var i=0,o=0,a=0;a<4;a++)for(var s=24;s>=0;s-=8)i<<=1,i|=t>>>s+a&1,i<<=1,i|=e>>>s+a&1;for(a=4;a<8;a++)for(s=24;s>=0;s-=8)o<<=1,o|=t>>>s+a&1,o<<=1,o|=e>>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.pc1=function(e,t,r,n){for(var i=0,o=0,a=7;a>=5;a--){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>s+a&1}for(s=0;s<=24;s+=8)i<<=1,i|=t>>s+a&1;for(a=1;a<=3;a++){for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1;for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1}for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1;r[n+0]=i>>>0,r[n+1]=o>>>0},t.r28shl=function(e,t){return e<>>28-t};var r=[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];t.pc2=function(e,t,n,i){for(var o=0,a=0,s=r.length>>>1,u=0;u>>r[u]&1;for(u=s;u>>r[u]&1;n[i+0]=o>>>0,n[i+1]=a>>>0},t.expand=function(e,t,r){var n=0,i=0;n=(1&e)<<5|e>>>27;for(var o=23;o>=15;o-=4)n<<=6,n|=e>>>o&63;for(o=11;o>=3;o-=4)i|=e>>>o&63,i<<=6;i|=(31&e)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=i>>>0};var n=[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];t.substitute=function(e,t){for(var r=0,i=0;i<4;i++)r<<=4,r|=n[64*i+(e>>>18-6*i&63)];for(i=0;i<4;i++)r<<=4,r|=n[256+64*i+(t>>>18-6*i&63)];return r>>>0};var i=[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];t.permute=function(e){for(var t=0,r=0;r>>i[r]&1;return t>>>0},t.padSplit=function(e,t,r){for(var n=e.toString(2);n.length{"use strict";var n=r(9033).Buffer,i=r(8557),o=r(9799),a=r(1592),s={binary:!0,hex:!0,base64:!0};t.DiffieHellmanGroup=t.createDiffieHellmanGroup=t.getDiffieHellman=function(e){var t=new n(o[e].prime,"hex"),r=new n(o[e].gen,"hex");return new a(t,r)},t.createDiffieHellman=t.DiffieHellman=function e(t,r,o,u){return n.isBuffer(r)||void 0===s[r]?e(t,"binary",r,o):(r=r||"binary",u=u||"binary",o=o||new n([2]),n.isBuffer(o)||(o=new n(o,u)),"number"==typeof t?new a(i(t,o),o,!0):(n.isBuffer(t)||(t=new n(t,r)),new a(t,o,!0)))}},1592:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(1734),o=new(r(137)),a=new i(24),s=new i(11),u=new i(10),c=new i(3),l=new i(7),f=r(8557),h=r(5010);function d(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._pub=new i(e),this}function p(e,t){return t=t||"utf8",n.isBuffer(e)||(e=new n(e,t)),this._priv=new i(e),this}e.exports=y;var m={};function y(e,t,r){this.setGenerator(t),this.__prime=new i(e),this._prime=i.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=d,this.setPrivateKey=p):this._primeCode=8}function g(e,t){var r=new n(e.toArray());return t?r.toString(t):r}Object.defineProperty(y.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),n=[r,e.toString(16)].join("_");if(n in m)return m[n];var i,h=0;if(e.isEven()||!f.simpleSieve||!f.fermatTest(e)||!o.test(e))return h+=1,h+="02"===r||"05"===r?8:4,m[n]=h,h;switch(o.test(e.shrn(1))||(h+=2),r){case"02":e.mod(a).cmp(s)&&(h+=8);break;case"05":(i=e.mod(u)).cmp(c)&&i.cmp(l)&&(h+=8);break;default:h+=4}return m[n]=h,h}(this.__prime,this.__gen)),this._primeCode}}),y.prototype.generateKeys=function(){return this._priv||(this._priv=new i(h(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},y.prototype.computeSecret=function(e){var t=(e=(e=new i(e)).toRed(this._prime)).redPow(this._priv).fromRed(),r=new n(t.toArray()),o=this.getPrime();if(r.length{"use strict";var n=r(5010);e.exports=g,g.simpleSieve=m,g.fermatTest=y;var i=r(1734),o=new i(24),a=new(r(137)),s=new i(1),u=new i(2),c=new i(5),l=(new i(16),new i(8),new i(10)),f=new i(3),h=(new i(7),new i(11)),d=new i(4),p=(new i(12),null);function m(e){for(var t=function(){if(null!==p)return p;var e=[];e[0]=2;for(var t=1,r=3;r<1048576;r+=2){for(var n=Math.ceil(Math.sqrt(r)),i=0;ie;)r.ishrn(1);if(r.isEven()&&r.iadd(s),r.testn(1)||r.iadd(u),t.cmp(u)){if(!t.cmp(c))for(;r.mod(l).cmp(f);)r.iadd(d)}else for(;r.mod(o).cmp(h);)r.iadd(d);if(m(p=r.shrn(1))&&m(r)&&y(p)&&y(r)&&a.test(p)&&a.test(r))return r}}},6597:(e,t,r)=>{"use strict";var n=t;n.version=r(8597).i8,n.utils=r(7528),n.rand=r(2202),n.curve=r(6063),n.curves=r(506),n.ec=r(8320),n.eddsa=r(8027)},1249:(e,t,r)=>{"use strict";var n=r(1734),i=r(7528),o=i.getNAF,a=i.getJSF,s=i.assert;function u(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function c(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=u,u.prototype.point=function(){throw new Error("Not implemented")},u.prototype.validate=function(){throw new Error("Not implemented")},u.prototype._fixedNafMul=function(e,t){s(e.precomputed);var r=e._getDoubles(),n=o(t,1,this._bitLength),i=(1<=a;l--)u=(u<<1)+n[l];c.push(u)}for(var f=this.jpoint(null,null,null),h=this.jpoint(null,null,null),d=i;d>0;d--){for(a=0;a=0;c--){for(var l=0;c>=0&&0===a[c];c--)l++;if(c>=0&&l++,u=u.dblp(l),c<0)break;var f=a[c];s(0!==f),u="affine"===e.type?f>0?u.mixedAdd(i[f-1>>1]):u.mixedAdd(i[-f-1>>1].neg()):f>0?u.add(i[f-1>>1]):u.add(i[-f-1>>1].neg())}return"affine"===e.type?u.toP():u},u.prototype._wnafMulAdd=function(e,t,r,n,i){var s,u,c,l=this._wnafT1,f=this._wnafT2,h=this._wnafT3,d=0;for(s=0;s=1;s-=2){var m=s-1,y=s;if(1===l[m]&&1===l[y]){var g=[t[m],null,null,t[y]];0===t[m].y.cmp(t[y].y)?(g[1]=t[m].add(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg())):0===t[m].y.cmp(t[y].y.redNeg())?(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].add(t[y].neg())):(g[1]=t[m].toJ().mixedAdd(t[y]),g[2]=t[m].toJ().mixedAdd(t[y].neg()));var b=[-3,-1,-5,-7,0,7,5,1,3],v=a(r[m],r[y]);for(d=Math.max(v[0].length,d),h[m]=new Array(d),h[y]=new Array(d),u=0;u=0;s--){for(var E=0;s>=0;){var _=!0;for(u=0;u=0&&E++,S=S.dblp(E),s<0)break;for(u=0;u0?c=f[u][M-1>>1]:M<0&&(c=f[u][-M-1>>1].neg()),S="affine"===c.type?S.mixedAdd(c):S.add(c))}}for(s=0;s=Math.ceil((e.bitLength()+1)/t.step)},c.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i{"use strict";var n=r(7528),i=r(1734),o=r(1736),a=r(1249),s=n.assert;function u(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,a.call(this,"edwards",e),this.a=new i(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new i(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new i(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function c(e,t,r,n,o){a.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===n?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new i(t,16),this.y=new i(r,16),this.z=n?new i(n,16):this.curve.one,this.t=o&&new i(o,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}o(u,a),e.exports=u,u.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},u.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},u.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=n.redMul(o.redInvm()),s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");var u=s.fromRed().isOdd();return(t&&!u||!t&&u)&&(s=s.redNeg()),this.point(e,s)},u.prototype.pointFromY=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=n.redMul(o.redInvm());if(0===a.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");return s.fromRed().isOdd()!==t&&(s=s.redNeg()),this.point(s,e)},u.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===n.cmp(i)},o(c,a.BasePoint),u.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},u.prototype.point=function(e,t,r,n){return new c(this,e,t,r,n)},c.fromJSON=function(e,t){return new c(e,t[0],t[1],t[2])},c.prototype.inspect=function(){return this.isInfinity()?"":""},c.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},c.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),o=n.redAdd(t),a=o.redSub(r),s=n.redSub(t),u=i.redMul(a),c=o.redMul(s),l=i.redMul(s),f=a.redMul(o);return this.curve.point(u,c,f,l)},c.prototype._projDbl=function(){var e,t,r,n,i,o,a=this.x.redAdd(this.y).redSqr(),s=this.x.redSqr(),u=this.y.redSqr();if(this.curve.twisted){var c=(n=this.curve._mulA(s)).redAdd(u);this.zOne?(e=a.redSub(s).redSub(u).redMul(c.redSub(this.curve.two)),t=c.redMul(n.redSub(u)),r=c.redSqr().redSub(c).redSub(c)):(i=this.z.redSqr(),o=c.redSub(i).redISub(i),e=a.redSub(s).redISub(u).redMul(o),t=c.redMul(n.redSub(u)),r=c.redMul(o))}else n=s.redAdd(u),i=this.curve._mulC(this.z).redSqr(),o=n.redSub(i).redSub(i),e=this.curve._mulC(a.redISub(n)).redMul(o),t=this.curve._mulC(n).redMul(s.redISub(u)),r=n.redMul(o);return this.curve.point(e,t,r)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},c.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),o=r.redSub(t),a=i.redSub(n),s=i.redAdd(n),u=r.redAdd(t),c=o.redMul(a),l=s.redMul(u),f=o.redMul(u),h=a.redMul(s);return this.curve.point(c,l,h,f)},c.prototype._projAdd=function(e){var t,r,n=this.z.redMul(e.z),i=n.redSqr(),o=this.x.redMul(e.x),a=this.y.redMul(e.y),s=this.curve.d.redMul(o).redMul(a),u=i.redSub(s),c=i.redAdd(s),l=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(o).redISub(a),f=n.redMul(u).redMul(l);return this.curve.twisted?(t=n.redMul(c).redMul(a.redSub(this.curve._mulA(o))),r=u.redMul(c)):(t=n.redMul(c).redMul(a.redSub(o)),r=this.curve._mulC(u).redMul(c)),this.curve.point(f,t,r)},c.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},c.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},c.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},c.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},c.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()},c.prototype.getY=function(){return this.normalize(),this.y.fromRed()},c.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},c.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(n),0===this.x.cmp(t))return!0}},c.prototype.toP=c.prototype.normalize,c.prototype.mixedAdd=c.prototype.add},6063:(e,t,r)=>{"use strict";var n=t;n.base=r(1249),n.short=r(3148),n.mont=r(1105),n.edwards=r(1123)},1105:(e,t,r)=>{"use strict";var n=r(1734),i=r(1736),o=r(1249),a=r(7528);function s(e){o.call(this,"mont",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.i4=new n(4).toRed(this.red).redInvm(),this.two=new n(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function u(e,t,r){o.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new n(t,16),this.z=new n(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}i(s,o),e.exports=s,s.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===n.redSqrt().redSqr().cmp(n)},i(u,o.BasePoint),s.prototype.decodePoint=function(e,t){return this.point(a.toArray(e,t),1)},s.prototype.point=function(e,t){return new u(this,e,t)},s.prototype.pointFromJSON=function(e){return u.fromJSON(this,e)},u.prototype.precompute=function(){},u.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},u.fromJSON=function(e,t){return new u(e,t[0],t[1]||e.one)},u.prototype.inspect=function(){return this.isInfinity()?"":""},u.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},u.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),n=e.redMul(t),i=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(n,i)},u.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),o=e.x.redSub(e.z).redMul(r),a=i.redMul(n),s=t.z.redMul(o.redAdd(a).redSqr()),u=t.x.redMul(o.redISub(a).redSqr());return this.curve.point(s,u)},u.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=[];0!==t.cmpn(0);t.iushrn(1))i.push(t.andln(1));for(var o=i.length-1;o>=0;o--)0===i[o]?(r=r.diffAdd(n,this),n=n.dbl()):(n=r.diffAdd(n,this),r=r.dbl());return n},u.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},u.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},u.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},3148:(e,t,r)=>{"use strict";var n=r(7528),i=r(1734),o=r(1736),a=r(1249),s=n.assert;function u(e){a.call(this,"short",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.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(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function c(e,t,r,n){a.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new i(t,16),this.y=new i(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function l(e,t,r,n){a.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new i(0)):(this.x=new i(t,16),this.y=new i(r,16),this.z=new i(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}o(u,a),e.exports=u,u.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new i(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new i(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],s(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new i(e.a,16),b:new i(e.b,16)}})):this._getEndoBasis(r)}}},u.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:i.mont(e),r=new i(2).toRed(t).redInvm(),n=r.redNeg(),o=new i(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(o).fromRed(),n.redSub(o).fromRed()]},u.prototype._getEndoBasis=function(e){for(var t,r,n,o,a,s,u,c,l,f=this.n.ushrn(Math.floor(this.n.bitLength()/2)),h=e,d=this.n.clone(),p=new i(1),m=new i(0),y=new i(0),g=new i(1),b=0;0!==h.cmpn(0);){var v=d.div(h);c=d.sub(v.mul(h)),l=y.sub(v.mul(p));var w=g.sub(v.mul(m));if(!n&&c.cmp(f)<0)t=u.neg(),r=p,n=c.neg(),o=l;else if(n&&2==++b)break;u=c,d=h,h=c,y=p,p=l,g=m,m=w}a=c.neg(),s=l;var A=n.sqr().add(o.sqr());return a.sqr().add(s.sqr()).cmp(A)>=0&&(a=t,s=r),n.negative&&(n=n.neg(),o=o.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:n,b:o},{a,b:s}]},u.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),s=o.mul(n.a),u=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(s),k2:u.add(c).neg()}},u.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=n.fromRed().isOdd();return(t&&!o||!t&&o)&&(n=n.redNeg()),this.point(e,n)},u.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},u.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o":""},c.prototype.isInfinity=function(){return this.inf},c.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},c.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},c.prototype.getX=function(){return this.x.fromRed()},c.prototype.getY=function(){return this.y.fromRed()},c.prototype.mul=function(e){return e=new i(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},c.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},c.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},c.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},c.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(l,a.BasePoint),u.prototype.jpoint=function(e,t,r){return new l(this,e,t,r)},l.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},l.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},l.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),f=n.redMul(c),h=u.redSqr().redIAdd(l).redISub(f).redISub(f),d=u.redMul(f.redISub(h)).redISub(o.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(h,d,p)},l.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),s=i.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),c=u.redMul(a),l=r.redMul(u),f=s.redSqr().redIAdd(c).redISub(l).redISub(l),h=s.redMul(l.redISub(f)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(f,h,d)},l.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},l.prototype.inspect=function(){return this.isInfinity()?"":""},l.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},506:(e,t,r)=>{"use strict";var n,i=t,o=r(7198),a=r(6063),s=r(7528).assert;function u(e){"short"===e.type?this.curve=new a.short(e):"edwards"===e.type?this.curve=new a.edwards(e):this.curve=new a.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,s(this.g.validate(),"Invalid curve"),s(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(i,e,{configurable:!0,enumerable:!0,get:function(){var r=new u(t);return Object.defineProperty(i,e,{configurable:!0,enumerable:!0,value:r}),r}})}i.PresetCurve=u,c("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:o.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("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:o.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("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:o.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("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:o.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"]}),c("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:o.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"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["9"]}),c("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:o.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{n=r(6401)}catch(e){n=void 0}c("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:o.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",n]})},8320:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(9410),a=r(7528),s=r(506),u=r(2202),c=a.assert,l=r(7791),f=r(488);function h(e){if(!(this instanceof h))return new h(e);"string"==typeof e&&(c(Object.prototype.hasOwnProperty.call(s,e),"Unknown curve "+e),e=s[e]),e instanceof s.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=h,h.prototype.keyPair=function(e){return new l(this,e)},h.prototype.keyFromPrivate=function(e,t){return l.fromPrivate(this,e,t)},h.prototype.keyFromPublic=function(e,t){return l.fromPublic(this,e,t)},h.prototype.genKeyPair=function(e){e||(e={});for(var t=new o({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||u(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new i(2));;){var a=new i(t.generate(r));if(!(a.cmp(n)>0))return a.iaddn(1),this.keyFromPrivate(a)}},h.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},h.prototype.sign=function(e,t,r,a){"object"===(0,n.default)(r)&&(a=r,r=null),a||(a={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new i(e,16));for(var s=this.n.byteLength(),u=t.getPrivate().toArray("be",s),c=e.toArray("be",s),l=new o({hash:this.hash,entropy:u,nonce:c,pers:a.pers,persEnc:a.persEnc||"utf8"}),h=this.n.sub(new i(1)),d=0;;d++){var p=a.k?a.k(d):new i(l.generate(this.n.byteLength()));if(!((p=this._truncateToN(p,!0)).cmpn(1)<=0||p.cmp(h)>=0)){var m=this.g.mul(p);if(!m.isInfinity()){var y=m.getX(),g=y.umod(this.n);if(0!==g.cmpn(0)){var b=p.invm(this.n).mul(g.mul(t.getPrivate()).iadd(e));if(0!==(b=b.umod(this.n)).cmpn(0)){var v=(m.getY().isOdd()?1:0)|(0!==y.cmp(g)?2:0);return a.canonical&&b.cmp(this.nh)>0&&(b=this.n.sub(b),v^=1),new f({r:g,s:b,recoveryParam:v})}}}}}},h.prototype.verify=function(e,t,r,n){e=this._truncateToN(new i(e,16)),r=this.keyFromPublic(r,n);var o=(t=new f(t,"hex")).r,a=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),c=u.mul(e).umod(this.n),l=u.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(c,r.getPublic(),l)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(c,r.getPublic(),l)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},h.prototype.recoverPubKey=function(e,t,r,n){c((3&r)===r,"The recovery param is more than two bits"),t=new f(t,n);var o=this.n,a=new i(e),s=t.r,u=t.s,l=1&r,h=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&h)throw new Error("Unable to find sencond key candinate");s=h?this.curve.pointFromX(s.add(this.curve.n),l):this.curve.pointFromX(s,l);var d=t.r.invm(o),p=o.sub(a).mul(d).umod(o),m=u.mul(d).umod(o);return this.g.mulAdd(p,s,m)},h.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new f(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")}},7791:(e,t,r)=>{"use strict";var n=r(1734),i=r(7528).assert;function o(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=o,o.fromPublic=function(e,t,r){return t instanceof o?t:new o(e,{pub:t,pubEnc:r})},o.fromPrivate=function(e,t,r){return t instanceof o?t:new o(e,{priv:t,privEnc:r})},o.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.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"}},o.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},o.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},o.prototype._importPrivate=function(e,t){this.priv=new n(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},o.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?i(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||i(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},o.prototype.derive=function(e){return e.validate()||i(e.validate(),"public point not validated"),e.mul(this.priv).getX()},o.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},o.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},o.prototype.inspect=function(){return""}},488:(e,t,r)=>{"use strict";var n=r(1734),i=r(7528),o=i.assert;function a(e,t){if(e instanceof a)return e;this._importDER(e,t)||(o(e.r&&e.s,"Signature without r or s"),this.r=new n(e.r,16),this.s=new n(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function s(){this.place=0}function u(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o>>=0;return!(i<=127)&&(t.place=a,i)}function c(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}e.exports=a,a.prototype._importDER=function(e,t){e=i.toArray(e,t);var r=new s;if(48!==e[r.place++])return!1;var o=u(e,r);if(!1===o)return!1;if(o+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var a=u(e,r);if(!1===a)return!1;var c=e.slice(r.place,a+r.place);if(r.place+=a,2!==e[r.place++])return!1;var l=u(e,r);if(!1===l)return!1;if(e.length!==l+r.place)return!1;var f=e.slice(r.place,l+r.place);if(0===c[0]){if(!(128&c[1]))return!1;c=c.slice(1)}if(0===f[0]){if(!(128&f[1]))return!1;f=f.slice(1)}return this.r=new n(c),this.s=new n(f),this.recoveryParam=null,!0},a.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=c(t),r=c(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];l(n,t.length),(n=n.concat(t)).push(2),l(n,r.length);var o=n.concat(r),a=[48];return l(a,o.length),a=a.concat(o),i.encode(a,e)}},8027:(e,t,r)=>{"use strict";var n=r(7198),i=r(506),o=r(7528),a=o.assert,s=o.parseBytes,u=r(7303),c=r(6646);function l(e){if(a("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof l))return new l(e);e=i[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=n.sha512}e.exports=l,l.prototype.sign=function(e,t){e=s(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),o=this.encodePoint(i),a=this.hashInt(o,r.pubBytes(),e).mul(r.priv()),u=n.add(a).umod(this.curve.n);return this.makeSignature({R:i,S:u,Rencoded:o})},l.prototype.verify=function(e,t,r){e=s(e),t=this.makeSignature(t);var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),o=this.g.mul(t.S());return t.R().add(n.pub().mul(i)).eq(o)},l.prototype.hashInt=function(){for(var e=this.hash(),t=0;t{"use strict";var n=r(7528),i=n.assert,o=n.parseBytes,a=n.cachedProperty;function s(e,t){this.eddsa=e,this._secret=o(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=o(t.pub)}s.fromPublic=function(e,t){return t instanceof s?t:new s(e,{pub:t})},s.fromSecret=function(e,t){return t instanceof s?t:new s(e,{secret:t})},s.prototype.secret=function(){return this._secret},a(s,"pubBytes",(function(){return this.eddsa.encodePoint(this.pub())})),a(s,"pub",(function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())})),a(s,"privBytes",(function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n})),a(s,"priv",(function(){return this.eddsa.decodeInt(this.privBytes())})),a(s,"hash",(function(){return this.eddsa.hash().update(this.secret()).digest()})),a(s,"messagePrefix",(function(){return this.hash().slice(this.eddsa.encodingLength)})),s.prototype.sign=function(e){return i(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},s.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},s.prototype.getSecret=function(e){return i(this._secret,"KeyPair is public only"),n.encode(this.secret(),e)},s.prototype.getPublic=function(e){return n.encode(this.pubBytes(),e)},e.exports=s},6646:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(7528),a=o.assert,s=o.cachedProperty,u=o.parseBytes;function c(e,t){this.eddsa=e,"object"!==(0,n.default)(t)&&(t=u(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),a(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof i&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}s(c,"S",(function(){return this.eddsa.decodeInt(this.Sencoded())})),s(c,"R",(function(){return this.eddsa.decodePoint(this.Rencoded())})),s(c,"Rencoded",(function(){return this.eddsa.encodePoint(this.R())})),s(c,"Sencoded",(function(){return this.eddsa.encodeInt(this.S())})),c.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},c.prototype.toHex=function(){return o.encode(this.toBytes(),"hex").toUpperCase()},e.exports=c},6401:e=>{"use strict";e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},7528:(e,t,r)=>{"use strict";var n=t,i=r(1734),o=r(4504),a=r(6580);n.assert=o,n.toArray=a.toArray,n.zero2=a.zero2,n.toHex=a.toHex,n.encode=a.encode,n.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<(i>>1)-1?(i>>1)-u:u,o.isubn(s)):s=0,n[a]=s,o.iushrn(1)}return n},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,s,u=e.andln(3)+i&3,c=t.andln(3)+o&3;3===u&&(u=-1),3===c&&(c=-1),a=0==(1&u)?0:3!=(n=e.andln(7)+i&7)&&5!==n||2!==c?u:-u,r[0].push(a),s=0==(1&c)?0:3!=(n=t.andln(7)+o&7)&&5!==n||2!==u?c:-c,r[1].push(s),2*i===a+1&&(i=1-i),2*o===s+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"==typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new i(e,"hex","le")}},6464:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=function(){if("object"===("undefined"==typeof self?"undefined":(0,n.default)(self))&&self)return self;if("object"===("undefined"==typeof window?"undefined":(0,n.default)(window))&&window)return window;throw new Error("Unable to resolve global `this`")};e.exports=function(){if(this)return this;if("object"===("undefined"==typeof globalThis?"undefined":(0,n.default)(globalThis))&&globalThis)return globalThis;try{Object.defineProperty(Object.prototype,"__global__",{get:function(){return this},configurable:!0})}catch(e){return i()}try{return __global__||i()}finally{delete Object.prototype.__global__}}()},4258:(e,t,r)=>{"use strict";var n,i,o,a=r(9142),s=r(8847)(r(3355));o=function(){function e(e){return"function"==typeof e}var t=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},n=0,i=void 0,o=void 0,u=function(e,t){m[n]=e,m[n+1]=t,2===(n+=2)&&(o?o(y):A())},c="undefined"!=typeof window?window:void 0,l=c||{},f=l.MutationObserver||l.WebKitMutationObserver,h="undefined"==typeof self&&void 0!==a&&"[object process]"==={}.toString.call(a),d="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function p(){var e=setTimeout;return function(){return e(y,1)}}var m=new Array(1e3);function y(){for(var e=0;e{"use strict";var n=r(9033).Buffer,i=r(4858).keccak_256,o=r(3956);function a(e){return e?o.toUnicode(e,{useStd3ASCII:!0,transitional:!1}):e}t.hash=function(e){for(var t="",r=0;r<32;r++)t+="00";if(name=a(e),name){var o=name.split(".");for(r=o.length-1;r>=0;r--){var s=i(o[r]);t=i(new n(t+s,"hex"))}}return"0x"+t},t.normalize=a},3058:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847)(r(4519)),o=r(6851),a=r(9733),s=r(6597),u=(r(6740),new s.ec("secp256k1")),c=r(2922),l=c.keccak256,f=c.keccak256s,h=function(e){for(var t=f(e.slice(2)),r="0x",n=0;n<40;n++)r+=parseInt(t[n+2],16)>7?e[n+2].toUpperCase():e[n+2];return r},d=function(e){var t=new n(e.slice(2),"hex"),r="0x"+u.keyFromPrivate(t).getPublic(!1,"hex").slice(2),i=l(r);return{address:h("0x"+i.slice(-40)),privateKey:e}},p=function(e){var t=(0,i.default)(e,3),r=t[0],n=t[1],a=t[2];return o.flatten([n,a,r])},m=function(e){return[o.slice(64,o.length(e),e),o.slice(0,32,e),o.slice(32,64,e)]},y=function(e){return function(t,r){var i=u.keyFromPrivate(new n(r.slice(2),"hex")).sign(new n(t.slice(2),"hex"),{canonical:!0});return p([a.fromString(o.fromNumber(e+i.recoveryParam)),o.pad(32,o.fromNat("0x"+i.r.toString(16))),o.pad(32,o.fromNat("0x"+i.s.toString(16)))])}},g=y(27);e.exports={create:function(e){var t=l(o.concat(o.random(32),e||o.random(32))),r=o.concat(o.concat(o.random(32),t),o.random(32)),n=l(r);return d(n)},toChecksum:h,fromPrivate:d,sign:g,makeSigner:y,recover:function(e,t){var r=m(t),i={v:o.toNumber(r[0]),r:r[1].slice(2),s:r[2].slice(2)},a="0x"+u.recoverPubKey(new n(e.slice(2),"hex"),i,i.v<2?i.v:1-i.v%2).encode("hex",!1).slice(2),s=l(a);return h("0x"+s.slice(-40))},encodeSignature:p,decodeSignature:m}},1376:e=>{"use strict";var t=function(e,t){for(var r=[],n=0;n{"use strict";r(1376);var n=function(e,t){return parseInt(e.slice(2*t+2,2*t+4),16)},i=function(e){return(e.length-2)/2},o=function(e){for(var t=[],r=2,n=e.length;r>6|192);else{if(i>55295&&i<56320){if(++n==e.length)return null;var o=e.charCodeAt(n);if(o<56320||o>57343)return null;r+=t((i=65536+((1023&i)<<10)+(1023&o))>>18|240),r+=t(i>>12&63|128)}else r+=t(i>>12|224);r+=t(i>>6&63|128)}r+=t(63&i|128)}}return r},toString:function(e){for(var t="",r=0,o=i(e);r127){if(a>191&&a<224){if(r>=o)return null;a=(31&a)<<6|63&n(e,r)}else if(a>223&&a<240){if(r+1>=o)return null;a=(15&a)<<12|(63&n(e,r))<<6|63&n(e,++r)}else{if(!(a>239&&a<248))return null;if(r+2>=o)return null;a=(7&a)<<18|(63&n(e,r))<<12|(63&n(e,++r))<<6|63&n(e,++r)}++r}if(a<=65535)t+=String.fromCharCode(a);else{if(!(a<=1114111))return null;a-=65536,t+=String.fromCharCode(a>>10|55296),t+=String.fromCharCode(1023&a|56320)}}return t},fromNumber:function(e){var t=e.toString(16);return t.length%2==0?"0x"+t:"0x0"+t},toNumber:function(e){return parseInt(e.slice(2),16)},fromNat:function(e){return"0x0"===e?"0x":e.length%2==0?e:"0x0"+e.slice(2)},toNat:function(e){return"0"===e[2]?"0x"+e.slice(3):e},fromArray:a,toArray:o,fromUint8Array:function(e){return a([].slice.call(e,0))},toUint8Array:function(e){return new Uint8Array(o(e))}}},2922:e=>{"use strict";var t="0123456789abcdef".split(""),r=[1,256,65536,16777216],n=[0,8,16,24],i=[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],o=function(e){var t,r,n,o,a,s,u,c,l,f,h,d,p,m,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)o=e[0]^e[10]^e[20]^e[30]^e[40],a=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],u=e[3]^e[13]^e[23]^e[33]^e[43],c=e[4]^e[14]^e[24]^e[34]^e[44],l=e[5]^e[15]^e[25]^e[35]^e[45],f=e[6]^e[16]^e[26]^e[36]^e[46],h=e[7]^e[17]^e[27]^e[37]^e[47],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(s<<1|u>>>31),r=(p=e[9]^e[19]^e[29]^e[39]^e[49])^(u<<1|s>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=o^(c<<1|l>>>31),r=a^(l<<1|c>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=s^(f<<1|h>>>31),r=u^(h<<1|f>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=c^(d<<1|p>>>31),r=l^(p<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=f^(o<<1|a>>>31),r=h^(a<<1|o>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=m^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&m,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~m&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=i[n],e[1]^=i[n+1]},a=function(e){return function(i){var a;if("0x"===i.slice(0,2)){a=[];for(var s=2,u=i.length;s>2]|=i[d]<>2]|=a<>2]|=(192|a>>6)<>2]|=(128|63&a)<=57344?(u[y>>2]|=(224|a>>12)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<>2]|=(240|a>>18)<>2]|=(128|a>>12&63)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<=c){for(e.start=y-c,e.block=u[l],y=0;y>2]|=r[3&y],e.lastByteIndex===c)for(u[0]=u[l],y=1;y>4&15]+t[15&p]+t[p>>12&15]+t[p>>8&15]+t[p>>20&15]+t[p>>16&15]+t[p>>28&15]+t[p>>24&15];g%l==0&&(o(h),y=0)}return"0x"+m}(function(e){return{blocks:[],reset:!0,block:0,start:0,blockCount:1600-(e<<1)>>5,outputBlocks:e>>5,s:(t=[0,0,0,0,0,0,0,0,0,0],[].concat(t,t,t,t,t))};var t}(e),a)}};e.exports={keccak256:a(256),keccak512:a(512),keccak256s:a(256),keccak512s:a(512)}},9733:(e,t,r)=>{"use strict";var n=r(1734),i=r(6851),o=function(e){return new n(e.slice(2),16)},a=function(e){var t="0x"+("0x"===e.slice(0,2)?new n(e.slice(2),16):new n(e,10)).toString("hex");return"0x0"===t?"0x":t},s=function(e){return"string"==typeof e?/^0x/.test(e)?e:"0x"+e:"0x"+new n(e).toString("hex")},u=function(e){return o(e).toNumber()},c=function(e){return function(t,r){return"0x"+o(t)[e](o(r)).toString("hex")}},l=c("add"),f=c("mul"),h=c("div"),d=c("sub");e.exports={toString:function(e){return o(e).toString(10)},fromString:a,toNumber:u,fromNumber:s,toEther:function(e){return u(h(e,a("10000000000")))/1e8},fromEther:function(e){return f(s(Math.floor(1e8*e)),a("10000000000"))},toUint256:function(e){return i.pad(32,e)},add:l,mul:f,div:h,sub:d}},6740:e=>{"use strict";e.exports={encode:function(e){var t=function(e){return(t=e.toString(16)).length%2==0?t:"0"+t;var t},r=function(e,r){return e<56?t(r+e):t(r+t(e).length/2+55)+t(e)};return"0x"+function e(t){if("string"==typeof t){var n=t.slice(2);return(2!=n.length||n>="80"?r(n.length/2,128):"")+n}var i=t.map(e).join("");return r(i.length/2,192)+i}(e)},decode:function(e){var t=2,r=function(){if(t>=e.length)throw"";var r=e.slice(t,t+2);return r<"80"?(t+=2,"0x"+r):r<"c0"?i():o()},n=function(){var r=parseInt(e.slice(t,t+=2),16)%64;return r<56?r:parseInt(e.slice(t,t+=2*(r-55)),16)},i=function(){var r=n();return"0x"+e.slice(t,t+=2*r)},o=function(){for(var e=2*n()+t,i=[];t{"use strict";var n=r(8847)(r(3355));Object.defineProperty(t,"__esModule",{value:!0});var i=r(8179);function o(e){return!("string"!=typeof e||!/^(0x)?[0-9a-f]{512}$/i.test(e)||!/^(0x)?[0-9a-f]{512}$/.test(e)&&!/^(0x)?[0-9A-F]{512}$/.test(e))}function a(e,t){"object"===(0,n.default)(t)&&t.constructor===Uint8Array&&(t=i.bytesToHex(t));for(var r=i.keccak256(t).replace("0x",""),o=0;o<12;o+=4){var a=(parseInt(r.substr(o,2),16)<<8)+parseInt(r.substr(o+2,2),16)&2047,u=1<=48&&e<=57)return e-48;if(e>=65&&e<=70)return e-55;if(e>=97&&e<=102)return e-87;throw new Error("invalid bloom")}function u(e){return!("string"!=typeof e||!/^(0x)?[0-9a-f]{64}$/i.test(e)||!/^(0x)?[0-9a-f]{64}$/.test(e)&&!/^(0x)?[0-9A-F]{64}$/.test(e))}function c(e){return!("string"!=typeof e||!e.match(/^(0x)?[0-9a-fA-F]{40}$/)&&!e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/))}t.isBloom=o,t.isInBloom=a,t.isUserEthereumAddressInBloom=function(e,t){if(!o(e))throw new Error("Invalid bloom given");if(!c(t))throw new Error('Invalid ethereum address given: "'.concat(t,'"'));return a(e,i.padLeft(t,64))},t.isContractAddressInBloom=function(e,t){if(!o(e))throw new Error("Invalid bloom given");if(!c(t))throw new Error('Invalid contract address given: "'.concat(t,'"'));return a(e,t)},t.isTopicInBloom=function(e,t){if(!o(e))throw new Error("Invalid bloom given");if(!u(t))throw new Error("Invalid topic");return a(e,t)},t.isTopic=u,t.isAddress=c},8179:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7286);function i(e){if(null==e)throw new Error("cannot convert null value to array");if("string"==typeof e){var t=e.match(/^(0x)?[0-9a-fA-F]*$/);if(!t)throw new Error("invalid hexidecimal string");if("0x"!==t[1])throw new Error("hex string must have 0x prefix");(e=e.substring(2)).length%2&&(e="0"+e);for(var r=[],n=0;n=256||parseInt(String(r))!=r)return!1}return!0}(e))return o(new Uint8Array(e));throw new Error("invalid arrayify value")}function o(e){var t=arguments;return void 0!==e.slice||(e.slice=function(){var r=Array.prototype.slice.call(t);return o(new Uint8Array(Array.prototype.slice.apply(e,r)))}),e}t.keccak256=function(e){return"0x"+n.keccak_256(i(e))},t.padLeft=function(e,t){var r=/^0x/i.test(e)||"number"==typeof e,n=t-(e=e.toString().replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(r?"0x":"")+new Array(n).join("0")+e},t.bytesToHex=function(e){for(var t=[],r=0;r>>4).toString(16)),t.push((15&e[r]).toString(16));return"0x".concat(t.join("").replace(/^0+/,""))},t.toByteArray=i},7286:(e,t,r)=>{"use strict";e=r.nmd(e);var n,i=r(9142),o=r(8847)(r(3355));!function(){var a="input is invalid type",s="object"===("undefined"==typeof window?"undefined":(0,o.default)(window)),u=s?window:{};u.JS_SHA3_NO_WINDOW&&(s=!1);var c=!s&&"object"===("undefined"==typeof self?"undefined":(0,o.default)(self));!u.JS_SHA3_NO_NODE_JS&&"object"===(void 0===i?"undefined":(0,o.default)(i))&&i.versions&&i.versions.node?u=r.g:c&&(u=self);var l=!u.JS_SHA3_NO_COMMON_JS&&"object"===(0,o.default)(e)&&e.exports,f=r.amdO,h=!u.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,d="0123456789abcdef".split(""),p=[4,1024,262144,67108864],m=[0,8,16,24],y=[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],g=[224,256,384,512],b=[128,256],v=["hex","buffer","arrayBuffer","array","digest"],w={128:168,256:136};!u.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!h||!u.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===(0,o.default)(e)&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var A=function(e,t,r){return function(n){return new L(e,t,e).update(n)[r]()}},S=function(e,t,r){return function(n,i){return new L(e,t,i).update(n)[r]()}},k=function(e,t,r){return function(t,n,i,o){return x["cshake"+e].update(t,n,i,o)[r]()}},E=function(e,t,r){return function(t,n,i,o){return x["kmac"+e].update(t,n,i,o)[r]()}},_=function(e,t,r,n){for(var i=0;i>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function U(e,t,r){L.call(this,e,t,r)}L.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}for(var n,i,s=this.blocks,u=this.byteCount,c=e.length,l=this.blockCount,f=0,d=this.s;f>2]|=e[f]<>2]|=i<>2]|=(192|i>>6)<>2]|=(128|63&i)<=57344?(s[n>>2]|=(224|i>>12)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<>2]|=(240|i>>18)<>2]|=(128|i>>12&63)<>2]|=(128|i>>6&63)<>2]|=(128|63&i)<=u){for(this.start=n-u,this.block=s[l],n=0;n>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},L.prototype.encodeString=function(e){var t,r=(0,o.default)(e);if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||h&&ArrayBuffer.isView(e)))throw new Error(a);t=!0}var n=0,i=e.length;if(t)n=i;else for(var s=0;s=57344?n+=3:(u=65536+((1023&u)<<10|1023&e.charCodeAt(++s)),n+=4)}return n+=this.encode(8*n),this.update(e),n},L.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+d[15&e]+d[e>>12&15]+d[e>>8&15]+d[e>>20&15]+d[e>>16&15]+d[e>>28&15]+d[e>>24&15];a%t==0&&(F(r),o=0)}return i&&(e=r[o],s+=d[e>>4&15]+d[15&e],i>1&&(s+=d[e>>12&15]+d[e>>8&15]),i>2&&(s+=d[e>>20&15]+d[e>>16&15])),s},L.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&F(n)}return o&&(e=s<<2,t=n[a],u[e]=255&t,o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u},U.prototype=new L,U.prototype.finalize=function(){return this.encode(this.outputBits,!0),L.prototype.finalize.call(this)};var F=function(e){var t,r,n,i,o,a,s,u,c,l,f,h,d,p,m,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],u=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],l=e[6]^e[16]^e[26]^e[36]^e[46],f=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(d=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|c>>>31),r=o^(c<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(l<<1|f>>>31),r=s^(f<<1|l>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(h<<1|d>>>31),r=c^(d<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=l^(i<<1|o>>>31),r=f^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],m=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=p^~g&v,e[1]=m^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&p,e[7]=S^~E&m,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~p&g,e[9]=E^~m&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=y[n],e[1]^=y[n+1]};if(l)e.exports=x;else{for(I=0;I{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.createHashFunction=function(e){return function(t){var r=e();return r.update(t),n.from(r.digest())}}},1243:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9989),i=r(3135);t.keccak224=n.createHashFunction((function(){return i("keccak224")})),t.keccak256=n.createHashFunction((function(){return i("keccak256")})),t.keccak384=n.createHashFunction((function(){return i("keccak384")})),t.keccak512=n.createHashFunction((function(){return i("keccak512")}))},4893:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(5010);t.getRandomBytes=function(e){return new Promise((function(t,r){n(e,(function(e,n){e?r(e):t(n)}))}))},t.getRandomBytesSync=function(e){return n(e)}},6992:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7902),i=r(4893);t.createPrivateKey=function(){return e=this,r=function(){var e;return function(e,t){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.isZeroAddress=t.zeroAddress=t.importPublic=t.privateToAddress=t.privateToPublic=t.publicToAddress=t.pubToAddress=t.isValidPublic=t.isValidPrivate=t.generateAddress2=t.generateAddress=t.isValidChecksumAddress=t.toChecksumAddress=t.isValidAddress=t.Account=void 0;var i,o=(i=r(3894))&&i.__esModule?i:{default:i},a=r(9100),s=r(6992),u=r(3271),c=r(986),l=r(3464),f=r(9808),h=r(5725),d=r(5513),p=function(){function e(e,t,r,n){void 0===e&&(e=new a.BN(0)),void 0===t&&(t=new a.BN(0)),void 0===r&&(r=c.KECCAK256_RLP),void 0===n&&(n=c.KECCAK256_NULL),this.nonce=e,this.balance=t,this.stateRoot=r,this.codeHash=n,this._validate()}return e.fromAccountData=function(t){var r=t.nonce,n=t.balance,i=t.stateRoot,o=t.codeHash;return new e(r?new a.BN((0,l.toBuffer)(r)):void 0,n?new a.BN((0,l.toBuffer)(n)):void 0,i?(0,l.toBuffer)(i):void 0,o?(0,l.toBuffer)(o):void 0)},e.fromRlpSerializedAccount=function(e){var t=a.rlp.decode(e);if(!Array.isArray(t))throw new Error("Invalid serialized account input. Must be array");return this.fromValuesArray(t)},e.fromValuesArray=function(t){var r=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}(t,4),n=r[0],i=r[1],o=r[2],s=r[3];return new e(new a.BN(n),new a.BN(i),o,s)},e.prototype._validate=function(){if(this.nonce.lt(new a.BN(0)))throw new Error("nonce must be greater than zero");if(this.balance.lt(new a.BN(0)))throw new Error("balance must be greater than zero");if(32!==this.stateRoot.length)throw new Error("stateRoot must have a length of 32");if(32!==this.codeHash.length)throw new Error("codeHash must have a length of 32")},e.prototype.raw=function(){return[(0,d.bnToUnpaddedBuffer)(this.nonce),(0,d.bnToUnpaddedBuffer)(this.balance),this.stateRoot,this.codeHash]},e.prototype.serialize=function(){return a.rlp.encode(this.raw())},e.prototype.isContract=function(){return!this.codeHash.equals(c.KECCAK256_NULL)},e.prototype.isEmpty=function(){return this.balance.isZero()&&this.nonce.isZero()&&this.codeHash.equals(c.KECCAK256_NULL)},e}();t.Account=p,t.isValidAddress=function(e){try{(0,h.assertIsString)(e)}catch(e){return!1}return/^0x[0-9a-fA-F]{40}$/.test(e)},t.toChecksumAddress=function(e,t){(0,h.assertIsHexString)(e);var r=(0,u.stripHexPrefix)(e).toLowerCase(),n="";t&&(n=(0,d.toType)(t,d.TypeOutput.BN).toString()+"0x");for(var i=(0,f.keccakFromString)(n+r).toString("hex"),o="0x",a=0;a=8?o+=r[a].toUpperCase():o+=r[a];return o},t.isValidChecksumAddress=function(e,r){return(0,t.isValidAddress)(e)&&(0,t.toChecksumAddress)(e,r)===e},t.generateAddress=function(e,t){(0,h.assertIsBuffer)(e),(0,h.assertIsBuffer)(t);var r=new a.BN(t);return r.isZero()?(0,f.rlphash)([e,null]).slice(-20):(0,f.rlphash)([e,n.from(r.toArray())]).slice(-20)},t.generateAddress2=function(e,t,r){return(0,h.assertIsBuffer)(e),(0,h.assertIsBuffer)(t),(0,h.assertIsBuffer)(r),(0,o.default)(20===e.length),(0,o.default)(32===t.length),(0,f.keccak256)(n.concat([n.from("ff","hex"),e,t,(0,f.keccak256)(r)])).slice(-20)},t.isValidPrivate=function(e){return(0,s.privateKeyVerify)(e)},t.isValidPublic=function(e,t){return void 0===t&&(t=!1),(0,h.assertIsBuffer)(e),64===e.length?(0,s.publicKeyVerify)(n.concat([n.from([4]),e])):!!t&&(0,s.publicKeyVerify)(e)},t.pubToAddress=function(e,t){return void 0===t&&(t=!1),(0,h.assertIsBuffer)(e),t&&64!==e.length&&(e=n.from((0,s.publicKeyConvert)(e,!1).slice(1))),(0,o.default)(64===e.length),(0,f.keccak)(e).slice(-20)},t.publicToAddress=t.pubToAddress,t.privateToPublic=function(e){return(0,h.assertIsBuffer)(e),n.from((0,s.publicKeyCreate)(e,!1)).slice(1)},t.privateToAddress=function(e){return(0,t.publicToAddress)((0,t.privateToPublic)(e))},t.importPublic=function(e){return(0,h.assertIsBuffer)(e),64!==e.length&&(e=n.from((0,s.publicKeyConvert)(e,!1).slice(1))),e},t.zeroAddress=function(){var e=(0,l.zeros)(20);return(0,l.bufferToHex)(e)},t.isZeroAddress=function(e){try{(0,h.assertIsString)(e)}catch(e){return!1}return(0,t.zeroAddress)()===e}},1984:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.Address=void 0;var i,o=(i=r(3894))&&i.__esModule?i:{default:i},a=r(9100),s=r(3464),u=r(1968),c=function(){function e(e){(0,o.default)(20===e.length,"Invalid address length"),this.buf=e}return e.zero=function(){return new e((0,s.zeros)(20))},e.fromString=function(t){return(0,o.default)((0,u.isValidAddress)(t),"Invalid address"),new e((0,s.toBuffer)(t))},e.fromPublicKey=function(t){return(0,o.default)(n.isBuffer(t),"Public key should be Buffer"),new e((0,u.pubToAddress)(t))},e.fromPrivateKey=function(t){return(0,o.default)(n.isBuffer(t),"Private key should be Buffer"),new e((0,u.privateToAddress)(t))},e.generate=function(t,r){return(0,o.default)(a.BN.isBN(r)),new e((0,u.generateAddress)(t.buf,r.toArrayLike(n)))},e.generate2=function(t,r,i){return(0,o.default)(n.isBuffer(r)),(0,o.default)(n.isBuffer(i)),new e((0,u.generateAddress2)(t.buf,r,i))},e.prototype.equals=function(e){return this.buf.equals(e.buf)},e.prototype.isZero=function(){return this.equals(e.zero())},e.prototype.isPrecompileOrSystemAddress=function(){var e=new a.BN(this.buf),t=new a.BN(0),r=new a.BN("ffff","hex");return e.gte(t)&&e.lte(r)},e.prototype.toString=function(){return"0x"+this.buf.toString("hex")},e.prototype.toBuffer=function(){return n.from(this.buf)},e}();t.Address=c},3464:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a};Object.defineProperty(t,"__esModule",{value:!0}),t.bufArrToArr=t.arrToBufArr=t.validateNoLeadingZeroes=t.baToJSON=t.toUtf8=t.addHexPrefix=t.toUnsigned=t.fromSigned=t.bufferToHex=t.bufferToInt=t.toBuffer=t.unpadHexString=t.unpadArray=t.unpadBuffer=t.setLengthRight=t.setLengthLeft=t.zeros=t.intToBuffer=t.intToHex=void 0;var o=r(9100),a=r(3271),s=r(5725);t.intToHex=function(e){if(!Number.isSafeInteger(e)||e<0)throw new Error("Received an invalid integer type: ".concat(e));return"0x".concat(e.toString(16))},t.intToBuffer=function(e){var r=(0,t.intToHex)(e);return n.from((0,a.padToEven)(r.slice(2)),"hex")},t.zeros=function(e){return n.allocUnsafe(e).fill(0)};var u=function(e,r,n){var i=(0,t.zeros)(r);return n?e.length0&&"0"===t.toString();)t=(e=e.slice(1))[0];return e};t.unpadBuffer=function(e){return(0,s.assertIsBuffer)(e),c(e)},t.unpadArray=function(e){return(0,s.assertIsArray)(e),c(e)},t.unpadHexString=function(e){return(0,s.assertIsHexString)(e),e=(0,a.stripHexPrefix)(e),c(e)},t.toBuffer=function(e){if(null==e)return n.allocUnsafe(0);if(n.isBuffer(e))return n.from(e);if(Array.isArray(e)||e instanceof Uint8Array)return n.from(e);if("string"==typeof e){if(!(0,a.isHexString)(e))throw new Error("Cannot convert string to buffer. toBuffer only supports 0x-prefixed hex strings and this string was given: ".concat(e));return n.from((0,a.padToEven)((0,a.stripHexPrefix)(e)),"hex")}if("number"==typeof e)return(0,t.intToBuffer)(e);if(o.BN.isBN(e)){if(e.isNeg())throw new Error("Cannot convert negative BN to buffer. Given: ".concat(e));return e.toArrayLike(n)}if(e.toArray)return n.from(e.toArray());if(e.toBuffer)return n.from(e.toBuffer());throw new Error("invalid type")},t.bufferToInt=function(e){return new o.BN((0,t.toBuffer)(e)).toNumber()},t.bufferToHex=function(e){return"0x"+(e=(0,t.toBuffer)(e)).toString("hex")},t.fromSigned=function(e){return new o.BN(e).fromTwos(256)},t.toUnsigned=function(e){return n.from(e.toTwos(256).toArray())},t.addHexPrefix=function(e){return"string"!=typeof e||(0,a.isHexPrefixed)(e)?e:"0x"+e},t.toUtf8=function(e){if((e=(0,a.stripHexPrefix)(e)).length%2!=0)throw new Error("Invalid non-even hex string input for toUtf8() provided");return n.from(e.replace(/^(00)+|(00)+$/g,""),"hex").toString("utf8")},t.baToJSON=function(e){if(n.isBuffer(e))return"0x".concat(e.toString("hex"));if(e instanceof Array){for(var r=[],i=0;i=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),o=n.next();!o.done;o=n.next()){var a=i(o.value,2),s=a[0],u=a[1];if(void 0!==u&&u.length>0&&0===u[0])throw new Error("".concat(s," cannot have leading zeroes, received: ").concat(u.toString("hex")))}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}},t.arrToBufArr=function e(t){return Array.isArray(t)?t.map((function(t){return e(t)})):n.from(t)},t.bufArrToArr=function e(t){return Array.isArray(t)?t.map((function(t){return e(t)})):Uint8Array.from(null!=t?t:[])}},986:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.KECCAK256_RLP=t.KECCAK256_RLP_S=t.KECCAK256_RLP_ARRAY=t.KECCAK256_RLP_ARRAY_S=t.KECCAK256_NULL=t.KECCAK256_NULL_S=t.TWO_POW256=t.MAX_INTEGER=t.MAX_UINT64=void 0;var n=r(9033),i=r(9100);t.MAX_UINT64=new i.BN("ffffffffffffffff",16),t.MAX_INTEGER=new i.BN("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16),t.TWO_POW256=new i.BN("10000000000000000000000000000000000000000000000000000000000000000",16),t.KECCAK256_NULL_S="c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",t.KECCAK256_NULL=n.Buffer.from(t.KECCAK256_NULL_S,"hex"),t.KECCAK256_RLP_ARRAY_S="1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",t.KECCAK256_RLP_ARRAY=n.Buffer.from(t.KECCAK256_RLP_ARRAY_S,"hex"),t.KECCAK256_RLP_S="56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",t.KECCAK256_RLP=n.Buffer.from(t.KECCAK256_RLP_S,"hex")},9100:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};Object.defineProperty(t,"__esModule",{value:!0}),t.rlp=t.BN=void 0;var o,a=(o=r(1734))&&o.__esModule?o:{default:o};t.BN=a.default;var s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t}(r(6905));t.rlp=s},9808:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.rlphash=t.ripemd160FromArray=t.ripemd160FromString=t.ripemd160=t.sha256FromArray=t.sha256FromString=t.sha256=t.keccakFromArray=t.keccakFromHexString=t.keccakFromString=t.keccak256=t.keccak=void 0;var i=r(1243),o=r(5866),a=r(9100),s=r(3464),u=r(5725);t.keccak=function(e,t){switch(void 0===t&&(t=256),(0,u.assertIsBuffer)(e),t){case 224:return(0,i.keccak224)(e);case 256:return(0,i.keccak256)(e);case 384:return(0,i.keccak384)(e);case 512:return(0,i.keccak512)(e);default:throw new Error("Invald algorithm: keccak".concat(t))}},t.keccak256=function(e){return(0,t.keccak)(e)},t.keccakFromString=function(e,r){void 0===r&&(r=256),(0,u.assertIsString)(e);var i=n.from(e,"utf8");return(0,t.keccak)(i,r)},t.keccakFromHexString=function(e,r){return void 0===r&&(r=256),(0,u.assertIsHexString)(e),(0,t.keccak)((0,s.toBuffer)(e),r)},t.keccakFromArray=function(e,r){return void 0===r&&(r=256),(0,u.assertIsArray)(e),(0,t.keccak)((0,s.toBuffer)(e),r)};var c=function(e){return e=(0,s.toBuffer)(e),o("sha256").update(e).digest()};t.sha256=function(e){return(0,u.assertIsBuffer)(e),c(e)},t.sha256FromString=function(e){return(0,u.assertIsString)(e),c(e)},t.sha256FromArray=function(e){return(0,u.assertIsArray)(e),c(e)};var l=function(e,t){e=(0,s.toBuffer)(e);var r=o("rmd160").update(e).digest();return!0===t?(0,s.setLengthLeft)(r,32):r};t.ripemd160=function(e,t){return(0,u.assertIsBuffer)(e),l(e,t)},t.ripemd160FromString=function(e,t){return(0,u.assertIsString)(e),l(e,t)},t.ripemd160FromArray=function(e,t){return(0,u.assertIsArray)(e),l(e,t)},t.rlphash=function(e){return(0,t.keccak)(a.rlp.encode(e))}},5725:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.assertIsString=t.assertIsArray=t.assertIsBuffer=t.assertIsHexString=void 0;var i=r(3271);t.assertIsHexString=function(e){if(!(0,i.isHexString)(e)){var t="This method only supports 0x-prefixed hex strings but input was: ".concat(e);throw new Error(t)}},t.assertIsBuffer=function(e){if(!n.isBuffer(e)){var t="This method only supports Buffer but input was: ".concat(e);throw new Error(t)}},t.assertIsArray=function(e){if(!Array.isArray(e)){var t="This method only supports number arrays but input was: ".concat(e);throw new Error(t)}},t.assertIsString=function(e){if("string"!=typeof e){var t="This method only supports strings but input was: ".concat(e);throw new Error(t)}}},3062:(e,t,r)=>{"use strict";var n=Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]},i=function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.isHexString=t.getKeys=t.fromAscii=t.fromUtf8=t.toAscii=t.arrayContainsArray=t.getBinarySize=t.padToEven=t.stripHexPrefix=t.isHexPrefixed=void 0,i(r(986),t),i(r(1968),t),i(r(1984),t),i(r(9808),t),i(r(6081),t),i(r(3464),t),i(r(1677),t),i(r(9100),t),i(r(5513),t);var o=r(3271);Object.defineProperty(t,"isHexPrefixed",{enumerable:!0,get:function(){return o.isHexPrefixed}}),Object.defineProperty(t,"stripHexPrefix",{enumerable:!0,get:function(){return o.stripHexPrefix}}),Object.defineProperty(t,"padToEven",{enumerable:!0,get:function(){return o.padToEven}}),Object.defineProperty(t,"getBinarySize",{enumerable:!0,get:function(){return o.getBinarySize}}),Object.defineProperty(t,"arrayContainsArray",{enumerable:!0,get:function(){return o.arrayContainsArray}}),Object.defineProperty(t,"toAscii",{enumerable:!0,get:function(){return o.toAscii}}),Object.defineProperty(t,"fromUtf8",{enumerable:!0,get:function(){return o.fromUtf8}}),Object.defineProperty(t,"fromAscii",{enumerable:!0,get:function(){return o.fromAscii}}),Object.defineProperty(t,"getKeys",{enumerable:!0,get:function(){return o.getKeys}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return o.isHexString}})},3271:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847)(r(3355));function o(e){if("string"!=typeof e)throw new Error("[isHexPrefixed] input must be type 'string', received type ".concat((0,i.default)(e)));return"0"===e[0]&&"x"===e[1]}function a(e){var t=e;if("string"!=typeof t)throw new Error("[padToEven] value must be type 'string', received ".concat((0,i.default)(t)));return t.length%2&&(t="0".concat(t)),t}Object.defineProperty(t,"__esModule",{value:!0}),t.isHexString=t.getKeys=t.fromAscii=t.fromUtf8=t.toAscii=t.arrayContainsArray=t.getBinarySize=t.padToEven=t.stripHexPrefix=t.isHexPrefixed=void 0,t.isHexPrefixed=o,t.stripHexPrefix=function(e){if("string"!=typeof e)throw new Error("[stripHexPrefix] input must be type 'string', received ".concat((0,i.default)(e)));return o(e)?e.slice(2):e},t.padToEven=a,t.getBinarySize=function(e){if("string"!=typeof e)throw new Error("[getBinarySize] method requires input type 'string', recieved ".concat((0,i.default)(e)));return n.byteLength(e,"utf8")},t.arrayContainsArray=function(e,t,r){if(!0!==Array.isArray(e))throw new Error("[arrayContainsArray] method requires input 'superset' to be an array, got type '".concat((0,i.default)(e),"'"));if(!0!==Array.isArray(t))throw new Error("[arrayContainsArray] method requires input 'subset' to be an array, got type '".concat((0,i.default)(t),"'"));return t[r?"some":"every"]((function(t){return e.indexOf(t)>=0}))},t.toAscii=function(e){var t="",r=0,n=e.length;for("0x"===e.substring(0,2)&&(r=2);r{"use strict";var n=r(9033).Buffer,i=r(8847)(r(3355));Object.defineProperty(t,"__esModule",{value:!0}),t.defineProperties=void 0;var o,a=(o=r(3894))&&o.__esModule?o:{default:o},s=r(3271),u=r(9100),c=r(3464);t.defineProperties=function(e,t,r){if(e.raw=[],e._fields=[],e.toJSON=function(t){if(void 0===t&&(t=!1),t){var r={};return e._fields.forEach((function(t){r[t]="0x".concat(e[t].toString("hex"))})),r}return(0,c.baToJSON)(e.raw)},e.serialize=function(){return u.rlp.encode(e.raw)},t.forEach((function(t,r){function i(){return e.raw[r]}function o(i){"00"!==(i=(0,c.toBuffer)(i)).toString("hex")||t.allowZero||(i=n.allocUnsafe(0)),t.allowLess&&t.length?(i=(0,c.unpadBuffer)(i),(0,a.default)(t.length>=i.length,"The field ".concat(t.name," must not have more ").concat(t.length," bytes"))):t.allowZero&&0===i.length||!t.length||(0,a.default)(t.length===i.length,"The field ".concat(t.name," must have byte length of ").concat(t.length)),e.raw[r]=i}e._fields.push(t.name),Object.defineProperty(e,t.name,{enumerable:!0,configurable:!0,get:i,set:o}),t.default&&(e[t.name]=t.default),t.alias&&Object.defineProperty(e,t.alias,{enumerable:!1,configurable:!0,set:o,get:i})})),r)if("string"==typeof r&&(r=n.from((0,s.stripHexPrefix)(r),"hex")),n.isBuffer(r)&&(r=u.rlp.decode(r)),Array.isArray(r)){if(r.length>e._fields.length)throw new Error("wrong number of fields in data");r.forEach((function(t,r){e[e._fields[r]]=(0,c.toBuffer)(t)}))}else{if("object"!==(0,i.default)(r))throw new Error("invalid data");var o=Object.keys(r);t.forEach((function(t){-1!==o.indexOf(t.name)&&(e[t.name]=r[t.name]),-1!==o.indexOf(t.alias)&&(e[t.alias]=r[t.alias])}))}}},6081:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.hashPersonalMessage=t.isValidSignature=t.fromRpcSig=t.toCompactSig=t.toRpcSig=t.ecrecover=t.ecsign=void 0;var i=r(6992),o=r(9100),a=r(3464),s=r(9808),u=r(5725),c=r(5513);function l(e,t){var r=(0,c.toType)(e,c.TypeOutput.BN);if(r.eqn(0)||r.eqn(1))return(0,c.toType)(e,c.TypeOutput.BN);if(!t)return r.subn(27);var n=(0,c.toType)(t,c.TypeOutput.BN);return r.sub(n.muln(2).addn(35))}function f(e){var t=new o.BN(e);return t.eqn(0)||t.eqn(1)}t.ecsign=function(e,t,r){var o=(0,i.ecdsaSign)(e,t),a=o.signature,s=o.recid,u=n.from(a.slice(0,32)),l=n.from(a.slice(32,64));if(!r||"number"==typeof r){if(r&&!Number.isSafeInteger(r))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative input type)");return{r:u,s:l,v:r?s+(2*r+35):s+27}}return{r:u,s:l,v:(0,c.toType)(r,c.TypeOutput.BN).muln(2).addn(35).addn(s).toArrayLike(n)}},t.ecrecover=function(e,t,r,o,s){var u=n.concat([(0,a.setLengthLeft)(r,32),(0,a.setLengthLeft)(o,32)],64),c=l(t,s);if(!f(c))throw new Error("Invalid signature v value");var h=(0,i.ecdsaRecover)(u,c.toNumber(),e);return n.from((0,i.publicKeyConvert)(h,!1).slice(1))},t.toRpcSig=function(e,t,r,i){if(!f(l(e,i)))throw new Error("Invalid signature v value");return(0,a.bufferToHex)(n.concat([(0,a.setLengthLeft)(t,32),(0,a.setLengthLeft)(r,32),(0,a.toBuffer)(e)]))},t.toCompactSig=function(e,t,r,i){if(!f(l(e,i)))throw new Error("Invalid signature v value");var o=(0,c.toType)(e,c.TypeOutput.Number),s=r;return(o>28&&o%2==1||1===o||28===o)&&((s=n.from(r))[0]|=128),(0,a.bufferToHex)(n.concat([(0,a.setLengthLeft)(t,32),(0,a.setLengthLeft)(s,32)]))},t.fromRpcSig=function(e){var t,r,n,i=(0,a.toBuffer)(e);if(i.length>=65)t=i.slice(0,32),r=i.slice(32,64),n=(0,a.bufferToInt)(i.slice(64));else{if(64!==i.length)throw new Error("Invalid signature length");t=i.slice(0,32),r=i.slice(32,64),n=(0,a.bufferToInt)(i.slice(32,33))>>7,r[0]&=127}return n<27&&(n+=27),{v:n,r:t,s:r}},t.isValidSignature=function(e,t,r,n,i){void 0===n&&(n=!0);var a=new o.BN("7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0",16),s=new o.BN("fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141",16);if(32!==t.length||32!==r.length)return!1;if(!f(l(e,i)))return!1;var u=new o.BN(t),c=new o.BN(r);return!(u.isZero()||u.gt(s)||c.isZero()||c.gt(s)||n&&1===c.cmp(a))},t.hashPersonalMessage=function(e){(0,u.assertIsBuffer)(e);var t=n.from("Ethereum Signed Message:\n".concat(e.length),"utf-8");return(0,s.keccak)(n.concat([t,e]))}},5513:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.toType=t.TypeOutput=t.bnToRlp=t.bnToUnpaddedBuffer=t.bnToHex=void 0;var i,o=r(9100),a=r(3271),s=r(3464);function u(e){return(0,s.unpadBuffer)(e.toArrayLike(n))}t.bnToHex=function(e){return"0x".concat(e.toString(16))},t.bnToUnpaddedBuffer=u,t.bnToRlp=function(e){return u(e)},function(e){e[e.Number=0]="Number",e[e.BN=1]="BN",e[e.Buffer=2]="Buffer",e[e.PrefixedHexString=3]="PrefixedHexString"}(i=t.TypeOutput||(t.TypeOutput={})),t.toType=function(e,t){if(null===e)return null;if(void 0!==e){if("string"==typeof e&&!(0,a.isHexString)(e))throw new Error("A string must be provided with a 0x-prefix, given: ".concat(e));if("number"==typeof e&&!Number.isSafeInteger(e))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative input type)");var r=(0,s.toBuffer)(e);if(t===i.Buffer)return r;if(t===i.BN)return new o.BN(r);if(t===i.Number){var n=new o.BN(r),u=new o.BN(Number.MAX_SAFE_INTEGER.toString());if(n.gt(u))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative output type)");return n.toNumber()}return"0x".concat(r.toString("hex"))}}},7130:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(7277),a=new i(0),s=new i(-1),u={noether:"0",wei:"1",kwei:"1000",Kwei:"1000",babbage:"1000",femtoether:"1000",mwei:"1000000",Mwei:"1000000",lovelace:"1000000",picoether:"1000000",gwei:"1000000000",Gwei:"1000000000",shannon:"1000000000",nanoether:"1000000000",nano:"1000000000",szabo:"1000000000000",microether:"1000000000000",micro:"1000000000000",finney:"1000000000000000",milliether:"1000000000000000",milli:"1000000000000000",ether:"1000000000000000000",kether:"1000000000000000000000",grand:"1000000000000000000000",mether:"1000000000000000000000000",gether:"1000000000000000000000000000",tether:"1000000000000000000000000000000"};function c(e){var t=e?e.toLowerCase():"ether",r=u[t];if("string"!=typeof r)throw new Error("[ethjs-unit] the unit provided "+e+" doesn't exists, please use the one of the following units "+JSON.stringify(u,null,2));return new i(r,10)}function l(e){if("string"==typeof e){if(!e.match(/^-?[0-9.]+$/))throw new Error("while converting number to string, invalid number value '"+e+"', should be a number matching (^-?[0-9.]+).");return e}if("number"==typeof e)return String(e);if("object"===(0,n.default)(e)&&e.toString&&(e.toTwos||e.dividedToIntegerBy))return e.toPrecision?String(e.toPrecision()):e.toString(10);throw new Error("while converting number to string, invalid number value '"+e+"' type "+(0,n.default)(e)+".")}e.exports={unitMap:u,numberToString:l,getValueOfUnit:c,fromWei:function(e,t,r){var n=o(e),i=n.lt(a),l=c(t),f=u[t].length-1||1,h=r||{};i&&(n=n.mul(s));for(var d=n.mod(l).toString(10);d.length2)throw new Error("[ethjs-unit] while converting number "+e+" to wei, too many decimal points");var h=f[0],d=f[1];if(h||(h="0"),d||(d="0"),d.length>o)throw new Error("[ethjs-unit] while converting number "+e+" to wei, too many decimal places");for(;d.length{"use strict";var t=Object.prototype.hasOwnProperty,r="~";function n(){}function i(e,t,r){this.fn=e,this.context=t,this.once=r||!1}function o(e,t,n,o,a){if("function"!=typeof n)throw new TypeError("The listener must be a function");var s=new i(n,o||e,a),u=r?r+t:t;return e._events[u]?e._events[u].fn?e._events[u]=[e._events[u],s]:e._events[u].push(s):(e._events[u]=s,e._eventsCount++),e}function a(e,t){0==--e._eventsCount?e._events=new n:delete e._events[t]}function s(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(r=!1)),s.prototype.eventNames=function(){var e,n,i=[];if(0===this._eventsCount)return i;for(n in e=this._events)t.call(e,n)&&i.push(r?n.slice(1):n);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(e)):i},s.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,o=n.length,a=new Array(o);i{"use strict";var n=r(8847)(r(3355)),i=Object.create||function(e){var t=function(){};return t.prototype=e,new t},o=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return r},a=Function.prototype.bind||function(e){var t=this;return function(){return t.apply(e,arguments)}};function s(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=i(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0}e.exports=s,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._maxListeners=void 0;var u,c=10;try{var l={};Object.defineProperty&&Object.defineProperty(l,"x",{value:0}),u=0===l.x}catch(e){u=!1}function f(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}function h(e,t,r){if(t)e.call(r);else for(var n=e.length,i=S(e,n),o=0;o0&&u.length>a){u.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+u.length+' "'+String(t)+'" listeners added. Use emitter.setMaxListeners() to increase limit.');c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=u.length,"object"===("undefined"==typeof console?"undefined":(0,n.default)(console))&&console.warn&&console.warn("%s: %s",c.name,c.message)}}else u=s[t]=r,++e._eventsCount;return e}function b(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var e=new Array(arguments.length),t=0;t1&&(t=arguments[1]),t instanceof Error)throw t;var u=new Error('Unhandled "error" event. ('+t+")");throw u.context=t,u}if(!(r=a[e]))return!1;var c="function"==typeof r;switch(n=arguments.length){case 1:h(r,c,this);break;case 2:d(r,c,this,arguments[1]);break;case 3:p(r,c,this,arguments[1],arguments[2]);break;case 4:m(r,c,this,arguments[1],arguments[2],arguments[3]);break;default:for(i=new Array(n-1),o=1;o=0;a--)if(r[a]===t||r[a].listener===t){s=r[a].listener,o=a;break}if(o<0)return this;0===o?r.shift():function(e,t){for(var r=t,n=r+1,i=e.length;n=0;n--)this.removeListener(e,t[n]);return this},s.prototype.listeners=function(e){return w(this,e,!0)},s.prototype.rawListeners=function(e){return w(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):A.call(e,t)},s.prototype.listenerCount=A,s.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]}},7085:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(807);e.exports=function(e,t,r,o){if(n.isBuffer(e)||(e=n.from(e,"binary")),t&&(n.isBuffer(t)||(t=n.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var a=r/8,s=n.alloc(a),u=n.alloc(o||0),c=n.alloc(0);a>0||o>0;){var l=new i;l.update(c),l.update(e),t&&l.update(t),c=l.digest();var f=0;if(a>0){var h=s.length-a;f=Math.min(a,c.length),c.copy(s,h,0,f),a-=f}if(f0){var d=u.length-o,p=Math.min(o,c.length-f);c.copy(u,d,f,f+p),o-=p}}return c.fill(0),{key:s,iv:u}}},8184:(e,t,r)=>{"use strict";var n=r(1493),i=Object.prototype.toString,o=Object.prototype.hasOwnProperty,a=function(e,t,r){for(var n=0,i=e.length;n=3&&(o=r),"[object Array]"===i.call(e)?a(e,t,o):"string"==typeof e?s(e,t,o):u(e,t,o)}},3161:e=>{"use strict";var t="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,i="[object Function]";e.exports=function(e){var o=this;if("function"!=typeof o||n.call(o)!==i)throw new TypeError(t+o);for(var a,s=r.call(arguments,1),u=function(){if(this instanceof a){var t=o.apply(this,s.concat(r.call(arguments)));return Object(t)===t?t:this}return o.apply(e,s.concat(r.call(arguments)))},c=Math.max(0,o.length-s.length),l=[],f=0;f{"use strict";var n=r(3161);e.exports=Function.prototype.bind||n},7701:(e,t,r)=>{"use strict";var n,i=r(8847)(r(3355)),o=SyntaxError,a=Function,s=TypeError,u=function(e){try{return a('"use strict"; return ('+e+").constructor;")()}catch(e){}},c=Object.getOwnPropertyDescriptor;if(c)try{c({},"")}catch(e){c=null}var l=function(){throw new s},f=c?function(){try{return l}catch(e){try{return c(arguments,"callee").get}catch(e){return l}}}():l,h=r(8489)(),d=Object.getPrototypeOf||function(e){return e.__proto__},p={},m="undefined"==typeof Uint8Array?n:d(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":h?d([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":p,"%AsyncGenerator%":p,"%AsyncGeneratorFunction%":p,"%AsyncIteratorPrototype%":p,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":a,"%GeneratorFunction%":p,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":h?d(d([][Symbol.iterator]())):n,"%JSON%":"object"===("undefined"==typeof JSON?"undefined":(0,i.default)(JSON))?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&h?d((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&h?d((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":h?d(""[Symbol.iterator]()):n,"%Symbol%":h?Symbol:n,"%SyntaxError%":o,"%ThrowTypeError%":f,"%TypedArray%":m,"%TypeError%":s,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},g=function e(t){var r;if("%AsyncFunction%"===t)r=u("async function () {}");else if("%GeneratorFunction%"===t)r=u("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=u("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(r=d(i.prototype))}return y[t]=r,r},b={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},v=r(3767),w=r(1888),A=v.call(Function.call,Array.prototype.concat),S=v.call(Function.apply,Array.prototype.splice),k=v.call(Function.call,String.prototype.replace),E=v.call(Function.call,String.prototype.slice),_=v.call(Function.call,RegExp.prototype.exec),M=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,T=/\\(\\)?/g,x=function(e){var t=E(e,0,1),r=E(e,-1);if("%"===t&&"%"!==r)throw new o("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new o("invalid intrinsic syntax, expected opening `%`");var n=[];return k(e,M,(function(e,t,r,i){n[n.length]=r?k(i,T,"$1"):t||e})),n},P=function(e,t){var r,n=e;if(w(b,n)&&(n="%"+(r=b[n])[0]+"%"),w(y,n)){var i=y[n];if(i===p&&(i=g(n)),void 0===i&&!t)throw new s("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:i}}throw new o("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new s("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new s('"allowMissing" argument must be a boolean');if(null===_(/^%?[^%]*%?$/,e))throw new o("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=x(e),n=r.length>0?r[0]:"",i=P("%"+n+"%",t),a=i.name,u=i.value,l=!1,f=i.alias;f&&(n=f[0],S(r,A([0,1],f)));for(var h=1,d=!0;h=r.length){var b=c(u,p);u=(d=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:u[p]}else d=w(u,p),u=u[p];d&&!l&&(y[a]=u)}}return u}},2948:(e,t,r)=>{"use strict";var n;n="undefined"!=typeof window?window:void 0!==r.g?r.g:"undefined"!=typeof self?self:{},e.exports=n},3820:(e,t,r)=>{"use strict";var n=r(7701)("%Object.getOwnPropertyDescriptor%",!0);if(n)try{n([],"length")}catch(e){n=null}e.exports=n},8489:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i="undefined"!=typeof Symbol&&Symbol,o=r(7027);e.exports=function(){return"function"==typeof i&&"function"==typeof Symbol&&"symbol"===(0,n.default)(i("foo"))&&"symbol"===(0,n.default)(Symbol("bar"))&&o()}},7027:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"===(0,n.default)(Symbol.iterator))return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var i=Object.getOwnPropertySymbols(e);if(1!==i.length||i[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(42!==o.value||!0!==o.enumerable)return!1}return!0}},1191:(e,t,r)=>{"use strict";var n=r(7027);e.exports=function(){return n()&&!!Symbol.toStringTag}},1888:(e,t,r)=>{"use strict";var n=r(3767);e.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},2353:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=r(6505).Transform;function o(e){i.call(this),this._block=n.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(1736)(o,i),o.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)},o.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},o.prototype.update=function(e,t){if(function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError("Data must be a string or a buffer")}(e),this._finalized)throw new Error("Digest already called");n.isBuffer(e)||(e=n.from(e,t));for(var r=this._block,i=0;this._blockOffset+e.length-i>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},o.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=o},7198:(e,t,r)=>{"use strict";var n=t;n.utils=r(4268),n.common=r(4696),n.sha=r(9310),n.ripemd=r(9294),n.hmac=r(3201),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},4696:(e,t,r)=>{"use strict";var n=r(4268),i=r(4504);function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}t.BlockHash=o,o.prototype.update=function(e,t){if(e=n.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var i=0;i>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o{"use strict";var n=r(4268),i=r(4504);function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(n.toArray(t,r))}e.exports=o,o.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t{"use strict";var n=r(4268),i=r(4696),o=n.rotl32,a=n.sum32,s=n.sum32_3,u=n.sum32_4,c=i.BlockHash;function l(){if(!(this instanceof l))return new l;c.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function f(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function h(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function d(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}n.inherits(l,c),t.ripemd160=l,l.blockSize=512,l.outSize=160,l.hmacStrength=192,l.padLength=64,l.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],c=this.h[3],l=this.h[4],b=r,v=n,w=i,A=c,S=l,k=0;k<80;k++){var E=a(o(u(r,f(k,n,i,c),e[p[k]+t],h(k)),y[k]),l);r=l,l=c,c=o(i,10),i=n,n=E,E=a(o(u(b,f(79-k,v,w,A),e[m[k]+t],d(k)),g[k]),S),b=S,S=A,A=o(w,10),w=v,v=E}E=s(this.h[1],i,A),this.h[1]=s(this.h[2],c,S),this.h[2]=s(this.h[3],l,b),this.h[3]=s(this.h[4],r,v),this.h[4]=s(this.h[0],n,w),this.h[0]=E},l.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"little"):n.split32(this.h,"little")};var p=[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],m=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],y=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],g=[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]},9310:(e,t,r)=>{"use strict";t.sha1=r(8142),t.sha224=r(4909),t.sha256=r(7682),t.sha384=r(4532),t.sha512=r(6515)},8142:(e,t,r)=>{"use strict";var n=r(4268),i=r(4696),o=r(70),a=n.rotl32,s=n.sum32,u=n.sum32_5,c=o.ft_1,l=i.BlockHash,f=[1518500249,1859775393,2400959708,3395469782];function h(){if(!(this instanceof h))return new h;l.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}n.inherits(h,l),e.exports=h,h.blockSize=512,h.outSize=160,h.hmacStrength=80,h.padLength=64,h.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(4268),i=r(7682);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,7),"big"):n.split32(this.h.slice(0,7),"big")}},7682:(e,t,r)=>{"use strict";var n=r(4268),i=r(4696),o=r(70),a=r(4504),s=n.sum32,u=n.sum32_4,c=n.sum32_5,l=o.ch32,f=o.maj32,h=o.s0_256,d=o.s1_256,p=o.g0_256,m=o.g1_256,y=i.BlockHash,g=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function b(){if(!(this instanceof b))return new b;y.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=g,this.W=new Array(64)}n.inherits(b,y),e.exports=b,b.blockSize=512,b.outSize=256,b.hmacStrength=192,b.padLength=64,b.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(4268),i=r(6515);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,12),"big"):n.split32(this.h.slice(0,12),"big")}},6515:(e,t,r)=>{"use strict";var n=r(4268),i=r(4696),o=r(4504),a=n.rotr64_hi,s=n.rotr64_lo,u=n.shr64_hi,c=n.shr64_lo,l=n.sum64,f=n.sum64_hi,h=n.sum64_lo,d=n.sum64_4_hi,p=n.sum64_4_lo,m=n.sum64_5_hi,y=n.sum64_5_lo,g=i.BlockHash,b=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=b,this.W=new Array(160)}function w(e,t,r,n,i){var o=e&r^~e&i;return o<0&&(o+=4294967296),o}function A(e,t,r,n,i,o){var a=t&n^~t&o;return a<0&&(a+=4294967296),a}function S(e,t,r,n,i){var o=e&r^e&i^r&i;return o<0&&(o+=4294967296),o}function k(e,t,r,n,i,o){var a=t&n^t&o^n&o;return a<0&&(a+=4294967296),a}function E(e,t){var r=a(e,t,28)^a(t,e,2)^a(t,e,7);return r<0&&(r+=4294967296),r}function _(e,t){var r=s(e,t,28)^s(t,e,2)^s(t,e,7);return r<0&&(r+=4294967296),r}function M(e,t){var r=s(e,t,14)^s(e,t,18)^s(t,e,9);return r<0&&(r+=4294967296),r}function T(e,t){var r=a(e,t,1)^a(e,t,8)^u(e,t,7);return r<0&&(r+=4294967296),r}function x(e,t){var r=s(e,t,1)^s(e,t,8)^c(e,t,7);return r<0&&(r+=4294967296),r}function P(e,t){var r=s(e,t,19)^s(t,e,29)^c(e,t,6);return r<0&&(r+=4294967296),r}n.inherits(v,g),e.exports=v,v.blockSize=1024,v.outSize=512,v.hmacStrength=192,v.padLength=128,v.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n{"use strict";var n=r(4268).rotr32;function i(e,t,r){return e&t^~e&r}function o(e,t,r){return e&t^e&r^t&r}function a(e,t,r){return e^t^r}t.ft_1=function(e,t,r,n){return 0===e?i(t,r,n):1===e||3===e?a(t,r,n):2===e?o(t,r,n):void 0},t.ch32=i,t.maj32=o,t.p32=a,t.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},t.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},t.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},4268:(e,t,r)=>{"use strict";var n=r(4504),i=r(1736);function o(e,t){return 55296==(64512&e.charCodeAt(t))&&!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1))}function a(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function s(e){return 1===e.length?"0"+e:e}function u(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=i,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),i=0;i>6|192,r[n++]=63&a|128):o(e,i)?(a=65536+((1023&a)<<10)+(1023&e.charCodeAt(++i)),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=63&a|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=63&a|128)}else for(i=0;i>>0}return a},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,n){return(t+n>>>0>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,o,a,s){var u=0,c=t;return u+=(c=c+n>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,n,i,o,a,s){return t+n+o+s>>>0},t.sum64_5_hi=function(e,t,r,n,i,o,a,s,u,c){var l=0,f=t;return l+=(f=f+n>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,n,i,o,a,s,u,c){return t+n+o+s+c>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},9410:(e,t,r)=>{"use strict";var n=r(7198),i=r(6580),o=r(4504);function a(e){if(!(this instanceof a))return new a(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=i.toArray(e.entropy,e.entropyEnc||"hex"),r=i.toArray(e.nonce,e.nonceEnc||"hex"),n=i.toArray(e.pers,e.persEnc||"hex");o(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}e.exports=a,a.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},a.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=i.toArray(r,n||"hex"),this._update(r));for(var o=[];o.length{"use strict";var n=r(9519),i=r(1143),o=e.exports;for(var a in n)n.hasOwnProperty(a)&&(o[a]=n[a]);function s(e){if("string"==typeof e&&(e=i.parse(e)),e.protocol||(e.protocol="https:"),"https:"!==e.protocol)throw new Error('Protocol "'+e.protocol+'" not supported. Expected "https:"');return e}o.request=function(e,t){return e=s(e),n.request.call(this,e,t)},o.get=function(e,t){return e=s(e),n.get.call(this,e,t)}},2996:(e,t,r)=>{"use strict";var n;r(8847)(r(3355)),void 0===(n=function(){return e=[new Uint32Array([2157250,2157314,2157378,2157442,2157506,2157570,2157634,0,2157698,2157762,2157826,2157890,2157954,0,2158018,0]),new Uint32Array([2179041,6291456,2179073,6291456,2179105,6291456,2179137,6291456,2179169,6291456,2179201,6291456,2179233,6291456,2179265,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([0,2113729,2197345,2197377,2113825,2197409,2197441,2113921,2197473,2114017,2197505,2197537,2197569,2197601,2197633,2197665]),new Uint32Array([6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,23068672,23068672,23068672,0,0,0,0,23068672]),new Uint32Array([14680064,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,14680064,14680064]),new Uint32Array([2196001,2196033,2196065,2196097,2196129,2196161,2196193,2196225,2196257,2196289,2196321,2196353,2196385,2196417,2196449,2196481]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,6291456,0,0,0,0,0]),new Uint32Array([2097281,2105921,2097729,2106081,0,2097601,2162337,2106017,2133281,2097505,2105889,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([2177025,6291456,2177057,6291456,2177089,6291456,2177121,6291456,2177153,6291456,2177185,6291456,2177217,6291456,2177249,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,0,6291456,6291456,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456]),new Uint32Array([2134435,2134531,2134627,2134723,2134723,2134819,2134819,2134915,2134915,2135011,2105987,2135107,2135203,2135299,2131587,2135395]),new Uint32Array([0,0,0,0,0,0,0,6291456,2168673,2169249,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2147906,2147970,2148034,2148098,2148162,2148226,2148290,2148354,2147906,2147970,2148034,2148098,2148162,2148226,2148290,2148354]),new Uint32Array([2125219,2125315,2152834,2152898,2125411,2152962,2153026,2125506,2125507,2125603,2153090,2153154,2153218,2153282,2153346,2105348]),new Uint32Array([2203393,6291456,2203425,6291456,2203457,6291456,2203489,6291456,6291456,6291456,6291456,2203521,6291456,2181281,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,6291456,2145538,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,6291456]),new Uint32Array([2139426,2160834,2160898,2160962,2134242,2161026,2161090,2161154,2161218,2161282,2161346,2161410,2138658,2161474,2161538,2134722]),new Uint32Array([2119939,2124930,2125026,2106658,2125218,2128962,2129058,2129154,2129250,2129346,2129442,2108866,2108770,2150466,2150530,2150594]),new Uint32Array([2201601,6291456,2201633,6291456,2201665,6291456,2201697,6291456,2201729,6291456,2201761,6291456,2201793,6291456,2201825,6291456]),new Uint32Array([2193537,2193569,2193601,2193633,2193665,2193697,2193729,2193761,2193793,2193825,2193857,2193889,2193921,2193953,2193985,2194017]),new Uint32Array([6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2190561,6291456,2190593,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2190625,6291456,2190657,6291456,23068672]),new Uint32Array([2215905,2215937,2215969,2216001,2216033,2216065,2216097,2216129,2216161,2216193,2216225,2216257,2105441,2216289,2216321,2216353]),new Uint32Array([23068672,18884130,23068672,23068672,23068672,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2191233,2191265,2191297,2191329,2191361,2191393,2191425,2117377,2191457,2191489,2191521,2191553,2191585,2191617,2191649,2117953]),new Uint32Array([2132227,2132323,2132419,2132419,2132515,2132515,2132611,2132707,2132707,2132803,2132899,2132899,2132995,2132995,2133091,2133187]),new Uint32Array([0,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,6291456,0,0]),new Uint32Array([2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,10609889,10610785,10609921,10610817,2222241]),new Uint32Array([6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0]),new Uint32Array([2219969,2157121,2157441,2157505,2157889,2157953,2220001,2158465,2158529,10575617,2156994,2157058,2129923,2130019,2157122,2157186]),new Uint32Array([6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2185249,6291456,2185281,6291456,2185313,6291456,2185345,6291456,2185377,6291456,2185409,6291456,2185441,6291456,2185473,6291456]),new Uint32Array([0,0,0,0,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,0,0,23068672,23068672,23068672,6291456,0]),new Uint32Array([2183361,6291456,2183393,6291456,2183425,6291456,2183457,6291456,2183489,6291456,2183521,6291456,2183553,6291456,2183585,6291456]),new Uint32Array([2192161,2192193,2192225,2192257,2192289,2192321,2192353,2192385,2192417,2192449,2192481,2192513,2192545,2192577,2192609,2192641]),new Uint32Array([2212001,2212033,2212065,2212097,2212129,2212161,2212193,2212225,2212257,2212289,2212321,2212353,2212385,2212417,2212449,2207265]),new Uint32Array([2249825,2249857,2249889,2249921,2249954,2250018,2250082,2250145,2250177,2250209,2250241,2250274,2250337,2250370,2250433,2250465]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2147905,2147969,2148033,2148097,2148161,2148225,2148289,2148353]),new Uint32Array([10485857,6291456,2197217,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,23068672,23068672]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2180353,2180385,2144033,2180417,2180449,2180481,2180513,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,10610209,10610465,10610241,10610753,10609857]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,0,0]),new Uint32Array([2223842,2223906,2223970,2224034,2224098,2224162,2224226,2224290,2224354,2224418,2224482,2224546,2224610,2224674,2224738,2224802]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([23068672,23068672,23068672,18923650,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,18923714,23068672,23068672]),new Uint32Array([2126179,2125538,2126275,2126371,2126467,2125634,2126563,2105603,2105604,2125346,2126659,2126755,2126851,2098179,2098181,2098182]),new Uint32Array([2227426,2227490,2227554,2227618,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2192353,2240642,2240642,2240705,2240737,2240737,2240769,2240802,2240866,2240929,2240961,2240993,2241025,2241057,2241089,2241121]),new Uint32Array([6291456,2170881,2170913,2170945,6291456,2170977,6291456,2171009,2171041,6291456,6291456,6291456,2171073,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2132226,2132514,2163586,2132610,2160386,2133090,2133186,2160450,2160514,2160578,2133570,2106178,2160642,2133858,2160706,2160770]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,10532162,10532226,10532290,10532354,10532418,10532482,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,23068672]),new Uint32Array([2098209,2108353,2108193,2108481,2170241,2111713,2105473,2105569,2105601,2112289,2112481,2098305,2108321,0,0,0]),new Uint32Array([2209121,2209153,2209185,2209217,2209249,2209281,2209313,2209345,2209377,2209409,2209441,2209473,2207265,2209505,2209537,2209569]),new Uint32Array([2189025,6291456,2189057,6291456,2189089,6291456,2189121,6291456,2189153,6291456,2189185,6291456,2189217,6291456,2189249,6291456]),new Uint32Array([2173825,2153473,2173857,2173889,2173921,2173953,2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233057]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2165764,2140004]),new Uint32Array([2215105,6291456,2215137,6291456,6291456,2215169,2215201,6291456,6291456,6291456,2215233,2215265,2215297,2215329,2215361,2215393]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,23068672,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([10505091,10505187,10505283,10505379,10505475,10505571,10505667,10505763,10505859,10505955,10506051,10506147,10506243,10506339,10506435,10506531]),new Uint32Array([2229730,2229794,2229858,2229922,2229986,2230050,2230114,2230178,2230242,2230306,2230370,2230434,2230498,2230562,2230626,2230690]),new Uint32Array([2105505,2098241,2108353,2108417,2105825,0,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177]),new Uint32Array([6291456,6291456,6291456,6291456,10502115,10502178,10502211,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456]),new Uint32Array([2190305,6291456,2190337,6291456,2190369,6291456,2190401,6291456,2190433,6291456,2190465,6291456,2190497,6291456,2190529,6291456]),new Uint32Array([2173793,2173985,2174017,6291456,2173761,2173697,6291456,2174689,6291456,2174017,2174721,6291456,6291456,2174753,2174785,2174817]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2099521,2099105,2120705,2098369,2120801,2103361,2097985,2098433,2121377,2121473,2099169,2099873,2098401,2099393,2152609,2100033]),new Uint32Array([2132898,2163842,2163906,2133282,2132034,2131938,2137410,2132802,2132706,2164866,2133282,2160578,2165186,2165186,6291456,6291456]),new Uint32Array([10500003,10500099,10500195,10500291,10500387,10500483,10500579,10500675,10500771,10500867,10500963,10501059,10501155,10501251,10501347,10501443]),new Uint32Array([2163458,2130978,2131074,2131266,2131362,2163522,2160130,2132066,2131010,2131106,2106018,2131618,2131298,2132034,2131938,2137410]),new Uint32Array([2212961,2116993,2212993,2213025,2213057,2213089,2213121,2213153,2213185,2213217,2213249,2209633,2213281,2213313,2213345,2213377]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2113729,2113825,2113921,2114017,2114113,2114209,2114305,2114401,2114497,2114593,2114689,2114785,2114881,2114977,2115073,2115169]),new Uint32Array([2238177,2238209,2238241,2238273,2238305,2238337,2238337,2217537,2238369,2238401,2238433,2238465,2215649,2238497,2238529,2238561]),new Uint32Array([2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905]),new Uint32Array([6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,0]),new Uint32Array([6291456,0,6291456,2145026,0,6291456,2145090,0,6291456,6291456,0,0,23068672,0,23068672,23068672]),new Uint32Array([2099233,2122017,2200673,2098113,2121537,2103201,2200705,2104033,2121857,2121953,2122401,2099649,2099969,2123009,2100129,2100289]),new Uint32Array([6291456,23068672,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,23068672,23068672,0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0]),new Uint32Array([2187681,2187713,2187745,2187777,2187809,2187841,2187873,2187905,2187937,2187969,2188001,2188033,2188065,2188097,2188129,2188161]),new Uint32Array([0,10554498,10554562,10554626,10554690,10554754,10554818,10554882,10554946,10555010,10555074,6291456,6291456,0,0,0]),new Uint32Array([2235170,2235234,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0]),new Uint32Array([2181153,6291456,2188897,6291456,6291456,2188929,6291456,6291456,6291456,6291456,6291456,6291456,2111905,2100865,2188961,2188993]),new Uint32Array([2100833,2100897,0,0,2101569,2101697,2101825,2101953,2102081,2102209,10575617,2187041,10502177,10489601,10489697,2112289]),new Uint32Array([6291456,2172833,6291456,2172865,2172897,2172929,2172961,6291456,2172993,6291456,2173025,6291456,2173057,6291456,2173089,6291456]),new Uint32Array([6291456,0,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,0,0,23068672,6291456,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,2190721]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,23068672,6291456,6291456]),new Uint32Array([2184993,6291456,2185025,6291456,2185057,6291456,2185089,6291456,2185121,6291456,2185153,6291456,2185185,6291456,2185217,6291456]),new Uint32Array([2115265,2115361,2115457,2115553,2115649,2115745,2115841,2115937,2116033,2116129,2116225,2116321,2150658,2150722,2200225,6291456]),new Uint32Array([2168321,6291456,2168353,6291456,2168385,6291456,2168417,6291456,2168449,6291456,2168481,6291456,2168513,6291456,2168545,6291456]),new Uint32Array([23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,0,6291456,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,2186625,0,0,6291456,6291456,2186657,2186689,2186721,2173505,0,10496067,10496163,10496259]),new Uint32Array([2178785,6291456,2178817,6291456,2178849,6291456,2178881,6291456,2178913,6291456,2178945,6291456,2178977,6291456,2179009,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0]),new Uint32Array([2097152,0,0,0,2097152,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,2197857,2197889,2197921,2197953,2197985,2198017,0,0,2198049,2198081,2198113,2198145,2198177,2198209]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2098209,2167297,2111137,6291456]),new Uint32Array([2171393,6291456,2171425,6291456,2171457,6291456,2171489,6291456,2171521,6291456,2171553,6291456,2171585,6291456,2171617,6291456]),new Uint32Array([2206753,2206785,2195457,2206817,2206849,2206881,2206913,2197153,2197153,2206945,2117857,2206977,2207009,2207041,2207073,2207105]),new Uint32Array([0,0,0,0,0,0,0,23068672,0,0,0,0,2144834,2144898,0,2144962]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,23068672]),new Uint32Array([2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,0,2105505,2098241]),new Uint32Array([6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,2202049,6291456,2202081,6291456,2202113,6291456,2202145,6291456,2202177,6291456,2202209,6291456,2202241,6291456]),new Uint32Array([10501155,10501251,10501347,10501443,10501539,10501635,10501731,10501827,10501923,10502019,2141731,2105505,2098177,2155586,2166530,0]),new Uint32Array([2102081,2102209,2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,2100833,2100737,2098337,2101441]),new Uint32Array([2146882,2146946,2147010,2147074,2147138,2147202,2147266,2147330,2146882,2146946,2147010,2147074,2147138,2147202,2147266,2147330]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([10502307,10502403,10502499,10502595,10502691,10502787,10502883,10502979,10503075,10503171,10503267,10503363,10503459,10503555,10503651,10503747]),new Uint32Array([2179937,2179969,2180001,2180033,2156545,2180065,2156577,2180097,2180129,2180161,2180193,2180225,2180257,2180289,2156737,2180321]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,0,0,0,6291456,0,0,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0]),new Uint32Array([2227682,2227746,2227810,2227874,2227938,2228002,2228066,2228130,2228194,2228258,2228322,2228386,2228450,2228514,2228578,2228642]),new Uint32Array([2105601,2169121,2108193,2170049,2181025,2181057,2112481,2108321,2108289,2181089,2170497,2100865,2181121,2173601,2173633,2173665]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2180641,6291456,6291456,6291456]),new Uint32Array([0,6291456,6291456,6291456,0,6291456,0,6291456,0,0,6291456,6291456,0,6291456,6291456,6291456]),new Uint32Array([2178273,6291456,2178305,6291456,2178337,6291456,2178369,6291456,2178401,6291456,2178433,6291456,2178465,6291456,2178497,6291456]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,6291456,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,14680064,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456]),new Uint32Array([2237377,2237409,2236225,2237441,2237473,2217441,2215521,2215553,2217473,2237505,2237537,2209697,2237569,2215585,2237601,2237633]),new Uint32Array([2221985,2165601,2165601,2165665,2165665,2222017,2222017,2165729,2165729,2158913,2158913,2158913,2158913,2097281,2097281,2105921]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2149634,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2176897,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,2176929,6291456,2176961,6291456,2176993,6291456]),new Uint32Array([2172641,6291456,2172673,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2172705,2172737,6291456,2172769,2172801,6291456]),new Uint32Array([2099173,2104196,2121667,2099395,2121763,2152258,2152322,2098946,2152386,2121859,2121955,2099333,2122051,2104324,2099493,2122147]),new Uint32Array([6291456,6291456,6291456,2145794,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,2145858,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,0,0,6291456,0]),new Uint32Array([0,2105921,2097729,0,2097377,0,0,2106017,0,2097505,2105889,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2239074,2239138,2239201,2239233,2239265,2239297,2239329,2239361,0,2239393,2239425,2239425,2239458,2239521,2239553,2209569]),new Uint32Array([14680064,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,6291456,23068672]),new Uint32Array([2108321,2108289,2113153,2098209,2180897,2180929,2180961,2111137,2098241,2108353,2170241,2170273,2180993,2105825,6291456,2105473]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2146114,6291456,6291456,6291456,0,0,0]),new Uint32Array([2105921,2105921,2105921,2222049,2222049,2130977,2130977,2130977,2130977,2160065,2160065,2160065,2160065,2097729,2097729,2097729]),new Uint32Array([2218145,2214785,2207937,2218177,2218209,2192993,2210113,2212769,2218241,2218273,2216129,2218305,2216161,2218337,2218369,2218401]),new Uint32Array([0,0,0,2156546,2156610,2156674,2156738,2156802,0,0,0,0,0,2156866,23068672,2156930]),new Uint32Array([23068672,23068672,23068672,0,0,0,0,23068672,23068672,0,0,23068672,23068672,23068672,0,0]),new Uint32Array([2213409,2213441,2213473,2213505,2213537,2213569,2213601,2213633,2213665,2195681,2213697,2213729,2213761,2213793,2213825,2213857]),new Uint32Array([2100033,2099233,2122017,2200673,2098113,2121537,2103201,2200705,2104033,2121857,2121953,2122401,2099649,2099969,2123009,2100129]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2201857,6291456,2201889,6291456,2201921,6291456,2201953,6291456,2201985,6291456,2202017,6291456,2176193,2176257,23068672,23068672]),new Uint32Array([6291456,6291456,23068672,23068672,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2188193,2188225,2188257,2188289,2188321,2188353,2188385,2188417,2188449,2188481,2188513,2188545,2188577,2188609,2188641,0]),new Uint32Array([10554529,2221089,0,10502113,10562017,10537921,10538049,2221121,2221153,0,0,0,0,0,0,0]),new Uint32Array([2213889,2213921,2213953,2213985,2214017,2214049,2214081,2194177,2214113,2214145,2214177,2214209,2214241,2214273,2214305,2214337]),new Uint32Array([2166978,2167042,2099169,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2180545,6291456,6291456,6291456]),new Uint32Array([10518915,10519011,10519107,10519203,2162242,2162306,2159554,2162370,2159362,2159618,2105922,2162434,2159746,2162498,2159810,2159874]),new Uint32Array([2161730,2161794,2135586,2161858,2161922,2137186,2131810,2160290,2135170,2161986,2137954,2162050,2162114,2162178,10518723,10518819]),new Uint32Array([10506627,10506723,10506819,10506915,10507011,10507107,10507203,10507299,10507395,10507491,10507587,10507683,10507779,10507875,10507971,10508067]),new Uint32Array([6291456,23068672,23068672,23068672,0,23068672,23068672,0,0,0,0,0,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0]),new Uint32Array([2175873,2175905,2175937,2175969,2176001,2176033,2176065,2176097,2176129,2176161,2176193,2176225,2176257,2176289,2176321,2176353]),new Uint32Array([2140006,2140198,2140390,2140582,2140774,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,23068672,23068672,23068672]),new Uint32Array([2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241]),new Uint32Array([0,23068672,0,0,0,0,0,0,0,2145154,2145218,2145282,6291456,0,2145346,0]),new Uint32Array([0,0,0,0,10531458,10495395,2148545,2143201,2173473,2148865,2173505,0,2173537,0,2173569,2149121]),new Uint32Array([10537282,10495683,2148738,2148802,2148866,0,6291456,2148930,2186593,2173473,2148737,2148865,2148802,10495779,10495875,10495971]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2215425,2215457,2215489,2215521,2215553,2215585,2215617,2215649,2215681,2215713,2215745,2215777,2192033,2215809,2215841,2215873]),new Uint32Array([2242049,2242081,2242113,2242145,2242177,2242209,2242241,2242273,2215937,2242305,2242338,2242401,2242433,2242465,2242497,2216001]),new Uint32Array([10554529,2221089,0,0,10562017,10502113,10538049,10537921,2221185,10489601,10489697,10609889,10609921,2141729,2141793,10610273]),new Uint32Array([2141923,2142019,2142115,2142211,2142307,2142403,2142499,2142595,2142691,0,0,0,0,0,0,0]),new Uint32Array([0,2221185,2221217,10609857,10609857,10489601,10489697,10609889,10609921,2141729,2141793,2221345,2221377,2221409,2221441,2187105]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,18923970,23068672,23068672,23068672,0,6291456,6291456]),new Uint32Array([2183105,6291456,2183137,6291456,2183169,6291456,2183201,6291456,2183233,6291456,2183265,6291456,2183297,6291456,2183329,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([2134434,2134818,2097666,2097186,2097474,2097698,2105986,2131586,2132450,2131874,2131778,2135970,2135778,2161602,2136162,2161666]),new Uint32Array([2236865,2236897,2236930,2236993,2237025,2235681,2237058,2237121,2237153,2237185,2237217,2217281,2237250,2191233,2237313,2237345]),new Uint32Array([2190049,6291456,2190081,6291456,2190113,6291456,2190145,6291456,2190177,6291456,2190209,6291456,2190241,6291456,2190273,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2101922,2102050,2102178,2102306,10498755,10498851,10498947,10499043,10499139,10499235,10499331,10499427,10499523,10489604,10489732,10489860]),new Uint32Array([2166914,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2181601,2170561,2181633,2181665,2170753,2181697,2172897,2170881,2181729,2170913,2172929,2113441,2181761,2181793,2171009,2173761]),new Uint32Array([0,2105921,2097729,2106081,0,2097601,2162337,2106017,2133281,2097505,0,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([2248001,2248033,2248066,2248130,2248193,2248226,2248289,2248322,2248385,2248417,2216673,2248450,2248514,2248577,2248610,2248673]),new Uint32Array([6291456,6291456,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,0,0,0]),new Uint32Array([2169729,6291456,2169761,6291456,2169793,6291456,2169825,6291456,2169857,2169889,6291456,2169921,6291456,2143329,6291456,2098305]),new Uint32Array([2162178,2163202,2163266,2135170,2136226,2161986,2137954,2159426,2159490,2163330,2159554,2163394,2159682,2139522,2136450,2159746]),new Uint32Array([2173953,2173985,0,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2174209,2174241,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,4271169,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2174273]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,0,0,0,0,0,0,0,6291456,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,2190785,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2189793,6291456,2189825,6291456,2189857,6291456,2189889,6291456,2189921,6291456,2189953,6291456,2189985,6291456,2190017,6291456]),new Uint32Array([2105601,2112289,2108193,2112481,2112577,0,2098305,2108321,2108289,2100865,2113153,2108481,2113345,0,2098209,2111137]),new Uint32Array([2172129,6291456,2172161,6291456,2172193,6291456,2172225,6291456,2172257,6291456,2172289,6291456,2172321,6291456,2172353,6291456]),new Uint32Array([2214753,6291456,2214785,6291456,6291456,2214817,2214849,2214881,2214913,2214945,2214977,2215009,2215041,2215073,2194401,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([0,0,0,0,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([10610305,10610337,10575617,2221761,10610401,10610433,10502177,0,10610465,10610497,10610529,10610561,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,23068672,0,0,0,0,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2187105,2187137,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2199393,2199425,2199457,2199489,2199521,2199553,2199585,2199617,2199649,2199681,2199713,2199745,2199777,2199809,2199841,0]),new Uint32Array([2217249,2217281,2217313,2217345,2217377,2217409,2217441,2217473,2215617,2217505,2217537,2217569,2214753,2217601,2217633,2217665]),new Uint32Array([2170273,2170305,6291456,2170337,2170369,6291456,2170401,2170433,2170465,6291456,6291456,6291456,2170497,2170529,6291456,2170561]),new Uint32Array([2188673,6291456,2188705,2188737,2188769,6291456,6291456,2188801,6291456,2188833,6291456,2188865,6291456,2180929,2181505,2180897]),new Uint32Array([10489988,10490116,10490244,10490372,10490500,10490628,10490756,10490884,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2147393,2147457,2147521,2147585,2147649,2147713,2147777,2147841]),new Uint32Array([23068672,23068672,0,23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2241153,2241185,2241217,2215809,2241250,2241313,2241345,2241377,2217921,2241377,2241409,2215873,2241441,2241473,2241505,2241537]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2220417,2220417,2220449,2220449,2220481,2220481,2220513,2220513,2220545,2220545,2220577,2220577,2220609,2220609,2220641,2220641]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,2144002,0,6291456,6291456,0,0,6291456,6291456,6291456]),new Uint32Array([2167105,2167137,2167169,2167201,2167233,2167265,2167297,2167329,2167361,2167393,2167425,2167457,2167489,2167521,2167553,2167585]),new Uint32Array([10575521,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193]),new Uint32Array([2234146,2234210,2234274,2234338,2234402,2234466,2234530,2234594,2234658,2234722,2234786,2234850,2234914,2234978,2235042,2235106]),new Uint32Array([0,0,0,0,0,0,0,2180577,0,0,0,0,0,2180609,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,0,0,6291456,6291456]),new Uint32Array([2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2242529,2242561,2242593,2242625,2242657,2242689,2242721,2242753,2207937,2218177,2242785,2242817,2242849,2242882,2242945,2242977]),new Uint32Array([2118049,2105345,2118241,2105441,2118433,2118529,2118625,2118721,2118817,2200257,2200289,2191809,2200321,2200353,2200385,2200417]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([2185505,6291456,2185537,6291456,2185569,6291456,2185601,6291456,2185633,6291456,2185665,6291456,2185697,6291456,2185729,6291456]),new Uint32Array([2231970,2232034,2232098,2232162,2232226,2232290,2232354,2232418,2232482,2232546,2232610,2232674,2232738,2232802,2232866,2232930]),new Uint32Array([2218625,2246402,2246466,2246530,2246594,2246657,2246689,2246689,2218657,2219681,2246721,2246753,2246785,2246818,2246881,2208481]),new Uint32Array([2197025,2197057,2197089,2197121,2197153,2197185,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2219137,2216961,2219169,2219201,2219233,2219265,2219297,2217025,2215041,2219329,2217057,2219361,2217089,2219393,2197153,2219426]),new Uint32Array([23068672,23068672,23068672,0,0,0,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713]),new Uint32Array([2243522,2243585,2243617,2243649,2243681,2210113,2243713,2243746,2243810,2243874,2243937,2243970,2244033,2244065,2244097,2244129]),new Uint32Array([2178017,6291456,2178049,6291456,2178081,6291456,2178113,6291456,2178145,6291456,2178177,6291456,2178209,6291456,2178241,6291456]),new Uint32Array([10553858,2165314,10518722,6291456,10518818,0,10518914,2130690,10519010,2130786,10519106,2130882,10519202,2165378,10554050,2165506]),new Uint32Array([0,0,2135491,2135587,2135683,2135779,2135875,2135971,2135971,2136067,2136163,2136259,2136355,2136355,2136451,2136547]),new Uint32Array([23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2220033,2220033,2220065,2220065,2220065,2220065,2220097,2220097,2220097,2220097,2220129,2220129,2220129,2220129,2220161,2220161]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2100897,2100898,2100899,2150018,2100865,2100866,2100867,2100868,2150082,2108481,2109858,2109859,2105569,2105505,2098241,2105601]),new Uint32Array([2097217,2097505,2097505,2097505,2097505,2165570,2165570,2165634,2165634,2165698,2165698,2097858,2097858,0,0,2097152]),new Uint32Array([23068672,6291456,23068672,23068672,23068672,6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,23068672,23068672]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([10503843,10503939,10504035,10504131,10504227,10504323,10504419,10504515,10504611,10504707,10504803,10504899,10504995,10491140,10491268,0]),new Uint32Array([2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2173761,2174017,2174049]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2134145,2097153,2134241,2105953,2132705,2130977,2160065,2131297,2162049,2133089,2160577,2133857,2235297,2220769,2235329,2235361]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2222401,2222433,2222465,10531394,2222497,2222529,2222561,0,2222593,2222625,2222657,2222689,2222721,2222753,2222785,0]),new Uint32Array([2184481,6291456,2184513,6291456,2184545,6291456,2184577,6291456,2184609,6291456,2184641,6291456,2184673,6291456,2184705,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0,0,0,0,0,0,0,0]),new Uint32Array([2105570,2156034,2126947,2156098,2153666,2127043,2127139,2156162,0,2127235,2156226,2156290,2156354,2156418,2127331,2127427]),new Uint32Array([2215905,2207041,2153185,2241569,2241601,2241633,2241665,2241697,2241730,2241793,2241825,2241857,2241889,2241921,2241954,2242017]),new Uint32Array([2203777,6291456,2203809,6291456,2203841,6291456,2203873,6291456,2203905,6291456,2173121,2180993,2181249,2203937,2181313,0]),new Uint32Array([2168577,6291456,2168609,6291456,2168641,6291456,2168673,6291456,2168705,6291456,2168737,6291456,2168769,6291456,2168801,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,23068672,23068672,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,0,23068672,23068672,23068672,0,0]),new Uint32Array([2210113,2195521,2210145,2210177,2210209,2210241,2210273,2210305,2210337,2210369,2210401,2210433,2210465,2210497,2210529,2210561]),new Uint32Array([6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([2228706,2228770,2228834,2228898,2228962,2229026,2229090,2229154,2229218,2229282,2229346,2229410,2229474,2229538,2229602,2229666]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,18874368,18874368,18874368,0,0]),new Uint32Array([2133089,2133281,2133281,2133281,2133281,2160577,2160577,2160577,2160577,2097441,2097441,2097441,2097441,2133857,2133857,2133857]),new Uint32Array([6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2173825,2153473,2173857,2173889,2173921,2173953,2173985,2174017,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233089]),new Uint32Array([2178529,6291456,2178561,6291456,2178593,6291456,2178625,6291456,2178657,6291456,2178689,6291456,2178721,6291456,2178753,6291456]),new Uint32Array([2221025,2221025,2221057,2221057,2159329,2159329,2159329,2159329,2097217,2097217,2158914,2158914,2158978,2158978,2159042,2159042]),new Uint32Array([2208161,2208193,2208225,2208257,2194433,2208289,2208321,2208353,2208385,2208417,2208449,2208481,2208513,2208545,2208577,2208609]),new Uint32Array([2169217,6291456,2169249,6291456,2169281,6291456,2169313,6291456,2169345,6291456,2169377,6291456,2169409,6291456,2169441,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([2133187,2133283,2133283,2133379,2133475,2133571,2133667,2133667,2133763,2133859,2133955,2134051,2134147,2134147,2134243,2134339]),new Uint32Array([2197697,2114113,2114209,2197729,2197761,2114305,2197793,2114401,2114497,2197825,2114593,2114689,2114785,2114881,2114977,0]),new Uint32Array([2193089,2193121,2193153,2193185,2117665,2117569,2193217,2193249,2193281,2193313,2193345,2193377,2193409,2193441,2193473,2193505]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2184225,6291456,2184257,6291456,2184289,6291456,2184321,6291456,2184353,6291456,2184385,6291456,2184417,6291456,2184449,6291456]),new Uint32Array([2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2100833,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2098657,2098049,2200737,2123489,2123681,2200769,2098625,2100321,2098145,2100449,2098017,2098753,2200801,2200833,2200865,0]),new Uint32Array([23068672,23068672,23068672,0,0,0,0,0,0,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0]),new Uint32Array([2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,0,2098241,2108353,2108417,2105825,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2181153,2105505,2181185,2167617,2180993]),new Uint32Array([2160002,2160066,2160130,2160194,2160258,2132066,2131010,2131106,2106018,2131618,2160322,2131298,2132034,2131938,2137410,2132226]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,6291456]),new Uint32Array([2183617,6291456,2183649,6291456,2183681,6291456,2183713,6291456,2183745,6291456,2183777,6291456,2183809,6291456,2183841,6291456]),new Uint32Array([0,6291456,6291456,0,6291456,0,0,6291456,6291456,0,6291456,0,0,6291456,0,0]),new Uint32Array([2250977,2251009,2251041,2251073,2195009,2251106,2251169,2251201,2251233,2251265,2251297,2251330,2251394,2251457,2251489,2251521]),new Uint32Array([2205729,2205761,2205793,2205825,2205857,2205889,2205921,2205953,2205985,2206017,2206049,2206081,2206113,2206145,2206177,2206209]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2143170,2168993,6291456,2169025,6291456,2169057,6291456,2169089,6291456,2143234,2169121,6291456,2169153,6291456,2169185,6291456]),new Uint32Array([23068672,23068672,2190689,6291456,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2248706,2248769,2248801,2248833,2248865,2248897,2248929,2248962,2249026,2249090,2249154,2240705,2249217,2249249,2249281,2249313]),new Uint32Array([10485857,6291456,6291456,6291456,6291456,6291456,6291456,6291456,10495394,6291456,2098209,6291456,6291456,2097152,6291456,10531394]),new Uint32Array([0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([14680064,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2173985,2173953,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889]),new Uint32Array([6291456,2186977,6291456,6291456,6291456,6291456,6291456,10537858,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2209601,2209633,2209665,2209697,2209729,2209761,2209793,2209825,2209857,2209889,2209921,2209953,2209985,2210017,2210049,2210081]),new Uint32Array([10501539,10501635,10501731,10501827,10501923,10502019,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905]),new Uint32Array([2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2174017,2174017,2174049]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2194561,2194593,2194625,2119777,2119873,2194657,2194689,2194721,2194753,2194785,2194817,2194849,2194881,2194913,2194945,2194977]),new Uint32Array([2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569]),new Uint32Array([2222818,2222882,2222946,2223010,2223074,2223138,2223202,2223266,2223330,2223394,2223458,2223522,2223586,2223650,2223714,2223778]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672]),new Uint32Array([0,2179553,2179585,2179617,2179649,2144001,2179681,2179713,2179745,2179777,2179809,2156705,2179841,2156833,2179873,2179905]),new Uint32Array([6291456,23068672,6291456,2145602,23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,6291456,0,0]),new Uint32Array([2196513,2196545,2196577,2196609,2196641,2196673,2196705,2196737,2196769,2196801,2196833,2196865,2196897,2196929,2196961,2196993]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2177281,6291456,2177313,6291456,2177345,6291456,2177377,6291456,2177409,6291456,2177441,6291456,2177473,6291456,2177505,6291456]),new Uint32Array([2187137,2221473,2221505,2221537,2221569,6291456,6291456,10610209,10610241,10537986,10537986,10537986,10537986,10609857,10609857,10609857]),new Uint32Array([2243009,2243041,2216033,2243074,2243137,2243169,2243201,2219617,2243233,2243265,2243297,2243329,2243362,2243425,2243457,2243489]),new Uint32Array([10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,10485857,2097152,4194304,4194304,0,0]),new Uint32Array([2143042,6291456,2143106,2143106,2168833,6291456,2168865,6291456,6291456,2168897,6291456,2168929,6291456,2168961,6291456,2143170]),new Uint32Array([6291456,6291456,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2204193,2204225,2204257,2204289,2204321,2204353,2204385,2204417,2204449,2204481,2204513,2204545,2204577,2204609,2204641,2204673]),new Uint32Array([2202753,6291456,2202785,6291456,2202817,6291456,2202849,6291456,2202881,6291456,2202913,6291456,2202945,6291456,2202977,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321]),new Uint32Array([2147394,2147458,2147522,2147586,2147650,2147714,2147778,2147842,2147394,2147458,2147522,2147586,2147650,2147714,2147778,2147842]),new Uint32Array([2253313,2253346,2253409,2253441,2253473,2253505,2253537,2253569,2253601,2253634,2219393,2253697,2253729,2253761,2253793,2253825]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([2162562,2162626,2131362,2162690,2159938,2160002,2162754,2162818,2160130,2162882,2160194,2160258,2160834,2160898,2161026,2161090]),new Uint32Array([2175361,2175393,2175425,2175457,2175489,2175521,2175553,2175585,2175617,2175649,2175681,2175713,2175745,2175777,2175809,2175841]),new Uint32Array([2253858,2253921,2253954,2254018,2254082,2196737,2254145,2196865,2254177,2254209,2254241,2254273,2197025,2254306,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2202113,2204129,2188705,2204161]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([2173985,2174017,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113,2173985,2173953]),new Uint32Array([2101569,2101697,2101825,2101953,2102081,2102209,2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209]),new Uint32Array([2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,0,2108417,0,2111713,2100897,2111905]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0]),new Uint32Array([2175425,2175489,2175809,2175905,2175937,2175937,2176193,2176417,2180865,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,2143298,2143298,2143298,2143362,2143362,2143362,2143426,2143426,2143426,2171105,6291456,2171137]),new Uint32Array([2120162,2120258,2151618,2151682,2151746,2151810,2151874,2151938,2152002,2120035,2120131,2120227,2152066,2120323,2152130,2120419]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2195361,2142433,2236065,2236097,2236129,2236161,2118241,2117473,2236193,2236225,2236257,2236289,0,0,0,0]),new Uint32Array([2189281,6291456,2189313,6291456,2189345,6291456,2189377,6291456,2189409,6291456,2189441,6291456,2189473,6291456,2189505,6291456]),new Uint32Array([6291456,6291456,2145922,6291456,6291456,6291456,6291456,2145986,6291456,6291456,6291456,6291456,2146050,6291456,6291456,6291456]),new Uint32Array([2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,10502113,10562017,10610401,10502177,10610433,10538049]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,2186401,0,2186433,0,2186465,0,2186497]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,23068672,23068672,23068672]),new Uint32Array([0,0,2198241,2198273,2198305,2198337,2198369,2198401,0,0,2198433,2198465,2198497,0,0,0]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,6291456,0,23068672,23068672,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,0,0,23068672,6291456,23068672,23068672]),new Uint32Array([0,2105921,2097729,0,2097377,0,0,2106017,2133281,2097505,2105889,0,2097697,2135777,2097633,2097441]),new Uint32Array([2197889,2197921,2197953,2197985,2198017,2198049,2198081,2198113,2198145,2198177,2198209,2198241,2198273,2198305,2198337,2198369]),new Uint32Array([2132514,2132610,2160386,2133090,2133186,2160450,2160514,2133282,2160578,2133570,2106178,2160642,2133858,2160706,2160770,2134146]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,23068672,6291456,23068672,23068672,6291456,23068672,0,0,0,0,0,0,0,0]),new Uint32Array([2184737,6291456,2184769,6291456,2184801,6291456,2184833,6291456,2184865,6291456,2184897,6291456,2184929,6291456,2184961,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,23068672,23068672,23068672,6291456,23068672,23068672,23068672,23068672,23068672,0,0]),new Uint32Array([6291456,6291456,6291456,2186753,6291456,6291456,6291456,6291456,2186785,2186817,2186849,2173569,2186881,10496355,10495395,10575521]),new Uint32Array([0,0,2097729,0,0,0,0,2106017,0,2097505,0,2097185,0,2135777,2097633,2097441]),new Uint32Array([2189537,6291456,2189569,6291456,2189601,6291456,2189633,6291456,2189665,6291456,2189697,6291456,2189729,6291456,2189761,6291456]),new Uint32Array([2202497,6291456,2202529,6291456,2202561,6291456,2202593,6291456,2202625,6291456,2202657,6291456,2202689,6291456,2202721,6291456]),new Uint32Array([2245217,2218369,2245249,2245282,2245345,2245377,2245410,2245474,2245537,2245569,2245601,2245633,2245665,2245665,2245697,2245729]),new Uint32Array([6291456,0,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,0,0,0,0,0,0,23068672,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,6291456,23068672,6291456,23068672,6291456,6291456,6291456,6291456,23068672,23068672]),new Uint32Array([0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2097281,2105921,2097729,2106081,2097377,2097601,2162337,2106017,2133281,2097505,0,2097185,2097697,2135777,2097633,2097441]),new Uint32Array([2176641,6291456,2176673,6291456,2176705,6291456,2176737,6291456,2176769,6291456,2176801,6291456,2176833,6291456,2176865,6291456]),new Uint32Array([2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113,2173985,2173953,2174369,2174369,0,0,2100833,2100737]),new Uint32Array([2116513,2190817,2190849,2190881,2190913,2190945,2116609,2190977,2191009,2191041,2191073,2117185,2191105,2191137,2191169,2191201]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,6291456,6291456,6291456]),new Uint32Array([0,0,0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456]),new Uint32Array([2167617,2167649,2167681,2167713,2167745,2167777,2167809,6291456,2167841,2167873,2167905,2167937,2167969,2168001,2168033,4240130]),new Uint32Array([2165122,2163970,2164034,2164098,2164162,2164226,2164290,2164354,2164418,2164482,2164546,2133122,2134562,2132162,2132834,2136866]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,2186209,2186241,2186273,2186305,2186337,2186369,0,0]),new Uint32Array([2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([0,0,23068672,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456]),new Uint32Array([0,10537921,10610689,10610273,10610497,10610529,10610305,10610721,10489601,10489697,10610337,10575617,10554529,2221761,2197217,10496577]),new Uint32Array([2105473,2105569,2105601,2112289,0,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441]),new Uint32Array([2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481]),new Uint32Array([2125346,2153410,2153474,2127394,2153538,2153602,2153666,2153730,2105507,2105476,2153794,2153858,2153922,2153986,2154050,2105794]),new Uint32Array([2200449,2119681,2200481,2153313,2199873,2199905,2199937,2200513,2200545,2200577,2200609,2119105,2119201,2119297,2119393,2119489]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2175777,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2222273,2197217,2221473,2221505,2221089,2222305,2200865,2099681,2104481,2222337,2099905,2120737,2222369,2103713,2100225,2098785]),new Uint32Array([2201377,6291456,2201409,6291456,2201441,6291456,2201473,6291456,2201505,6291456,2201537,6291456,2201569,6291456,6291456,23068672]),new Uint32Array([2174081,2174113,2174145,2174177,2149057,2233057,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793]),new Uint32Array([2200897,6291456,2200929,6291456,2200961,6291456,2200993,6291456,2201025,6291456,2180865,6291456,2201057,6291456,2201089,6291456]),new Uint32Array([0,0,0,0,0,23068672,23068672,0,6291456,6291456,6291456,0,0,0,0,0]),new Uint32Array([2161154,2161410,2138658,2161474,2161538,2097666,2097186,2097474,2162946,2132450,2163010,2163074,2136162,2163138,2161666,2161730]),new Uint32Array([2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953]),new Uint32Array([0,0,0,0,0,0,23068672,23068672,0,0,0,0,2145410,2145474,0,6291456]),new Uint32Array([2244161,2216065,2212769,2244193,2244225,2244257,2244290,2244353,2244385,2244417,2244449,2218273,2244481,2244514,2244577,2244609]),new Uint32Array([2125730,2125699,2125795,2125891,2125987,2154114,2154178,2154242,2154306,2154370,2154434,2154498,2126082,2126178,2126274,2126083]),new Uint32Array([2237665,2237697,2237697,2237697,2237730,2237793,2237825,2237857,2237890,2237953,2237985,2238017,2238049,2238081,2238113,2238145]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2150146,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,0,0,23068672,23068672,23068672,0,0]),new Uint32Array([2214369,2238593,2238625,2238657,2238689,2238721,2238753,2238785,2238817,2238850,2238913,2238945,2238977,2235457,2239009,2239041]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([2252066,2252130,2252193,2252225,2252257,2252290,2252353,2252385,2252417,2252449,2252481,2252513,2252545,2252578,2252641,2252673]),new Uint32Array([2197697,2114113,2114209,2197729,2197761,2114305,2197793,2114401,2114497,2197825,2114593,2114689,2114785,2114881,2114977,2197857]),new Uint32Array([2224866,2224930,2224994,2225058,2225122,2225186,2225250,2225314,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2219490,2219554,2219617,2219649,2219681,2219714,2219778,2219842,2219905,2219937,0,0,0,0,0,0]),new Uint32Array([6291456,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456]),new Uint32Array([2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289]),new Uint32Array([2174081,2174113,2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113,2173985,2173953,2148481,2173601,2173633,2173665]),new Uint32Array([2220161,2220161,2220193,2220193,2220193,2220193,2220225,2220225,2220225,2220225,2220257,2220257,2220257,2220257,2220289,2220289]),new Uint32Array([2192673,2192705,2192737,2192769,2192801,2192833,2192865,2118049,2192897,2117473,2117761,2192929,2192961,2192993,2193025,2193057]),new Uint32Array([2179297,6291456,2179329,6291456,2179361,6291456,2179393,6291456,2179425,6291456,2179457,6291456,2179489,6291456,2179521,6291456]),new Uint32Array([6291456,6291456,6291456,23068672,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2235745,2235777,2193633,2235809,2235841,2235873,2235905,2235937,2235969,2116513,2116705,2236001,2200513,2199905,2200545,2236033]),new Uint32Array([2113153,2108481,2113345,2113441,2232993,2233025,0,0,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761]),new Uint32Array([2170593,6291456,2170625,6291456,2170657,6291456,2170689,2170721,6291456,2170753,6291456,6291456,2170785,6291456,2170817,2170849]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2166786,2166850,0,0,0,0]),new Uint32Array([23068672,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,10575617,2187041,10502177,10489601,10489697,0]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2134562,2132162,2132834,2136866,2136482,2164610,2164674,2164738,2164802,2132802,2132706,2164866,2132898,2164930,2164994,2165058]),new Uint32Array([6291456,6291456,2098337,2101441,10531458,2153473,6291456,6291456,10531522,2100737,2108193,6291456,2106499,2106595,2106691,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0]),new Uint32Array([2233122,2233186,2233250,2233314,2233378,2233442,2233506,2233570,2233634,2233698,2233762,2233826,2233890,2233954,2234018,2234082]),new Uint32Array([23068672,6291456,23068672,23068672,23068672,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2205217,2205249,2205281,2205313,2205345,2205377,2205409,2205441,2205473,2205505,2205537,2205569,2205601,2205633,2205665,2205697]),new Uint32Array([6291456,0,6291456,0,0,0,6291456,6291456,6291456,6291456,0,0,23068672,6291456,23068672,23068672]),new Uint32Array([2173601,2173761,2174081,2173569,2174241,2174113,2173953,6291456,2174305,6291456,2174337,6291456,2174369,6291456,2174401,6291456]),new Uint32Array([6291456,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([2152450,2152514,2099653,2104452,2099813,2122243,2099973,2152578,2122339,2122435,2122531,2122627,2122723,2104580,2122819,2152642]),new Uint32Array([2236385,2236417,2236449,2236482,2236545,2215425,2236577,2236609,2236641,2236673,2215457,2236705,2236737,2236770,2215489,2236833]),new Uint32Array([2163394,2159746,2163458,2131362,2163522,2160130,2163778,2132226,2163842,2132898,2163906,2161410,2138658,2097666,2136162,2163650]),new Uint32Array([2218721,2246913,2246946,2216385,2247010,2247074,2215009,2247137,2247169,2216481,2247201,2247233,2247266,2247330,2247330,0]),new Uint32Array([2129730,2129762,2129858,2129731,2129827,2156482,2156482,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,0,0,0,0,6291456,0,0]),new Uint32Array([2203969,2204001,2181377,2204033,2204065,6291456,2204097,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([2169473,6291456,2169505,6291456,2169537,6291456,2169569,6291456,2169601,6291456,2169633,6291456,2169665,6291456,2169697,6291456]),new Uint32Array([2141542,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2220801,2220801,2220801,2220801,2220833,2220833,2220865,2220865,2220865,2220865,2220897,2220897,2220897,2220897,2139873,2139873]),new Uint32Array([0,0,0,0,0,23068672,23068672,0,0,0,0,0,0,0,6291456,0]),new Uint32Array([2214849,2218433,2218465,2218497,2218529,2218561,2214881,2218593,2218625,2218657,2218689,2218721,2218753,2216545,2218785,2218817]),new Uint32Array([23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,0,0,0,6291456]),new Uint32Array([2136482,2164610,2164674,2164738,2164802,2132802,2132706,2164866,2132898,2164930,2164994,2165058,2165122,2132802,2132706,2164866]),new Uint32Array([2207649,2207681,2207713,2207745,2207777,2207809,2207841,2207873,2207905,2207937,2207969,2208001,2208033,2208065,2208097,2208129]),new Uint32Array([2123683,2105092,2152706,2123779,2105220,2152770,2100453,2098755,2123906,2124002,2124098,2124194,2124290,2124386,2124482,2124578]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,6291456,0,0,0,0,0,0,0,10485857]),new Uint32Array([6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([10508163,10508259,10508355,10508451,2200129,2200161,2192737,2200193,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2203553,6291456,2203585,6291456,6291456,6291456,2203617,6291456,2203649,6291456,2203681,6291456,2203713,6291456,2203745,6291456]),new Uint32Array([18884449,18884065,23068672,18884417,18884034,18921185,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,18874368]),new Uint32Array([2247393,2247426,2247489,2247521,2247553,2247586,2247649,2247681,2247713,2247745,2247777,2247810,2247873,2247905,2247937,2247969]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,23068672]),new Uint32Array([2134145,2097153,2134241,0,2132705,2130977,2160065,2131297,0,2133089,2160577,2133857,2235297,0,2235329,0]),new Uint32Array([2182593,6291456,2182625,6291456,2182657,6291456,2182689,6291456,2182721,6291456,2182753,6291456,2182785,6291456,2182817,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2102402,2102403,6291456,2110050]),new Uint32Array([2149890,2108323,2149954,6291456,2113441,6291456,2149057,6291456,2113441,6291456,2105473,2167265,2111137,2105505,6291456,2108353]),new Uint32Array([2219105,2219137,2195233,2251554,2251617,2251649,2251681,2251713,2251746,2251810,2251873,2251905,2251937,2251970,2252033,2219169]),new Uint32Array([2203009,6291456,2203041,6291456,2203073,6291456,2203105,6291456,2203137,6291456,2203169,6291456,2203201,6291456,2203233,6291456]),new Uint32Array([2128195,2128291,2128387,2128483,2128579,2128675,2128771,2128867,2128963,2129059,2129155,2129251,2129347,2129443,2129539,2129635]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2140964,2141156,2140966,2141158,2141350]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2225378,2225442,2225506,2225570,2225634,2225698,2225762,2225826,2225890,2225954,2226018,2226082,2226146,2226210,2226274,2226338]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137,2105505,2098241,2108353,2108417]),new Uint32Array([2108353,2108417,0,2105601,2108193,2157121,2157313,2157377,2157441,2100897,6291456,2108419,2173953,2173633,2173633,2173953]),new Uint32Array([2111713,2173121,2111905,2098177,2173153,2173185,2173217,2113153,2113345,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,2190753]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,2197249,6291456,2117377,2197281,2197313,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,0,0,0,0,0,0,23068672,0,0,0,0,0,6291456,6291456,6291456]),new Uint32Array([2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,2100833,2100737,2098337,2101441,2101569,2101697,2101825,2101953]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0]),new Uint32Array([0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,23068672,23068672,23068672]),new Uint32Array([2173281,6291456,2173313,6291456,2173345,6291456,2173377,6291456,0,0,10532546,6291456,6291456,6291456,10562017,2173441]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,0,0]),new Uint32Array([23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2159426,2159490,2159554,2159362,2159618,2159682,2139522,2136450,2159746,2159810,2159874,2130978,2131074,2131266,2131362,2159938]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2203233,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2203265,6291456,2203297,6291456,2203329,2203361,6291456]),new Uint32Array([6291456,6291456,2148418,2148482,2148546,0,6291456,2148610,2186529,2186561,2148417,2148545,2148482,10495778,2143969,10495778]),new Uint32Array([2134146,2139426,2160962,2134242,2161218,2161282,2161346,2161410,2138658,2134722,2134434,2134818,2097666,2097346,2097698,2105986]),new Uint32Array([2198881,2198913,2198945,2198977,2199009,2199041,2199073,2199105,2199137,2199169,2199201,2199233,2199265,2199297,2199329,2199361]),new Uint32Array([0,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([10610561,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193]),new Uint32Array([2183873,6291456,2183905,6291456,2183937,6291456,2183969,6291456,2184001,6291456,2184033,6291456,2184065,6291456,2184097,6291456]),new Uint32Array([2244642,2244706,2244769,2244801,2218305,2244833,2244865,2244897,2244929,2244961,2244993,2245026,2245089,2245122,2245185,0]),new Uint32Array([6291456,6291456,2116513,2116609,2116705,2116801,2199873,2199905,2199937,2199969,2190913,2200001,2200033,2200065,2200097,2191009]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,2180673,2180705,2180737,2180769,2180801,2180833,0,0]),new Uint32Array([2098081,2099521,2099105,2120705,2098369,2120801,2103361,2097985,2098433,2121377,2121473,2099169,2099873,2098401,2099393,2152609]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2150402]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,2145666,2145730,6291456,6291456]),new Uint32Array([2173921,2173953,2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233057,2148481,2173601,2173633,2173665]),new Uint32Array([2187073,6291456,6291456,6291456,6291456,2098241,2098241,2108353,2100897,2111905,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2102404,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,2100612,6291456,6291456,6291456,6291456,6291456,6291456,6291456,10485857]),new Uint32Array([2149057,2233057,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889]),new Uint32Array([2217697,2217729,2217761,2217793,2217825,2217857,2217889,2217921,2217953,2215873,2217985,2215905,2218017,2218049,2218081,2218113]),new Uint32Array([2211233,2218849,2216673,2218881,2218913,2218945,2218977,2219009,2216833,2219041,2215137,2219073,2216865,2209505,2219105,2216897]),new Uint32Array([2240097,2240129,2240161,2240193,2240225,2240257,2240289,2240321,2240353,2240386,2240449,2240481,2240513,2240545,2207905,2240578]),new Uint32Array([6291456,6291456,2202273,6291456,2202305,6291456,2202337,6291456,2202369,6291456,2202401,6291456,2202433,6291456,2202465,6291456]),new Uint32Array([0,23068672,23068672,18923394,23068672,18923458,18923522,18884099,18923586,18884195,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2201121,6291456,2201153,6291456,2201185,6291456,2201217,6291456,2201249,6291456,2201281,6291456,2201313,6291456,2201345,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,6291456]),new Uint32Array([2211041,2211073,2211105,2211137,2211169,2211201,2211233,2211265,2211297,2211329,2211361,2211393,2211425,2211457,2211489,2211521]),new Uint32Array([2181825,6291456,2181857,6291456,2181889,6291456,2181921,6291456,2181953,6291456,2181985,6291456,2182017,6291456,2182049,6291456]),new Uint32Array([2162337,2097633,2097633,2097633,2097633,2132705,2132705,2132705,2132705,2097153,2097153,2097153,2097153,2133089,2133089,2133089]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,2148545,6291456,2173473,6291456,2148865,6291456,2173505,6291456,2173537,6291456,2173569,6291456,2149121,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,0,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2174017,2174017,2174049,2174081,2174113]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2207137,2207169,2207201,2207233,2207265,2207297,2207329,2207361,2207393,2207425,2207457,2207489,2207521,2207553,2207585,2207617]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,6291456,6291456,0,23068672,23068672,0,0,0,0,0,0]),new Uint32Array([2198401,2198433,2198465,2198497,0,2198529,2198561,2198593,2198625,2198657,2198689,2198721,2198753,2198785,2198817,2198849]),new Uint32Array([2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,0,0]),new Uint32Array([2216385,2118721,2216417,2216449,2216481,2216513,2216545,2211233,2216577,2216609,2216641,2216673,2216705,2216737,2216737,2216769]),new Uint32Array([2216801,2216833,2216865,2216897,2216929,2216961,2216993,2215169,2217025,2217057,2217089,2217121,2217154,2217217,0,0]),new Uint32Array([2210593,2191809,2210625,2210657,2210689,2210721,2210753,2210785,2210817,2210849,2191297,2210881,2210913,2210945,2210977,2211009]),new Uint32Array([0,0,2105825,0,0,2111905,2105473,0,0,2112289,2108193,2112481,2112577,0,2098305,2108321]),new Uint32Array([0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,2097153,2134241,0,2132705,0,0,2131297,0,2133089,0,2133857,0,2220769,0,2235361]),new Uint32Array([14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,6291456,6291456,14680064]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([2171873,6291456,2171905,6291456,2171937,6291456,2171969,6291456,2172001,6291456,2172033,6291456,2172065,6291456,2172097,6291456]),new Uint32Array([2220929,2220929,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2133857,2134145,2134145,2134145,2134145,2134241,2134241,2134241,2134241,2105889,2105889,2105889,2105889,2097185,2097185,2097185]),new Uint32Array([2173697,2173761,2173793,2174113,2173985,2173953,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,10499619,10499715,10499811,10499907]),new Uint32Array([0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,0,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,0,23068672,23068672,23068672,0,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,6291456,23068672,23068672]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,2144322,2144386,2144450,2144514,2144578,2144642,2144706,2144770]),new Uint32Array([23068672,23068672,23068672,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456]),new Uint32Array([2113153,2108481,2113345,2113441,2098209,2111137,0,2098241,2108353,2108417,2105825,0,0,2111905,2105473,2105569]),new Uint32Array([2236321,2236353,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2152194,2121283,2103684,2103812,2097986,2098533,2097990,2098693,2098595,2098853,2099013,2103940,2121379,2121475,2121571,2104068]),new Uint32Array([2206241,2206273,2206305,2206337,2206369,2206401,2206433,2206465,2206497,2206529,2206561,2206593,2206625,2206657,2206689,2206721]),new Uint32Array([6291456,6291456,6291456,6291456,16777216,16777216,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,23068672,23068672,10538818,10538882,6291456,6291456,2150338]),new Uint32Array([6291456,6291456,6291456,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2214369,2214401,2214433,2214465,2214497,2214529,2214561,2214593,2194977,2214625,2195073,2214657,2214689,2214721,6291456,6291456]),new Uint32Array([2097152,2097152,2097152,2097152,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2182081,6291456,2182113,6291456,2182145,6291456,2182177,6291456,2182209,6291456,2182241,6291456,2182273,6291456,2182305,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2146881,2146945,2147009,2147073,2147137,2147201,2147265,2147329]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,23068672,23068672]),new Uint32Array([0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2122915,2123011,2123107,2104708,2123203,2123299,2123395,2100133,2104836,2100290,2100293,2104962,2104964,2098052,2123491,2123587]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456]),new Uint32Array([6291456,2171169,6291456,2171201,6291456,2171233,6291456,2171265,6291456,2171297,6291456,2171329,6291456,6291456,2171361,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,2148994,2149058,2149122,0,6291456,2149186,2186945,2173537,2148993,2149121,2149058,10531458,10496066,0]),new Uint32Array([2195009,2195041,2195073,2195105,2195137,2195169,2195201,2195233,2195265,2195297,2195329,2195361,2195393,2195425,2195457,2195489]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,0,0,6291456,6291456]),new Uint32Array([2182849,6291456,2182881,6291456,2182913,6291456,2182945,6291456,2182977,6291456,2183009,6291456,2183041,6291456,2183073,6291456]),new Uint32Array([2211553,2210081,2211585,2211617,2211649,2211681,2211713,2211745,2211777,2211809,2209569,2211841,2211873,2211905,2211937,2211969]),new Uint32Array([2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2166594,2127298,2166658,2142978,2141827,2166722]),new Uint32Array([2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233057,2148481,2173601,2173633,2173665,2173697,2173729]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,0,0,2185761,2185793,2185825,2185857,2185889,2185921,0,0]),new Uint32Array([6291456,2148481,2173601,2173633,2173665,2173697,2173729,2148801,2173761,2143969,2173793,2173825,2153473,2173857,2173889,2173921]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,6291456]),new Uint32Array([0,0,0,2220961,2220961,2220961,2220961,2144193,2144193,2159201,2159201,2159265,2159265,2144194,2220993,2220993]),new Uint32Array([2192641,2235393,2235425,2152257,2116609,2235457,2235489,2200065,2235521,2235553,2235585,2212449,2235617,2235649,2235681,2235713]),new Uint32Array([2194049,2194081,2194113,2194145,2194177,2194209,2194241,2194273,2194305,2194337,2194369,2194401,2194433,2194465,2194497,2194529]),new Uint32Array([2196673,2208641,2208673,2208705,2208737,2208769,2208801,2208833,2208865,2208897,2208929,2208961,2208993,2209025,2209057,2209089]),new Uint32Array([2191681,2191713,2191745,2191777,2153281,2191809,2191841,2191873,2191905,2191937,2191969,2192001,2192033,2192065,2192097,2192129]),new Uint32Array([2230946,2231010,2231074,2231138,2231202,2231266,2231330,2231394,2231458,2231522,2231586,2231650,2231714,2231778,2231842,2231906]),new Uint32Array([14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064,14680064]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,2185953,2185985,2186017,2186049,2186081,2186113,2186145,2186177]),new Uint32Array([2139811,2139907,2097284,2105860,2105988,2106116,2106244,2097444,2097604,2097155,10485778,10486344,2106372,6291456,0,0]),new Uint32Array([2110051,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2172385,6291456,2172417,6291456,2172449,6291456,2172481,6291456,2172513,6291456,2172545,6291456,2172577,6291456,2172609,6291456]),new Uint32Array([0,0,23068672,23068672,6291456,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2249345,2249377,2249409,2249441,2249473,2249505,2249537,2249570,2210209,2249633,2249665,2249697,2249729,2249761,2249793,2216769]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,6291456,6291456,6291456,6291456]),new Uint32Array([2187169,2187201,2187233,2187265,2187297,2187329,2187361,2187393,2187425,2187457,2187489,2187521,2187553,2187585,2187617,2187649]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([0,0,0,6291456,6291456,0,0,0,6291456,6291456,6291456,0,0,0,6291456,6291456]),new Uint32Array([2182337,6291456,2182369,6291456,2182401,6291456,2182433,6291456,2182465,6291456,2182497,6291456,2182529,6291456,2182561,6291456]),new Uint32Array([2138179,2138275,2138371,2138467,2134243,2134435,2138563,2138659,2138755,2138851,2138947,2139043,2138947,2138755,2139139,2139235]),new Uint32Array([23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([0,0,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2250498,2250562,2250625,2250657,2208321,2250689,2250721,2250753,2250785,2250817,2250849,2218945,2250881,2250913,2250945,0]),new Uint32Array([2170369,2105569,2098305,2108481,2173249,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456]),new Uint32Array([2100897,2111905,2105473,2105569,2105601,0,2108193,0,0,0,2098305,2108321,2108289,2100865,2113153,2108481]),new Uint32Array([2100897,2100897,2105569,2105569,6291456,2112289,2149826,6291456,6291456,2112481,2112577,2098177,2098177,2098177,6291456,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,6291456,6291456,6291456]),new Uint32Array([6291456,2169953,2169985,6291456,2170017,6291456,2170049,2170081,6291456,2170113,2170145,2170177,6291456,6291456,2170209,2170241]),new Uint32Array([6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([0,0,0,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2220641,2220641,2220673,2220673,2220673,2220673,2220705,2220705,2220705,2220705,2220737,2220737,2220737,2220737,2220769,2220769]),new Uint32Array([2127650,2127746,2127842,2127938,2128034,2128130,2128226,2128322,2128418,2127523,2127619,2127715,2127811,2127907,2128003,2128099]),new Uint32Array([2143969,2173793,2173825,2153473,2173857,2173889,2173921,2173953,2173985,2173761,2174017,2174049,2174081,2174113,2174145,2174177]),new Uint32Array([0,0,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([2204705,2204737,2204769,2204801,2204833,2204865,2204897,2204929,2204961,2204993,2205025,2205057,2205089,2205121,2205153,2205185]),new Uint32Array([2176385,6291456,2176417,6291456,2176449,6291456,2176481,6291456,2176513,6291456,2176545,6291456,2176577,6291456,2176609,6291456]),new Uint32Array([2195521,2195553,2195585,2195617,2195649,2195681,2117857,2195713,2195745,2195777,2195809,2195841,2195873,2195905,2195937,2195969]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,6291456,6291456]),new Uint32Array([2173921,2173953,2173985,2174017,2174017,2174049,2174081,2174113,2174145,2174177,2149057,2233089,2173697,2173761,2173793,2174113]),new Uint32Array([2131586,2132450,2135970,2135778,2161602,2136162,2163650,2161794,2135586,2163714,2137186,2131810,2160290,2135170,2097506,2159554]),new Uint32Array([2134145,2097153,2134241,2105953,2132705,2130977,2160065,2131297,2162049,2133089,2160577,2133857,0,0,0,0]),new Uint32Array([2116513,2116609,2116705,2116801,2116897,2116993,2117089,2117185,2117281,2117377,2117473,2117569,2117665,2117761,2117857,2117953]),new Uint32Array([2100737,2098337,2101441,2101569,2101697,2101825,2101953,2102081,2102209,2100802,2101154,2101282,2101410,2101538,2101666,2101794]),new Uint32Array([2100289,2098657,2098049,2200737,2123489,2123681,2200769,2098625,2100321,2098145,2100449,2098017,2098753,2098977,2150241,2150305]),new Uint32Array([6291456,6291456,6291456,0,6291456,6291456,6291456,6291456,6291456,2109955,6291456,6291456,0,0,0,0]),new Uint32Array([18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368,18874368]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,6291456,0,6291456,0,0]),new Uint32Array([2130979,2131075,2131075,2131171,2131267,2131363,2131459,2131555,2131651,2131651,2131747,2131843,2131939,2132035,2132131,2132227]),new Uint32Array([0,2177793,6291456,2177825,6291456,2177857,6291456,2177889,6291456,2177921,6291456,2177953,6291456,2177985,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672]),new Uint32Array([6291456,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2113345,0,2098209,2111137,2105505,2098241,2108353,2108417,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289]),new Uint32Array([2136643,2136739,2136835,2136931,2137027,2137123,2137219,2137315,2137411,2137507,2137603,2137699,2137795,2137891,2137987,2138083]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0]),new Uint32Array([2174433,6291456,2174465,6291456,2174497,6291456,2174529,6291456,2174561,6291456,2174593,6291456,2174625,6291456,2174657,6291456]),new Uint32Array([0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441]),new Uint32Array([10496547,10496643,2105505,2149698,6291456,10496739,10496835,2170273,6291456,2149762,2105825,2111713,2111713,2111713,2111713,2168673]),new Uint32Array([6291456,2143490,2143490,2143490,2171649,6291456,2171681,2171713,2171745,6291456,2171777,6291456,2171809,6291456,2171841,6291456]),new Uint32Array([2159106,2159106,2159170,2159170,2159234,2159234,2159298,2159298,2159298,2159362,2159362,2159362,2106401,2106401,2106401,2106401]),new Uint32Array([2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865,2113153,2108481,2113345,2113441,2098209,2111137]),new Uint32Array([2108417,2181217,2181249,2181281,2170433,2170401,2181313,2181345,2181377,2181409,2181441,2181473,2181505,2181537,2170529,2181569]),new Uint32Array([2218433,2245761,2245793,2245825,2245857,2245890,2245953,2245986,2209665,2246050,2246113,2246146,2246210,2246274,2246337,2246369]),new Uint32Array([2230754,2230818,2230882,0,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([6291456,0,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,0,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2184129,6291456,2184161,6291456,2184193,6291456,6291456,6291456,6291456,6291456,2146818,2183361,6291456,6291456,2142978,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2135170,2097506,2130691,2130787,2130883,2163970,2164034,2164098,2164162,2164226,2164290,2164354,2164418,2164482,2164546,2133122]),new Uint32Array([2108515,2108611,2100740,2108707,2108803,2108899,2108995,2109091,2109187,2109283,2109379,2109475,2109571,2109667,2109763,2100738]),new Uint32Array([2102788,2102916,2103044,2120515,2103172,2120611,2120707,2098373,2103300,2120803,2120899,2120995,2103428,2103556,2121091,2121187]),new Uint32Array([2158082,2158146,0,2158210,2158274,0,2158338,2158402,2158466,2129922,2158530,2158594,2158658,2158722,2158786,2158850]),new Uint32Array([10499619,10499715,10499811,10499907,10500003,10500099,10500195,10500291,10500387,10500483,10500579,10500675,10500771,10500867,10500963,10501059]),new Uint32Array([2239585,2239618,2239681,2239713,0,2191969,2239745,2239777,2192033,2239809,2239841,2239874,2239937,2239970,2240033,2240065]),new Uint32Array([2252705,2252738,2252801,2252833,2252865,2252897,2252930,2252994,2253057,2253089,2253121,2253154,2253217,2253250,2219361,2219361]),new Uint32Array([2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,2108193,2112481,2112577,2098177,2098305,2108321,2108289,2100865]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,10538050,10538114,10538178,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([2226402,2226466,2226530,2226594,2226658,2226722,2226786,2226850,2226914,2226978,2227042,2227106,2227170,2227234,2227298,2227362]),new Uint32Array([23068672,6291456,6291456,6291456,6291456,2144066,2144130,2144194,2144258,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,23068672,23068672,23068672,6291456,23068672,23068672]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0]),new Uint32Array([2124674,2124770,2123875,2123971,2124067,2124163,2124259,2124355,2124451,2124547,2124643,2124739,2124835,2124931,2125027,2125123]),new Uint32Array([2168065,6291456,2168097,6291456,2168129,6291456,2168161,6291456,2168193,6291456,2168225,6291456,2168257,6291456,2168289,6291456]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0]),new Uint32Array([23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,2100610,2100611,6291456,2107842,2107843,6291456,6291456,6291456,6291456,10537922,6291456,10537986,6291456]),new Uint32Array([2174849,2174881,2174913,2174945,2174977,2175009,2175041,2175073,2175105,2175137,2175169,2175201,2175233,2175265,2175297,2175329]),new Uint32Array([2154562,2154626,2154690,2154754,2141858,2154818,2154882,2127298,2154946,2127298,2155010,2155074,2155138,2155202,2155266,2155202]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456,6291456,6291456,6291456,6291456,23068672,0]),new Uint32Array([2200641,2150786,2150850,2150914,2150978,2151042,2106562,2151106,2150562,2151170,2151234,2151298,2151362,2151426,2151490,2151554]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,23068672,0,0,0,0,0,0,0,0,6291456,6291456]),new Uint32Array([2220289,2220289,2220321,2220321,2220321,2220321,2220353,2220353,2220353,2220353,2220385,2220385,2220385,2220385,2220417,2220417]),new Uint32Array([2155330,2155394,0,2155458,2155522,2155586,2105732,0,2155650,2155714,2155778,2125314,2155842,2155906,2126274,2155970]),new Uint32Array([23068672,23068672,23068672,23068672,23068672,6291456,6291456,23068672,23068672,6291456,23068672,23068672,23068672,23068672,6291456,6291456]),new Uint32Array([6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,6291456,0,0,0,0,0,0]),new Uint32Array([2097729,2106017,2106017,2106017,2106017,2131297,2131297,2131297,2131297,2106081,2106081,2162049,2162049,2105953,2105953,2162337]),new Uint32Array([2097185,2097697,2097697,2097697,2097697,2135777,2135777,2135777,2135777,2097377,2097377,2097377,2097377,2097601,2097601,2097217]),new Uint32Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,23068672]),new Uint32Array([2139331,2139427,2139523,2139043,2133571,2132611,2139619,2139715,0,0,0,0,0,0,0,0]),new Uint32Array([2174113,2174145,2100897,2098177,2108289,2100865,2173601,2173633,2173985,2174113,2174145,6291456,6291456,6291456,6291456,6291456]),new Uint32Array([6291456,6291456,23068672,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456,23068672,6291456,6291456,6291456,6291456]),new Uint32Array([23068672,23068672,18923778,23068672,23068672,23068672,23068672,18923842,23068672,23068672,23068672,23068672,18923906,23068672,23068672,23068672]),new Uint32Array([2134145,2097153,2134241,0,2132705,2130977,2160065,2131297,0,2133089,0,2133857,0,0,0,0]),new Uint32Array([6291456,6291456,6291456,6291456,0,0,0,0,0,0,0,0,0,0,0,0]),new Uint32Array([2177537,6291456,2177569,6291456,2177601,6291456,2177633,6291456,2177665,6291456,2177697,6291456,2177729,6291456,2177761,6291456]),new Uint32Array([2212481,2212513,2212545,2212577,2197121,2212609,2212641,2212673,2212705,2212737,2212769,2212801,2212833,2212865,2212897,2212929]),new Uint32Array([6291456,6291456,23068672,23068672,23068672,6291456,6291456,0,0,0,0,0,0,0,0,0]),new Uint32Array([2098241,2108353,2170209,2105825,2111713,2100897,2111905,2105473,2105569,2105601,2112289,6291456,2108193,2172417,2112481,2098177]),new Uint32Array([6291456,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,23068672,6291456,6291456])],t=new Uint16Array([616,616,565,147,161,411,330,2,131,131,328,454,241,408,86,86,696,113,285,350,325,301,473,214,639,232,447,64,369,598,124,672,567,223,621,154,107,86,86,86,86,86,86,505,86,68,634,86,218,218,218,218,486,218,218,513,188,608,216,86,217,463,668,85,700,360,184,86,86,86,647,402,153,10,346,718,662,260,145,298,117,1,443,342,138,54,563,86,240,572,218,70,387,86,118,460,641,602,86,86,306,218,86,692,86,86,86,86,86,162,707,86,458,26,86,218,638,86,86,86,86,86,65,449,86,86,306,183,86,58,391,667,86,157,131,131,131,131,86,433,131,406,31,218,247,86,86,693,218,581,351,86,438,295,69,462,45,126,173,650,14,295,69,97,168,187,641,78,523,390,69,108,287,664,173,219,83,295,69,108,431,426,173,694,412,115,628,52,257,398,641,118,501,121,69,579,151,423,173,620,464,121,69,382,151,476,173,27,53,121,86,594,578,226,173,86,632,130,86,96,228,268,641,622,563,86,86,21,148,650,131,131,321,43,144,343,381,531,131,131,178,20,86,399,156,375,164,541,30,60,715,198,92,118,131,131,86,86,306,407,86,280,457,196,488,358,131,131,244,86,86,143,86,86,86,86,86,667,563,86,86,86,86,86,86,86,86,86,86,86,86,86,336,363,86,86,336,86,86,380,678,67,86,86,86,678,86,86,86,512,86,307,86,708,86,86,86,86,86,528,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,563,307,86,86,86,86,86,104,450,337,86,720,86,32,450,397,86,86,86,587,218,558,708,708,293,708,86,86,86,86,86,694,205,86,8,86,86,86,86,549,86,667,697,697,679,86,458,460,86,86,650,86,708,543,86,86,86,245,86,86,86,140,218,127,708,708,458,197,131,131,131,131,500,86,86,483,251,86,306,510,515,86,722,86,86,86,65,201,86,86,483,580,470,86,86,86,368,131,131,131,694,114,110,555,86,86,123,721,163,142,713,418,86,317,675,209,218,218,218,371,545,592,629,490,603,199,46,320,525,680,310,279,388,111,42,252,593,607,235,617,410,377,50,548,135,356,17,520,189,116,392,600,349,332,482,699,690,535,119,106,451,71,152,667,131,218,218,265,671,637,492,504,533,683,269,269,658,86,86,86,86,86,86,86,86,86,491,619,86,86,6,86,86,86,86,86,86,86,86,86,86,86,229,86,86,86,86,86,86,86,86,86,86,86,86,667,86,86,171,131,118,131,656,206,234,571,89,334,670,246,311,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,534,86,86,86,86,86,86,82,86,86,86,86,86,430,86,86,86,86,86,86,86,86,86,599,86,324,86,470,69,640,264,131,626,101,174,86,86,667,233,105,73,374,394,221,204,84,28,326,86,86,471,86,86,86,109,573,86,171,200,200,200,200,218,218,86,86,86,86,460,131,131,131,86,506,86,86,86,86,86,220,404,34,614,47,442,305,25,612,338,601,648,7,344,255,131,131,51,86,312,507,563,86,86,86,86,588,86,86,86,86,86,530,511,86,458,3,435,384,556,522,230,527,86,118,86,86,717,86,137,273,79,181,484,23,93,112,655,249,417,703,370,87,98,313,684,585,155,465,596,481,695,18,416,428,61,701,706,282,643,495,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,549,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,549,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,307,86,86,86,171,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,650,131,422,542,420,263,24,172,86,86,86,86,86,566,86,86,132,540,395,353,494,519,19,485,284,472,131,131,131,16,714,86,211,708,86,86,86,694,698,86,86,483,704,708,218,272,86,86,120,86,159,478,86,307,247,86,86,663,597,459,627,667,86,86,277,455,39,302,86,250,86,86,86,271,99,452,306,281,329,400,200,86,86,362,549,352,646,461,323,586,86,86,4,708,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,717,86,518,86,86,650,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,125,554,480,300,613,72,333,288,561,544,604,48,719,91,169,176,590,224,76,191,29,559,560,231,537,166,477,538,256,437,131,131,469,167,40,0,685,266,441,705,239,642,475,568,640,610,299,673,517,318,385,22,202,180,179,359,424,215,90,66,521,653,467,682,453,409,479,88,131,661,35,303,15,262,666,630,712,131,131,618,659,175,218,195,347,193,227,261,150,165,709,546,294,569,710,270,413,376,524,55,242,38,419,529,170,657,3,304,122,379,278,131,651,86,67,576,458,458,131,131,86,86,86,86,86,86,86,118,309,86,86,547,86,86,86,86,667,650,664,131,131,86,86,56,131,131,131,131,131,131,131,131,86,307,86,86,86,664,238,650,86,86,717,86,118,86,86,315,86,59,86,86,574,549,131,131,340,57,436,86,86,86,86,86,86,458,708,499,691,62,86,650,86,86,694,86,86,86,319,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,171,86,549,694,131,131,131,131,131,131,131,131,131,77,86,86,139,86,502,86,86,86,667,595,131,131,131,86,12,86,13,86,609,131,131,131,131,86,86,86,625,86,669,86,86,182,129,86,5,694,104,86,86,86,86,131,131,86,86,386,171,86,86,86,345,86,324,86,589,86,213,36,131,131,131,131,131,86,86,86,86,104,131,131,131,141,290,80,677,86,86,86,267,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,667,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,515,86,86,33,136,669,86,711,515,86,86,550,640,86,104,708,515,86,159,372,717,86,86,444,515,86,86,663,37,86,563,460,86,390,624,702,131,131,131,131,389,59,708,86,86,341,208,708,635,295,69,108,431,508,100,190,131,131,131,131,131,131,131,131,86,86,86,649,516,660,131,131,86,86,86,218,631,708,131,131,131,131,131,131,131,131,131,131,86,86,341,575,238,514,131,131,86,86,86,218,291,708,307,131,86,86,306,367,708,131,131,131,86,378,697,86,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,615,253,86,86,86,292,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,104,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,69,86,341,553,549,86,307,86,86,645,275,455,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,708,131,131,131,131,131,131,86,86,86,86,86,86,667,460,86,86,86,86,86,86,86,86,86,86,86,86,717,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,667,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,171,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,104,86,667,459,131,131,131,131,131,131,86,458,225,86,86,86,516,549,11,390,405,86,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,460,44,218,197,711,515,131,131,131,131,664,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,307,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,308,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,640,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,118,307,104,286,591,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,549,86,86,681,86,86,75,185,314,582,86,358,496,474,86,104,131,86,86,86,86,146,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,171,86,640,131,131,131,131,131,131,131,131,246,503,689,339,674,81,258,415,439,128,562,366,414,246,503,689,583,222,557,316,636,665,186,355,95,670,246,503,689,339,674,557,258,415,439,186,355,95,670,246,503,689,446,644,536,652,331,532,335,440,274,421,297,570,74,425,364,425,606,552,403,509,134,365,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,218,218,218,498,218,218,577,627,551,497,572,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,553,354,236,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,296,455,131,131,456,243,103,86,41,459,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,9,276,158,716,393,564,383,489,401,654,210,654,131,131,131,640,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,650,86,86,86,86,86,86,717,667,563,563,563,86,549,102,686,133,246,605,86,448,86,86,207,307,131,131,131,641,86,177,611,445,373,194,584,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,308,307,171,86,86,86,86,86,86,86,717,86,86,86,86,86,460,131,131,650,86,86,86,694,708,86,86,694,86,458,131,131,131,131,131,131,667,694,289,650,667,131,131,86,640,131,131,664,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,171,131,131,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,460,86,86,86,86,86,86,86,86,86,86,86,86,86,458,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,640,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,466,203,149,429,94,432,160,687,539,63,237,283,192,248,348,259,427,526,396,676,254,468,487,212,327,623,49,633,322,493,434,688,357,361,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131,131]),{mapStr:"صلى الله عليه وسلمجل جلالهキロメートルrad∕s2エスクードキログラムキロワットグラムトンクルゼイロサンチームパーセントピアストルファラッドブッシェルヘクタールマンションミリバールレントゲン′′′′1⁄10viii(10)(11)(12)(13)(14)(15)(16)(17)(18)(19)(20)∫∫∫∫(오전)(오후)アパートアルファアンペアイニングエーカーカラットカロリーキュリーギルダークローネサイクルシリングバーレルフィートポイントマイクロミクロンメガトンリットルルーブル株式会社kcalm∕s2c∕kgاكبرمحمدصلعمرسولریال1⁄41⁄23⁄4 ̈́ྲཱྀླཱྀ ̈͂ ̓̀ ̓́ ̓͂ ̔̀ ̔́ ̔͂ ̈̀‵‵‵a/ca/sc/oc/utelfax1⁄71⁄91⁄32⁄31⁄52⁄53⁄54⁄51⁄65⁄61⁄83⁄85⁄87⁄8xii0⁄3∮∮∮(1)(2)(3)(4)(5)(6)(7)(8)(9)(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)(l)(m)(n)(o)(p)(q)(r)(s)(t)(u)(v)(w)(x)(y)(z)::====(ᄀ)(ᄂ)(ᄃ)(ᄅ)(ᄆ)(ᄇ)(ᄉ)(ᄋ)(ᄌ)(ᄎ)(ᄏ)(ᄐ)(ᄑ)(ᄒ)(가)(나)(다)(라)(마)(바)(사)(아)(자)(차)(카)(타)(파)(하)(주)(一)(二)(三)(四)(五)(六)(七)(八)(九)(十)(月)(火)(水)(木)(金)(土)(日)(株)(有)(社)(名)(特)(財)(祝)(労)(代)(呼)(学)(監)(企)(資)(協)(祭)(休)(自)(至)pte10月11月12月ergltdアールインチウォンオンスオームカイリガロンガンマギニーケースコルナコーポセンチダースノットハイツパーツピクルフランペニヒヘルツペンスページベータボルトポンドホールホーンマイルマッハマルクヤードヤールユアンルピー10点11点12点13点14点15点16点17点18点19点20点21点22点23点24点hpabardm2dm3khzmhzghzthzmm2cm2km2mm3cm3km3kpampagpalogmilmolppmv∕ma∕m10日11日12日13日14日15日16日17日18日19日20日21日22日23日24日25日26日27日28日29日30日31日galffifflשּׁשּׂ ٌّ ٍّ َّ ُّ ِّ ّٰـَّـُّـِّتجمتحجتحمتخمتمجتمحتمخجمححميحمىسحجسجحسجىسمحسمجسممصححصممشحمشجيشمخشممضحىضخمطمحطممطميعجمعممعمىغممغميغمىفخمقمحقمملحملحيلحىلججلخملمحمحجمحيمجحمجممخممجخهمجهممنحمنحىنجمنجىنمينمىيممبخيتجيتجىتخيتخىتميتمىجميجحىجمىسخىصحيشحيضحيلجيلمييحييجييميمميقمينحيعميكمينجحمخيلجمكممجحيحجيمجيفميبحيسخينجيصلےقلے𝅘𝅥𝅮𝅘𝅥𝅯𝅘𝅥𝅰𝅘𝅥𝅱𝅘𝅥𝅲𝆹𝅥𝅮𝆺𝅥𝅮𝆹𝅥𝅯𝆺𝅥𝅯〔s〕ppv〔本〕〔三〕〔二〕〔安〕〔点〕〔打〕〔盗〕〔勝〕〔敗〕 ̄ ́ ̧ssi̇ijl·ʼndžljnjdz ̆ ̇ ̊ ̨ ̃ ̋ ιեւاٴوٴۇٴيٴक़ख़ग़ज़ड़ढ़फ़य़ড়ঢ়য়ਲ਼ਸ਼ਖ਼ਗ਼ਜ਼ਫ਼ଡ଼ଢ଼ําໍາຫນຫມགྷཌྷདྷབྷཛྷཀྵཱཱིུྲྀླྀྒྷྜྷྡྷྦྷྫྷྐྵaʾἀιἁιἂιἃιἄιἅιἆιἇιἠιἡιἢιἣιἤιἥιἦιἧιὠιὡιὢιὣιὤιὥιὦιὧιὰιαιάιᾶι ͂ὴιηιήιῆιὼιωιώιῶι ̳!! ̅???!!?rs°c°fnosmtmivix⫝̸ ゙ ゚よりコト333435참고주의363738394042444546474849503月4月5月6月7月8月9月hgevギガデシドルナノピコビルペソホンリラレムdaauovpciu平成昭和大正明治naμakakbmbgbpfnfμfμgmgμlmldlklfmnmμmpsnsμsmsnvμvkvpwnwμwmwkwkωmωbqcccddbgyhainkkktlnlxphprsrsvwbstմնմեմիվնմխיִײַשׁשׂאַאָאּבּגּדּהּוּזּטּיּךּכּלּמּנּסּףּפּצּקּרּתּוֹבֿכֿפֿאלئائەئوئۇئۆئۈئېئىئجئحئمئيبجبمبىبيتىتيثجثمثىثيخحضجضمطحظمغجفجفحفىفيقحقىقيكاكجكحكخكلكىكينخنىنيهجهىهييىذٰرٰىٰئرئزئنبزبنترتزتنثرثزثنمانرنزننيريزئخئهبهتهصخنههٰثهسهشهطىطيعىعيغىغيسىسيشىشيصىصيضىضيشخشرسرصرضراً ًـًـّ ْـْلآلألإ𝅗𝅥0,1,2,3,4,5,6,7,8,9,wzhvsdwcmcmddjほかココàáâãäåæçèéêëìíîïðñòóôõöøùúûüýþāăąćĉċčďđēĕėęěĝğġģĥħĩīĭįĵķĺļľłńņňŋōŏőœŕŗřśŝşšţťŧũūŭůűųŵŷÿźżɓƃƅɔƈɖɗƌǝəɛƒɠɣɩɨƙɯɲɵơƣƥʀƨʃƭʈưʊʋƴƶʒƹƽǎǐǒǔǖǘǚǜǟǡǣǥǧǩǫǭǯǵƕƿǹǻǽǿȁȃȅȇȉȋȍȏȑȓȕȗșțȝȟƞȣȥȧȩȫȭȯȱȳⱥȼƚⱦɂƀʉʌɇɉɋɍɏɦɹɻʁʕͱͳʹͷ;ϳέίόύβγδεζθκλνξοπρστυφχψϊϋϗϙϛϝϟϡϣϥϧϩϫϭϯϸϻͻͼͽѐёђѓєѕіїјљњћќѝўџабвгдежзийклмнопрстуфхцчшщъыьэюяѡѣѥѧѩѫѭѯѱѳѵѷѹѻѽѿҁҋҍҏґғҕҗҙқҝҟҡңҥҧҩҫҭүұҳҵҷҹһҽҿӂӄӆӈӊӌӎӑӓӕӗәӛӝӟӡӣӥӧөӫӭӯӱӳӵӷӹӻӽӿԁԃԅԇԉԋԍԏԑԓԕԗԙԛԝԟԡԣԥԧԩԫԭԯաբգդզէըթժլծկհձղճյշոչպջռստրցփքօֆ་ⴧⴭნᏰᏱᏲᏳᏴᏵꙋɐɑᴂɜᴖᴗᴝᴥɒɕɟɡɥɪᵻʝɭᶅʟɱɰɳɴɸʂƫᴜʐʑḁḃḅḇḉḋḍḏḑḓḕḗḙḛḝḟḡḣḥḧḩḫḭḯḱḳḵḷḹḻḽḿṁṃṅṇṉṋṍṏṑṓṕṗṙṛṝṟṡṣṥṧṩṫṭṯṱṳṵṷṹṻṽṿẁẃẅẇẉẋẍẏẑẓẕạảấầẩẫậắằẳẵặẹẻẽếềểễệỉịọỏốồổỗộớờởỡợụủứừửữựỳỵỷỹỻỽỿἐἑἒἓἔἕἰἱἲἳἴἵἶἷὀὁὂὃὄὅὑὓὕὗᾰᾱὲΐῐῑὶΰῠῡὺῥ`ὸ‐+−∑〈〉ⰰⰱⰲⰳⰴⰵⰶⰷⰸⰹⰺⰻⰼⰽⰾⰿⱀⱁⱂⱃⱄⱅⱆⱇⱈⱉⱊⱋⱌⱍⱎⱏⱐⱑⱒⱓⱔⱕⱖⱗⱘⱙⱚⱛⱜⱝⱞⱡɫᵽɽⱨⱪⱬⱳⱶȿɀⲁⲃⲅⲇⲉⲋⲍⲏⲑⲓⲕⲗⲙⲛⲝⲟⲡⲣⲥⲧⲩⲫⲭⲯⲱⲳⲵⲷⲹⲻⲽⲿⳁⳃⳅⳇⳉⳋⳍⳏⳑⳓⳕⳗⳙⳛⳝⳟⳡⳣⳬⳮⳳⵡ母龟丨丶丿乙亅亠人儿入冂冖冫几凵刀力勹匕匚匸卜卩厂厶又口囗士夂夊夕女子宀寸小尢尸屮山巛工己巾干幺广廴廾弋弓彐彡彳心戈戶手支攴文斗斤方无曰欠止歹殳毋比毛氏气爪父爻爿片牙牛犬玄玉瓜瓦甘生用田疋疒癶白皮皿目矛矢石示禸禾穴立竹米糸缶网羊羽老而耒耳聿肉臣臼舌舛舟艮色艸虍虫血行衣襾見角言谷豆豕豸貝赤走足身車辛辰辵邑酉釆里長門阜隶隹雨靑非面革韋韭音頁風飛食首香馬骨高髟鬥鬯鬲鬼魚鳥鹵鹿麥麻黃黍黑黹黽鼎鼓鼠鼻齊齒龍龜龠.〒卄卅ᄁᆪᆬᆭᄄᆰᆱᆲᆳᆴᆵᄚᄈᄡᄊ짜ᅢᅣᅤᅥᅦᅧᅨᅩᅪᅫᅬᅭᅮᅯᅰᅱᅲᅳᅴᅵᄔᄕᇇᇈᇌᇎᇓᇗᇙᄜᇝᇟᄝᄞᄠᄢᄣᄧᄩᄫᄬᄭᄮᄯᄲᄶᅀᅇᅌᇱᇲᅗᅘᅙᆄᆅᆈᆑᆒᆔᆞᆡ上中下甲丙丁天地問幼箏우秘男適優印注項写左右医宗夜テヌモヨヰヱヲꙁꙃꙅꙇꙉꙍꙏꙑꙓꙕꙗꙙꙛꙝꙟꙡꙣꙥꙧꙩꙫꙭꚁꚃꚅꚇꚉꚋꚍꚏꚑꚓꚕꚗꚙꚛꜣꜥꜧꜩꜫꜭꜯꜳꜵꜷꜹꜻꜽꜿꝁꝃꝅꝇꝉꝋꝍꝏꝑꝓꝕꝗꝙꝛꝝꝟꝡꝣꝥꝧꝩꝫꝭꝯꝺꝼᵹꝿꞁꞃꞅꞇꞌꞑꞓꞗꞙꞛꞝꞟꞡꞣꞥꞧꞩɬʞʇꭓꞵꞷꬷꭒᎠᎡᎢᎣᎤᎥᎦᎧᎨᎩᎪᎫᎬᎭᎮᎯᎰᎱᎲᎳᎴᎵᎶᎷᎸᎹᎺᎻᎼᎽᎾᎿᏀᏁᏂᏃᏄᏅᏆᏇᏈᏉᏊᏋᏌᏍᏎᏏᏐᏑᏒᏓᏔᏕᏖᏗᏘᏙᏚᏛᏜᏝᏞᏟᏠᏡᏢᏣᏤᏥᏦᏧᏨᏩᏪᏫᏬᏭᏮᏯ豈更賈滑串句契喇奈懶癩羅蘿螺裸邏樂洛烙珞落酪駱亂卵欄爛蘭鸞嵐濫藍襤拉臘蠟廊朗浪狼郎來冷勞擄櫓爐盧蘆虜路露魯鷺碌祿綠菉錄論壟弄籠聾牢磊賂雷壘屢樓淚漏累縷陋勒肋凜凌稜綾菱陵讀拏諾丹寧怒率異北磻便復不泌數索參塞省葉說殺沈拾若掠略亮兩凉梁糧良諒量勵呂廬旅濾礪閭驪麗黎曆歷轢年憐戀撚漣煉璉秊練聯輦蓮連鍊列劣咽烈裂廉念捻殮簾獵令囹嶺怜玲瑩羚聆鈴零靈領例禮醴隸惡了僚寮尿料燎療蓼遼暈阮劉杻柳流溜琉留硫紐類戮陸倫崙淪輪律慄栗隆利吏履易李梨泥理痢罹裏裡離匿溺吝燐璘藺隣鱗麟林淋臨笠粒狀炙識什茶刺切度拓糖宅洞暴輻降廓兀嗀塚晴凞猪益礼神祥福靖精蘒諸逸都飯飼館鶴郞隷侮僧免勉勤卑喝嘆器塀墨層悔慨憎懲敏既暑梅海渚漢煮爫琢碑祉祈祐祖禍禎穀突節縉繁署者臭艹著褐視謁謹賓贈辶難響頻恵𤋮舘並况全侀充冀勇勺啕喙嗢墳奄奔婢嬨廒廙彩徭惘慎愈慠戴揄搜摒敖望杖滛滋瀞瞧爵犯瑱甆画瘝瘟盛直睊着磌窱类絛缾荒華蝹襁覆調請諭變輸遲醙鉶陼韛頋鬒𢡊𢡄𣏕㮝䀘䀹𥉉𥳐𧻓齃龎עםٱٻپڀٺٿٹڤڦڄڃچڇڍڌڎڈژڑکگڳڱںڻۀہھۓڭۋۅۉ、〖〗—–_{}【】《》「」『』[]#&*-<>\\$%@ءؤة\"'^|~⦅⦆・ゥャ¢£¬¦¥₩│←↑→↓■○𐐨𐐩𐐪𐐫𐐬𐐭𐐮𐐯𐐰𐐱𐐲𐐳𐐴𐐵𐐶𐐷𐐸𐐹𐐺𐐻𐐼𐐽𐐾𐐿𐑀𐑁𐑂𐑃𐑄𐑅𐑆𐑇𐑈𐑉𐑊𐑋𐑌𐑍𐑎𐑏𐓘𐓙𐓚𐓛𐓜𐓝𐓞𐓟𐓠𐓡𐓢𐓣𐓤𐓥𐓦𐓧𐓨𐓩𐓪𐓫𐓬𐓭𐓮𐓯𐓰𐓱𐓲𐓳𐓴𐓵𐓶𐓷𐓸𐓹𐓺𐓻𐳀𐳁𐳂𐳃𐳄𐳅𐳆𐳇𐳈𐳉𐳊𐳋𐳌𐳍𐳎𐳏𐳐𐳑𐳒𐳓𐳔𐳕𐳖𐳗𐳘𐳙𐳚𐳛𐳜𐳝𐳞𐳟𐳠𐳡𐳢𐳣𐳤𐳥𐳦𐳧𐳨𐳩𐳪𐳫𐳬𐳭𐳮𐳯𐳰𐳱𐳲𑣀𑣁𑣂𑣃𑣄𑣅𑣆𑣇𑣈𑣉𑣊𑣋𑣌𑣍𑣎𑣏𑣐𑣑𑣒𑣓𑣔𑣕𑣖𑣗𑣘𑣙𑣚𑣛𑣜𑣝𑣞𑣟ıȷ∇∂𞤢𞤣𞤤𞤥𞤦𞤧𞤨𞤩𞤪𞤫𞤬𞤭𞤮𞤯𞤰𞤱𞤲𞤳𞤴𞤵𞤶𞤷𞤸𞤹𞤺𞤻𞤼𞤽𞤾𞤿𞥀𞥁𞥂𞥃ٮڡٯ字双多解交映無前後再新初終販声吹演投捕遊指禁空合満申割営配得可丽丸乁𠄢你侻倂偺備像㒞𠘺兔兤具𠔜㒹內𠕋冗冤仌冬𩇟刃㓟刻剆剷㔕包匆卉博即卽卿𠨬灰及叟𠭣叫叱吆咞吸呈周咢哶唐啓啣善喫喳嗂圖圗噑噴壮城埴堍型堲報墬𡓤売壷夆夢奢𡚨𡛪姬娛娧姘婦㛮嬈嬾𡧈寃寘寳𡬘寿将㞁屠峀岍𡷤嵃𡷦嵮嵫嵼巡巢㠯巽帨帽幩㡢𢆃㡼庰庳庶𪎒𢌱舁弢㣇𣊸𦇚形彫㣣徚忍志忹悁㤺㤜𢛔惇慈慌慺憲憤憯懞戛扝抱拔捐𢬌挽拼捨掃揤𢯱搢揅掩㨮摩摾撝摷㩬敬𣀊旣書晉㬙㬈㫤冒冕最暜肭䏙朡杞杓𣏃㭉柺枅桒𣑭梎栟椔楂榣槪檨𣚣櫛㰘次𣢧歔㱎歲殟殻𣪍𡴋𣫺汎𣲼沿泍汧洖派浩浸涅𣴞洴港湮㴳滇𣻑淹潮𣽞𣾎濆瀹瀛㶖灊災灷炭𠔥煅𤉣熜爨牐𤘈犀犕𤜵𤠔獺王㺬玥㺸瑇瑜璅瓊㼛甤𤰶甾𤲒𢆟瘐𤾡𤾸𥁄㿼䀈𥃳𥃲𥄙𥄳眞真瞋䁆䂖𥐝硎䃣𥘦𥚚𥛅秫䄯穊穏𥥼𥪧䈂𥮫篆築䈧𥲀糒䊠糨糣紀𥾆絣䌁緇縂繅䌴𦈨𦉇䍙𦋙罺𦌾羕翺𦓚𦔣聠𦖨聰𣍟䏕育脃䐋脾媵𦞧𦞵𣎓𣎜舄辞䑫芑芋芝劳花芳芽苦𦬼茝荣莭茣莽菧荓菊菌菜𦰶𦵫𦳕䔫蓱蓳蔖𧏊蕤𦼬䕝䕡𦾱𧃒䕫虐虧虩蚩蚈蜎蛢蜨蝫螆蟡蠁䗹衠𧙧裗裞䘵裺㒻𧢮𧥦䚾䛇誠𧲨貫賁贛起𧼯𠠄跋趼跰𠣞軔𨗒𨗭邔郱鄑𨜮鄛鈸鋗鋘鉼鏹鐕𨯺開䦕閷𨵷䧦雃嶲霣𩅅𩈚䩮䩶韠𩐊䪲𩒖頩𩖶飢䬳餩馧駂駾䯎𩬰鱀鳽䳎䳭鵧𪃎䳸𪄅𪈎𪊑䵖黾鼅鼏鼖𪘀",mapChar:function(r){return r>=196608?r>=917760&&r<=917999?18874368:0:e[t[r>>4]][15&r]}};var e,t}.apply(t,[]))||(e.exports=n)},4489:(e,t,r)=>{"use strict";var n=r(8847)(r(3106));function i(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return o(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r= 0x80 (not a basic code point)","invalid-input":"Invalid input"},h=Math.floor,d=String.fromCharCode;function p(e){throw new RangeError(f[e])}function m(e,t){var r=e.split("@"),n="";r.length>1&&(n=r[0]+"@",e=r[1]);var i=function(e,t){for(var r=[],n=e.length;n--;)r[n]=t(e[n]);return r}((e=e.replace(l,".")).split("."),t).join(".");return n+i}function y(e){for(var t=[],r=0,n=e.length;r=55296&&i<=56319&&r>1,e+=h(e/t);e>455;n+=s)e=h(e/35);return h(n+36*e/(e+38))},v=function(e){var t,r=[],n=e.length,i=0,o=128,u=72,c=e.lastIndexOf("-");c<0&&(c=0);for(var l=0;l=128&&p("not-basic"),r.push(e.charCodeAt(l));for(var f=c>0?c+1:0;f=n&&p("invalid-input");var g=(t=e.charCodeAt(f++))-48<10?t-22:t-65<26?t-65:t-97<26?t-97:s;(g>=s||g>h((a-i)/m))&&p("overflow"),i+=g*m;var v=y<=u?1:y>=u+26?26:y-u;if(gh(a/w)&&p("overflow"),m*=w}var A=r.length+1;u=b(i-d,A,0==d),h(i/A)>a-o&&p("overflow"),o+=h(i/A),i%=A,r.splice(i++,0,o)}return String.fromCodePoint.apply(String,r)},w=function(e){var t,r=[],n=(e=y(e)).length,o=128,u=0,c=72,l=i(e);try{for(l.s();!(t=l.n()).done;){var f=t.value;f<128&&r.push(d(f))}}catch(e){l.e(e)}finally{l.f()}var m=r.length,v=m;for(m&&r.push("-");v=o&&kh((a-u)/E)&&p("overflow"),u+=(A-o)*E,o=A;var _,M=i(e);try{for(M.s();!(_=M.n()).done;){var T=_.value;if(Ta&&p("overflow"),T==o){for(var x=u,P=s;;P+=s){var I=P<=c?1:P>=c+26?26:P-c;if(x{"use strict";var n,i;r(8847)(r(3355)),n=[r(4489),r(2996)],void 0===(i=function(e,t){return function(e,t){function r(r,n,i){for(var o=[],a=e.ucs2.decode(r),s=0;s>23,h=l>>21&3,d=l>>5&65535,p=31&l,m=t.mapStr.substr(d,p);if(0===h||n&&1&f)throw new Error("Illegal char "+c);1===h?o.push(m):2===h?o.push(i?m:c):3===h&&o.push(c)}return o.join("").normalize("NFC")}function n(t,n,o){void 0===o&&(o=!1);var a=r(t,o,n).split(".");return(a=a.map((function(t){return t.startsWith("xn--")?i(t=e.decode(t.substring(4)),o,!1):i(t,o,n),t}))).join(".")}function i(e,n,i){if("-"===e[2]&&"-"===e[3])throw new Error("Failed to validate "+e);if(e.startsWith("-")||e.endsWith("-"))throw new Error("Failed to validate "+e);if(e.includes("."))throw new Error("Failed to validate "+e);if(r(e,n,i)!==e)throw new Error("Failed to validate "+e);var o=e.codePointAt(0);if(t.mapChar(o)&2<<23)throw new Error("Label contains illegal character: "+o)}return{toUnicode:function(e,t){return void 0===t&&(t={}),n(e,!1,"useStd3ASCII"in t&&t.useStd3ASCII)},toAscii:function(t,r){void 0===r&&(r={});var i,o=!("transitional"in r)||r.transitional,a="useStd3ASCII"in r&&r.useStd3ASCII,s="verifyDnsLength"in r&&r.verifyDnsLength,u=n(t,o,a).split(".").map(e.toASCII),c=u.join(".");if(s){if(c.length<1||c.length>253)throw new Error("DNS name has wrong length: "+c);for(i=0;i63)throw new Error("DNS label has wrong length: "+l)}}return c}}}(e,t)}.apply(t,n))||(e.exports=i)},3226:(e,t)=>{"use strict";t.read=function(e,t,r,n,i){var o,a,s=8*i-n-1,u=(1<>1,l=-7,f=r?i-1:0,h=r?-1:1,d=e[t+f];for(f+=h,o=d&(1<<-l)-1,d>>=-l,l+=s;l>0;o=256*o+e[t+f],f+=h,l-=8);for(a=o&(1<<-l)-1,o>>=-l,l+=n;l>0;a=256*a+e[t+f],f+=h,l-=8);if(0===o)o=1-c;else{if(o===u)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),o-=c}return(d?-1:1)*a*Math.pow(2,o-n)},t.write=function(e,t,r,n,i,o){var a,s,u,c=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:o-1,p=n?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=l):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),(t+=a+f>=1?h/u:h*Math.pow(2,1-f))*u>=2&&(a++,u/=2),a+f>=l?(s=0,a=l):a+f>=1?(s=(t*u-1)*Math.pow(2,i),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),a=0));i>=8;e[r+d]=255&s,d+=p,s/=256,i-=8);for(a=a<0;e[r+d]=255&a,d+=p,a/=256,c-=8);e[r+d-p]|=128*m}},1736:e=>{"use strict";"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},9446:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1191)(),o=r(593)("Object.prototype.toString"),a=function(e){return!(i&&e&&"object"===(0,n.default)(e)&&Symbol.toStringTag in e)&&"[object Arguments]"===o(e)},s=function(e){return!!a(e)||null!==e&&"object"===(0,n.default)(e)&&"number"==typeof e.length&&e.length>=0&&"[object Array]"!==o(e)&&"[object Function]"===o(e.callee)},u=function(){return a(arguments)}();a.isLegacyArguments=s,e.exports=u?a:s},1493:(e,t,r)=>{"use strict";var n,i,o=r(8847)(r(3355)),a=Function.prototype.toString,s="object"===("undefined"==typeof Reflect?"undefined":(0,o.default)(Reflect))&&null!==Reflect&&Reflect.apply;if("function"==typeof s&&"function"==typeof Object.defineProperty)try{n=Object.defineProperty({},"length",{get:function(){throw i}}),i={},s((function(){throw 42}),null,n)}catch(e){e!==i&&(s=null)}else s=null;var u=/^\s*class\b/,c=function(e){try{var t=a.call(e);return u.test(t)}catch(e){return!1}},l=function(e){try{return!c(e)&&(a.call(e),!0)}catch(e){return!1}},f=Object.prototype.toString,h="function"==typeof Symbol&&!!Symbol.toStringTag,d=!(0 in[,]),p=function(){return!1};if("object"===("undefined"==typeof document?"undefined":(0,o.default)(document))){var m=document.all;f.call(m)===f.call(document.all)&&(p=function(e){if((d||!e)&&(void 0===e||"object"===(0,o.default)(e)))try{var t=f.call(e);return("[object HTMLAllCollection]"===t||"[object HTML document.all class]"===t||"[object HTMLCollection]"===t||"[object Object]"===t)&&null==e("")}catch(e){}return!1})}e.exports=s?function(e){if(p(e))return!0;if(!e)return!1;if("function"!=typeof e&&"object"!==(0,o.default)(e))return!1;try{s(e,null,n)}catch(e){if(e!==i)return!1}return!c(e)&&l(e)}:function(e){if(p(e))return!0;if(!e)return!1;if("function"!=typeof e&&"object"!==(0,o.default)(e))return!1;if(h)return l(e);if(c(e))return!1;var t=f.call(e);return!("[object Function]"!==t&&"[object GeneratorFunction]"!==t&&!/^\[object HTML/.test(t))&&l(e)}},4339:e=>{"use strict";e.exports=function(e){if(!e)return!1;var r=t.call(e);return"[object Function]"===r||"function"==typeof e&&"[object RegExp]"!==r||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)};var t=Object.prototype.toString},4477:(e,t,r)=>{"use strict";var n,i=Object.prototype.toString,o=Function.prototype.toString,a=/^\s*(?:function)?\*/,s=r(1191)(),u=Object.getPrototypeOf;e.exports=function(e){if("function"!=typeof e)return!1;if(a.test(o.call(e)))return!0;if(!s)return"[object GeneratorFunction]"===i.call(e);if(!u)return!1;if(void 0===n){var t=function(){if(!s)return!1;try{return Function("return function*() {}")()}catch(e){}}();n=!!t&&u(t)}return u(e)===n}},8619:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(e){if("string"!=typeof e)throw new Error("[is-hex-prefixed] value must be type 'string', is currently type "+(0,n.default)(e)+", while checking isHexPrefixed.");return"0x"===e.slice(0,2)}},8915:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(8184),o=r(3604),a=r(593),s=a("Object.prototype.toString"),u=r(1191)(),c=r(3820),l="undefined"==typeof globalThis?r.g:globalThis,f=o(),h=a("Array.prototype.indexOf",!0)||function(e,t){for(var r=0;r-1}return!!c&&function(e){var t=!1;return i(p,(function(r,n){if(!t)try{t=r.call(e)===n}catch(e){}})),t}(e)}},9484:e=>{"use strict";var t={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==t.call(e)}},4858:(e,t,r)=>{"use strict";e=r.nmd(e);var n=r(9142),i=r(8847)(r(3355));!function(){var t="object"===("undefined"==typeof window?"undefined":(0,i.default)(window))?window:{};!t.JS_SHA3_NO_NODE_JS&&"object"===(void 0===n?"undefined":(0,i.default)(n))&&n.versions&&n.versions.node&&(t=r.g);for(var o=!t.JS_SHA3_NO_COMMON_JS&&"object"===(0,i.default)(e)&&e.exports,a="0123456789abcdef".split(""),s=[0,8,16,24],u=[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],c=[224,256,384,512],l=["hex","buffer","arrayBuffer","array"],f=function(e,t,r){return function(n){return new S(e,t,e).update(n)[r]()}},h=function(e,t,r){return function(n,i){return new S(e,t,i).update(n)[r]()}},d=function(e,t){var r=f(e,t,"hex");r.create=function(){return new S(e,t,e)},r.update=function(e){return r.create().update(e)};for(var n=0;n>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}S.prototype.update=function(e){var t="string"!=typeof e;t&&e.constructor===ArrayBuffer&&(e=new Uint8Array(e));for(var r,n,i=e.length,o=this.blocks,a=this.byteCount,u=this.blockCount,c=0,l=this.s;c>2]|=e[c]<>2]|=n<>2]|=(192|n>>6)<>2]|=(128|63&n)<=57344?(o[r>>2]|=(224|n>>12)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<>2]|=(240|n>>18)<>2]|=(128|n>>12&63)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<=a){for(this.start=r-a,this.block=o[u],r=0;r>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+a[15&e]+a[e>>12&15]+a[e>>8&15]+a[e>>20&15]+a[e>>16&15]+a[e>>28&15]+a[e>>24&15];s%t==0&&(k(r),o=0)}return i&&(e=r[o],i>0&&(u+=a[e>>4&15]+a[15&e]),i>1&&(u+=a[e>>12&15]+a[e>>8&15]),i>2&&(u+=a[e>>20&15]+a[e>>16&15])),u},S.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,s=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var u=new Uint32Array(e);a>8&255,u[e+2]=t>>16&255,u[e+3]=t>>24&255;s%r==0&&k(n)}return o&&(e=s<<2,t=n[a],o>0&&(u[e]=255&t),o>1&&(u[e+1]=t>>8&255),o>2&&(u[e+2]=t>>16&255)),u};var k=function(e){var t,r,n,i,o,a,s,c,l,f,h,d,p,m,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],c=e[4]^e[14]^e[24]^e[34]^e[44],l=e[5]^e[15]^e[25]^e[35]^e[45],f=e[6]^e[16]^e[26]^e[36]^e[46],h=e[7]^e[17]^e[27]^e[37]^e[47],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|s>>>31),r=(p=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(c<<1|l>>>31),r=o^(l<<1|c>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(f<<1|h>>>31),r=s^(h<<1|f>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=c^(d<<1|p>>>31),r=l^(p<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=f^(i<<1|o>>>31),r=h^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=m^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&m,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~m&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=u[n],e[1]^=u[n+1]};if(o)e.exports=m;else for(g=0;g{"use strict";e.exports=r(2109)(r(801))},2109:(e,t,r)=>{"use strict";var n=r(6543),i=r(274);e.exports=function(e){var t=n(e),r=i(e);return function(e,n){switch("string"==typeof e?e.toLowerCase():e){case"keccak224":return new t(1152,448,null,224,n);case"keccak256":return new t(1088,512,null,256,n);case"keccak384":return new t(832,768,null,384,n);case"keccak512":return new t(576,1024,null,512,n);case"sha3-224":return new t(1152,448,6,224,n);case"sha3-256":return new t(1088,512,6,256,n);case"sha3-384":return new t(832,768,6,384,n);case"sha3-512":return new t(576,1024,6,512,n);case"shake128":return new r(1344,256,31,n);case"shake256":return new r(1088,512,31,n);default:throw new Error("Invald algorithm: "+e)}}}},6543:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(9721)),a=i(r(8985)),s=i(r(5163)),u=i(r(4650)),c=i(r(1949)),l=r(6505).Transform;e.exports=function(e){return function(t){(0,s.default)(f,t);var r,i,l=(r=f,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=(0,c.default)(r);if(i){var n=(0,c.default)(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return(0,u.default)(this,e)});function f(t,r,n,i,a){var s;return(0,o.default)(this,f),(s=l.call(this,a))._rate=t,s._capacity=r,s._delimitedSuffix=n,s._hashBitLength=i,s._options=a,s._state=new e,s._state.initialize(t,r),s._finalized=!1,s}return(0,a.default)(f,[{key:"_transform",value:function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)}},{key:"_flush",value:function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)}},{key:"update",value:function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Digest already called");return n.isBuffer(e)||(e=n.from(e,t)),this._state.absorb(e),this}},{key:"digest",value:function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0,this._delimitedSuffix&&this._state.absorbLastFewBits(this._delimitedSuffix);var t=this._state.squeeze(this._hashBitLength/8);return void 0!==e&&(t=t.toString(e)),this._resetState(),t}},{key:"_resetState",value:function(){return this._state.initialize(this._rate,this._capacity),this}},{key:"_clone",value:function(){var e=new f(this._rate,this._capacity,this._delimitedSuffix,this._hashBitLength,this._options);return this._state.copy(e._state),e._finalized=this._finalized,e}}]),f}(l)}},274:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(9721)),a=i(r(8985)),s=i(r(5163)),u=i(r(4650)),c=i(r(1949)),l=r(6505).Transform;e.exports=function(e){return function(t){(0,s.default)(f,t);var r,i,l=(r=f,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=(0,c.default)(r);if(i){var n=(0,c.default)(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return(0,u.default)(this,e)});function f(t,r,n,i){var a;return(0,o.default)(this,f),(a=l.call(this,i))._rate=t,a._capacity=r,a._delimitedSuffix=n,a._options=i,a._state=new e,a._state.initialize(t,r),a._finalized=!1,a}return(0,a.default)(f,[{key:"_transform",value:function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)}},{key:"_flush",value:function(){}},{key:"_read",value:function(e){this.push(this.squeeze(e))}},{key:"update",value:function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Squeeze already called");return n.isBuffer(e)||(e=n.from(e,t)),this._state.absorb(e),this}},{key:"squeeze",value:function(e,t){this._finalized||(this._finalized=!0,this._state.absorbLastFewBits(this._delimitedSuffix));var r=this._state.squeeze(e);return void 0!==t&&(r=r.toString(t)),r}},{key:"_resetState",value:function(){return this._state.initialize(this._rate,this._capacity),this}},{key:"_clone",value:function(){var e=new f(this._rate,this._capacity,this._delimitedSuffix,this._options);return this._state.copy(e._state),e._finalized=this._finalized,e}}]),f}(l)}},5612:(e,t)=>{"use strict";var r=[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];t.p1600=function(e){for(var t=0;t<24;++t){var n=e[0]^e[10]^e[20]^e[30]^e[40],i=e[1]^e[11]^e[21]^e[31]^e[41],o=e[2]^e[12]^e[22]^e[32]^e[42],a=e[3]^e[13]^e[23]^e[33]^e[43],s=e[4]^e[14]^e[24]^e[34]^e[44],u=e[5]^e[15]^e[25]^e[35]^e[45],c=e[6]^e[16]^e[26]^e[36]^e[46],l=e[7]^e[17]^e[27]^e[37]^e[47],f=e[8]^e[18]^e[28]^e[38]^e[48],h=e[9]^e[19]^e[29]^e[39]^e[49],d=f^(o<<1|a>>>31),p=h^(a<<1|o>>>31),m=e[0]^d,y=e[1]^p,g=e[10]^d,b=e[11]^p,v=e[20]^d,w=e[21]^p,A=e[30]^d,S=e[31]^p,k=e[40]^d,E=e[41]^p;d=n^(s<<1|u>>>31),p=i^(u<<1|s>>>31);var _=e[2]^d,M=e[3]^p,T=e[12]^d,x=e[13]^p,P=e[22]^d,I=e[23]^p,O=e[32]^d,R=e[33]^p,C=e[42]^d,B=e[43]^p;d=o^(c<<1|l>>>31),p=a^(l<<1|c>>>31);var N=e[4]^d,L=e[5]^p,U=e[14]^d,F=e[15]^p,D=e[24]^d,j=e[25]^p,H=e[34]^d,J=e[35]^p,z=e[44]^d,G=e[45]^p;d=s^(f<<1|h>>>31),p=u^(h<<1|f>>>31);var q=e[6]^d,K=e[7]^p,V=e[16]^d,X=e[17]^p,Q=e[26]^d,W=e[27]^p,Z=e[36]^d,Y=e[37]^p,$=e[46]^d,ee=e[47]^p;d=c^(n<<1|i>>>31),p=l^(i<<1|n>>>31);var te=e[8]^d,re=e[9]^p,ne=e[18]^d,ie=e[19]^p,oe=e[28]^d,ae=e[29]^p,se=e[38]^d,ue=e[39]^p,ce=e[48]^d,le=e[49]^p,fe=m,he=y,de=b<<4|g>>>28,pe=g<<4|b>>>28,me=v<<3|w>>>29,ye=w<<3|v>>>29,ge=S<<9|A>>>23,be=A<<9|S>>>23,ve=k<<18|E>>>14,we=E<<18|k>>>14,Ae=_<<1|M>>>31,Se=M<<1|_>>>31,ke=x<<12|T>>>20,Ee=T<<12|x>>>20,_e=P<<10|I>>>22,Me=I<<10|P>>>22,Te=R<<13|O>>>19,xe=O<<13|R>>>19,Pe=C<<2|B>>>30,Ie=B<<2|C>>>30,Oe=L<<30|N>>>2,Re=N<<30|L>>>2,Ce=U<<6|F>>>26,Be=F<<6|U>>>26,Ne=j<<11|D>>>21,Le=D<<11|j>>>21,Ue=H<<15|J>>>17,Fe=J<<15|H>>>17,De=G<<29|z>>>3,je=z<<29|G>>>3,He=q<<28|K>>>4,Je=K<<28|q>>>4,ze=X<<23|V>>>9,Ge=V<<23|X>>>9,qe=Q<<25|W>>>7,Ke=W<<25|Q>>>7,Ve=Z<<21|Y>>>11,Xe=Y<<21|Z>>>11,Qe=ee<<24|$>>>8,We=$<<24|ee>>>8,Ze=te<<27|re>>>5,Ye=re<<27|te>>>5,$e=ne<<20|ie>>>12,et=ie<<20|ne>>>12,tt=ae<<7|oe>>>25,rt=oe<<7|ae>>>25,nt=se<<8|ue>>>24,it=ue<<8|se>>>24,ot=ce<<14|le>>>18,at=le<<14|ce>>>18;e[0]=fe^~ke&Ne,e[1]=he^~Ee&Le,e[10]=He^~$e&me,e[11]=Je^~et&ye,e[20]=Ae^~Ce&qe,e[21]=Se^~Be&Ke,e[30]=Ze^~de&_e,e[31]=Ye^~pe&Me,e[40]=Oe^~ze&tt,e[41]=Re^~Ge&rt,e[2]=ke^~Ne&Ve,e[3]=Ee^~Le&Xe,e[12]=$e^~me&Te,e[13]=et^~ye&xe,e[22]=Ce^~qe&nt,e[23]=Be^~Ke&it,e[32]=de^~_e&Ue,e[33]=pe^~Me&Fe,e[42]=ze^~tt&ge,e[43]=Ge^~rt&be,e[4]=Ne^~Ve&ot,e[5]=Le^~Xe&at,e[14]=me^~Te&De,e[15]=ye^~xe&je,e[24]=qe^~nt&ve,e[25]=Ke^~it&we,e[34]=_e^~Ue&Qe,e[35]=Me^~Fe&We,e[44]=tt^~ge&Pe,e[45]=rt^~be&Ie,e[6]=Ve^~ot&fe,e[7]=Xe^~at&he,e[16]=Te^~De&He,e[17]=xe^~je&Je,e[26]=nt^~ve&Ae,e[27]=it^~we&Se,e[36]=Ue^~Qe&Ze,e[37]=Fe^~We&Ye,e[46]=ge^~Pe&Oe,e[47]=be^~Ie&Re,e[8]=ot^~fe&ke,e[9]=at^~he&Ee,e[18]=De^~He&$e,e[19]=je^~Je&et,e[28]=ve^~Ae&Ce,e[29]=we^~Se&Be,e[38]=Qe^~Ze&de,e[39]=We^~Ye&pe,e[48]=Pe^~Oe&ze,e[49]=Ie^~Re&Ge,e[0]^=r[2*t],e[1]^=r[2*t+1]}}},801:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(5612);function o(){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}o.prototype.initialize=function(e,t){for(var r=0;r<50;++r)this.state[r]=0;this.blockSize=e/8,this.count=0,this.squeezing=!1},o.prototype.absorb=function(e){for(var t=0;t>>this.count%4*8&255,this.count+=1,this.count===this.blockSize&&(i.p1600(this.state),this.count=0);return t},o.prototype.copy=function(e){for(var t=0;t<50;++t)e.state[t]=this.state[t];e.blockSize=this.blockSize,e.count=this.count,e.squeezing=this.squeezing},e.exports=o},807:(e,t,r)=>{"use strict";var n=r(1736),i=r(2353),o=r(8850).Buffer,a=new Array(16);function s(){i.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function u(e,t){return e<>>32-t}function c(e,t,r,n,i,o,a){return u(e+(t&r|~t&n)+i+o|0,a)+t|0}function l(e,t,r,n,i,o,a){return u(e+(t&n|r&~n)+i+o|0,a)+t|0}function f(e,t,r,n,i,o,a){return u(e+(t^r^n)+i+o|0,a)+t|0}function h(e,t,r,n,i,o,a){return u(e+(r^(t|~n))+i+o|0,a)+t|0}n(s,i),s.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,o=this._d;r=c(r,n,i,o,e[0],3614090360,7),o=c(o,r,n,i,e[1],3905402710,12),i=c(i,o,r,n,e[2],606105819,17),n=c(n,i,o,r,e[3],3250441966,22),r=c(r,n,i,o,e[4],4118548399,7),o=c(o,r,n,i,e[5],1200080426,12),i=c(i,o,r,n,e[6],2821735955,17),n=c(n,i,o,r,e[7],4249261313,22),r=c(r,n,i,o,e[8],1770035416,7),o=c(o,r,n,i,e[9],2336552879,12),i=c(i,o,r,n,e[10],4294925233,17),n=c(n,i,o,r,e[11],2304563134,22),r=c(r,n,i,o,e[12],1804603682,7),o=c(o,r,n,i,e[13],4254626195,12),i=c(i,o,r,n,e[14],2792965006,17),r=l(r,n=c(n,i,o,r,e[15],1236535329,22),i,o,e[1],4129170786,5),o=l(o,r,n,i,e[6],3225465664,9),i=l(i,o,r,n,e[11],643717713,14),n=l(n,i,o,r,e[0],3921069994,20),r=l(r,n,i,o,e[5],3593408605,5),o=l(o,r,n,i,e[10],38016083,9),i=l(i,o,r,n,e[15],3634488961,14),n=l(n,i,o,r,e[4],3889429448,20),r=l(r,n,i,o,e[9],568446438,5),o=l(o,r,n,i,e[14],3275163606,9),i=l(i,o,r,n,e[3],4107603335,14),n=l(n,i,o,r,e[8],1163531501,20),r=l(r,n,i,o,e[13],2850285829,5),o=l(o,r,n,i,e[2],4243563512,9),i=l(i,o,r,n,e[7],1735328473,14),r=f(r,n=l(n,i,o,r,e[12],2368359562,20),i,o,e[5],4294588738,4),o=f(o,r,n,i,e[8],2272392833,11),i=f(i,o,r,n,e[11],1839030562,16),n=f(n,i,o,r,e[14],4259657740,23),r=f(r,n,i,o,e[1],2763975236,4),o=f(o,r,n,i,e[4],1272893353,11),i=f(i,o,r,n,e[7],4139469664,16),n=f(n,i,o,r,e[10],3200236656,23),r=f(r,n,i,o,e[13],681279174,4),o=f(o,r,n,i,e[0],3936430074,11),i=f(i,o,r,n,e[3],3572445317,16),n=f(n,i,o,r,e[6],76029189,23),r=f(r,n,i,o,e[9],3654602809,4),o=f(o,r,n,i,e[12],3873151461,11),i=f(i,o,r,n,e[15],530742520,16),r=h(r,n=f(n,i,o,r,e[2],3299628645,23),i,o,e[0],4096336452,6),o=h(o,r,n,i,e[7],1126891415,10),i=h(i,o,r,n,e[14],2878612391,15),n=h(n,i,o,r,e[5],4237533241,21),r=h(r,n,i,o,e[12],1700485571,6),o=h(o,r,n,i,e[3],2399980690,10),i=h(i,o,r,n,e[10],4293915773,15),n=h(n,i,o,r,e[1],2240044497,21),r=h(r,n,i,o,e[8],1873313359,6),o=h(o,r,n,i,e[15],4264355552,10),i=h(i,o,r,n,e[6],2734768916,15),n=h(n,i,o,r,e[13],1309151649,21),r=h(r,n,i,o,e[4],4149444226,6),o=h(o,r,n,i,e[11],3174756917,10),i=h(i,o,r,n,e[2],718787259,15),n=h(n,i,o,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+o|0},s.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 e=o.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=s},137:(e,t,r)=>{"use strict";var n=r(1734),i=r(2202);function o(e){this.rand=e||new i.Rand}e.exports=o,o.create=function(e){return new o(e)},o.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var i=new n(this.rand.generate(r))}while(i.cmp(e)>=0);return i},o.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},o.prototype.test=function(e,t,r){var i=e.bitLength(),o=n.mont(e),a=new n(1).toRed(o);t||(t=Math.max(1,i/48|0));for(var s=e.subn(1),u=0;!s.testn(u);u++);for(var c=e.shrn(u),l=s.toRed(o);t>0;t--){var f=this._randrange(new n(2),s);r&&r(f);var h=f.toRed(o).redPow(c);if(0!==h.cmp(a)&&0!==h.cmp(l)){for(var d=1;d0;t--){var l=this._randrange(new n(2),a),f=e.gcd(l);if(0!==f.cmpn(1))return f;var h=l.toRed(i).redPow(u);if(0!==h.cmp(o)&&0!==h.cmp(c)){for(var d=1;d{"use strict";function t(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=t,t.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},6580:(e,t)=>{"use strict";var r=t;function n(e){return 1===e.length?"0"+e:e}function i(e){for(var t="",r=0;r>8,a=255&i;o?r.push(o,a):r.push(a)}return r},r.zero2=n,r.toHex=i,r.encode=function(e,t){return"hex"===t?i(e):e}},6565:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=function(){function e(t,r,n,o){(0,i.default)(this,e),this.name=t,this.code=r,this.alphabet=o,n&&o&&(this.engine=n(o))}return(0,o.default)(e,[{key:"encode",value:function(e){return this.engine.encode(e)}},{key:"decode",value:function(e){return this.engine.decode(e)}},{key:"isImplemented",value:function(){return this.engine}}]),e}();e.exports=a},2642:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base16 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"hex")}}}},6494:e=>{"use strict";function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=5;)s+=t[a>>>o-5&31],o-=5;if(o>0&&(s+=t[a<<5-o&31]),i)for(;s.length%8!=0;)s+="=";return s}("string"==typeof t?Uint8Array.from(t):t,e)},decode:function(r){var n,i=function(e,r){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,r){if(e){if("string"==typeof e)return t(e,r);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?t(e,r):void 0}}(e))){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(r);try{for(i.s();!(n=i.n()).done;){var o=n.value;if(e.indexOf(o)<0)throw new Error("invalid base32 character")}}catch(e){i.e(e)}finally{i.f()}return function(e,t){for(var r=(e=e.replace(new RegExp("=","g"),"")).length,n=0,i=0,o=0,a=new Uint8Array(5*r/8|0),s=0;s=8&&(a[o++]=i>>>n-8&255,n-=8);return a.buffer}(r,e)}}}},6627:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r-1,r=e.indexOf("-")>-1&&e.indexOf("_")>-1;return{encode:function(e){var n="";n="string"==typeof e?i.from(e).toString("base64"):e.toString("base64"),r&&(n=n.replace(/\+/g,"-").replace(/\//g,"_"));var o=n.indexOf("=");return o>0&&!t&&(n=n.substring(0,o)),n},decode:function(t){var r,o=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}(e))){r&&(e=r);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base64 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"base64")}}}},7905:(e,t,r)=>{"use strict";var n=r(6565),i=r(7548),o=r(2642),a=r(6494),s=r(6627),u=[["base1","1","","1"],["base2","0",i,"01"],["base8","7",i,"01234567"],["base10","9",i,"0123456789"],["base16","f",o,"0123456789abcdef"],["base32","b",a,"abcdefghijklmnopqrstuvwxyz234567"],["base32pad","c",a,"abcdefghijklmnopqrstuvwxyz234567="],["base32hex","v",a,"0123456789abcdefghijklmnopqrstuv"],["base32hexpad","t",a,"0123456789abcdefghijklmnopqrstuv="],["base32z","h",a,"ybndrfg8ejkmcpqxot1uwisza345h769"],["base58flickr","Z",i,"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"],["base58btc","z",i,"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"],["base64","m",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],["base64pad","M",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],["base64url","u",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],["base64urlpad","U",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_="]],c=u.reduce((function(e,t){return e[t[0]]=new n(t[0],t[1],t[2],t[3]),e}),{}),l=u.reduce((function(e,t){return e[t[1]]=c[t[0]],e}),{});e.exports={names:c,codes:l}},6086:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(7905);(t=e.exports=a).encode=function(e,t){var r=s(e);return a(r.name,n.from(r.encode(t)))},t.decode=function(e){n.isBuffer(e)&&(e=e.toString());var t=e.substring(0,1);"string"==typeof(e=e.substring(1,e.length))&&(e=n.from(e));var r=s(t);return n.from(r.decode(e.toString()))},t.isEncoded=function(e){if(n.isBuffer(e)&&(e=e.toString()),"[object String]"!==Object.prototype.toString.call(e))return!1;var t=e.substring(0,1);try{return s(t).name}catch(e){return!1}},t.names=Object.freeze(Object.keys(i.names)),t.codes=Object.freeze(Object.keys(i.codes));var o=new Error("Unsupported encoding");function a(e,t){if(!t)throw new Error("requires an encoded buffer");var r=s(e),i=n.from(r.code);return function(e,t){s(e).decode(t.toString())}(r.name,t),n.concat([i,t])}function s(e){var t;if(i.names[e])t=i.names[e];else{if(!i.codes[e])throw o;t=i.codes[e]}if(!t.isImplemented())throw new Error("Base "+e+" is not implemented yet");return t}},4093:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(4070),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(9033).Buffer,i=r(6657),o=r(7054),a=r(6002),s=r(5576);(t=e.exports).addPrefix=function(e,t){var r;if(n.isBuffer(e))r=s.varintBufferEncode(e);else{if(!a[e])throw new Error("multicodec not recognized");r=a[e]}return n.concat([r,t])},t.rmPrefix=function(e){return i.decode(e),e.slice(i.decode.bytes)},t.getCodec=function(e){var t=i.decode(e),r=o.get(t);if(void 0===r)throw new Error("Code ".concat(t," not found"));return r},t.getName=function(e){return o.get(e)},t.getNumber=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return s.varintBufferDecode(t)[0]},t.getCode=function(e){return i.decode(e)},t.getCodeVarint=function(e){var t=a[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return t},t.getVarint=function(e){return i.encode(e)};var u=r(4093);Object.assign(t,u),t.print=r(1032)},7054:(e,t,r)=>{"use strict";var n=r(4070),i=new Map;for(var o in n){var a=n[o];i.set(a,o)}e.exports=Object.freeze(i)},1032:(e,t,r)=>{"use strict";for(var n=r(8847)(r(4519)),i=r(4070),o={},a=0,s=Object.entries(i);a{"use strict";var n=r(9033).Buffer,i=r(6657);function o(e){return parseInt(e.toString("hex"),16)}function a(e){var t=e.toString(16);return t.length%2==1&&(t="0"+t),n.from(t,"hex")}e.exports={numberToBuffer:a,bufferToNumber:o,varintBufferEncode:function(e){return n.from(i.encode(o(e)))},varintBufferDecode:function(e){return a(i.decode(e))},varintEncode:function(e){return n.from(i.encode(e))}}},6002:(e,t,r)=>{"use strict";var n=r(4070),i=r(5576).varintEncode,o={};for(var a in n){var s=n[a];o[a]=i(s)}e.exports=Object.freeze(o)},1786:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=function(){function e(t,r,n,o){(0,i.default)(this,e),this.name=t,this.code=r,this.alphabet=o,n&&o&&(this.engine=n(o))}return(0,o.default)(e,[{key:"encode",value:function(e){return this.engine.encode(e)}},{key:"decode",value:function(e){return this.engine.decode(e)}},{key:"isImplemented",value:function(){return this.engine}}]),e}();e.exports=a},7739:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base16 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"hex")}}}},976:e=>{"use strict";function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=5;)s+=t[a>>>o-5&31],o-=5;if(o>0&&(s+=t[a<<5-o&31]),i)for(;s.length%8!=0;)s+="=";return s}("string"==typeof t?Uint8Array.from(t):t,e)},decode:function(r){var n,i=function(e,r){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,r){if(e){if("string"==typeof e)return t(e,r);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?t(e,r):void 0}}(e))){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(r);try{for(i.s();!(n=i.n()).done;){var o=n.value;if(e.indexOf(o)<0)throw new Error("invalid base32 character")}}catch(e){i.e(e)}finally{i.f()}return function(e,t){for(var r=(e=e.replace(new RegExp("=","g"),"")).length,n=0,i=0,o=0,a=new Uint8Array(5*r/8|0),s=0;s=8&&(a[o++]=i>>>n-8&255,n-=8);return a.buffer}(r,e)}}}},8504:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r-1,r=e.indexOf("-")>-1&&e.indexOf("_")>-1;return{encode:function(e){var n="";n="string"==typeof e?i.from(e).toString("base64"):e.toString("base64"),r&&(n=n.replace(/\+/g,"-").replace(/\//g,"_"));var o=n.indexOf("=");return o>0&&!t&&(n=n.substring(0,o)),n},decode:function(t){var r,o=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}(e))){r&&(e=r);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==r.return||r.return()}finally{if(u)throw a}}}}(t);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(e.indexOf(a)<0)throw new Error("invalid base64 character")}}catch(e){o.e(e)}finally{o.f()}return i.from(t,"base64")}}}},2263:(e,t,r)=>{"use strict";var n=r(1786),i=r(7548),o=r(7739),a=r(976),s=r(8504),u=[["base1","1","","1"],["base2","0",i,"01"],["base8","7",i,"01234567"],["base10","9",i,"0123456789"],["base16","f",o,"0123456789abcdef"],["base32","b",a,"abcdefghijklmnopqrstuvwxyz234567"],["base32pad","c",a,"abcdefghijklmnopqrstuvwxyz234567="],["base32hex","v",a,"0123456789abcdefghijklmnopqrstuv"],["base32hexpad","t",a,"0123456789abcdefghijklmnopqrstuv="],["base32z","h",a,"ybndrfg8ejkmcpqxot1uwisza345h769"],["base58flickr","Z",i,"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"],["base58btc","z",i,"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"],["base64","m",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],["base64pad","M",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],["base64url","u",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],["base64urlpad","U",s,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_="]],c=u.reduce((function(e,t){return e[t[0]]=new n(t[0],t[1],t[2],t[3]),e}),{}),l=u.reduce((function(e,t){return e[t[1]]=c[t[0]],e}),{});e.exports={names:c,codes:l}},2592:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(2263);function o(e,t){if(!t)throw new Error("requires an encoded buffer");var r=a(e),i=n.from(r.code);return function(e,t){a(e).decode(t.toString())}(r.name,t),n.concat([i,t])}function a(e){var t;if(i.names[e])t=i.names[e];else{if(!i.codes[e])throw new Error("Unsupported encoding");t=i.codes[e]}if(!t.isImplemented())throw new Error("Base "+e+" is not implemented yet");return t}(t=e.exports=o).encode=function(e,t){var r=a(e);return o(r.name,n.from(r.encode(t)))},t.decode=function(e){n.isBuffer(e)&&(e=e.toString());var t=e.substring(0,1);"string"==typeof(e=e.substring(1,e.length))&&(e=n.from(e));var r=a(t);return n.from(r.decode(e.toString()))},t.isEncoded=function(e){if(n.isBuffer(e)&&(e=e.toString()),"[object String]"!==Object.prototype.toString.call(e))return!1;var t=e.substring(0,1);try{return a(t).name}catch(e){return!1}},t.names=Object.freeze(Object.keys(i.names)),t.codes=Object.freeze(Object.keys(i.codes))},1269:(e,t)=>{"use strict";t.names=Object.freeze({identity:0,sha1:17,"sha2-256":18,"sha2-512":19,"dbl-sha2-256":86,"sha3-224":23,"sha3-256":22,"sha3-384":21,"sha3-512":20,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"murmur3-128":34,"murmur3-32":35,md4:212,md5:213,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"Skein256-8":45825,"Skein256-16":45826,"Skein256-24":45827,"Skein256-32":45828,"Skein256-40":45829,"Skein256-48":45830,"Skein256-56":45831,"Skein256-64":45832,"Skein256-72":45833,"Skein256-80":45834,"Skein256-88":45835,"Skein256-96":45836,"Skein256-104":45837,"Skein256-112":45838,"Skein256-120":45839,"Skein256-128":45840,"Skein256-136":45841,"Skein256-144":45842,"Skein256-152":45843,"Skein256-160":45844,"Skein256-168":45845,"Skein256-176":45846,"Skein256-184":45847,"Skein256-192":45848,"Skein256-200":45849,"Skein256-208":45850,"Skein256-216":45851,"Skein256-224":45852,"Skein256-232":45853,"Skein256-240":45854,"Skein256-248":45855,"Skein256-256":45856,"Skein512-8":45857,"Skein512-16":45858,"Skein512-24":45859,"Skein512-32":45860,"Skein512-40":45861,"Skein512-48":45862,"Skein512-56":45863,"Skein512-64":45864,"Skein512-72":45865,"Skein512-80":45866,"Skein512-88":45867,"Skein512-96":45868,"Skein512-104":45869,"Skein512-112":45870,"Skein512-120":45871,"Skein512-128":45872,"Skein512-136":45873,"Skein512-144":45874,"Skein512-152":45875,"Skein512-160":45876,"Skein512-168":45877,"Skein512-176":45878,"Skein512-184":45879,"Skein512-192":45880,"Skein512-200":45881,"Skein512-208":45882,"Skein512-216":45883,"Skein512-224":45884,"Skein512-232":45885,"Skein512-240":45886,"Skein512-248":45887,"Skein512-256":45888,"Skein512-264":45889,"Skein512-272":45890,"Skein512-280":45891,"Skein512-288":45892,"Skein512-296":45893,"Skein512-304":45894,"Skein512-312":45895,"Skein512-320":45896,"Skein512-328":45897,"Skein512-336":45898,"Skein512-344":45899,"Skein512-352":45900,"Skein512-360":45901,"Skein512-368":45902,"Skein512-376":45903,"Skein512-384":45904,"Skein512-392":45905,"Skein512-400":45906,"Skein512-408":45907,"Skein512-416":45908,"Skein512-424":45909,"Skein512-432":45910,"Skein512-440":45911,"Skein512-448":45912,"Skein512-456":45913,"Skein512-464":45914,"Skein512-472":45915,"Skein512-480":45916,"Skein512-488":45917,"Skein512-496":45918,"Skein512-504":45919,"Skein512-512":45920,"Skein1024-8":45921,"Skein1024-16":45922,"Skein1024-24":45923,"Skein1024-32":45924,"Skein1024-40":45925,"Skein1024-48":45926,"Skein1024-56":45927,"Skein1024-64":45928,"Skein1024-72":45929,"Skein1024-80":45930,"Skein1024-88":45931,"Skein1024-96":45932,"Skein1024-104":45933,"Skein1024-112":45934,"Skein1024-120":45935,"Skein1024-128":45936,"Skein1024-136":45937,"Skein1024-144":45938,"Skein1024-152":45939,"Skein1024-160":45940,"Skein1024-168":45941,"Skein1024-176":45942,"Skein1024-184":45943,"Skein1024-192":45944,"Skein1024-200":45945,"Skein1024-208":45946,"Skein1024-216":45947,"Skein1024-224":45948,"Skein1024-232":45949,"Skein1024-240":45950,"Skein1024-248":45951,"Skein1024-256":45952,"Skein1024-264":45953,"Skein1024-272":45954,"Skein1024-280":45955,"Skein1024-288":45956,"Skein1024-296":45957,"Skein1024-304":45958,"Skein1024-312":45959,"Skein1024-320":45960,"Skein1024-328":45961,"Skein1024-336":45962,"Skein1024-344":45963,"Skein1024-352":45964,"Skein1024-360":45965,"Skein1024-368":45966,"Skein1024-376":45967,"Skein1024-384":45968,"Skein1024-392":45969,"Skein1024-400":45970,"Skein1024-408":45971,"Skein1024-416":45972,"Skein1024-424":45973,"Skein1024-432":45974,"Skein1024-440":45975,"Skein1024-448":45976,"Skein1024-456":45977,"Skein1024-464":45978,"Skein1024-472":45979,"Skein1024-480":45980,"Skein1024-488":45981,"Skein1024-496":45982,"Skein1024-504":45983,"Skein1024-512":45984,"Skein1024-520":45985,"Skein1024-528":45986,"Skein1024-536":45987,"Skein1024-544":45988,"Skein1024-552":45989,"Skein1024-560":45990,"Skein1024-568":45991,"Skein1024-576":45992,"Skein1024-584":45993,"Skein1024-592":45994,"Skein1024-600":45995,"Skein1024-608":45996,"Skein1024-616":45997,"Skein1024-624":45998,"Skein1024-632":45999,"Skein1024-640":46e3,"Skein1024-648":46001,"Skein1024-656":46002,"Skein1024-664":46003,"Skein1024-672":46004,"Skein1024-680":46005,"Skein1024-688":46006,"Skein1024-696":46007,"Skein1024-704":46008,"Skein1024-712":46009,"Skein1024-720":46010,"Skein1024-728":46011,"Skein1024-736":46012,"Skein1024-744":46013,"Skein1024-752":46014,"Skein1024-760":46015,"Skein1024-768":46016,"Skein1024-776":46017,"Skein1024-784":46018,"Skein1024-792":46019,"Skein1024-800":46020,"Skein1024-808":46021,"Skein1024-816":46022,"Skein1024-824":46023,"Skein1024-832":46024,"Skein1024-840":46025,"Skein1024-848":46026,"Skein1024-856":46027,"Skein1024-864":46028,"Skein1024-872":46029,"Skein1024-880":46030,"Skein1024-888":46031,"Skein1024-896":46032,"Skein1024-904":46033,"Skein1024-912":46034,"Skein1024-920":46035,"Skein1024-928":46036,"Skein1024-936":46037,"Skein1024-944":46038,"Skein1024-952":46039,"Skein1024-960":46040,"Skein1024-968":46041,"Skein1024-976":46042,"Skein1024-984":46043,"Skein1024-992":46044,"Skein1024-1000":46045,"Skein1024-1008":46046,"Skein1024-1016":46047,"Skein1024-1024":46048}),t.codes=Object.freeze({0:"identity",17:"sha1",18:"sha2-256",19:"sha2-512",86:"dbl-sha2-256",23:"sha3-224",22:"sha3-256",21:"sha3-384",20:"sha3-512",24:"shake-128",25:"shake-256",26:"keccak-224",27:"keccak-256",28:"keccak-384",29:"keccak-512",34:"murmur3-128",35:"murmur3-32",212:"md4",213:"md5",45569:"blake2b-8",45570:"blake2b-16",45571:"blake2b-24",45572:"blake2b-32",45573:"blake2b-40",45574:"blake2b-48",45575:"blake2b-56",45576:"blake2b-64",45577:"blake2b-72",45578:"blake2b-80",45579:"blake2b-88",45580:"blake2b-96",45581:"blake2b-104",45582:"blake2b-112",45583:"blake2b-120",45584:"blake2b-128",45585:"blake2b-136",45586:"blake2b-144",45587:"blake2b-152",45588:"blake2b-160",45589:"blake2b-168",45590:"blake2b-176",45591:"blake2b-184",45592:"blake2b-192",45593:"blake2b-200",45594:"blake2b-208",45595:"blake2b-216",45596:"blake2b-224",45597:"blake2b-232",45598:"blake2b-240",45599:"blake2b-248",45600:"blake2b-256",45601:"blake2b-264",45602:"blake2b-272",45603:"blake2b-280",45604:"blake2b-288",45605:"blake2b-296",45606:"blake2b-304",45607:"blake2b-312",45608:"blake2b-320",45609:"blake2b-328",45610:"blake2b-336",45611:"blake2b-344",45612:"blake2b-352",45613:"blake2b-360",45614:"blake2b-368",45615:"blake2b-376",45616:"blake2b-384",45617:"blake2b-392",45618:"blake2b-400",45619:"blake2b-408",45620:"blake2b-416",45621:"blake2b-424",45622:"blake2b-432",45623:"blake2b-440",45624:"blake2b-448",45625:"blake2b-456",45626:"blake2b-464",45627:"blake2b-472",45628:"blake2b-480",45629:"blake2b-488",45630:"blake2b-496",45631:"blake2b-504",45632:"blake2b-512",45633:"blake2s-8",45634:"blake2s-16",45635:"blake2s-24",45636:"blake2s-32",45637:"blake2s-40",45638:"blake2s-48",45639:"blake2s-56",45640:"blake2s-64",45641:"blake2s-72",45642:"blake2s-80",45643:"blake2s-88",45644:"blake2s-96",45645:"blake2s-104",45646:"blake2s-112",45647:"blake2s-120",45648:"blake2s-128",45649:"blake2s-136",45650:"blake2s-144",45651:"blake2s-152",45652:"blake2s-160",45653:"blake2s-168",45654:"blake2s-176",45655:"blake2s-184",45656:"blake2s-192",45657:"blake2s-200",45658:"blake2s-208",45659:"blake2s-216",45660:"blake2s-224",45661:"blake2s-232",45662:"blake2s-240",45663:"blake2s-248",45664:"blake2s-256",45825:"Skein256-8",45826:"Skein256-16",45827:"Skein256-24",45828:"Skein256-32",45829:"Skein256-40",45830:"Skein256-48",45831:"Skein256-56",45832:"Skein256-64",45833:"Skein256-72",45834:"Skein256-80",45835:"Skein256-88",45836:"Skein256-96",45837:"Skein256-104",45838:"Skein256-112",45839:"Skein256-120",45840:"Skein256-128",45841:"Skein256-136",45842:"Skein256-144",45843:"Skein256-152",45844:"Skein256-160",45845:"Skein256-168",45846:"Skein256-176",45847:"Skein256-184",45848:"Skein256-192",45849:"Skein256-200",45850:"Skein256-208",45851:"Skein256-216",45852:"Skein256-224",45853:"Skein256-232",45854:"Skein256-240",45855:"Skein256-248",45856:"Skein256-256",45857:"Skein512-8",45858:"Skein512-16",45859:"Skein512-24",45860:"Skein512-32",45861:"Skein512-40",45862:"Skein512-48",45863:"Skein512-56",45864:"Skein512-64",45865:"Skein512-72",45866:"Skein512-80",45867:"Skein512-88",45868:"Skein512-96",45869:"Skein512-104",45870:"Skein512-112",45871:"Skein512-120",45872:"Skein512-128",45873:"Skein512-136",45874:"Skein512-144",45875:"Skein512-152",45876:"Skein512-160",45877:"Skein512-168",45878:"Skein512-176",45879:"Skein512-184",45880:"Skein512-192",45881:"Skein512-200",45882:"Skein512-208",45883:"Skein512-216",45884:"Skein512-224",45885:"Skein512-232",45886:"Skein512-240",45887:"Skein512-248",45888:"Skein512-256",45889:"Skein512-264",45890:"Skein512-272",45891:"Skein512-280",45892:"Skein512-288",45893:"Skein512-296",45894:"Skein512-304",45895:"Skein512-312",45896:"Skein512-320",45897:"Skein512-328",45898:"Skein512-336",45899:"Skein512-344",45900:"Skein512-352",45901:"Skein512-360",45902:"Skein512-368",45903:"Skein512-376",45904:"Skein512-384",45905:"Skein512-392",45906:"Skein512-400",45907:"Skein512-408",45908:"Skein512-416",45909:"Skein512-424",45910:"Skein512-432",45911:"Skein512-440",45912:"Skein512-448",45913:"Skein512-456",45914:"Skein512-464",45915:"Skein512-472",45916:"Skein512-480",45917:"Skein512-488",45918:"Skein512-496",45919:"Skein512-504",45920:"Skein512-512",45921:"Skein1024-8",45922:"Skein1024-16",45923:"Skein1024-24",45924:"Skein1024-32",45925:"Skein1024-40",45926:"Skein1024-48",45927:"Skein1024-56",45928:"Skein1024-64",45929:"Skein1024-72",45930:"Skein1024-80",45931:"Skein1024-88",45932:"Skein1024-96",45933:"Skein1024-104",45934:"Skein1024-112",45935:"Skein1024-120",45936:"Skein1024-128",45937:"Skein1024-136",45938:"Skein1024-144",45939:"Skein1024-152",45940:"Skein1024-160",45941:"Skein1024-168",45942:"Skein1024-176",45943:"Skein1024-184",45944:"Skein1024-192",45945:"Skein1024-200",45946:"Skein1024-208",45947:"Skein1024-216",45948:"Skein1024-224",45949:"Skein1024-232",45950:"Skein1024-240",45951:"Skein1024-248",45952:"Skein1024-256",45953:"Skein1024-264",45954:"Skein1024-272",45955:"Skein1024-280",45956:"Skein1024-288",45957:"Skein1024-296",45958:"Skein1024-304",45959:"Skein1024-312",45960:"Skein1024-320",45961:"Skein1024-328",45962:"Skein1024-336",45963:"Skein1024-344",45964:"Skein1024-352",45965:"Skein1024-360",45966:"Skein1024-368",45967:"Skein1024-376",45968:"Skein1024-384",45969:"Skein1024-392",45970:"Skein1024-400",45971:"Skein1024-408",45972:"Skein1024-416",45973:"Skein1024-424",45974:"Skein1024-432",45975:"Skein1024-440",45976:"Skein1024-448",45977:"Skein1024-456",45978:"Skein1024-464",45979:"Skein1024-472",45980:"Skein1024-480",45981:"Skein1024-488",45982:"Skein1024-496",45983:"Skein1024-504",45984:"Skein1024-512",45985:"Skein1024-520",45986:"Skein1024-528",45987:"Skein1024-536",45988:"Skein1024-544",45989:"Skein1024-552",45990:"Skein1024-560",45991:"Skein1024-568",45992:"Skein1024-576",45993:"Skein1024-584",45994:"Skein1024-592",45995:"Skein1024-600",45996:"Skein1024-608",45997:"Skein1024-616",45998:"Skein1024-624",45999:"Skein1024-632",46e3:"Skein1024-640",46001:"Skein1024-648",46002:"Skein1024-656",46003:"Skein1024-664",46004:"Skein1024-672",46005:"Skein1024-680",46006:"Skein1024-688",46007:"Skein1024-696",46008:"Skein1024-704",46009:"Skein1024-712",46010:"Skein1024-720",46011:"Skein1024-728",46012:"Skein1024-736",46013:"Skein1024-744",46014:"Skein1024-752",46015:"Skein1024-760",46016:"Skein1024-768",46017:"Skein1024-776",46018:"Skein1024-784",46019:"Skein1024-792",46020:"Skein1024-800",46021:"Skein1024-808",46022:"Skein1024-816",46023:"Skein1024-824",46024:"Skein1024-832",46025:"Skein1024-840",46026:"Skein1024-848",46027:"Skein1024-856",46028:"Skein1024-864",46029:"Skein1024-872",46030:"Skein1024-880",46031:"Skein1024-888",46032:"Skein1024-896",46033:"Skein1024-904",46034:"Skein1024-912",46035:"Skein1024-920",46036:"Skein1024-928",46037:"Skein1024-936",46038:"Skein1024-944",46039:"Skein1024-952",46040:"Skein1024-960",46041:"Skein1024-968",46042:"Skein1024-976",46043:"Skein1024-984",46044:"Skein1024-992",46045:"Skein1024-1000",46046:"Skein1024-1008",46047:"Skein1024-1016",46048:"Skein1024-1024"}),t.defaultLengths=Object.freeze({17:20,18:32,19:64,86:32,23:28,22:32,21:48,20:64,24:32,25:64,26:28,27:32,28:48,29:64,34:32,45569:1,45570:2,45571:3,45572:4,45573:5,45574:6,45575:7,45576:8,45577:9,45578:10,45579:11,45580:12,45581:13,45582:14,45583:15,45584:16,45585:17,45586:18,45587:19,45588:20,45589:21,45590:22,45591:23,45592:24,45593:25,45594:26,45595:27,45596:28,45597:29,45598:30,45599:31,45600:32,45601:33,45602:34,45603:35,45604:36,45605:37,45606:38,45607:39,45608:40,45609:41,45610:42,45611:43,45612:44,45613:45,45614:46,45615:47,45616:48,45617:49,45618:50,45619:51,45620:52,45621:53,45622:54,45623:55,45624:56,45625:57,45626:58,45627:59,45628:60,45629:61,45630:62,45631:63,45632:64,45633:1,45634:2,45635:3,45636:4,45637:5,45638:6,45639:7,45640:8,45641:9,45642:10,45643:11,45644:12,45645:13,45646:14,45647:15,45648:16,45649:17,45650:18,45651:19,45652:20,45653:21,45654:22,45655:23,45656:24,45657:25,45658:26,45659:27,45660:28,45661:29,45662:30,45663:31,45664:32,45825:1,45826:2,45827:3,45828:4,45829:5,45830:6,45831:7,45832:8,45833:9,45834:10,45835:11,45836:12,45837:13,45838:14,45839:15,45840:16,45841:17,45842:18,45843:19,45844:20,45845:21,45846:22,45847:23,45848:24,45849:25,45850:26,45851:27,45852:28,45853:29,45854:30,45855:31,45856:32,45857:1,45858:2,45859:3,45860:4,45861:5,45862:6,45863:7,45864:8,45865:9,45866:10,45867:11,45868:12,45869:13,45870:14,45871:15,45872:16,45873:17,45874:18,45875:19,45876:20,45877:21,45878:22,45879:23,45880:24,45881:25,45882:26,45883:27,45884:28,45885:29,45886:30,45887:31,45888:32,45889:33,45890:34,45891:35,45892:36,45893:37,45894:38,45895:39,45896:40,45897:41,45898:42,45899:43,45900:44,45901:45,45902:46,45903:47,45904:48,45905:49,45906:50,45907:51,45908:52,45909:53,45910:54,45911:55,45912:56,45913:57,45914:58,45915:59,45916:60,45917:61,45918:62,45919:63,45920:64,45921:1,45922:2,45923:3,45924:4,45925:5,45926:6,45927:7,45928:8,45929:9,45930:10,45931:11,45932:12,45933:13,45934:14,45935:15,45936:16,45937:17,45938:18,45939:19,45940:20,45941:21,45942:22,45943:23,45944:24,45945:25,45946:26,45947:27,45948:28,45949:29,45950:30,45951:31,45952:32,45953:33,45954:34,45955:35,45956:36,45957:37,45958:38,45959:39,45960:40,45961:41,45962:42,45963:43,45964:44,45965:45,45966:46,45967:47,45968:48,45969:49,45970:50,45971:51,45972:52,45973:53,45974:54,45975:55,45976:56,45977:57,45978:58,45979:59,45980:60,45981:61,45982:62,45983:63,45984:64,45985:65,45986:66,45987:67,45988:68,45989:69,45990:70,45991:71,45992:72,45993:73,45994:74,45995:75,45996:76,45997:77,45998:78,45999:79,46e3:80,46001:81,46002:82,46003:83,46004:84,46005:85,46006:86,46007:87,46008:88,46009:89,46010:90,46011:91,46012:92,46013:93,46014:94,46015:95,46016:96,46017:97,46018:98,46019:99,46020:100,46021:101,46022:102,46023:103,46024:104,46025:105,46026:106,46027:107,46028:108,46029:109,46030:110,46031:111,46032:112,46033:113,46034:114,46035:115,46036:116,46037:117,46038:118,46039:119,46040:120,46041:121,46042:122,46043:123,46044:124,46045:125,46046:126,46047:127,46048:128})},7748:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(2592),o=r(6657),a=r(1269);function s(e){t.decode(e)}t.names=a.names,t.codes=a.codes,t.defaultLengths=a.defaultLengths,t.toHexString=function(e){if(!n.isBuffer(e))throw new Error("must be passed a buffer");return e.toString("hex")},t.fromHexString=function(e){return n.from(e,"hex")},t.toB58String=function(e){if(!n.isBuffer(e))throw new Error("must be passed a buffer");return i.encode("base58btc",e).toString().slice(1)},t.fromB58String=function(e){var t=e;return n.isBuffer(e)&&(t=e.toString()),i.decode("z"+t)},t.decode=function(e){if(!n.isBuffer(e))throw new Error("multihash must be a Buffer");if(e.length<2)throw new Error("multihash too short. must be > 2 bytes.");var r=o.decode(e);if(!t.isValidCode(r))throw new Error("multihash unknown function code: 0x".concat(r.toString(16)));e=e.slice(o.decode.bytes);var i=o.decode(e);if(i<0)throw new Error("multihash invalid length: ".concat(i));if((e=e.slice(o.decode.bytes)).length!==i)throw new Error("multihash length inconsistent: 0x".concat(e.toString("hex")));return{code:r,name:a.codes[r],length:i,digest:e}},t.encode=function(e,r,i){if(!e||void 0===r)throw new Error("multihash encode requires at least two args: digest, code");var a=t.coerceCode(r);if(!n.isBuffer(e))throw new Error("digest should be a Buffer");if(null==i&&(i=e.length),i&&e.length!==i)throw new Error("digest length should be equal to specified length.");return n.concat([n.from(o.encode(a)),n.from(o.encode(i)),e])},t.coerceCode=function(e){var r=e;if("string"==typeof e){if(void 0===a.names[e])throw new Error("Unrecognized hash function named: ".concat(e));r=a.names[e]}if("number"!=typeof r)throw new Error("Hash function code should be a number. Got: ".concat(r));if(void 0===a.codes[r]&&!t.isAppCode(r))throw new Error("Unrecognized function code: ".concat(r));return r},t.isAppCode=function(e){return e>0&&e<16},t.isValidCode=function(e){return!!t.isAppCode(e)||!!a.codes[e]},t.validate=s,t.prefix=function(e){return s(e),e.slice(0,2)}},7277:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(6931);e.exports=function(e){if("string"==typeof e||"number"==typeof e){var t=new i(1),r=String(e).toLowerCase().trim(),a="0x"===r.substr(0,2)||"-0x"===r.substr(0,3),s=o(r);if("-"===s.substr(0,1)&&(s=o(s.slice(1)),t=new i(-1,10)),!(s=""===s?"0":s).match(/^-?[0-9]+$/)&&s.match(/^[0-9A-Fa-f]+$/)||s.match(/^[a-fA-F]+$/)||!0===a&&s.match(/^[0-9A-Fa-f]+$/))return new i(s,16).mul(t);if((s.match(/^-?[0-9]+$/)||""===s)&&!1===a)return new i(s,10).mul(t)}else if("object"===(0,n.default)(e)&&e.toString&&!e.pop&&!e.push&&e.toString(10).match(/^-?[0-9]+$/)&&(e.mul||e.dividedToIntegerBy))return new i(e.toString(10),10);throw new Error("[number-to-bn] while converting number "+JSON.stringify(e)+" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.")}},3103:e=>{"use strict";var t=Object.getOwnPropertySymbols,r=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function i(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,o){for(var a,s,u=i(e),c=1;c{"use strict";var n,i,o;e=r.nmd(e);var a,s=r(8847)(r(3355));"undefined"!=typeof self&&self,a=function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=7)}([function(e,t,r){r.d(t,"j",(function(){return i})),r.d(t,"d",(function(){return o})),r.d(t,"c",(function(){return a})),r.d(t,"h",(function(){return s})),r.d(t,"b",(function(){return u})),r.d(t,"k",(function(){return c})),r.d(t,"e",(function(){return l})),r.d(t,"g",(function(){return f})),r.d(t,"i",(function(){return h})),r.d(t,"a",(function(){return d})),r.d(t,"f",(function(){return p}));var n=r(1),i=c((function(e,t){var r=t.length;return c((function(n){for(var i=0;i0&&(i=r),r=e[c++]);)switch(J++,"\n"===r?(G++,z=0):z++,U){case d:if("{"===r)U=m;else if("["===r)U=g;else if(!K(r))return q("Non-whitespace before {[.");continue;case w:case m:if(K(r))continue;if(U===w)F.push(A);else{if("}"===r){s({}),u(),U=F.pop()||p;continue}F.push(y)}if('"'!==r)return q('Malformed object key should start with " ');U=v;continue;case A:case y:if(K(r))continue;if(":"===r)U===y?(F.push(y),void 0!==o&&(s({}),a(o),o=void 0),H++):void 0!==o&&(a(o),o=void 0),U=p;else if("}"===r)void 0!==o&&(s(o),u(),o=void 0),u(),H--,U=F.pop()||p;else{if(","!==r)return q("Bad object");U===y&&F.push(y),void 0!==o&&(s(o),u(),o=void 0),U=w}continue;case g:case p:if(K(r))continue;if(U===g){if(s([]),H++,U=p,"]"===r){u(),H--,U=F.pop()||p;continue}F.push(b)}if('"'===r)U=v;else if("{"===r)U=m;else if("["===r)U=g;else if("t"===r)U=S;else if("f"===r)U=_;else if("n"===r)U=P;else if("-"===r)B+=r;else if("0"===r)B+=r,U=20;else{if(-1==="123456789".indexOf(r))return q("Bad value");B+=r,U=20}continue;case b:if(","===r)F.push(b),void 0!==o&&(s(o),u(),o=void 0),U=p;else{if("]"!==r){if(K(r))continue;return q("Bad array")}void 0!==o&&(s(o),u(),o=void 0),u(),H--,U=F.pop()||p}continue;case v:void 0===o&&(o="");var h=c-1;e:for(;;){for(;j>0;)if(D+=r,r=e.charAt(c++),4===j?(o+=String.fromCharCode(parseInt(D,16)),j=0,h=c-1):j++,!r)break e;if('"'===r&&!N){U=F.pop()||p,o+=e.substring(h,c-1);break}if(!("\\"!==r||N||(N=!0,o+=e.substring(h,c-1),r=e.charAt(c++))))break;if(N){if(N=!1,"n"===r?o+="\n":"r"===r?o+="\r":"t"===r?o+="\t":"f"===r?o+="\f":"b"===r?o+="\b":"u"===r?(j=1,D=""):o+=r,r=e.charAt(c++),h=c-1,r)continue;break}f.lastIndex=c;var V=f.exec(e);if(!V){c=e.length+1,o+=e.substring(h,c-1);break}if(c=V.index+1,!(r=e.charAt(V.index))){o+=e.substring(h,c-1);break}}continue;case S:if(!r)continue;if("r"!==r)return q("Invalid true started with t"+r);U=k;continue;case k:if(!r)continue;if("u"!==r)return q("Invalid true started with tr"+r);U=E;continue;case E:if(!r)continue;if("e"!==r)return q("Invalid true started with tru"+r);s(!0),u(),U=F.pop()||p;continue;case _:if(!r)continue;if("a"!==r)return q("Invalid false started with f"+r);U=M;continue;case M:if(!r)continue;if("l"!==r)return q("Invalid false started with fa"+r);U=T;continue;case T:if(!r)continue;if("s"!==r)return q("Invalid false started with fal"+r);U=x;continue;case x:if(!r)continue;if("e"!==r)return q("Invalid false started with fals"+r);s(!1),u(),U=F.pop()||p;continue;case P:if(!r)continue;if("u"!==r)return q("Invalid null started with n"+r);U=I;continue;case I:if(!r)continue;if("l"!==r)return q("Invalid null started with nu"+r);U=O;continue;case O:if(!r)continue;if("l"!==r)return q("Invalid null started with nul"+r);s(null),u(),U=F.pop()||p;continue;case R:if("."!==r)return q("Leading zero not followed by .");B+=r,U=20;continue;case 20:if(-1!=="0123456789".indexOf(r))B+=r;else if("."===r){if(-1!==B.indexOf("."))return q("Invalid number has two dots");B+=r}else if("e"===r||"E"===r){if(-1!==B.indexOf("e")||-1!==B.indexOf("E"))return q("Invalid number has two exponential");B+=r}else if("+"===r||"-"===r){if("e"!==i&&"E"!==i)return q("Invalid symbol in number");B+=r}else B&&(s(parseFloat(B)),u(),B=""),c--,U=F.pop()||p;continue;default:return q("Unknown state: "+U)}J>=C&&(n=0,void 0!==o&&o.length>l&&(q("Max buffer length exceeded: textNode"),n=Math.max(n,o.length)),B.length>l&&(q("Max buffer length exceeded: numberNode"),n=Math.max(n,B.length)),C=l-n+J)}})),e(n.n).on((function(){if(U===d)return s({}),u(),void(L=!0);U===p&&0===H||q("Unexpected end"),void 0!==o&&(s(o),u(),o=void 0),L=!0}))}},function(e,t,r){r.d(t,"a",(function(){return u})),r.d(t,"b",(function(){return c}));var n=r(19),i=r(3),o=r(2),a=r(20),s=r(0);function u(){return new XMLHttpRequest}function c(e,t,r,u,c,l,f){var h=e(i.m).emit,d=e(i.b).emit,p=0,m=!0;function y(){if("2"===String(t.status)[0]){var e=t.responseText,r=(" "+e.substr(p)).substr(1);r&&h(r),p=Object(o.e)(e)}}function g(t){try{m&&e(i.c).emit(t.status,Object(a.a)(t.getAllResponseHeaders())),m=!1}catch(e){}}e(i.a).on((function(){t.onreadystatechange=null,t.abort()})),"onprogress"in t&&(t.onprogress=y),t.onreadystatechange=function(){switch(t.readyState){case 2:case 3:return g(t);case 4:g(t),"2"===String(t.status)[0]?(y(),e(i.n).emit()):d(Object(i.o)(t.status,t.responseText))}};try{for(var b in t.open(r,u,!0),l)t.setRequestHeader(b,l[b]);Object(n.a)(window.location,Object(n.b)(u))||t.setRequestHeader("X-Requested-With","XMLHttpRequest"),t.withCredentials=f,t.send(c)}catch(e){window.setTimeout(Object(s.j)(d,Object(i.o)(void 0,void 0,e)),0)}}},function(e,t,r){function n(e,t){function r(t){return String(t.port||{"http:":80,"https:":443}[t.protocol||e.protocol])}return!!(t.protocol&&t.protocol!==e.protocol||t.host&&t.host!==e.host||t.host&&r(t)!==r(e))}function i(e){var t=/(\w+:)?(?:\/\/)([\w.-]+)?(?::(\d+))?\/?/.exec(e)||[];return{protocol:t[1]||"",host:t[2]||"",port:t[3]||""}}r.d(t,"a",(function(){return n})),r.d(t,"b",(function(){return i}))},function(e,t,r){function n(e){var t={};return e&&e.split("\r\n").forEach((function(e){var r=e.indexOf(": ");t[e.substring(0,r)]=e.substring(r+2)})),t}r.d(t,"a",(function(){return n}))}]).default},"object"===(0,s.default)(t)&&"object"===(0,s.default)(e)?e.exports=a():(i=[],void 0===(o="function"==typeof(n=a)?n.apply(t,i):n)||(e.exports=o))},1823:(e,t,r)=>{"use strict";var n=r(8357);t.certificate=r(1320);var i=n.define("RSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())}));t.RSAPrivateKey=i;var o=n.define("RSAPublicKey",(function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())}));t.RSAPublicKey=o;var a=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())}));t.PublicKey=a;var s=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())})),u=n.define("PrivateKeyInfo",(function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(s),this.key("subjectPrivateKey").octstr())}));t.PrivateKey=u;var c=n.define("EncryptedPrivateKeyInfo",(function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())}));t.EncryptedPrivateKey=c;var l=n.define("DSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())}));t.DSAPrivateKey=l,t.DSAparam=n.define("DSAparam",(function(){this.int()}));var f=n.define("ECPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(h),this.key("publicKey").optional().explicit(1).bitstr())}));t.ECPrivateKey=f;var h=n.define("ECParameters",(function(){this.choice({namedCurve:this.objid()})}));t.signature=n.define("signature",(function(){this.seq().obj(this.key("r").int(),this.key("s").int())}))},1320:(e,t,r)=>{"use strict";var n=r(8357),i=n.define("Time",(function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})})),o=n.define("AttributeTypeValue",(function(){this.seq().obj(this.key("type").objid(),this.key("value").any())})),a=n.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())})),s=n.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(a),this.key("subjectPublicKey").bitstr())})),u=n.define("RelativeDistinguishedName",(function(){this.setof(o)})),c=n.define("RDNSequence",(function(){this.seqof(u)})),l=n.define("Name",(function(){this.choice({rdnSequence:this.use(c)})})),f=n.define("Validity",(function(){this.seq().obj(this.key("notBefore").use(i),this.key("notAfter").use(i))})),h=n.define("Extension",(function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())})),d=n.define("TBSCertificate",(function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(a),this.key("issuer").use(l),this.key("validity").use(f),this.key("subject").use(l),this.key("subjectPublicKeyInfo").use(s),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(h).optional())})),p=n.define("X509Certificate",(function(){this.seq().obj(this.key("tbsCertificate").use(d),this.key("signatureAlgorithm").use(a),this.key("signatureValue").bitstr())}));e.exports=p},4988:(e,t,r)=>{"use strict";var n=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,i=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,o=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,a=r(7085),s=r(8073),u=r(8850).Buffer;e.exports=function(e,t){var r,c=e.toString(),l=c.match(n);if(l){var f="aes"+l[1],h=u.from(l[2],"hex"),d=u.from(l[3].replace(/[\r\n]/g,""),"base64"),p=a(t,h.slice(0,8),parseInt(l[1],10)).key,m=[],y=s.createDecipheriv(f,p,h);m.push(y.update(d)),m.push(y.final()),r=u.concat(m)}else{var g=c.match(o);r=u.from(g[2].replace(/[\r\n]/g,""),"base64")}return{tag:c.match(i)[1],data:r}}},7552:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1823),o=r(2562),a=r(4988),s=r(8073),u=r(4192),c=r(8850).Buffer;function l(e){var t;"object"!==(0,n.default)(e)||c.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=c.from(e));var r,l,f=a(e,t),h=f.tag,d=f.data;switch(h){case"CERTIFICATE":l=i.certificate.decode(d,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(l||(l=i.PublicKey.decode(d,"der")),r=l.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return i.RSAPublicKey.decode(l.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return l.subjectPrivateKey=l.subjectPublicKey,{type:"ec",data:l};case"1.2.840.10040.4.1":return l.algorithm.params.pub_key=i.DSAparam.decode(l.subjectPublicKey.data,"der"),{type:"dsa",data:l.algorithm.params};default:throw new Error("unknown key id "+r)}case"ENCRYPTED PRIVATE KEY":d=function(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,n=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),i=o[e.algorithm.decrypt.cipher.algo.join(".")],a=e.algorithm.decrypt.cipher.iv,l=e.subjectPrivateKey,f=parseInt(i.split("-")[1],10)/8,h=u.pbkdf2Sync(t,r,n,f,"sha1"),d=s.createDecipheriv(i,h,a),p=[];return p.push(d.update(l)),p.push(d.final()),c.concat(p)}(d=i.EncryptedPrivateKey.decode(d,"der"),t);case"PRIVATE KEY":switch(r=(l=i.PrivateKey.decode(d,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return i.RSAPrivateKey.decode(l.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:l.algorithm.curve,privateKey:i.ECPrivateKey.decode(l.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return l.algorithm.params.priv_key=i.DSAparam.decode(l.subjectPrivateKey,"der"),{type:"dsa",params:l.algorithm.params};default:throw new Error("unknown key id "+r)}case"RSA PUBLIC KEY":return i.RSAPublicKey.decode(d,"der");case"RSA PRIVATE KEY":return i.RSAPrivateKey.decode(d,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:i.DSAPrivateKey.decode(d,"der")};case"EC PRIVATE KEY":return{curve:(d=i.ECPrivateKey.decode(d,"der")).parameters.value,privateKey:d.privateKey};default:throw new Error("unknown key type "+h)}}e.exports=l,l.signature=i.signature},8209:e=>{"use strict";var t=function(e){return e.replace(/^\s+|\s+$/g,"")};e.exports=function(e){if(!e)return{};for(var r,n={},i=t(e).split("\n"),o=0;o{"use strict";t.pbkdf2=r(1882),t.pbkdf2Sync=r(1658)},1882:(e,t,r)=>{"use strict";var n,i,o=r(8850).Buffer,a=r(3127),s=r(7401),u=r(1658),c=r(8398),l=r.g.crypto&&r.g.crypto.subtle,f={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},h=[];function d(){return i||(i=r.g.process&&r.g.process.nextTick?r.g.process.nextTick:r.g.queueMicrotask?r.g.queueMicrotask:r.g.setImmediate?r.g.setImmediate:r.g.setTimeout)}function p(e,t,r,n,i){return l.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then((function(e){return l.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},e,n<<3)})).then((function(e){return o.from(e)}))}e.exports=function(e,t,i,m,y,g){"function"==typeof y&&(g=y,y=void 0);var b=f[(y=y||"sha1").toLowerCase()];if(b&&"function"==typeof r.g.Promise){if(a(i,m),e=c(e,s,"Password"),t=c(t,s,"Salt"),"function"!=typeof g)throw new Error("No callback provided to pbkdf2");!function(e,t){e.then((function(e){d()((function(){t(null,e)}))}),(function(e){d()((function(){t(e)}))}))}(function(e){if(r.g.process&&!r.g.process.browser)return Promise.resolve(!1);if(!l||!l.importKey||!l.deriveBits)return Promise.resolve(!1);if(void 0!==h[e])return h[e];var t=p(n=n||o.alloc(8),n,10,128,e).then((function(){return!0})).catch((function(){return!1}));return h[e]=t,t}(b).then((function(r){return r?p(e,t,i,m,b):u(e,t,i,m,y)})),g)}else d()((function(){var r;try{r=u(e,t,i,m,y)}catch(e){return g(e)}g(null,r)}))}},7401:(e,t,r)=>{"use strict";var n,i=r(9142);n=r.g.process&&r.g.process.browser?"utf-8":r.g.process&&r.g.process.version?parseInt(i.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary":"utf-8",e.exports=n},3127:e=>{"use strict";var t=Math.pow(2,30)-1;e.exports=function(e,r){if("number"!=typeof e)throw new TypeError("Iterations not a number");if(e<0)throw new TypeError("Bad iterations");if("number"!=typeof r)throw new TypeError("Key length not a number");if(r<0||r>t||r!=r)throw new TypeError("Bad key length")}},1658:(e,t,r)=>{"use strict";var n=r(5349),i=r(6707),o=r(1708),a=r(8850).Buffer,s=r(3127),u=r(7401),c=r(8398),l=a.alloc(128),f={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function h(e,t,r){var s=function(e){return"rmd160"===e||"ripemd160"===e?function(e){return(new i).update(e).digest()}:"md5"===e?n:function(t){return o(e).update(t).digest()}}(e),u="sha512"===e||"sha384"===e?128:64;t.length>u?t=s(t):t.length{"use strict";var n=r(8850).Buffer;e.exports=function(e,t,r){if(n.isBuffer(e))return e;if("string"==typeof e)return n.from(e,t);if(ArrayBuffer.isView(e))return n.from(e.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")}},9142:e=>{"use strict";var t,r,n=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===i||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:i}catch(e){t=i}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(e){r=o}}();var s,u=[],c=!1,l=-1;function f(){c&&s&&(c=!1,s.length?u=s.concat(u):l=-1,u.length&&h())}function h(){if(!c){var e=a(f);c=!0;for(var t=u.length;t;){for(s=u,u=[];++l1)for(var r=1;r{"use strict";t.publicEncrypt=r(2466),t.privateDecrypt=r(3144),t.privateEncrypt=function(e,r){return t.publicEncrypt(e,r,!0)},t.publicDecrypt=function(e,r){return t.privateDecrypt(e,r,!0)}},6873:(e,t,r)=>{"use strict";var n=r(5866),i=r(8850).Buffer;function o(e){var t=i.allocUnsafe(4);return t.writeUInt32BE(e,0),t}e.exports=function(e,t){for(var r,a=i.alloc(0),s=0;a.length{"use strict";var n=r(7552),i=r(6873),o=r(817),a=r(1734),s=r(9782),u=r(5866),c=r(2561),l=r(8850).Buffer;e.exports=function(e,t,r){var f;f=e.padding?e.padding:r?1:4;var h,d=n(e),p=d.modulus.byteLength();if(t.length>p||new a(t).cmp(d.modulus)>=0)throw new Error("decryption error");h=r?c(new a(t),d):s(t,d);var m=l.alloc(p-h.length);if(h=l.concat([m,h],p),4===f)return function(e,t){var r=e.modulus.byteLength(),n=u("sha1").update(l.alloc(0)).digest(),a=n.length;if(0!==t[0])throw new Error("decryption error");var s=t.slice(1,a+1),c=t.slice(a+1),f=o(s,i(c,a)),h=o(c,i(f,r-a-1));if(function(e,t){e=l.from(e),t=l.from(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));for(var i=-1;++i=t.length){o++;break}var a=t.slice(2,i-1);if(("0002"!==n.toString("hex")&&!r||"0001"!==n.toString("hex")&&r)&&o++,a.length<8&&o++,o)throw new Error("decryption error");return t.slice(i)}(0,h,r);if(3===f)return h;throw new Error("unknown padding")}},2466:(e,t,r)=>{"use strict";var n=r(7552),i=r(5010),o=r(5866),a=r(6873),s=r(817),u=r(1734),c=r(2561),l=r(9782),f=r(8850).Buffer;e.exports=function(e,t,r){var h;h=e.padding?e.padding:r?1:4;var d,p=n(e);if(4===h)d=function(e,t){var r=e.modulus.byteLength(),n=t.length,c=o("sha1").update(f.alloc(0)).digest(),l=c.length,h=2*l;if(n>r-h-2)throw new Error("message too long");var d=f.alloc(r-n-h-2),p=r-l-1,m=i(l),y=s(f.concat([c,d,f.alloc(1,1),t],p),a(m,p)),g=s(m,a(y,l));return new u(f.concat([f.alloc(1),g,y],r))}(p,t);else if(1===h)d=function(e,t,r){var n,o=t.length,a=e.modulus.byteLength();if(o>a-11)throw new Error("message too long");return n=r?f.alloc(a-o-3,255):function(e){for(var t,r=f.allocUnsafe(e),n=0,o=i(2*e),a=0;n=0)throw new Error("data too long for modulus")}return r?l(d,p):c(d,p)}},2561:(e,t,r)=>{"use strict";var n=r(1734),i=r(8850).Buffer;e.exports=function(e,t){return i.from(e.toRed(n.mont(t.modulus)).redPow(new n(t.publicExponent)).fromRed().toArray())}},817:e=>{"use strict";e.exports=function(e,t){for(var r=e.length,n=-1;++n{"use strict";var n=r(9142),i=65536,o=r(8850).Buffer,a=r.g.crypto||r.g.msCrypto;a&&a.getRandomValues?e.exports=function(e,t){if(e>4294967295)throw new RangeError("requested too many random bytes");var r=o.allocUnsafe(e);if(e>0)if(e>i)for(var s=0;s{"use strict";var n=r(9142);function i(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var o=r(8850),a=r(5010),s=o.Buffer,u=o.kMaxLength,c=r.g.crypto||r.g.msCrypto,l=Math.pow(2,32)-1;function f(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(e>l||e<0)throw new TypeError("offset must be a uint32");if(e>u||e>t)throw new RangeError("offset out of range")}function h(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(e>l||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>u)throw new RangeError("buffer too small")}function d(e,t,r,i){if(n.browser){var o=e.buffer,s=new Uint8Array(o,t,r);return c.getRandomValues(s),i?void n.nextTick((function(){i(null,e)})):e}if(!i)return a(r).copy(e,t),e;a(r,(function(r,n){if(r)return i(r);n.copy(e,t),i(null,e)}))}c&&c.getRandomValues||!n.browser?(t.randomFill=function(e,t,n,i){if(!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof t)i=t,t=0,n=e.length;else if("function"==typeof n)i=n,n=e.length-t;else if("function"!=typeof i)throw new TypeError('"cb" argument must be a function');return f(t,e.length),h(n,t,e.length),d(e,t,n,i)},t.randomFillSync=function(e,t,n){if(void 0===t&&(t=0),!(s.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return f(t,e.length),void 0===n&&(n=e.length-t),h(n,t,e.length),d(e,t,n)}):(t.randomFill=i,t.randomFillSync=i)},9024:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i={};function o(e,t,r){r||(r=Error);var n=function(e){var r,n;function i(r,n,i){return e.call(this,function(e,r,n){return"string"==typeof t?t:t(e,r,n)}(r,n,i))||this}return n=e,(r=i).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,i}(r);n.prototype.name=r.name,n.prototype.code=e,i[e]=n}function a(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map((function(e){return String(e)})),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}o("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),o("ERR_INVALID_ARG_TYPE",(function(e,t,r){var i,o,s,u,c;if("string"==typeof t&&(o="not ",t.substr(0,o.length)===o)?(i="must not be",t=t.replace(/^not /,"")):i="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))s="The ".concat(e," ").concat(i," ").concat(a(t,"type"));else{var l=("number"!=typeof c&&(c=0),c+".".length>(u=e).length||-1===u.indexOf(".",c)?"argument":"property");s='The "'.concat(e,'" ').concat(l," ").concat(i," ").concat(a(t,"type"))}return s+". Received type ".concat((0,n.default)(r))}),TypeError),o("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),o("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),o("ERR_STREAM_PREMATURE_CLOSE","Premature close"),o("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),o("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),o("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),o("ERR_STREAM_WRITE_AFTER_END","write after end"),o("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),o("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),o("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.q=i},6884:(e,t,r)=>{"use strict";var n=r(9142),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=l;var o=r(6297),a=r(1471);r(1736)(l,o);for(var s=i(a.prototype),u=0;u{"use strict";e.exports=i;var n=r(9154);function i(e){if(!(this instanceof i))return new i(e);n.call(this,e)}r(1736)(i,n),i.prototype._transform=function(e,t,r){r(null,e)}},6297:(e,t,r)=>{"use strict";var n,i=r(9142);e.exports=_,_.ReadableState=E,r(8291).EventEmitter;var o,a=function(e,t){return e.listeners(t).length},s=r(7144),u=r(9033).Buffer,c=r.g.Uint8Array||function(){},l=r(4616);o=l&&l.debuglog?l.debuglog("stream"):function(){};var f,h,d,p=r(5392),m=r(7572),y=r(6756).getHighWaterMark,g=r(9024).q,b=g.ERR_INVALID_ARG_TYPE,v=g.ERR_STREAM_PUSH_AFTER_EOF,w=g.ERR_METHOD_NOT_IMPLEMENTED,A=g.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(1736)(_,s);var S=m.errorOrDestroy,k=["error","close","destroy","pause","resume"];function E(e,t,i){n=n||r(6884),e=e||{},"boolean"!=typeof i&&(i=t instanceof n),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",i),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(f||(f=r(3462).s),this.decoder=new f(e.encoding),this.encoding=e.encoding)}function _(e){if(n=n||r(6884),!(this instanceof _))return new _(e);var t=this instanceof n;this._readableState=new E(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),s.call(this)}function M(e,t,r,n,i){o("readableAddChunk",t);var a,s=e._readableState;if(null===t)s.reading=!1,function(e,t){if(o("onEofChunk"),!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?I(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,O(e)))}}(e,s);else if(i||(a=function(e,t){var r,n;return n=t,u.isBuffer(n)||n instanceof c||"string"==typeof t||void 0===t||e.objectMode||(r=new b("chunk",["string","Buffer","Uint8Array"],t)),r}(s,t)),a)S(e,a);else if(s.objectMode||t&&t.length>0)if("string"==typeof t||s.objectMode||Object.getPrototypeOf(t)===u.prototype||(t=function(e){return u.from(e)}(t)),n)s.endEmitted?S(e,new A):T(e,s,t,!0);else if(s.ended)S(e,new v);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(t=s.decoder.write(t),s.objectMode||0!==t.length?T(e,s,t,!1):R(e,s)):T(e,s,t,!1)}else n||(s.reading=!1,R(e,s));return!s.ended&&(s.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=x?e=x:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function I(e){var t=e._readableState;o("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(o("emitReadable",t.flowing),t.emittedReadable=!0,i.nextTick(O,e))}function O(e){var t=e._readableState;o("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,U(e)}function R(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(C,e,t))}function C(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function N(e){o("readable nexttick read 0"),e.read(0)}function L(e,t){o("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(o("flow",t.flowing);t.flowing&&null!==e.read(););}function F(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function D(e){var t=e._readableState;o("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,i.nextTick(j,t,e))}function j(e,t){if(o("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function H(e,t){for(var r=0,n=e.length;r=t.highWaterMark:t.length>0)||t.ended))return o("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?D(this):I(this),null;if(0===(e=P(e,t))&&t.ended)return 0===t.length&&D(this),null;var n,i=t.needReadable;return o("need readable",i),(0===t.length||t.length-e0?F(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&D(this)),null!==n&&this.emit("data",n),n},_.prototype._read=function(e){S(this,new w("_read()"))},_.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e)}n.pipesCount+=1,o("pipe count=%d opts=%j",n.pipesCount,t);var s=t&&!1===t.end||e===i.stdout||e===i.stderr?m:u;function u(){o("onend"),e.end()}n.endEmitted?i.nextTick(s):r.once("end",s),e.on("unpipe",(function t(i,a){o("onunpipe"),i===r&&a&&!1===a.hasUnpiped&&(a.hasUnpiped=!0,o("cleanup"),e.removeListener("close",d),e.removeListener("finish",p),e.removeListener("drain",c),e.removeListener("error",h),e.removeListener("unpipe",t),r.removeListener("end",u),r.removeListener("end",m),r.removeListener("data",f),l=!0,!n.awaitDrain||e._writableState&&!e._writableState.needDrain||c())}));var c=function(e){return function(){var t=e._readableState;o("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&a(e,"data")&&(t.flowing=!0,U(e))}}(r);e.on("drain",c);var l=!1;function f(t){o("ondata");var i=e.write(t);o("dest.write",i),!1===i&&((1===n.pipesCount&&n.pipes===e||n.pipesCount>1&&-1!==H(n.pipes,e))&&!l&&(o("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function h(t){o("onerror",t),m(),e.removeListener("error",h),0===a(e,"error")&&S(e,t)}function d(){e.removeListener("finish",p),m()}function p(){o("onfinish"),e.removeListener("close",d),m()}function m(){o("unpipe"),r.unpipe(e)}return r.on("data",f),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",h),e.once("close",d),e.once("finish",p),e.emit("pipe",r),n.flowing||(o("pipe resume"),r.resume()),e},_.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0,!1!==n.flowing&&this.resume()):"readable"===e&&(n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,o("on readable",n.length,n.reading),n.length?I(this):n.reading||i.nextTick(N,this))),r},_.prototype.addListener=_.prototype.on,_.prototype.removeListener=function(e,t){var r=s.prototype.removeListener.call(this,e,t);return"readable"===e&&i.nextTick(B,this),r},_.prototype.removeAllListeners=function(e){var t=s.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||i.nextTick(B,this),t},_.prototype.resume=function(){var e=this._readableState;return e.flowing||(o("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}(this,e)),e.paused=!1,this},_.prototype.pause=function(){return o("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(o("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},_.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",(function(){if(o("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(i){o("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i||(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))})),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var a=0;a{"use strict";e.exports=l;var n=r(9024).q,i=n.ERR_METHOD_NOT_IMPLEMENTED,o=n.ERR_MULTIPLE_CALLBACK,a=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=n.ERR_TRANSFORM_WITH_LENGTH_0,u=r(6884);function c(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length{"use strict";var n,i=r(9142);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(void 0),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}e.exports=_,_.WritableState=E;var a,s={deprecate:r(6219)},u=r(7144),c=r(9033).Buffer,l=r.g.Uint8Array||function(){},f=r(7572),h=r(6756).getHighWaterMark,d=r(9024).q,p=d.ERR_INVALID_ARG_TYPE,m=d.ERR_METHOD_NOT_IMPLEMENTED,y=d.ERR_MULTIPLE_CALLBACK,g=d.ERR_STREAM_CANNOT_PIPE,b=d.ERR_STREAM_DESTROYED,v=d.ERR_STREAM_NULL_VALUES,w=d.ERR_STREAM_WRITE_AFTER_END,A=d.ERR_UNKNOWN_ENCODING,S=f.errorOrDestroy;function k(){}function E(e,t,a){n=n||r(6884),e=e||{},"boolean"!=typeof a&&(a=t instanceof n),this.objectMode=!!e.objectMode,a&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=h(this,e,"writableHighWaterMark",a),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var s=!1===e.decodeStrings;this.decodeStrings=!s,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if("function"!=typeof o)throw new y;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,n,o){--t.pendingcb,r?(i.nextTick(o,n),i.nextTick(O,e,t),e._writableState.errorEmitted=!0,S(e,n)):(o(n),e._writableState.errorEmitted=!0,S(e,n),O(e,t))}(e,r,n,t,o);else{var a=P(r)||e.destroyed;a||r.corked||r.bufferProcessing||!r.bufferedRequest||x(e,r),n?i.nextTick(T,e,r,a,o):T(e,r,a,o)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function _(e){var t=this instanceof(n=n||r(6884));if(!t&&!a.call(_,this))return new _(e);this._writableState=new E(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),u.call(this)}function M(e,t,r,n,i,o,a){t.writelen=n,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new b("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function T(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),O(e,t)}function x(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),a=t.corkedRequestsFree;a.entry=r;for(var s=0,u=!0;r;)i[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;i.allBuffers=u,M(e,t,!0,t.length,i,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,l=r.encoding,f=r.callback;if(M(e,t,!1,t.objectMode?1:c.length,c,l,f),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function P(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function I(e,t){e._final((function(r){t.pendingcb--,r&&S(e,r),t.prefinished=!0,e.emit("prefinish"),O(e,t)}))}function O(e,t){var r=P(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,i.nextTick(I,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}r(1736)(_,u),E.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(E.prototype,"buffer",{get:s.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(a=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!a.call(this,e)||this===_&&e&&e._writableState instanceof E}})):a=function(e){return e instanceof this},_.prototype.pipe=function(){S(this,new g)},_.prototype.write=function(e,t,r){var n,o=this._writableState,a=!1,s=!o.objectMode&&(n=e,c.isBuffer(n)||n instanceof l);return s&&!c.isBuffer(e)&&(e=function(e){return c.from(e)}(e)),"function"==typeof t&&(r=t,t=null),s?t="buffer":t||(t=o.defaultEncoding),"function"!=typeof r&&(r=k),o.ending?function(e,t){var r=new w;S(e,r),i.nextTick(t,r)}(this,r):(s||function(e,t,r,n){var o;return null===r?o=new v:"string"==typeof r||t.objectMode||(o=new p("chunk",["string","Buffer"],r)),!o||(S(e,o),i.nextTick(n,o),!1)}(this,o,e,r))&&(o.pendingcb++,a=function(e,t,r,n,i,o){if(!r){var a=function(e,t,r){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=c.from(t,r)),t}(t,n,i);n!==a&&(r=!0,i="buffer",n=a)}var s=t.objectMode?1:n.length;t.length+=s;var u=t.length-1))throw new A(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(_.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,r){r(new m("_write()"))},_.prototype._writev=null,_.prototype.end=function(e,t,r){var n=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||function(e,t,r){t.ending=!0,O(e,t),r&&(t.finished?i.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}(this,n,r),this},Object.defineProperty(_.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(_.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=f.destroy,_.prototype._undestroy=f.undestroy,_.prototype._destroy=function(e,t){t(e)}},2317:(e,t,r)=>{"use strict";var n,i=r(9142);function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var a=r(5831),s=Symbol("lastResolve"),u=Symbol("lastReject"),c=Symbol("error"),l=Symbol("ended"),f=Symbol("lastPromise"),h=Symbol("handlePromise"),d=Symbol("stream");function p(e,t){return{value:e,done:t}}function m(e){var t=e[s];if(null!==t){var r=e[d].read();null!==r&&(e[f]=null,e[s]=null,e[u]=null,t(p(r,!1)))}}function y(e){i.nextTick(m,e)}var g=Object.getPrototypeOf((function(){})),b=Object.setPrototypeOf((o(n={get stream(){return this[d]},next:function(){var e=this,t=this[c];if(null!==t)return Promise.reject(t);if(this[l])return Promise.resolve(p(void 0,!0));if(this[d].destroyed)return new Promise((function(t,r){i.nextTick((function(){e[c]?r(e[c]):t(p(void 0,!0))}))}));var r,n=this[f];if(n)r=new Promise(function(e,t){return function(r,n){e.then((function(){t[l]?r(p(void 0,!0)):t[h](r,n)}),n)}}(n,this));else{var o=this[d].read();if(null!==o)return Promise.resolve(p(o,!1));r=new Promise(this[h])}return this[f]=r,r}},Symbol.asyncIterator,(function(){return this})),o(n,"return",(function(){var e=this;return new Promise((function(t,r){e[d].destroy(null,(function(e){e?r(e):t(p(void 0,!0))}))}))})),n),g);e.exports=function(e){var t,r=Object.create(b,(o(t={},d,{value:e,writable:!0}),o(t,s,{value:null,writable:!0}),o(t,u,{value:null,writable:!0}),o(t,c,{value:null,writable:!0}),o(t,l,{value:e._readableState.endEmitted,writable:!0}),o(t,h,{value:function(e,t){var n=r[d].read();n?(r[f]=null,r[s]=null,r[u]=null,e(p(n,!1))):(r[s]=e,r[u]=t)},writable:!0}),t));return r[f]=null,a(e,(function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[u];return null!==t&&(r[f]=null,r[s]=null,r[u]=null,t(e)),void(r[c]=e)}var n=r[s];null!==n&&(r[f]=null,r[s]=null,r[u]=null,n(p(void 0,!0))),r[l]=!0})),e.on("readable",y.bind(null,r)),r}},5392:(e,t,r)=>{"use strict";function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var o=r(9033).Buffer,a=r(2361).inspect,s=a&&a.custom||"inspect";e.exports=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.head=null,this.tail=null,this.length=0}var t;return t=[{key:"push",value:function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return o.alloc(0);for(var t,r,n,i=o.allocUnsafe(e>>>0),a=this.head,s=0;a;)t=a.data,r=i,n=s,o.prototype.copy.call(t,r,n),s+=a.data.length,a=a.next;return i}},{key:"consume",value:function(e,t){var r;return ei.length?i.length:e;if(o===i.length?n+=i:n+=i.slice(0,e),0==(e-=o)){o===i.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(e){var t=o.allocUnsafe(e),r=this.head,n=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var i=r.data,a=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,a),0==(e-=a)){a===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(a));break}++n}return this.length-=n,t}},{key:s,value:function(e,t){return a(this,function(e){for(var t=1;t{"use strict";var n=r(9142);function i(e,t){a(e,t),o(e)}function o(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function a(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,s=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return s||u?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,n.nextTick(a,this,e)):n.nextTick(a,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!t&&e?r._writableState?r._writableState.errorEmitted?n.nextTick(o,r):(r._writableState.errorEmitted=!0,n.nextTick(i,r,e)):n.nextTick(i,r,e):t?(n.nextTick(o,r),t(e)):n.nextTick(o,r)})),this)},undestroy:function(){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)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}},5831:(e,t,r)=>{"use strict";var n=r(9024).q.ERR_STREAM_PREMATURE_CLOSE;function i(){}e.exports=function e(t,r,o){if("function"==typeof r)return e(t,null,r);r||(r={}),o=function(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i{"use strict";e.exports=function(){throw new Error("Readable.from is not available in the browser")}},384:(e,t,r)=>{"use strict";var n,i=r(9024).q,o=i.ERR_MISSING_ARGS,a=i.ERR_STREAM_DESTROYED;function s(e){if(e)throw e}function u(e,t,i,o){o=function(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}(o);var s=!1;e.on("close",(function(){s=!0})),void 0===n&&(n=r(5831)),n(e,{readable:t,writable:i},(function(e){if(e)return o(e);s=!0,o()}));var u=!1;return function(t){if(!s&&!u)return u=!0,function(e){return e.setHeader&&"function"==typeof e.abort}(e)?e.abort():"function"==typeof e.destroy?e.destroy():void o(t||new a("pipe"))}}function c(e){e()}function l(e,t){return e.pipe(t)}function f(e){return e.length?"function"!=typeof e[e.length-1]?s:e.pop():s}e.exports=function(){for(var e=arguments.length,t=new Array(e),r=0;r0,(function(e){n||(n=e),e&&a.forEach(c),o||(a.forEach(c),i(n))}))}));return t.reduce(l)}},6756:(e,t,r)=>{"use strict";var n=r(9024).q.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,i){var o=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,i,r);if(null!=o){if(!isFinite(o)||Math.floor(o)!==o||o<0)throw new n(i?r:"highWaterMark",o);return Math.floor(o)}return e.objectMode?16:16384}}},7144:(e,t,r)=>{"use strict";e.exports=r(8291).EventEmitter},6505:(e,t,r)=>{"use strict";(t=e.exports=r(6297)).Stream=t,t.Readable=t,t.Writable=r(1471),t.Duplex=r(6884),t.Transform=r(9154),t.PassThrough=r(3582),t.finished=r(5831),t.pipeline=r(384)},6707:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(1736),o=r(2353),a=new Array(16),s=[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],u=[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],c=[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],l=[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],f=[0,1518500249,1859775393,2400959708,2840853838],h=[1352829926,1548603684,1836072691,2053994217,0];function d(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(e,t){return e<>>32-t}function m(e,t,r,n,i,o,a,s){return p(e+(t^r^n)+o+a|0,s)+i|0}function y(e,t,r,n,i,o,a,s){return p(e+(t&r|~t&n)+o+a|0,s)+i|0}function g(e,t,r,n,i,o,a,s){return p(e+((t|~r)^n)+o+a|0,s)+i|0}function b(e,t,r,n,i,o,a,s){return p(e+(t&n|r&~n)+o+a|0,s)+i|0}function v(e,t,r,n,i,o,a,s){return p(e+(t^(r|~n))+o+a|0,s)+i|0}i(d,o),d.prototype._update=function(){for(var e=a,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,A=0|this._b,S=0|this._c,k=0|this._d,E=0|this._e,_=0;_<80;_+=1){var M,T;_<16?(M=m(r,n,i,o,d,e[s[_]],f[0],c[_]),T=v(w,A,S,k,E,e[u[_]],h[0],l[_])):_<32?(M=y(r,n,i,o,d,e[s[_]],f[1],c[_]),T=b(w,A,S,k,E,e[u[_]],h[1],l[_])):_<48?(M=g(r,n,i,o,d,e[s[_]],f[2],c[_]),T=g(w,A,S,k,E,e[u[_]],h[2],l[_])):_<64?(M=b(r,n,i,o,d,e[s[_]],f[3],c[_]),T=y(w,A,S,k,E,e[u[_]],h[3],l[_])):(M=v(r,n,i,o,d,e[s[_]],f[4],c[_]),T=m(w,A,S,k,E,e[u[_]],h[4],l[_])),r=d,d=o,o=p(i,10),i=n,n=M,w=E,E=k,k=p(S,10),S=A,A=T}var x=this._b+i+k|0;this._b=this._c+o+E|0,this._c=this._d+d+w|0,this._d=this._e+r+A|0,this._e=this._a+n+S|0,this._a=x},d.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 e=n.alloc?n.alloc(20):new n(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=d},6905:(e,t,r)=>{"use strict";var n=r(9033).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.getLength=t.decode=t.encode=void 0;var i,o=(i=r(1734))&&i.__esModule?i:{default:i};function a(e,t){if("0"===e[0]&&"0"===e[1])throw new Error("invalid RLP: extra zeros");return parseInt(e,t)}function s(e,t){if(e<56)return n.from([e+t]);var r=l(e),i=l(t+55+r.length/2);return n.from(i+r,"hex")}function u(e){var t,r,i,o,s,c=[],l=e[0];if(l<=127)return{data:e.slice(0,1),remainder:e.slice(1)};if(l<=183){if(t=l-127,i=128===l?n.from([]):e.slice(1,t),2===t&&i[0]<128)throw new Error("invalid rlp encoding: byte must be less 0x80");return{data:i,remainder:e.slice(t)}}if(l<=191){if(r=l-182,e.length-1e.length)throw new Error("invalid rlp: total length is larger than the data");if(0===(o=e.slice(r,f)).length)throw new Error("invalid rlp, List has a invalid length");for(;o.length;)s=u(o),c.push(s.data),o=s.remainder;return{data:c,remainder:e.slice(f)}}function c(e){return"0x"===e.slice(0,2)}function l(e){if(e<0)throw new Error("Invalid integer as argument, must be unsigned!");var t=e.toString(16);return t.length%2?"0"+t:t}function f(e){if(!n.isBuffer(e)){if("string"==typeof e)return c(e)?n.from((r="string"!=typeof(i=e)?i:c(i)?i.slice(2):i).length%2?"0"+r:r,"hex"):n.from(e);if("number"==typeof e||"bigint"==typeof e)return e?(t=l(e),n.from(t,"hex")):n.from([]);if(null==e)return n.from([]);if(e instanceof Uint8Array)return n.from(e);if(o.default.isBN(e))return n.from(e.toArray());throw new Error("invalid type")}var t,r,i;return e}t.encode=function e(t){if(Array.isArray(t)){for(var r=[],i=0;i{"use strict";var n=r(9033),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=a),a.prototype=Object.create(i.prototype),o(i,a),a.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},1755:(e,t,r)=>{"use strict";var n,i=r(9142),o=r(8847)(r(3355)),a=r(9033),s=a.Buffer,u={};for(n in a)a.hasOwnProperty(n)&&"SlowBuffer"!==n&&"Buffer"!==n&&(u[n]=a[n]);var c=u.Buffer={};for(n in s)s.hasOwnProperty(n)&&"allocUnsafe"!==n&&"allocUnsafeSlow"!==n&&(c[n]=s[n]);if(u.Buffer.prototype=s.prototype,c.from&&c.from!==Uint8Array.from||(c.from=function(e,t,r){if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type '+(0,o.default)(e));if(e&&void 0===e.length)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+(0,o.default)(e));return s(e,t,r)}),c.alloc||(c.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError('The "size" argument must be of type number. Received type '+(0,o.default)(e));if(e<0||e>=2*(1<<30))throw new RangeError('The value "'+e+'" is invalid for option "size"');var n=s(e);return t&&0!==t.length?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n}),!u.kStringMaxLength)try{u.kStringMaxLength=i.binding("buffer").kStringMaxLength}catch(e){}u.constants||(u.constants={MAX_LENGTH:u.kMaxLength},u.kStringMaxLength&&(u.constants.MAX_STRING_LENGTH=u.kStringMaxLength)),e.exports=u},7799:e=>{"use strict";!function(t){var r=2147483647;function n(e){var t=new Uint32Array([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]),r=1779033703,n=3144134277,i=1013904242,o=2773480762,a=1359893119,s=2600822924,u=528734635,c=1541459225,l=new Uint32Array(64);function f(e){for(var f=0,h=e.length;h>=64;){var d=r,p=n,m=i,y=o,g=a,b=s,v=u,w=c,A=void 0,S=void 0,k=void 0,E=void 0,_=void 0;for(S=0;S<16;S++)k=f+4*S,l[S]=(255&e[k])<<24|(255&e[k+1])<<16|(255&e[k+2])<<8|255&e[k+3];for(S=16;S<64;S++)E=((A=l[S-2])>>>17|A<<15)^(A>>>19|A<<13)^A>>>10,_=((A=l[S-15])>>>7|A<<25)^(A>>>18|A<<14)^A>>>3,l[S]=(E+l[S-7]|0)+(_+l[S-16]|0)|0;for(S=0;S<64;S++)E=(((g>>>6|g<<26)^(g>>>11|g<<21)^(g>>>25|g<<7))+(g&b^~g&v)|0)+(w+(t[S]+l[S]|0)|0)|0,_=((d>>>2|d<<30)^(d>>>13|d<<19)^(d>>>22|d<<10))+(d&p^d&m^p&m)|0,w=v,v=b,b=g,g=y+E|0,y=m,m=p,p=d,d=E+_|0;r=r+d|0,n=n+p|0,i=i+m|0,o=o+y|0,a=a+g|0,s=s+b|0,u=u+v|0,c=c+w|0,f+=64,h-=64}}f(e);var h,d=e.length%64,p=e.length/536870912|0,m=e.length<<3,y=d<56?56:120,g=e.slice(e.length-d,e.length);for(g.push(128),h=d+1;h>>24&255),g.push(p>>>16&255),g.push(p>>>8&255),g.push(p>>>0&255),g.push(m>>>24&255),g.push(m>>>16&255),g.push(m>>>8&255),g.push(m>>>0&255),f(g),[r>>>24&255,r>>>16&255,r>>>8&255,r>>>0&255,n>>>24&255,n>>>16&255,n>>>8&255,n>>>0&255,i>>>24&255,i>>>16&255,i>>>8&255,i>>>0&255,o>>>24&255,o>>>16&255,o>>>8&255,o>>>0&255,a>>>24&255,a>>>16&255,a>>>8&255,a>>>0&255,s>>>24&255,s>>>16&255,s>>>8&255,s>>>0&255,u>>>24&255,u>>>16&255,u>>>8&255,u>>>0&255,c>>>24&255,c>>>16&255,c>>>8&255,c>>>0&255]}function i(e,t,r){e=e.length<=64?e:n(e);var i,o=64+t.length+4,a=new Array(o),s=new Array(64),u=[];for(i=0;i<64;i++)a[i]=54;for(i=0;i=o-4;e--){if(a[e]++,a[e]<=255)return;a[e]=0}}for(;r>=32;)c(),u=u.concat(n(s.concat(n(a)))),r-=32;return r>0&&(c(),u=u.concat(n(s.concat(n(a))).slice(0,r))),u}function o(e,t,r,n,i){var o;for(c(e,16*(2*r-1),i,0,16),o=0;o<2*r;o++)u(e,16*o,i,16),s(i,n),c(i,0,e,t+16*o,16);for(o=0;o>>32-t}function s(e,t){c(e,0,t,0,16);for(var r=8;r>0;r-=2)t[4]^=a(t[0]+t[12],7),t[8]^=a(t[4]+t[0],9),t[12]^=a(t[8]+t[4],13),t[0]^=a(t[12]+t[8],18),t[9]^=a(t[5]+t[1],7),t[13]^=a(t[9]+t[5],9),t[1]^=a(t[13]+t[9],13),t[5]^=a(t[1]+t[13],18),t[14]^=a(t[10]+t[6],7),t[2]^=a(t[14]+t[10],9),t[6]^=a(t[2]+t[14],13),t[10]^=a(t[6]+t[2],18),t[3]^=a(t[15]+t[11],7),t[7]^=a(t[3]+t[15],9),t[11]^=a(t[7]+t[3],13),t[15]^=a(t[11]+t[7],18),t[1]^=a(t[0]+t[3],7),t[2]^=a(t[1]+t[0],9),t[3]^=a(t[2]+t[1],13),t[0]^=a(t[3]+t[2],18),t[6]^=a(t[5]+t[4],7),t[7]^=a(t[6]+t[5],9),t[4]^=a(t[7]+t[6],13),t[5]^=a(t[4]+t[7],18),t[11]^=a(t[10]+t[9],7),t[8]^=a(t[11]+t[10],9),t[9]^=a(t[8]+t[11],13),t[10]^=a(t[9]+t[8],18),t[12]^=a(t[15]+t[14],7),t[13]^=a(t[12]+t[15],9),t[14]^=a(t[13]+t[12],13),t[15]^=a(t[14]+t[13],18);for(var n=0;n<16;++n)e[n]+=t[n]}function u(e,t,r,n){for(var i=0;i=256)return!1}return!0}function f(e,t){if("number"!=typeof e||e%1)throw new Error("invalid "+t);return e}function h(e,t,n,a,s,h,d){if(n=f(n,"N"),a=f(a,"r"),s=f(s,"p"),h=f(h,"dkLen"),0===n||0!=(n&n-1))throw new Error("N must be power of 2");if(n>r/128/a)throw new Error("N too large");if(a>r/128/s)throw new Error("r too large");if(!l(e))throw new Error("password must be an array or buffer");if(e=Array.prototype.slice.call(e),!l(t))throw new Error("salt must be an array or buffer");t=Array.prototype.slice.call(t);for(var p=i(e,t,128*s*a),m=new Uint32Array(32*s*a),y=0;yO&&(r=O);for(var l=0;lO&&(r=O);for(var y=0;y>0&255),p.push(m[B]>>8&255),p.push(m[B]>>16&255),p.push(m[B]>>24&255);var N=i(e,p,h);return d&&d(null,1,N),N}d&&R(t)};if(!d)for(;;){var B=C();if(null!=B)return B}C()}var d={scrypt:function(e,t,r,n,i,o,a){return new Promise((function(s,u){var c=0;a&&a(0),h(e,t,r,n,i,o,(function(e,t,r){if(e)u(e);else if(r)a&&1!==c&&a(1),s(new Uint8Array(r));else if(a&&t!==c)return c=t,a(t)}))}))},syncScrypt:function(e,t,r,n,i,o){return new Uint8Array(h(e,t,r,n,i,o))}};e.exports=d}()},7902:(e,t,r)=>{"use strict";e.exports=r(6922)(r(8123))},8123:(e,t,r)=>{"use strict";var n=new(0,r(6597).ec)("secp256k1"),i=n.curve,o=i.n.constructor;function a(e){var t=e[0];switch(t){case 2:case 3:return 33!==e.length?null:function(e,t){var r=new o(t);if(r.cmp(i.p)>=0)return null;var a=(r=r.toRed(i.red)).redSqr().redIMul(r).redIAdd(i.b).redSqrt();return 3===e!==a.isOdd()&&(a=a.redNeg()),n.keyPair({pub:{x:r,y:a}})}(t,e.subarray(1,33));case 4:case 6:case 7:return 65!==e.length?null:function(e,t,r){var a=new o(t),s=new o(r);if(a.cmp(i.p)>=0||s.cmp(i.p)>=0)return null;if(a=a.toRed(i.red),s=s.toRed(i.red),(6===e||7===e)&&s.isOdd()!==(7===e))return null;var u=a.redSqr().redIMul(a);return s.redSqr().redISub(u.redIAdd(i.b)).isZero()?n.keyPair({pub:{x:a,y:s}}):null}(t,e.subarray(1,33),e.subarray(33,65));default:return null}}function s(e,t){for(var r=t.encode(null,33===e.length),n=0;n=0)return 1;if(r.iadd(new o(e)),r.cmp(i.n)>=0&&r.isub(i.n),r.isZero())return 1;var n=r.toArrayLike(Uint8Array,"be",32);return e.set(n),0},privateKeyTweakMul:function(e,t){var r=new o(t);if(r.cmp(i.n)>=0||r.isZero())return 1;r.imul(new o(e)),r.cmp(i.n)>=0&&(r=r.umod(i.n));var n=r.toArrayLike(Uint8Array,"be",32);return e.set(n),0},publicKeyVerify:function(e){return null===a(e)?1:0},publicKeyCreate:function(e,t){var r=new o(t);return r.cmp(i.n)>=0||r.isZero()?1:(s(e,n.keyFromPrivate(t).getPublic()),0)},publicKeyConvert:function(e,t){var r=a(t);return null===r?1:(s(e,r.getPublic()),0)},publicKeyNegate:function(e,t){var r=a(t);if(null===r)return 1;var n=r.getPublic();return n.y=n.y.redNeg(),s(e,n),0},publicKeyCombine:function(e,t){for(var r=new Array(t.length),n=0;n=0)return 2;var u=n.getPublic().add(i.g.mul(r));return u.isInfinity()?2:(s(e,u),0)},publicKeyTweakMul:function(e,t,r){var n=a(t);return null===n?1:(r=new o(r)).cmp(i.n)>=0||r.isZero()?2:(s(e,n.getPublic().mul(r)),0)},signatureNormalize:function(e){var t=new o(e.subarray(0,32)),r=new o(e.subarray(32,64));return t.cmp(i.n)>=0||r.cmp(i.n)>=0?1:(1===r.cmp(n.nh)&&e.set(i.n.sub(r).toArrayLike(Uint8Array,"be",32),32),0)},signatureExport:function(e,t){var r=t.subarray(0,32),n=t.subarray(32,64);if(new o(r).cmp(i.n)>=0)return 1;if(new o(n).cmp(i.n)>=0)return 1;var a=e.output,s=a.subarray(4,37);s[0]=0,s.set(r,1);for(var u=33,c=0;u>1&&0===s[c]&&!(128&s[c+1]);--u,++c);if(128&(s=s.subarray(c))[0])return 1;if(u>1&&0===s[0]&&!(128&s[1]))return 1;var l=a.subarray(39,72);l[0]=0,l.set(n,1);for(var f=33,h=0;f>1&&0===l[h]&&!(128&l[h+1]);--f,++h);return 128&(l=l.subarray(h))[0]||f>1&&0===l[0]&&!(128&l[1])?1:(e.outputlen=6+u+f,a[0]=48,a[1]=e.outputlen-2,a[2]=2,a[3]=s.length,a.set(s,4),a[4+u]=2,a[5+u]=l.length,a.set(l,6+u),0)},signatureImport:function(e,t){if(t.length<8)return 1;if(t.length>72)return 1;if(48!==t[0])return 1;if(t[1]!==t.length-2)return 1;if(2!==t[2])return 1;var r=t[3];if(0===r)return 1;if(5+r>=t.length)return 1;if(2!==t[4+r])return 1;var n=t[5+r];if(0===n)return 1;if(6+r+n!==t.length)return 1;if(128&t[4])return 1;if(r>1&&0===t[4]&&!(128&t[5]))return 1;if(128&t[r+6])return 1;if(n>1&&0===t[r+6]&&!(128&t[r+7]))return 1;var a=t.subarray(4,4+r);if(33===a.length&&0===a[0]&&(a=a.subarray(1)),a.length>32)return 1;var s=t.subarray(6+r);if(33===s.length&&0===s[0]&&(s=s.slice(1)),s.length>32)throw new Error("S length is too long");var u=new o(a);u.cmp(i.n)>=0&&(u=new o(0));var c=new o(t.subarray(6+r));return c.cmp(i.n)>=0&&(c=new o(0)),e.set(u.toArrayLike(Uint8Array,"be",32),0),e.set(c.toArrayLike(Uint8Array,"be",32),32),0},ecdsaSign:function(e,t,r,a,s){if(s){var u=s;s=function(e){var n=u(t,r,null,a,e);if(!(n instanceof Uint8Array&&32===n.length))throw new Error("This is the way");return new o(n)}}var c,l=new o(r);if(l.cmp(i.n)>=0||l.isZero())return 1;try{c=n.sign(t,r,{canonical:!0,k:s,pers:a})}catch(e){return 1}return e.signature.set(c.r.toArrayLike(Uint8Array,"be",32),0),e.signature.set(c.s.toArrayLike(Uint8Array,"be",32),32),e.recid=c.recoveryParam,0},ecdsaVerify:function(e,t,r){var s={r:e.subarray(0,32),s:e.subarray(32,64)},u=new o(s.r),c=new o(s.s);if(u.cmp(i.n)>=0||c.cmp(i.n)>=0)return 1;if(1===c.cmp(n.nh)||u.isZero()||c.isZero())return 3;var l=a(r);if(null===l)return 2;var f=l.getPublic();return n.verify(t,s,f)?0:3},ecdsaRecover:function(e,t,r,a){var u,c={r:t.slice(0,32),s:t.slice(32,64)},l=new o(c.r),f=new o(c.s);if(l.cmp(i.n)>=0||f.cmp(i.n)>=0)return 1;if(l.isZero()||f.isZero())return 2;try{u=n.recoverPubKey(a,c,r)}catch(e){return 2}return s(e,u),0},ecdh:function(e,t,r,s,u,c,l){var f=a(t);if(null===f)return 1;var h=new o(r);if(h.cmp(i.n)>=0||h.isZero())return 2;var d=f.getPublic().mul(h);if(void 0===u)for(var p=d.encode(null,!0),m=n.hash().update(p).digest(),y=0;y<32;++y)e[y]=m[y];else{c||(c=new Uint8Array(32));for(var g=d.getX().toArray("be",32),b=0;b<32;++b)c[b]=g[b];l||(l=new Uint8Array(32));for(var v=d.getY().toArray("be",32),w=0;w<32;++w)l[w]=v[w];var A=u(c,l,s);if(!(A instanceof Uint8Array&&A.length===e.length))return 2;e.set(A)}return 0}}},6922:e=>{"use strict";function t(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){u=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&void 0!==arguments[0]?arguments[0]:function(e){return new Uint8Array(e)},t=arguments.length>1?arguments[1]:void 0;return"function"==typeof e&&(e=e(t)),m("output",e,t),e}function b(e){return Object.prototype.toString.call(e).slice(8,-1)}e.exports=function(e){return{contextRandomize:function(t){if(p(null===t||t instanceof Uint8Array,"Expected seed to be an Uint8Array or null"),null!==t&&m("seed",t,32),1===e.contextRandomize(t))throw new Error("Unknow error on context randomization")},privateKeyVerify:function(t){return m("private key",t,32),0===e.privateKeyVerify(t)},privateKeyNegate:function(t){switch(m("private key",t,32),e.privateKeyNegate(t)){case 0:return t;case 1:throw new Error(n)}},privateKeyTweakAdd:function(t,r){switch(m("private key",t,32),m("tweak",r,32),e.privateKeyTweakAdd(t,r)){case 0:return t;case 1:throw new Error(i)}},privateKeyTweakMul:function(t,r){switch(m("private key",t,32),m("tweak",r,32),e.privateKeyTweakMul(t,r)){case 0:return t;case 1:throw new Error(o)}},publicKeyVerify:function(t){return m("public key",t,[33,65]),0===e.publicKeyVerify(t)},publicKeyCreate:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2?arguments[2]:void 0;switch(m("private key",t,32),y(r),n=g(n,r?33:65),e.publicKeyCreate(n,t)){case 0:return n;case 1:throw new Error(a);case 2:throw new Error(u)}},publicKeyConvert:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2?arguments[2]:void 0;switch(m("public key",t,[33,65]),y(r),n=g(n,r?33:65),e.publicKeyConvert(n,t)){case 0:return n;case 1:throw new Error(s);case 2:throw new Error(u)}},publicKeyNegate:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0;switch(m("public key",t,[33,65]),y(r),i=g(i,r?33:65),e.publicKeyNegate(i,t)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(n);case 3:throw new Error(u)}},publicKeyCombine:function(r){var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0;p(Array.isArray(r),"Expected public keys to be an Array"),p(r.length>0,"Expected public keys array will have more than zero items");var o,a=t(r);try{for(a.s();!(o=a.n()).done;){var l=o.value;m("public key",l,[33,65])}}catch(e){a.e(e)}finally{a.f()}switch(y(n),i=g(i,n?33:65),e.publicKeyCombine(i,r)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(c);case 3:throw new Error(u)}},publicKeyTweakAdd:function(t,r){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],o=arguments.length>3?arguments[3]:void 0;switch(m("public key",t,[33,65]),m("tweak",r,32),y(n),o=g(o,n?33:65),e.publicKeyTweakAdd(o,t,r)){case 0:return o;case 1:throw new Error(s);case 2:throw new Error(i)}},publicKeyTweakMul:function(t,r){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3?arguments[3]:void 0;switch(m("public key",t,[33,65]),m("tweak",r,32),y(n),i=g(i,n?33:65),e.publicKeyTweakMul(i,t,r)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(o)}},signatureNormalize:function(t){switch(m("signature",t,64),e.signatureNormalize(t)){case 0:return t;case 1:throw new Error(l)}},signatureExport:function(t,r){m("signature",t,64);var i={output:r=g(r,72),outputlen:72};switch(e.signatureExport(i,t)){case 0:return r.slice(0,i.outputlen);case 1:throw new Error(l);case 2:throw new Error(n)}},signatureImport:function(t,r){switch(m("signature",t),r=g(r,64),e.signatureImport(r,t)){case 0:return r;case 1:throw new Error(l);case 2:throw new Error(n)}},ecdsaSign:function(t,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=arguments.length>3?arguments[3]:void 0;m("message",t,32),m("private key",r,32),p("Object"===b(i),"Expected options to be an Object"),void 0!==i.data&&m("options.data",i.data),void 0!==i.noncefn&&p("Function"===b(i.noncefn),"Expected options.noncefn to be a Function");var a={signature:o=g(o,64),recid:null};switch(e.ecdsaSign(a,t,r,i.data,i.noncefn)){case 0:return a;case 1:throw new Error(f);case 2:throw new Error(n)}},ecdsaVerify:function(t,r,n){switch(m("signature",t,64),m("message",r,32),m("public key",n,[33,65]),e.ecdsaVerify(t,r,n)){case 0:return!0;case 3:return!1;case 1:throw new Error(l);case 2:throw new Error(s)}},ecdsaRecover:function(t,r,i){var o=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=arguments.length>4?arguments[4]:void 0;switch(m("signature",t,64),p("Number"===b(r)&&r>=0&&r<=3,"Expected recovery id to be a Number within interval [0, 3]"),m("message",i,32),y(o),a=g(a,o?33:65),e.ecdsaRecover(a,t,r,i)){case 0:return a;case 1:throw new Error(l);case 2:throw new Error(h);case 3:throw new Error(n)}},ecdh:function(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3?arguments[3]:void 0;switch(m("public key",t,[33,65]),m("private key",r,32),p("Object"===b(n),"Expected options to be an Object"),void 0!==n.data&&m("options.data",n.data),void 0!==n.hashfn?(p("Function"===b(n.hashfn),"Expected options.hashfn to be a Function"),void 0!==n.xbuf&&m("options.xbuf",n.xbuf,32),void 0!==n.ybuf&&m("options.ybuf",n.ybuf,32),m("output",i)):i=g(i,32),e.ecdh(i,t,r,n.data,n.hashfn,n.xbuf,n.ybuf)){case 0:return i;case 1:throw new Error(s);case 2:throw new Error(d)}}}}},6003:(e,t,r)=>{"use strict";var n=r(8850).Buffer;function i(e,t){this._block=n.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}i.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=n.from(e,t));for(var r=this._block,i=this._blockSize,o=e.length,a=this._len,s=0;s=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},1708:(e,t,r)=>{"use strict";var n=e.exports=function(e){e=e.toLowerCase();var t=n[e];if(!t)throw new Error(e+" is not supported (we accept pull requests)");return new t};n.sha=r(8210),n.sha1=r(544),n.sha224=r(6288),n.sha256=r(4571),n.sha384=r(6959),n.sha512=r(4515)},8210:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<30|e>>>2}function l(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,f=0;f<16;++f)r[f]=e.readInt32BE(4*f);for(;f<80;++f)r[f]=r[f-3]^r[f-8]^r[f-14]^r[f-16];for(var h=0;h<80;++h){var d=~~(h/20),p=0|((t=n)<<5|t>>>27)+l(d,i,o,s)+u+r[h]+a[d];u=s,s=o,o=c(i),i=n,n=p}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},544:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e){return e<<5|e>>>27}function l(e){return e<<30|e>>>2}function f(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,h=0;h<16;++h)r[h]=e.readInt32BE(4*h);for(;h<80;++h)r[h]=(t=r[h-3]^r[h-8]^r[h-14]^r[h-16])<<1|t>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=c(n)+f(p,i,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=l(i),i=n,n=m}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=u},6288:(e,t,r)=>{"use strict";var n=r(1736),i=r(4571),o=r(6003),a=r(8850).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}n(u,i),u.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=u},4571:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[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],s=new Array(64);function u(){this.init(),this._w=s,i.call(this,64,56)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function h(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function d(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}n(u,i),u.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},u.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,y=0|this._h,g=0;g<16;++g)r[g]=e.readInt32BE(4*g);for(;g<64;++g)r[g]=0|(((t=r[g-2])>>>17|t<<15)^(t>>>19|t<<13)^t>>>10)+r[g-7]+d(r[g-15])+r[g-16];for(var b=0;b<64;++b){var v=y+h(u)+c(u,p,m)+a[b]+r[b]|0,w=f(n)+l(n,i,o)|0;y=m,m=p,p=u,u=s+v|0,s=o,o=i,i=n,n=v+w|0}this._a=n+this._a|0,this._b=i+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=y+this._h|0},u.prototype._hash=function(){var e=o.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=u},6959:(e,t,r)=>{"use strict";var n=r(1736),i=r(4515),o=r(6003),a=r(8850).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}n(u,i),u.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},u.prototype._hash=function(){var e=a.allocUnsafe(48);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e},e.exports=u},4515:(e,t,r)=>{"use strict";var n=r(1736),i=r(6003),o=r(8850).Buffer,a=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],s=new Array(160);function u(){this.init(),this._w=s,i.call(this,128,112)}function c(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function h(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function d(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function p(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function y(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function g(e,t){return e>>>0>>0?1:0}n(u,i),u.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},u.prototype._update=function(e){for(var t=this._w,r=0|this._ah,n=0|this._bh,i=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,b=0|this._gh,v=0|this._hh,w=0|this._al,A=0|this._bl,S=0|this._cl,k=0|this._dl,E=0|this._el,_=0|this._fl,M=0|this._gl,T=0|this._hl,x=0;x<32;x+=2)t[x]=e.readInt32BE(4*x),t[x+1]=e.readInt32BE(4*x+4);for(;x<160;x+=2){var P=t[x-30],I=t[x-30+1],O=d(P,I),R=p(I,P),C=m(P=t[x-4],I=t[x-4+1]),B=y(I,P),N=t[x-14],L=t[x-14+1],U=t[x-32],F=t[x-32+1],D=R+L|0,j=O+N+g(D,R)|0;j=(j=j+C+g(D=D+B|0,B)|0)+U+g(D=D+F|0,F)|0,t[x]=j,t[x+1]=D}for(var H=0;H<160;H+=2){j=t[H],D=t[H+1];var J=l(r,n,i),z=l(w,A,S),G=f(r,w),q=f(w,r),K=h(s,E),V=h(E,s),X=a[H],Q=a[H+1],W=c(s,u,b),Z=c(E,_,M),Y=T+V|0,$=v+K+g(Y,T)|0;$=($=($=$+W+g(Y=Y+Z|0,Z)|0)+X+g(Y=Y+Q|0,Q)|0)+j+g(Y=Y+D|0,D)|0;var ee=q+z|0,te=G+J+g(ee,q)|0;v=b,T=M,b=u,M=_,u=s,_=E,s=o+$+g(E=k+Y|0,k)|0,o=i,k=S,i=n,S=A,n=r,A=w,r=$+te+g(w=Y+ee|0,Y)|0}this._al=this._al+w|0,this._bl=this._bl+A|0,this._cl=this._cl+S|0,this._dl=this._dl+k|0,this._el=this._el+E|0,this._fl=this._fl+_|0,this._gl=this._gl+M|0,this._hl=this._hl+T|0,this._ah=this._ah+r+g(this._al,w)|0,this._bh=this._bh+n+g(this._bl,A)|0,this._ch=this._ch+i+g(this._cl,S)|0,this._dh=this._dh+o+g(this._dl,k)|0,this._eh=this._eh+s+g(this._el,E)|0,this._fh=this._fh+u+g(this._fl,_)|0,this._gh=this._gh+b+g(this._gl,M)|0,this._hh=this._hh+v+g(this._hl,T)|0},u.prototype._hash=function(){var e=o.allocUnsafe(64);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=u},7245:(e,t,r)=>{"use strict";e.exports=i;var n=r(8291).EventEmitter;function i(){n.call(this)}r(1736)(i,n),i.Readable=r(6297),i.Writable=r(1471),i.Duplex=r(6884),i.Transform=r(9154),i.PassThrough=r(3582),i.finished=r(5831),i.pipeline=r(384),i.Stream=i,i.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",i),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",s),r.on("close",u));var a=!1;function s(){a||(a=!0,e.end())}function u(){a||(a=!0,"function"==typeof e.destroy&&e.destroy())}function c(e){if(l(),0===n.listenerCount(this,"error"))throw e}function l(){r.removeListener("data",i),e.removeListener("drain",o),r.removeListener("end",s),r.removeListener("close",u),r.removeListener("error",c),e.removeListener("error",c),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return r.on("error",c),e.on("error",c),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e}},9519:(e,t,r)=>{"use strict";var n=r(8844),i=r(3319),o=r(7705),a=r(3675),s=r(1143),u=t;u.request=function(e,t){e="string"==typeof e?s.parse(e):o(e);var i=-1===r.g.location.protocol.search(/^https?:$/)?"http:":"",a=e.protocol||i,u=e.hostname||e.host,c=e.port,l=e.path||"/";u&&-1!==u.indexOf(":")&&(u="["+u+"]"),e.url=(u?a+"//"+u:"")+(c?":"+c:"")+l,e.method=(e.method||"GET").toUpperCase(),e.headers=e.headers||{};var f=new n(e);return t&&f.on("response",t),f},u.get=function(e,t){var r=u.request(e,t);return r.end(),r},u.ClientRequest=n,u.IncomingMessage=i.IncomingMessage,u.Agent=function(){},u.Agent.defaultMaxSockets=4,u.globalAgent=new u.Agent,u.STATUS_CODES=a,u.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]},3928:(e,t,r)=>{"use strict";var n;function i(){if(void 0!==n)return n;if(r.g.XMLHttpRequest){n=new r.g.XMLHttpRequest;try{n.open("GET",r.g.XDomainRequest?"/":"https://example.com")}catch(e){n=null}}else n=null;return n}function o(e){var t=i();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}function a(e){return"function"==typeof e}t.fetch=a(r.g.fetch)&&a(r.g.ReadableStream),t.writableStream=a(r.g.WritableStream),t.abortController=a(r.g.AbortController),t.arraybuffer=t.fetch||o("arraybuffer"),t.msstream=!t.fetch&&o("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&o("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!i()&&a(i().overrideMimeType),n=null},8844:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(9142),o=r(3928),a=r(1736),s=r(3319),u=r(6505),c=s.IncomingMessage,l=s.readyStates,f=e.exports=function(e){var t,r=this;u.Writable.call(r),r._opts=e,r._body=[],r._headers={},e.auth&&r.setHeader("Authorization","Basic "+n.from(e.auth).toString("base64")),Object.keys(e.headers).forEach((function(t){r.setHeader(t,e.headers[t])}));var i=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!o.abortController)i=!1,t=!0;else if("prefer-streaming"===e.mode)t=!1;else if("allow-wrong-content-type"===e.mode)t=!o.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");t=!0}r._mode=function(e,t){return o.fetch&&t?"fetch":o.mozchunkedarraybuffer?"moz-chunked-arraybuffer":o.msstream?"ms-stream":o.arraybuffer&&e?"arraybuffer":"text"}(t,i),r._fetchTimer=null,r._socketTimeout=null,r._socketTimer=null,r.on("finish",(function(){r._onFinish()}))};a(f,u.Writable),f.prototype.setHeader=function(e,t){var r=e.toLowerCase();-1===h.indexOf(r)&&(this._headers[r]={name:e,value:t})},f.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},f.prototype.removeHeader=function(e){delete this._headers[e.toLowerCase()]},f.prototype._onFinish=function(){var e=this;if(!e._destroyed){var t=e._opts;"timeout"in t&&0!==t.timeout&&e.setTimeout(t.timeout);var n=e._headers,a=null;"GET"!==t.method&&"HEAD"!==t.method&&(a=new Blob(e._body,{type:(n["content-type"]||{}).value||""}));var s=[];if(Object.keys(n).forEach((function(e){var t=n[e].name,r=n[e].value;Array.isArray(r)?r.forEach((function(e){s.push([t,e])})):s.push([t,r])})),"fetch"===e._mode){var u=null;if(o.abortController){var c=new AbortController;u=c.signal,e._fetchAbortController=c,"requestTimeout"in t&&0!==t.requestTimeout&&(e._fetchTimer=r.g.setTimeout((function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()}),t.requestTimeout))}r.g.fetch(e._opts.url,{method:e._opts.method,headers:s,body:a||void 0,mode:"cors",credentials:t.withCredentials?"include":"same-origin",signal:u}).then((function(t){e._fetchResponse=t,e._resetTimers(!1),e._connect()}),(function(t){e._resetTimers(!0),e._destroyed||e.emit("error",t)}))}else{var f=e._xhr=new r.g.XMLHttpRequest;try{f.open(e._opts.method,e._opts.url,!0)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}"responseType"in f&&(f.responseType=e._mode),"withCredentials"in f&&(f.withCredentials=!!t.withCredentials),"text"===e._mode&&"overrideMimeType"in f&&f.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in t&&(f.timeout=t.requestTimeout,f.ontimeout=function(){e.emit("requestTimeout")}),s.forEach((function(e){f.setRequestHeader(e[0],e[1])})),e._response=null,f.onreadystatechange=function(){switch(f.readyState){case l.LOADING:case l.DONE:e._onXHRProgress()}},"moz-chunked-arraybuffer"===e._mode&&(f.onprogress=function(){e._onXHRProgress()}),f.onerror=function(){e._destroyed||(e._resetTimers(!0),e.emit("error",new Error("XHR error")))};try{f.send(a)}catch(t){return void i.nextTick((function(){e.emit("error",t)}))}}}},f.prototype._onXHRProgress=function(){var e=this;e._resetTimers(!1),function(e){try{var t=e.status;return null!==t&&0!==t}catch(e){return!1}}(e._xhr)&&!e._destroyed&&(e._response||e._connect(),e._response._onXHRProgress(e._resetTimers.bind(e)))},f.prototype._connect=function(){var e=this;e._destroyed||(e._response=new c(e._xhr,e._fetchResponse,e._mode,e._resetTimers.bind(e)),e._response.on("error",(function(t){e.emit("error",t)})),e.emit("response",e._response))},f.prototype._write=function(e,t,r){this._body.push(e),r()},f.prototype._resetTimers=function(e){var t=this;r.g.clearTimeout(t._socketTimer),t._socketTimer=null,e?(r.g.clearTimeout(t._fetchTimer),t._fetchTimer=null):t._socketTimeout&&(t._socketTimer=r.g.setTimeout((function(){t.emit("timeout")}),t._socketTimeout))},f.prototype.abort=f.prototype.destroy=function(e){var t=this;t._destroyed=!0,t._resetTimers(!0),t._response&&(t._response._destroyed=!0),t._xhr?t._xhr.abort():t._fetchAbortController&&t._fetchAbortController.abort(),e&&t.emit("error",e)},f.prototype.end=function(e,t,r){"function"==typeof e&&(r=e,e=void 0),u.Writable.prototype.end.call(this,e,t,r)},f.prototype.setTimeout=function(e,t){var r=this;t&&r.once("timeout",t),r._socketTimeout=e,r._resetTimers(!1)},f.prototype.flushHeaders=function(){},f.prototype.setNoDelay=function(){},f.prototype.setSocketKeepAlive=function(){};var h=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]},3319:(e,t,r)=>{"use strict";var n=r(9142),i=r(9033).Buffer,o=r(3928),a=r(1736),s=r(6505),u=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},c=t.IncomingMessage=function(e,t,r,a){var u=this;if(s.Readable.call(u),u._mode=r,u.headers={},u.rawHeaders=[],u.trailers={},u.rawTrailers=[],u.on("end",(function(){n.nextTick((function(){u.emit("close")}))})),"fetch"===r){if(u._fetchResponse=t,u.url=t.url,u.statusCode=t.status,u.statusMessage=t.statusText,t.headers.forEach((function(e,t){u.headers[t.toLowerCase()]=e,u.rawHeaders.push(t,e)})),o.writableStream){var c=new WritableStream({write:function(e){return a(!1),new Promise((function(t,r){u._destroyed?r():u.push(i.from(e))?t():u._resumeFetch=t}))},close:function(){a(!0),u._destroyed||u.push(null)},abort:function(e){a(!0),u._destroyed||u.emit("error",e)}});try{return void t.body.pipeTo(c).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}catch(e){}}var l=t.body.getReader();!function e(){l.read().then((function(t){u._destroyed||(a(t.done),t.done?u.push(null):(u.push(i.from(t.value)),e()))})).catch((function(e){a(!0),u._destroyed||u.emit("error",e)}))}()}else if(u._xhr=e,u._pos=0,u.url=e.responseURL,u.statusCode=e.status,u.statusMessage=e.statusText,e.getAllResponseHeaders().split(/\r?\n/).forEach((function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var r=t[1].toLowerCase();"set-cookie"===r?(void 0===u.headers[r]&&(u.headers[r]=[]),u.headers[r].push(t[2])):void 0!==u.headers[r]?u.headers[r]+=", "+t[2]:u.headers[r]=t[2],u.rawHeaders.push(t[1],t[2])}})),u._charset="x-user-defined",!o.overrideMimeType){var f=u.rawHeaders["mime-type"];if(f){var h=f.match(/;\s*charset=([^;])(;|$)/);h&&(u._charset=h[1].toLowerCase())}u._charset||(u._charset="utf-8")}};a(c,s.Readable),c.prototype._read=function(){var e=this._resumeFetch;e&&(this._resumeFetch=null,e())},c.prototype._onXHRProgress=function(e){var t=this,n=t._xhr,o=null;switch(t._mode){case"text":if((o=n.responseText).length>t._pos){var a=o.substr(t._pos);if("x-user-defined"===t._charset){for(var s=i.alloc(a.length),c=0;ct._pos&&(t.push(i.from(new Uint8Array(l.result.slice(t._pos)))),t._pos=l.result.byteLength)},l.onload=function(){e(!0),t.push(null)},l.readAsArrayBuffer(o)}t._xhr.readyState===u.DONE&&"ms-stream"!==t._mode&&(e(!0),t.push(null))}},3462:(e,t,r)=>{"use strict";var n=r(8850).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.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 o(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){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 e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=u,this.end=c,t=4;break;case"utf8":this.fillLast=s,t=4;break;case"base64":this.text=l,this.end=f,t=3;break;default:return this.write=h,void(this.end=d)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function a(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function u(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function c(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function l(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function h(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}t.s=o,o.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0?(i>0&&(e.lastNeed=i-1),i):--n=0?(i>0&&(e.lastNeed=i-2),i):--n=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},o.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},6931:(e,t,r)=>{"use strict";var n=r(8619);e.exports=function(e){return"string"!=typeof e?e:n(e)?e.slice(2):e}},6427:(e,t,r)=>{"use strict";var n=function(){throw"This swarm.js function isn't available on the browser."},i={readFile:n},o={download:n,safeDownloadArchived:n,directoryTree:n},a={platform:n,arch:n},s={join:n,slice:n},u={spawn:n},c={lookup:n},l=r(1357),f=r(631),h=r(2733),d=r(2510),p=r(3094);e.exports=p({fs:i,files:o,os:a,path:s,child_process:u,defaultArchives:{},mimetype:c,request:l,downloadUrl:null,bytes:f,hash:h,pick:d})},2510:e=>{"use strict";var t=function(e){return function(){return new Promise((function(t,r){var n,i=function(r){var n={},i=r.target.files.length,o=0;[].map.call(r.target.files,(function(r){var a=new FileReader;a.onload=function(a){var s=new Uint8Array(a.target.result);if("directory"===e){var u=r.webkitRelativePath;n[u.slice(u.indexOf("/")+1)]={type:"text/plain",data:s},++o===i&&t(n)}else if("file"===e){var c=r.webkitRelativePath;t({type:mimetype.lookup(c),data:s})}else t(s)},a.readAsArrayBuffer(r)}))};"directory"===e?((n=document.createElement("input")).addEventListener("change",i),n.type="file",n.webkitdirectory=!0,n.mozdirectory=!0,n.msdirectory=!0,n.odirectory=!0,n.directory=!0):((n=document.createElement("input")).addEventListener("change",i),n.type="file");var o=document.createEvent("MouseEvents");o.initEvent("click",!0,!1),n.dispatchEvent(o)}))}};e.exports={data:t("data"),file:t("file"),directory:t("directory")}},2733:(e,t,r)=>{"use strict";var n=r(9574).keccak256,i=r(631),o=function(e,t){var r=i.reverse(i.pad(6,i.fromNumber(e))),o=i.flatten([r,"0x0000",t]);return n(o).slice(2)};e.exports=function e(t){"string"==typeof t&&"0x"!==t.slice(0,2)?t=i.fromString(t):"string"!=typeof t&&void 0!==t.length&&(t=i.fromUint8Array(t));var r=i.length(t);if(r<=4096)return o(r,t);for(var n=4096;128*n{"use strict";e.exports=function(e){var t=e.fs,r=e.files,n=e.os,i=e.path,o=e.child_process,a=e.mimetype,s=e.defaultArchives,u=e.request,c=e.downloadUrl,l=e.bytes,f=e.hash,h=e.pick,d=function(e){return function(t){for(var r={},n=0,i=e.length;n=400?n(new Error("Error ".concat(i.statusCode,"."))):r(new Uint8Array(t))}))}))}},y=function(e){return function(t){return function t(r){return function(n){return function(i){var o=function(e){return void 0===e.path?Promise.resolve():"application/bzz-manifest+json"===e.contentType?t(e.hash)(n+e.path)(i):Promise.resolve((r=n+e.path,function(e){return function(t){return t[r]=e,t}})(function(e){return{type:e.contentType,hash:e.hash}}(e))(i));var r};return m(e)(r).then((function(e){return JSON.parse(L(e)).entries})).then((function(e){return Promise.all(e.map(o))})).then((function(){return i}))}}}(t)("")({})}},g=function(e){return function(t){return y(e)(t).then((function(e){return d(Object.keys(e))(Object.keys(e).map((function(t){return e[t].hash})))}))}},b=function(e){return function(t){return y(e)(t).then((function(t){var r=Object.keys(t),n=r.map((function(e){return t[e].hash})),i=r.map((function(e){return t[e].type})),o=n.map(m(e));return Promise.all(o).then((function(e){return d(r)(function(e){return e.map((function(e,t){return{type:i[t],data:e}}))}(e))}))}))}},v=function(e){return function(t){return function(n){return r.download(p(e)(t))(n)}}},w=function(e){return function(t){return function(r){return g(e)(t).then((function(t){var n=[];for(var o in t)if(o.length>0){var a=i.join(r,o);n.push(v(e)(t[o])(a))}return Promise.all(n).then((function(){return r}))}))}}},A=function(e){return function(t){return new Promise((function(r,n){var i={body:"string"==typeof t?U(t):t,method:"POST"};u("".concat(e,"/bzz-raw:/"),i,(function(e,t){return e?n(e):r(t)}))}))}},S=function(e){return function(t){return function(r){return function(n){return function i(o){var a="/"===r[0]?r:"/"+r,s="".concat(e,"/bzz:/").concat(t).concat(a),c={method:"PUT",headers:{"Content-Type":n.type},body:n.data};return new Promise((function(e,t){u(s,c,(function(r,n){return r?t(r):-1!==n.indexOf("error")?t(n):e(n)}))})).catch((function(e){return o>0&&i(o-1)}))}(3)}}}},k=function(e){return function(t){return _(e)({"":t})}},E=function(e){return function(r){return t.readFile(r).then((function(t){return k(e)({type:a.lookup(r),data:t})}))}},_=function(e){return function(t){return A(e)("{}").then((function(r){return Object.keys(t).reduce((function(r,n){return r.then(function(r){return function(n){return S(e)(n)(r)(t[r])}}(n))}),Promise.resolve(r))}))}},M=function(e){return function(r){return t.readFile(r).then(A(e))}},T=function(e){return function(n){return function(i){return r.directoryTree(i).then((function(e){return Promise.all(e.map((function(e){return t.readFile(e)}))).then((function(t){var r=e.map((function(e){return e.slice(i.length)})),n=e.map((function(e){return a.lookup(e)||"text/plain"}));return d(r)(t.map((function(e,t){return{type:n[t],data:e}})))}))})).then((function(e){return(t=n?{"":e[n]}:{},function(e){var r={};for(var n in t)r[n]=t[n];for(var i in e)r[i]=e[i];return r})(e);var t})).then(_(e))}}},x=function(e){return function(t){if("data"===t.pick)return h.data().then(A(e));if("file"===t.pick)return h.file().then(k(e));if("directory"===t.pick)return h.directory().then(_(e));if(t.path)switch(t.kind){case"data":return M(e)(t.path);case"file":return E(e)(t.path);case"directory":return T(e)(t.defaultFile)(t.path)}else{if(t.length||"string"==typeof t)return A(e)(t);if(t instanceof Object)return _(e)(t)}return Promise.reject(new Error("Bad arguments"))}},P=function(e){return function(t){return function(r){return B(e)(t).then((function(n){return n?r?w(e)(t)(r):b(e)(t):r?v(e)(t)(r):m(e)(t)}))}}},I=function(e,t){var i=n.platform().replace("win32","windows")+"-"+("x64"===n.arch()?"amd64":"386"),o=(t||s)[i],a=c+o.archive+".tar.gz",u=o.archiveMD5,l=o.binaryMD5;return r.safeDownloadArchived(a)(u)(l)(e)},O=function(e){return new Promise((function(t,r){var n=o.spawn,i=function(e){return function(t){return-1!==(""+t).indexOf(e)}},a=e.account,s=e.password,u=e.dataDir,c=e.ensApi,l=e.privateKey,f=0,h=n(e.binPath,["--bzzaccount",a||l,"--datadir",u,"--ens-api",c]),d=function(e){0===f&&i("Passphrase")(e)?setTimeout((function(){f=1,h.stdin.write(s+"\n")}),500):i("Swarm http proxy started")(e)&&(f=2,clearTimeout(p),t(h))};h.stdout.on("data",d),h.stderr.on("data",d);var p=setTimeout((function(){return r(new Error("Couldn't start swarm process."))}),2e4)}))},R=function(e){return new Promise((function(t,r){e.stderr.removeAllListeners("data"),e.stdout.removeAllListeners("data"),e.stdin.removeAllListeners("error"),e.removeAllListeners("error"),e.removeAllListeners("exit"),e.kill("SIGINT");var n=setTimeout((function(){return e.kill("SIGKILL")}),8e3);e.once("close",(function(){clearTimeout(n),t()}))}))},C=function(e){return A(e)("test").then((function(e){return"c9a99c7d326dcc6316f32fe2625b311f6dc49a175e6877681ded93137d3569e7"===e})).catch((function(){return!1}))},B=function(e){return function(t){return m(e)(t).then((function(e){try{return!!JSON.parse(L(e)).entries}catch(e){return!1}}))}},N=function(e){return function(t,r,n,i,o){var a;return void 0!==t&&(a=e(t)),void 0!==r&&(a=e(r)),void 0!==n&&(a=e(n)),void 0!==i&&(a=e(i)),void 0!==o&&(a=e(o)),a}},L=function(e){return l.toString(l.fromUint8Array(e))},U=function(e){return l.toUint8Array(l.fromString(e))},F=function(e){return{download:function(t,r){return P(e)(t)(r)},downloadData:N(m(e)),downloadDataToDisk:N(v(e)),downloadDirectory:N(b(e)),downloadDirectoryToDisk:N(w(e)),downloadEntries:N(y(e)),downloadRoutes:N(g(e)),isAvailable:function(){return C(e)},upload:function(t){return x(e)(t)},uploadData:N(A(e)),uploadFile:N(k(e)),uploadFileFromDisk:N(k(e)),uploadDataFromDisk:N(M(e)),uploadDirectory:N(_(e)),uploadDirectoryFromDisk:N(T(e)),uploadToManifest:N(S(e)),pick:h,hash:f,fromString:U,toString:L}};return{at:F,local:function(e){return function(t){return C("http://localhost:8500").then((function(r){return r?t(F("http://localhost:8500")).then((function(){})):I(e.binPath,e.archives).onData((function(t){return(e.onProgress||function(){})(t.length)})).then((function(){return O(e)})).then((function(e){return t(F("http://localhost:8500")).then((function(){return e}))})).then(R)}))}},download:P,downloadBinary:I,downloadData:m,downloadDataToDisk:v,downloadDirectory:b,downloadDirectoryToDisk:w,downloadEntries:y,downloadRoutes:g,isAvailable:C,startProcess:O,stopProcess:R,upload:x,uploadData:A,uploadDataFromDisk:M,uploadFile:k,uploadFileFromDisk:E,uploadDirectory:_,uploadDirectoryFromDisk:T,uploadToManifest:S,pick:h,hash:f,fromString:U,toString:L}}},7380:e=>{"use strict";var t=function(e,t){for(var r=[],n=0;n{"use strict";r(7380);var n=function(e,t){return parseInt(e.slice(2*t+2,2*t+4),16)},i=function(e){return(e.length-2)/2},o=function(e){for(var t=[],r=2,n=e.length;r>6|192);else{if(i>55295&&i<56320){if(++n==e.length)return null;var o=e.charCodeAt(n);if(o<56320||o>57343)return null;r+=t((i=65536+((1023&i)<<10)+(1023&o))>>18|240),r+=t(i>>12&63|128)}else r+=t(i>>12|224);r+=t(i>>6&63|128)}r+=t(63&i|128)}}return r},toString:function(e){for(var t="",r=0,o=i(e);r127){if(a>191&&a<224){if(r>=o)return null;a=(31&a)<<6|63&n(e,r)}else if(a>223&&a<240){if(r+1>=o)return null;a=(15&a)<<12|(63&n(e,r))<<6|63&n(e,++r)}else{if(!(a>239&&a<248))return null;if(r+2>=o)return null;a=(7&a)<<18|(63&n(e,r))<<12|(63&n(e,++r))<<6|63&n(e,++r)}++r}if(a<=65535)t+=String.fromCharCode(a);else{if(!(a<=1114111))return null;a-=65536,t+=String.fromCharCode(a>>10|55296),t+=String.fromCharCode(1023&a|56320)}}return t},fromNumber:function(e){var t=e.toString(16);return t.length%2==0?"0x"+t:"0x0"+t},toNumber:function(e){return parseInt(e.slice(2),16)},fromNat:function(e){return"0x0"===e?"0x":e.length%2==0?e:"0x0"+e.slice(2)},toNat:function(e){return"0"===e[2]?"0x"+e.slice(3):e},fromArray:a,toArray:o,fromUint8Array:function(e){return a([].slice.call(e,0))},toUint8Array:function(e){return new Uint8Array(o(e))}}},9574:e=>{"use strict";var t="0123456789abcdef".split(""),r=[1,256,65536,16777216],n=[0,8,16,24],i=[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],o=function(e){var t,r,n,o,a,s,u,c,l,f,h,d,p,m,y,g,b,v,w,A,S,k,E,_,M,T,x,P,I,O,R,C,B,N,L,U,F,D,j,H,J,z,G,q,K,V,X,Q,W,Z,Y,$,ee,te,re,ne,ie,oe,ae,se,ue,ce,le;for(n=0;n<48;n+=2)o=e[0]^e[10]^e[20]^e[30]^e[40],a=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],u=e[3]^e[13]^e[23]^e[33]^e[43],c=e[4]^e[14]^e[24]^e[34]^e[44],l=e[5]^e[15]^e[25]^e[35]^e[45],f=e[6]^e[16]^e[26]^e[36]^e[46],h=e[7]^e[17]^e[27]^e[37]^e[47],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(s<<1|u>>>31),r=(p=e[9]^e[19]^e[29]^e[39]^e[49])^(u<<1|s>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=o^(c<<1|l>>>31),r=a^(l<<1|c>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=s^(f<<1|h>>>31),r=u^(h<<1|f>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=c^(d<<1|p>>>31),r=l^(p<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=f^(o<<1|a>>>31),r=h^(a<<1|o>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],y=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,P=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ue=e[30]<<9|e[31]>>>23,z=e[40]<<18|e[41]>>>14,G=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,Q=e[22]<<10|e[23]>>>22,W=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,le=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,U=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,Y=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,B=e[44]<<29|e[45]>>>3,_=e[6]<<28|e[7]>>>4,M=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,j=e[27]<<25|e[26]>>>7,A=e[36]<<21|e[37]>>>11,S=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,q=e[8]<<27|e[9]>>>5,K=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,x=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,H=e[38]<<8|e[39]>>>24,J=e[39]<<8|e[38]>>>24,k=e[48]<<14|e[49]>>>18,E=e[49]<<14|e[48]>>>18,e[0]=m^~g&v,e[1]=y^~b&w,e[10]=_^~T&P,e[11]=M^~x&I,e[20]=N^~U&D,e[21]=L^~F&j,e[30]=q^~V&Q,e[31]=K^~X&W,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=g^~v&A,e[3]=b^~w&S,e[12]=T^~P&O,e[13]=x^~I&R,e[22]=U^~D&H,e[23]=F^~j&J,e[32]=V^~Q&Z,e[33]=X^~W&Y,e[42]=ne^~oe&se,e[43]=ie^~ae&ue,e[4]=v^~A&k,e[5]=w^~S&E,e[14]=P^~O&C,e[15]=I^~R&B,e[24]=D^~H&z,e[25]=j^~J&G,e[34]=Q^~Z&$,e[35]=W^~Y&ee,e[44]=oe^~se&ce,e[45]=ae^~ue&le,e[6]=A^~k&m,e[7]=S^~E&y,e[16]=O^~C&_,e[17]=R^~B&M,e[26]=H^~z&N,e[27]=J^~G&L,e[36]=Z^~$&q,e[37]=Y^~ee&K,e[46]=se^~ce&te,e[47]=ue^~le&re,e[8]=k^~m&g,e[9]=E^~y&b,e[18]=C^~_&T,e[19]=B^~M&x,e[28]=z^~N&U,e[29]=G^~L&F,e[38]=$^~q&V,e[39]=ee^~K&X,e[48]=ce^~te&ne,e[49]=le^~re&ie,e[0]^=i[n],e[1]^=i[n+1]},a=function(e){return function(i){var a;if("0x"===i.slice(0,2)){a=[];for(var s=2,u=i.length;s>2]|=i[d]<>2]|=a<>2]|=(192|a>>6)<>2]|=(128|63&a)<=57344?(u[y>>2]|=(224|a>>12)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<>2]|=(240|a>>18)<>2]|=(128|a>>12&63)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<=c){for(e.start=y-c,e.block=u[l],y=0;y>2]|=r[3&y],e.lastByteIndex===c)for(u[0]=u[l],y=1;y>4&15]+t[15&p]+t[p>>12&15]+t[p>>8&15]+t[p>>20&15]+t[p>>16&15]+t[p>>28&15]+t[p>>24&15];g%l==0&&(o(h),y=0)}return"0x"+m}(function(e){return{blocks:[],reset:!0,block:0,start:0,blockCount:1600-(e<<1)>>5,outputBlocks:e>>5,s:(t=[0,0,0,0,0,0,0,0,0,0],[].concat(t,t,t,t,t))};var t}(e),a)}};e.exports={keccak256:a(256),keccak512:a(512),keccak256s:a(256),keccak512s:a(512)}},8419:e=>{"use strict";e.exports=function(e,t){if(t){t=(t=t.trim().replace(/^(\?|#|&)/,""))?"?"+t:t;var r=e.split(/[\?\#]/)[0];t&&/\:\/\/[^\/]*$/.test(r)&&(r+="/");var n=e.match(/(\#.*)$/);e=r+t,n&&(e+=n[0])}return e}},8677:(e,t,r)=>{"use strict";var n;e=r.nmd(e);var i=r(8847)(r(3355));!function(o){var a="object"==(0,i.default)(t)&&t&&!t.nodeType&&t,s="object"==(0,i.default)(e)&&e&&!e.nodeType&&e,u="object"==(void 0===r.g?"undefined":(0,i.default)(r.g))&&r.g;u.global!==u&&u.window!==u&&u.self!==u||(o=u);var c,l,f=2147483647,h=36,d=/^xn--/,p=/[^\x20-\x7E]/,m=/[\x2E\u3002\uFF0E\uFF61]/g,y={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},g=Math.floor,b=String.fromCharCode;function v(e){throw RangeError(y[e])}function w(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function A(e,t){var r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+w((e=e.replace(m,".")).split("."),t).join(".")}function S(e){for(var t,r,n=[],i=0,o=e.length;i=55296&&t<=56319&&i65535&&(t+=b((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+b(e)})).join("")}function E(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function _(e,t,r){var n=0;for(e=r?g(e/700):e>>1,e+=g(e/t);e>455;n+=h)e=g(e/35);return g(n+36*e/(e+38))}function M(e){var t,r,n,i,o,a,s,u,c,l,d,p=[],m=e.length,y=0,b=128,w=72;for((r=e.lastIndexOf("-"))<0&&(r=0),n=0;n=128&&v("not-basic"),p.push(e.charCodeAt(n));for(i=r>0?r+1:0;i=m&&v("invalid-input"),((u=(d=e.charCodeAt(i++))-48<10?d-22:d-65<26?d-65:d-97<26?d-97:h)>=h||u>g((f-y)/a))&&v("overflow"),y+=u*a,!(u<(c=s<=w?1:s>=w+26?26:s-w));s+=h)a>g(f/(l=h-c))&&v("overflow"),a*=l;w=_(y-o,t=p.length+1,0==o),g(y/t)>f-b&&v("overflow"),b+=g(y/t),y%=t,p.splice(y++,0,b)}return k(p)}function T(e){var t,r,n,i,o,a,s,u,c,l,d,p,m,y,w,A=[];for(p=(e=S(e)).length,t=128,r=0,o=72,a=0;a=t&&dg((f-r)/(m=n+1))&&v("overflow"),r+=(s-t)*m,t=s,a=0;af&&v("overflow"),d==t){for(u=r,c=h;!(u<(l=c<=o?1:c>=o+26?26:c-o));c+=h)w=u-l,y=h-l,A.push(b(E(l+w%y,0))),u=g(w/y);A.push(b(E(u,0))),o=_(r,m,n==i),r=0,++n}++r,++t}return A.join("")}if(c={version:"1.3.2",ucs2:{decode:S,encode:k},decode:M,encode:T,toASCII:function(e){return A(e,(function(e){return p.test(e)?"xn--"+T(e):e}))},toUnicode:function(e){return A(e,(function(e){return d.test(e)?M(e.slice(4).toLowerCase()):e}))}},"object"==(0,i.default)(r.amdO)&&r.amdO)void 0===(n=function(){return c}.call(t,r,t,e))||(e.exports=n);else if(a&&s)if(e.exports==a)s.exports=c;else for(l in c)c.hasOwnProperty(l)&&(a[l]=c[l]);else o.punycode=c}(void 0)},8983:e=>{"use strict";function t(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,r,n,i){r=r||"&",n=n||"=";var o={};if("string"!=typeof e||0===e.length)return o;var a=/\+/g;e=e.split(r);var s=1e3;i&&"number"==typeof i.maxKeys&&(s=i.maxKeys);var u=e.length;s>0&&u>s&&(u=s);for(var c=0;c=0?(l=p.substr(0,m),f=p.substr(m+1)):(l=p,f=""),h=decodeURIComponent(l),d=decodeURIComponent(f),t(o,h)?Array.isArray(o[h])?o[h].push(d):o[h]=[o[h],d]:o[h]=d}return o}},4031:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=function(e){switch((0,n.default)(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,t,r,o){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===(0,n.default)(e)?Object.keys(e).map((function(n){var o=encodeURIComponent(i(n))+r;return Array.isArray(e[n])?e[n].map((function(e){return o+encodeURIComponent(i(e))})).join(t):o+encodeURIComponent(i(e[n]))})).join(t):o?encodeURIComponent(i(o))+r+encodeURIComponent(i(e)):""}},845:(e,t,r)=>{"use strict";t.decode=t.parse=r(8983),t.encode=t.stringify=r(4031)},1143:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(8677),o=r(5751);function a(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}t.parse=w,t.resolve=function(e,t){return w(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?w(e,!1,!0).resolveObject(t):t},t.format=function(e){return o.isString(e)&&(e=w(e)),e instanceof a?e.format():a.prototype.format.call(e)},t.Url=a;var s=/^([a-z0-9.+-]+:)/i,u=/:[0-9]*$/,c=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,l=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),f=["'"].concat(l),h=["%","/","?",";","#"].concat(f),d=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,m=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,y={javascript:!0,"javascript:":!0},g={javascript:!0,"javascript:":!0},b={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},v=r(845);function w(e,t,r){if(e&&o.isObject(e)&&e instanceof a)return e;var n=new a;return n.parse(e,t,r),n}a.prototype.parse=function(e,t,r){if(!o.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+(0,n.default)(e));var a=e.indexOf("?"),u=-1!==a&&a127?B+="x":B+=C[N];if(!B.match(p)){var U=O.slice(0,x),F=O.slice(x+1),D=C.match(m);D&&(U.push(D[1]),F.unshift(D[2])),F.length&&(w="/"+F.join(".")+w),this.hostname=U.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),I||(this.hostname=i.toASCII(this.hostname));var j=this.port?":"+this.port:"",H=this.hostname||"";this.host=H+j,this.href+=this.host,I&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==w[0]&&(w="/"+w))}if(!y[k])for(x=0,R=f.length;x0)&&r.host.split("@"))&&(r.auth=P.shift(),r.host=r.hostname=P.shift())),r.search=e.search,r.query=e.query,o.isNull(r.pathname)&&o.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r;if(!k.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var _=k.slice(-1)[0],M=(r.host||e.host||k.length>1)&&("."===_||".."===_)||""===_,T=0,x=k.length;x>=0;x--)"."===(_=k[x])?k.splice(x,1):".."===_?(k.splice(x,1),T++):T&&(k.splice(x,1),T--);if(!A&&!S)for(;T--;T)k.unshift("..");!A||""===k[0]||k[0]&&"/"===k[0].charAt(0)||k.unshift(""),M&&"/"!==k.join("/").substr(-1)&&k.push("");var P,I=""===k[0]||k[0]&&"/"===k[0].charAt(0);return E&&(r.hostname=r.host=I?"":k.length?k.shift():"",(P=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=P.shift(),r.host=r.hostname=P.shift())),(A=A||r.host&&k.length)&&!I&&k.unshift(""),k.length?r.pathname=k.join("/"):(r.pathname=null,r.path=null),o.isNull(r.pathname)&&o.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},a.prototype.parseHost=function(){var e=this.host,t=u.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},5751:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"===(0,n.default)(e)&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},8632:(e,t)=>{"use strict";!function(e){var t,r,n,i=String.fromCharCode;function o(e){for(var t,r,n=[],i=0,o=e.length;i=55296&&t<=56319&&i=55296&&e<=57343)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value")}function s(e,t){return i(e>>t&63|128)}function u(e){if(0==(4294967168&e))return i(e);var t="";return 0==(4294965248&e)?t=i(e>>6&31|192):0==(4294901760&e)?(a(e),t=i(e>>12&15|224),t+=s(e,6)):0==(4292870144&e)&&(t=i(e>>18&7|240),t+=s(e,12),t+=s(e,6)),t+i(63&e|128)}function c(){if(n>=r)throw Error("Invalid byte index");var e=255&t[n];if(n++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function l(){var e,i;if(n>r)throw Error("Invalid byte index");if(n==r)return!1;if(e=255&t[n],n++,0==(128&e))return e;if(192==(224&e)){if((i=(31&e)<<6|c())>=128)return i;throw Error("Invalid continuation byte")}if(224==(240&e)){if((i=(15&e)<<12|c()<<6|c())>=2048)return a(i),i;throw Error("Invalid continuation byte")}if(240==(248&e)&&(i=(7&e)<<18|c()<<12|c()<<6|c())>=65536&&i<=1114111)return i;throw Error("Invalid UTF-8 detected")}e.version="3.0.0",e.encode=function(e){for(var t=o(e),r=t.length,n=-1,i="";++n65535&&(o+=i((t-=65536)>>>10&1023|55296),t=56320|1023&t),o+=i(t);return o}(s)}}(t)},6219:(e,t,r)=>{"use strict";function n(e){try{if(!r.g.localStorage)return!1}catch(e){return!1}var t=r.g.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=function(e,t){if(n("noDeprecation"))return e;var r=!1;return function(){if(!r){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}},6248:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports=function(e){return e&&"object"===(0,n.default)(e)&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},7092:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(9446),o=r(4477),a=r(2337),s=r(8915);function u(e){return e.call.bind(e)}var c="undefined"!=typeof BigInt,l="undefined"!=typeof Symbol,f=u(Object.prototype.toString),h=u(Number.prototype.valueOf),d=u(String.prototype.valueOf),p=u(Boolean.prototype.valueOf);if(c)var m=u(BigInt.prototype.valueOf);if(l)var y=u(Symbol.prototype.valueOf);function g(e,t){if("object"!==(0,n.default)(e))return!1;try{return t(e),!0}catch(e){return!1}}function b(e){return"[object Map]"===f(e)}function v(e){return"[object Set]"===f(e)}function w(e){return"[object WeakMap]"===f(e)}function A(e){return"[object WeakSet]"===f(e)}function S(e){return"[object ArrayBuffer]"===f(e)}function k(e){return"undefined"!=typeof ArrayBuffer&&(S.working?S(e):e instanceof ArrayBuffer)}function E(e){return"[object DataView]"===f(e)}function _(e){return"undefined"!=typeof DataView&&(E.working?E(e):e instanceof DataView)}t.isArgumentsObject=i,t.isGeneratorFunction=o,t.isTypedArray=s,t.isPromise=function(e){return"undefined"!=typeof Promise&&e instanceof Promise||null!==e&&"object"===(0,n.default)(e)&&"function"==typeof e.then&&"function"==typeof e.catch},t.isArrayBufferView=function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):s(e)||_(e)},t.isUint8Array=function(e){return"Uint8Array"===a(e)},t.isUint8ClampedArray=function(e){return"Uint8ClampedArray"===a(e)},t.isUint16Array=function(e){return"Uint16Array"===a(e)},t.isUint32Array=function(e){return"Uint32Array"===a(e)},t.isInt8Array=function(e){return"Int8Array"===a(e)},t.isInt16Array=function(e){return"Int16Array"===a(e)},t.isInt32Array=function(e){return"Int32Array"===a(e)},t.isFloat32Array=function(e){return"Float32Array"===a(e)},t.isFloat64Array=function(e){return"Float64Array"===a(e)},t.isBigInt64Array=function(e){return"BigInt64Array"===a(e)},t.isBigUint64Array=function(e){return"BigUint64Array"===a(e)},b.working="undefined"!=typeof Map&&b(new Map),t.isMap=function(e){return"undefined"!=typeof Map&&(b.working?b(e):e instanceof Map)},v.working="undefined"!=typeof Set&&v(new Set),t.isSet=function(e){return"undefined"!=typeof Set&&(v.working?v(e):e instanceof Set)},w.working="undefined"!=typeof WeakMap&&w(new WeakMap),t.isWeakMap=function(e){return"undefined"!=typeof WeakMap&&(w.working?w(e):e instanceof WeakMap)},A.working="undefined"!=typeof WeakSet&&A(new WeakSet),t.isWeakSet=function(e){return A(e)},S.working="undefined"!=typeof ArrayBuffer&&S(new ArrayBuffer),t.isArrayBuffer=k,E.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&E(new DataView(new ArrayBuffer(1),0,1)),t.isDataView=_;var M="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function T(e){return"[object SharedArrayBuffer]"===f(e)}function x(e){return void 0!==M&&(void 0===T.working&&(T.working=T(new M)),T.working?T(e):e instanceof M)}function P(e){return g(e,h)}function I(e){return g(e,d)}function O(e){return g(e,p)}function R(e){return c&&g(e,m)}function C(e){return l&&g(e,y)}t.isSharedArrayBuffer=x,t.isAsyncFunction=function(e){return"[object AsyncFunction]"===f(e)},t.isMapIterator=function(e){return"[object Map Iterator]"===f(e)},t.isSetIterator=function(e){return"[object Set Iterator]"===f(e)},t.isGeneratorObject=function(e){return"[object Generator]"===f(e)},t.isWebAssemblyCompiledModule=function(e){return"[object WebAssembly.Module]"===f(e)},t.isNumberObject=P,t.isStringObject=I,t.isBooleanObject=O,t.isBigIntObject=R,t.isSymbolObject=C,t.isBoxedPrimitive=function(e){return P(e)||I(e)||O(e)||R(e)||C(e)},t.isAnyArrayBuffer=function(e){return"undefined"!=typeof Uint8Array&&(k(e)||x(e))},["isProxy","isExternal","isModuleNamespaceObject"].forEach((function(e){Object.defineProperty(t,e,{enumerable:!1,value:function(){throw new Error(e+" is not supported in userland")}})}))},5058:(e,t,r)=>{"use strict";var n=r(9142),i=r(8847)(r(3355)),o=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}})),s=n[r];r=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),g(r)?n.showHidden=r:r&&t._extend(n,r),A(n.showHidden)&&(n.showHidden=!1),A(n.depth)&&(n.depth=2),A(n.colors)&&(n.colors=!1),A(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=f),d(n,e,n.depth)}function f(e,t){var r=l.styles[t];return r?"["+l.colors[r][0]+"m"+e+"["+l.colors[r][1]+"m":e}function h(e,t){return e}function d(e,r,n){if(e.customInspect&&r&&M(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var i=r.inspect(n,e);return w(i)||(i=d(e,i,n)),i}var o=function(e,t){if(A(t))return e.stylize("undefined","undefined");if(w(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return v(t)?e.stylize(""+t,"number"):g(t)?e.stylize(""+t,"boolean"):b(t)?e.stylize("null","null"):void 0}(e,r);if(o)return o;var a=Object.keys(r),s=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),_(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return p(r);if(0===a.length){if(M(r)){var u=r.name?": "+r.name:"";return e.stylize("[Function"+u+"]","special")}if(S(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(E(r))return e.stylize(Date.prototype.toString.call(r),"date");if(_(r))return p(r)}var c,l="",f=!1,h=["{","}"];return y(r)&&(f=!0,h=["[","]"]),M(r)&&(l=" [Function"+(r.name?": "+r.name:"")+"]"),S(r)&&(l=" "+RegExp.prototype.toString.call(r)),E(r)&&(l=" "+Date.prototype.toUTCString.call(r)),_(r)&&(l=" "+p(r)),0!==a.length||f&&0!=r.length?n<0?S(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),c=f?function(e,t,r,n,i){for(var o=[],a=0,s=t.length;a60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}(c,l,h)):h[0]+l+h[1]}function p(e){return"["+Error.prototype.toString.call(e)+"]"}function m(e,t,r,n,i,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?s=u.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):u.set&&(s=e.stylize("[Setter]","special")),O(n,i)||(a="["+i+"]"),s||(e.seen.indexOf(u.value)<0?(s=b(r)?d(e,u.value,null):d(e,u.value,r-1)).indexOf("\n")>-1&&(s=o?s.split("\n").map((function(e){return" "+e})).join("\n").slice(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),A(a)){if(o&&i.match(/^\d+$/))return s;(a=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.slice(1,-1),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function y(e){return Array.isArray(e)}function g(e){return"boolean"==typeof e}function b(e){return null===e}function v(e){return"number"==typeof e}function w(e){return"string"==typeof e}function A(e){return void 0===e}function S(e){return k(e)&&"[object RegExp]"===T(e)}function k(e){return"object"===(0,i.default)(e)&&null!==e}function E(e){return k(e)&&"[object Date]"===T(e)}function _(e){return k(e)&&("[object Error]"===T(e)||e instanceof Error)}function M(e){return"function"==typeof e}function T(e){return Object.prototype.toString.call(e)}function x(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(e=e.toUpperCase(),!s[e])if(u.test(e)){var r=n.pid;s[e]=function(){var n=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,n)}}else s[e]=function(){};return s[e]},t.inspect=l,l.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},l.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.types=r(7092),t.isArray=y,t.isBoolean=g,t.isNull=b,t.isNullOrUndefined=function(e){return null==e},t.isNumber=v,t.isString=w,t.isSymbol=function(e){return"symbol"===(0,i.default)(e)},t.isUndefined=A,t.isRegExp=S,t.types.isRegExp=S,t.isObject=k,t.isDate=E,t.types.isDate=E,t.isError=_,t.types.isNativeError=_,t.isFunction=M,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"===(0,i.default)(e)||void 0===e},t.isBuffer=r(6248);var P=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function I(){var e=new Date,t=[x(e.getHours()),x(e.getMinutes()),x(e.getSeconds())].join(":");return[e.getDate(),P[e.getMonth()],t].join(" ")}function O(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",I(),t.format.apply(t,arguments))},t.inherits=r(1736),t._extend=function(e,t){if(!t||!k(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var R="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function C(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(R&&e[R]){var t;if("function"!=typeof(t=e[R]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,R,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise((function(e,n){t=e,r=n})),i=[],o=0;o{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"NIL",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"v1",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"v3",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"v4",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"v5",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"validate",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return u.default}});var n=h(r(5999)),i=h(r(8231)),o=h(r(8647)),a=h(r(5025)),s=h(r(5996)),u=h(r(8928)),c=h(r(6163)),l=h(r(2982)),f=h(r(1729));function h(e){return e&&e.__esModule?e:{default:e}}},6792:(e,t)=>{"use strict";function r(e){return 14+(e+64>>>9<<4)+1}function n(e,t){var r=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(r>>16)<<16|65535&r}function i(e,t,r,i,o,a){return n((s=n(n(t,e),n(i,a)))<<(u=o)|s>>>32-u,r);var s,u}function o(e,t,r,n,o,a,s){return i(t&r|~t&n,e,t,o,a,s)}function a(e,t,r,n,o,a,s){return i(t&n|r&~n,e,t,o,a,s)}function s(e,t,r,n,o,a,s){return i(t^r^n,e,t,o,a,s)}function u(e,t,r,n,o,a,s){return i(r^(t|~n),e,t,o,a,s)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default=function(e){if("string"==typeof e){var t=unescape(encodeURIComponent(e));e=new Uint8Array(t.length);for(var i=0;i>5]>>>i%32&255,a=parseInt(n.charAt(o>>>4&15)+n.charAt(15&o),16);t.push(a)}return t}(function(e,t){e[t>>5]|=128<>5]|=(255&e[i/8])<{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};t.default=r},5996:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default="00000000-0000-0000-0000-000000000000"},1729:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=(n=r(6163))&&n.__esModule?n:{default:n};t.default=function(e){if(!(0,i.default)(e))throw TypeError("Invalid UUID");var t,r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=255&t,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=255&t,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=255&t,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=255&t,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=255&t,r}},7300:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default=/^(?:[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},4402:(e,t)=>{"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){if(!r&&!(r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return r(n)};var n=new Uint8Array(16)},2702:(e,t)=>{"use strict";function r(e,t,r,n){switch(e){case 0:return t&r^~t&n;case 1:case 3:return t^r^n;case 2:return t&r^t&n^r&n}}function n(e,t){return e<>>32-t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default=function(e){var t=[1518500249,1859775393,2400959708,3395469782],i=[1732584193,4023233417,2562383102,271733878,3285377520];if("string"==typeof e){var o=unescape(encodeURIComponent(e));e=[];for(var a=0;a>>0;A=w,w=v,v=n(b,30)>>>0,b=g,g=E}i[0]=i[0]+g>>>0,i[1]=i[1]+b>>>0,i[2]=i[2]+v>>>0,i[3]=i[3]+w>>>0,i[4]=i[4]+A>>>0}return[i[0]>>24&255,i[0]>>16&255,i[0]>>8&255,255&i[0],i[1]>>24&255,i[1]>>16&255,i[1]>>8&255,255&i[1],i[2]>>24&255,i[2]>>16&255,i[2]>>8&255,255&i[2],i[3]>>24&255,i[3]>>16&255,i[3]>>8&255,255&i[3],i[4]>>24&255,i[4]>>16&255,i[4]>>8&255,255&i[4]]}},2982:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.unsafeStringify=s;for(var n,i=(n=r(6163))&&n.__esModule?n:{default:n},o=[],a=0;a<256;++a)o.push((a+256).toString(16).slice(1));function s(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(o[e[t+0]]+o[e[t+1]]+o[e[t+2]]+o[e[t+3]]+"-"+o[e[t+4]]+o[e[t+5]]+"-"+o[e[t+6]]+o[e[t+7]]+"-"+o[e[t+8]]+o[e[t+9]]+"-"+o[e[t+10]]+o[e[t+11]]+o[e[t+12]]+o[e[t+13]]+o[e[t+14]]+o[e[t+15]]).toLowerCase()}t.default=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=s(e,t);if(!(0,i.default)(r))throw TypeError("Stringified UUID is invalid");return r}},5999:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i,o,a=(n=r(4402))&&n.__esModule?n:{default:n},s=r(2982),u=0,c=0;t.default=function(e,t,r){var n=t&&r||0,l=t||new Array(16),f=(e=e||{}).node||i,h=void 0!==e.clockseq?e.clockseq:o;if(null==f||null==h){var d=e.random||(e.rng||a.default)();null==f&&(f=i=[1|d[0],d[1],d[2],d[3],d[4],d[5]]),null==h&&(h=o=16383&(d[6]<<8|d[7]))}var p=void 0!==e.msecs?e.msecs:Date.now(),m=void 0!==e.nsecs?e.nsecs:c+1,y=p-u+(m-c)/1e4;if(y<0&&void 0===e.clockseq&&(h=h+1&16383),(y<0||p>u)&&void 0===e.nsecs&&(m=0),m>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");u=p,c=m,o=h;var g=(1e4*(268435455&(p+=122192928e5))+m)%4294967296;l[n++]=g>>>24&255,l[n++]=g>>>16&255,l[n++]=g>>>8&255,l[n++]=255&g;var b=p/4294967296*1e4&268435455;l[n++]=b>>>8&255,l[n++]=255&b,l[n++]=b>>>24&15|16,l[n++]=b>>>16&255,l[n++]=h>>>8|128,l[n++]=255&h;for(var v=0;v<6;++v)l[n+v]=f[v];return t||(0,s.unsafeStringify)(l)}},8231:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=o(r(6125)),i=o(r(6792));function o(e){return e&&e.__esModule?e:{default:e}}var a=(0,n.default)("v3",48,i.default);t.default=a},6125:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.URL=t.DNS=void 0,t.default=function(e,t,r){function n(e,n,a,s){var u;if("string"==typeof e&&(e=function(e){e=unescape(encodeURIComponent(e));for(var t=[],r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=a(r(1788)),i=a(r(4402)),o=r(2982);function a(e){return e&&e.__esModule?e:{default:e}}t.default=function(e,t,r){if(n.default.randomUUID&&!t&&!e)return n.default.randomUUID();var a=(e=e||{}).random||(e.rng||i.default)();if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,t){r=r||0;for(var s=0;s<16;++s)t[r+s]=a[s];return t}return(0,o.unsafeStringify)(a)}},5025:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=o(r(6125)),i=o(r(2702));function o(e){return e&&e.__esModule?e:{default:e}}var a=(0,n.default)("v5",80,i.default);t.default=a},6163:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=(n=r(7300))&&n.__esModule?n:{default:n};t.default=function(e){return"string"==typeof e&&i.default.test(e)}},8928:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=(n=r(6163))&&n.__esModule?n:{default:n};t.default=function(e){if(!(0,i.default)(e))throw TypeError("Invalid UUID");return parseInt(e.slice(14,15),16)}},8325:e=>{"use strict";e.exports=function e(t,r){var n,i=0,o=0,a=r=r||0,s=t.length;do{if(a>=s)throw e.bytes=0,new RangeError("Could not decode varint");n=t[a++],i+=o<28?(127&n)<=128);return e.bytes=a-r,i}},2699:e=>{"use strict";e.exports=function e(r,n,i){n=n||[];for(var o=i=i||0;r>=t;)n[i++]=255&r|128,r/=128;for(;-128&r;)n[i++]=255&r|128,r>>>=7;return n[i]=0|r,e.bytes=i-o+1,n};var t=Math.pow(2,31)},6657:(e,t,r)=>{"use strict";e.exports={encode:r(2699),decode:r(8325),encodingLength:r(7490)}},7490:e=>{"use strict";var t=Math.pow(2,7),r=Math.pow(2,14),n=Math.pow(2,21),i=Math.pow(2,28),o=Math.pow(2,35),a=Math.pow(2,42),s=Math.pow(2,49),u=Math.pow(2,56),c=Math.pow(2,63);e.exports=function(e){return e{"use strict";var n,i=r(8847)(r(3355));if("object"===("undefined"==typeof globalThis?"undefined":(0,i.default)(globalThis)))n=globalThis;else try{n=r(6464)}catch(e){}finally{if(n||"undefined"==typeof window||(n=window),!n)throw new Error("Could not determine global this")}var o=n.WebSocket||n.MozWebSocket,a=r(5735);function s(e,t){return t?new o(e,t):new o(e)}o&&["CONNECTING","OPEN","CLOSING","CLOSED"].forEach((function(e){Object.defineProperty(s,e,{get:function(){return o[e]}})})),e.exports={w3cwebsocket:o?s:null,version:a}},5735:(e,t,r)=>{"use strict";e.exports=r(9794).version},2337:(e,t,r)=>{"use strict";var n=r(8184),i=r(3604),o=r(593),a=r(3820),s=o("Object.prototype.toString"),u=r(1191)(),c="undefined"==typeof globalThis?r.g:globalThis,l=i(),f=o("String.prototype.slice"),h={},d=Object.getPrototypeOf;u&&a&&d&&n(l,(function(e){if("function"==typeof c[e]){var t=new c[e];if(Symbol.toStringTag in t){var r=d(t),n=a(r,Symbol.toStringTag);if(!n){var i=d(r);n=a(i,Symbol.toStringTag)}h[e]=n.get}}}));var p=r(8915);e.exports=function(e){return!!p(e)&&(u&&Symbol.toStringTag in e?function(e){var t=!1;return n(h,(function(r,n){if(!t)try{var i=r.call(e);i===n&&(t=i)}catch(e){}})),t}(e):f(s(e),8,-1))}},1357:(e,t,r)=>{"use strict";var n=r(8992),i=r(8419),o=r(3103),a=r(9122),s=r(7321),u="application/json",c=function(){};e.exports=function(e,t,r){if(!e||"string"!=typeof e)throw new TypeError("must specify a URL");if("function"==typeof t&&(r=t,t={}),r&&"function"!=typeof r)throw new TypeError("expected cb to be undefined or a function");r=r||c;var l=(t=t||{}).json?"json":"text",f=(t=o({responseType:l},t)).headers||{},h=(t.method||"GET").toUpperCase(),d=t.query;return d&&("string"!=typeof d&&(d=n.stringify(d)),e=i(e,d)),"json"===t.responseType&&a(f,"Accept",u),t.json&&"GET"!==h&&"HEAD"!==h&&(a(f,"Content-Type",u),t.body=JSON.stringify(t.body)),t.method=h,t.url=e,t.headers=f,delete t.query,delete t.json,s(t,r)}},9122:e=>{"use strict";e.exports=function(e,t,r){var n=t.toLowerCase();e[t]||e[n]||(e[t]=r)}},9800:e=>{"use strict";e.exports=function(e,t){return t?{statusCode:t.statusCode,headers:t.headers,method:e.method,url:e.url,rawRequest:t.rawRequest?t.rawRequest:t}:null}},7321:(e,t,r)=>{"use strict";var n=r(346),i=r(9800),o=function(){};e.exports=function(e,t){delete e.uri;var r=!1;"json"===e.responseType&&(e.responseType="text",r=!0);var a=n(e,(function(n,a,s){if(r&&!n)try{var u=a.rawRequest.responseText;s=JSON.parse(u)}catch(e){n=e}a=i(e,a),t(n,n?null:s,a),t=o})),s=a.onabort;return a.onabort=function(){var e=s.apply(a,Array.prototype.slice.call(arguments));return t(new Error("XHR Aborted")),t=o,e},a}},8992:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(3621),o=r(3103),a=r(34);function s(e,t){return t.encode?t.strict?i(e):encodeURIComponent(e):e}function u(e){return Array.isArray(e)?e.sort():"object"===(0,n.default)(e)?u(Object.keys(e)).sort((function(e,t){return Number(e)-Number(t)})).map((function(t){return e[t]})):e}function c(e){var t=e.indexOf("?");return-1===t?"":e.slice(t+1)}function l(e,t){var r=function(e){var t;switch(e.arrayFormat){case"index":return function(e,r,n){t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),t?(void 0===n[e]&&(n[e]={}),n[e][t[1]]=r):n[e]=r};case"bracket":return function(e,r,n){t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),t?void 0!==n[e]?n[e]=[].concat(n[e],r):n[e]=[r]:n[e]=r};default:return function(e,t,r){void 0!==r[e]?r[e]=[].concat(r[e],t):r[e]=t}}}(t=o({arrayFormat:"none"},t)),i=Object.create(null);return"string"!=typeof e?i:(e=e.trim().replace(/^[?#&]/,""))?(e.split("&").forEach((function(e){var t=e.replace(/\+/g," ").split("="),n=t.shift(),o=t.length>0?t.join("="):void 0;o=void 0===o?null:a(o),r(a(n),o,i)})),Object.keys(i).sort().reduce((function(e,t){var r=i[t];return Boolean(r)&&"object"===(0,n.default)(r)&&!Array.isArray(r)?e[t]=u(r):e[t]=r,e}),Object.create(null))):i}t.extract=c,t.parse=l,t.stringify=function(e,t){!1===(t=o({encode:!0,strict:!0,arrayFormat:"none"},t)).sort&&(t.sort=function(){});var r=function(e){switch(e.arrayFormat){case"index":return function(t,r,n){return null===r?[s(t,e),"[",n,"]"].join(""):[s(t,e),"[",s(n,e),"]=",s(r,e)].join("")};case"bracket":return function(t,r){return null===r?s(t,e):[s(t,e),"[]=",s(r,e)].join("")};default:return function(t,r){return null===r?s(t,e):[s(t,e),"=",s(r,e)].join("")}}}(t);return e?Object.keys(e).sort(t.sort).map((function(n){var i=e[n];if(void 0===i)return"";if(null===i)return s(n,t);if(Array.isArray(i)){var o=[];return i.slice().forEach((function(e){void 0!==e&&o.push(r(n,e,o.length))})),o.join("&")}return s(n,t)+"="+s(i,t)})).filter((function(e){return e.length>0})).join("&"):""},t.parseUrl=function(e,t){return{url:e.split("?")[0]||"",query:l(c(e),t)}}},3621:e=>{"use strict";e.exports=function(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}},346:(e,t,r)=>{"use strict";var n=r(2948),i=r(4339),o=r(8209),a=r(7705);function s(e,t,r){var n=e;return i(t)?(r=t,"string"==typeof e&&(n={uri:e})):n=a(t,{uri:e}),n.callback=r,n}function u(e,t,r){return c(t=s(e,t,r))}function c(e){if(void 0===e.callback)throw new Error("callback argument missing");var t=!1,r=function(r,n,i){t||(t=!0,e.callback(r,n,i))};function n(){var e=void 0;if(e=l.response?l.response:l.responseText||function(e){try{if("document"===e.responseType)return e.responseXML;var t=e.responseXML&&"parsererror"===e.responseXML.documentElement.nodeName;if(""===e.responseType&&!t)return e.responseXML}catch(e){}return null}(l),g)try{e=JSON.parse(e)}catch(e){}return e}function i(e){return clearTimeout(f),e instanceof Error||(e=new Error(""+(e||"Unknown XMLHttpRequest Error"))),e.statusCode=0,r(e,b)}function a(){if(!c){var t;clearTimeout(f),t=e.useXDR&&void 0===l.status?200:1223===l.status?204:l.status;var i=b,a=null;return 0!==t?(i={body:n(),statusCode:t,method:d,headers:{},url:h,rawRequest:l},l.getAllResponseHeaders&&(i.headers=o(l.getAllResponseHeaders()))):a=new Error("Internal XMLHttpRequest Error"),r(a,i,i.body)}}var s,c,l=e.xhr||null;l||(l=e.cors||e.useXDR?new u.XDomainRequest:new u.XMLHttpRequest);var f,h=l.url=e.uri||e.url,d=l.method=e.method||"GET",p=e.body||e.data,m=l.headers=e.headers||{},y=!!e.sync,g=!1,b={body:void 0,headers:{},statusCode:0,method:d,url:h,rawRequest:l};if("json"in e&&!1!==e.json&&(g=!0,m.accept||m.Accept||(m.Accept="application/json"),"GET"!==d&&"HEAD"!==d&&(m["content-type"]||m["Content-Type"]||(m["Content-Type"]="application/json"),p=JSON.stringify(!0===e.json?p:e.json))),l.onreadystatechange=function(){4===l.readyState&&setTimeout(a,0)},l.onload=a,l.onerror=i,l.onprogress=function(){},l.onabort=function(){c=!0},l.ontimeout=i,l.open(d,h,!y,e.username,e.password),y||(l.withCredentials=!!e.withCredentials),!y&&e.timeout>0&&(f=setTimeout((function(){if(!c){c=!0,l.abort("timeout");var e=new Error("XMLHttpRequest timeout");e.code="ETIMEDOUT",i(e)}}),e.timeout)),l.setRequestHeader)for(s in m)m.hasOwnProperty(s)&&l.setRequestHeader(s,m[s]);else if(e.headers&&!function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}(e.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in e&&(l.responseType=e.responseType),"beforeSend"in e&&"function"==typeof e.beforeSend&&e.beforeSend(l),l.send(p||null),l}e.exports=u,e.exports.default=u,u.XMLHttpRequest=n.XMLHttpRequest||function(){},u.XDomainRequest="withCredentials"in new u.XMLHttpRequest?u.XMLHttpRequest:n.XDomainRequest,function(e,t){for(var r=0;r{"use strict";e.exports=function(){for(var e={},r=0;r{"use strict";var n=r(8847)(r(3355)),i=r(6427),o=function e(t){this.givenProvider=e.givenProvider,t&&t._requestManager&&(t=t.currentProvider),"undefined"!=typeof document&&(this.pick=i.pick),this.setProvider(t)};o.givenProvider=null,"undefined"!=typeof ethereum&ðereum.bzz&&(o.givenProvider=ethereum.bzz),o.prototype.setProvider=function(e){if(e&&"object"===(0,n.default)(e)&&"string"==typeof e.bzz&&(e=e.bzz),"string"!=typeof e){this.currentProvider=null;var t=new Error("No provider set, please set one using bzz.setProvider().");return this.download=this.upload=this.isAvailable=function(){throw t},!1}return this.currentProvider=e,this.download=i.at(e).download,this.upload=i.at(e).upload,this.isAvailable=i.at(e).isAvailable,!0},e.exports=o},4246:(e,t,r)=>{"use strict";var n=r(8847)(r(3355));e.exports={ErrorResponse:function(e){var t=e&&e.error&&e.error.message?e.error.message:JSON.stringify(e),r=e.error&&e.error.data?e.error.data:null,n=new Error("Returned error: "+t);return n.data=r,n},InvalidNumberOfParams:function(e,t,r){return new Error('Invalid number of parameters for "'+r+'". Got '+e+" expected "+t+"!")},InvalidConnection:function(e,t){return this.ConnectionError("CONNECTION ERROR: Couldn't connect to node "+e+".",t)},InvalidProvider:function(){return new Error("Provider not set or invalid")},InvalidResponse:function(e){var t=e&&e.error&&e.error.message?e.error.message:"Invalid JSON RPC response: "+JSON.stringify(e);return new Error(t)},ConnectionTimeout:function(e){return new Error("CONNECTION TIMEOUT: timeout of "+e+" ms achived")},ConnectionNotOpenError:function(e){return this.ConnectionError("connection not open on send()",e)},ConnectionCloseError:function(e){return"object"===(0,n.default)(e)&&e.code&&e.reason?this.ConnectionError("CONNECTION ERROR: The connection got closed with the close code `"+e.code+"` and the following reason string `"+e.reason+"`",e):new Error("CONNECTION ERROR: The connection closed unexpectedly")},MaxAttemptsReachedOnReconnectingError:function(){return new Error("Maximum number of reconnect attempts reached!")},PendingRequestsOnReconnectingError:function(){return new Error("CONNECTION ERROR: Provider started to reconnect before the response got received!")},ConnectionError:function(e,t){var r=new Error(e);return t&&(r.code=t.code,r.reason=t.reason),r},RevertInstructionError:function(e,t){var r=new Error("Your request got reverted with the following reason string: "+e);return r.reason=e,r.signature=t,r},TransactionRevertInstructionError:function(e,t,r){var n=new Error("Transaction has been reverted by the EVM:\n"+JSON.stringify(r,null,2));return n.reason=e,n.signature=t,n.receipt=r,n},TransactionError:function(e,t){var r=new Error(e);return r.receipt=t,r},NoContractAddressFoundError:function(e){return this.TransactionError("The transaction receipt didn't contain a contract address.",e)},ContractCodeNotStoredError:function(e){return this.TransactionError("The contract code couldn't be stored, please check your gas limit.",e)},TransactionRevertedWithoutReasonError:function(e){return this.TransactionError("Transaction has been reverted by the EVM:\n"+JSON.stringify(e,null,2),e)},TransactionOutOfGasError:function(e){return this.TransactionError("Transaction ran out of gas. Please provide more gas:\n"+JSON.stringify(e,null,2),e)},ResolverMethodMissingError:function(e,t){return new Error("The resolver at "+e+'does not implement requested method: "'+t+'".')},ContractMissingABIError:function(){return new Error("You must provide the json interface of the contract when instantiating a contract object.")},ContractOnceRequiresCallbackError:function(){return new Error("Once requires a callback as the second parameter.")},ContractEventDoesNotExistError:function(e){return new Error('Event "'+e+"\" doesn't exist in this contract.")},ContractReservedEventError:function(e){return new Error('The event "'+e+"\" is a reserved event name, you can't use it.")},ContractMissingDeployDataError:function(){return new Error('No "data" specified in neither the given options, nor the default options.')},ContractNoAddressDefinedError:function(){return new Error("This contract object doesn't have address set yet, please set an address first.")},ContractNoFromAddressDefinedError:function(){return new Error('No "from" address specified in neither the given options, nor the default options.')}}},2084:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(775)),o=n(r(3355));function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t{"use strict";var n=r(4246),i=r(2084);e.exports={errors:n,formatters:i}},3349:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(2247)),o=n(r(4519)),a=n(r(775)),s=n(r(5698)),u=n(r(3355));function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function l(e){for(var t=1;t1?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},g.prototype.getCall=function(e){return"function"==typeof this.call?this.call(e):this.call},g.prototype.extractCallback=function(e){if("function"==typeof e[e.length-1])return e.pop()},g.prototype.validateArgs=function(e){if(e.length!==this.params)throw f.InvalidNumberOfParams(e.length,this.params,this.name)},g.prototype.formatInput=function(e){var t=this;return this.inputFormatter?this.inputFormatter.map((function(r,n){return r?r.call(t,e[n]):e[n]})):e},g.prototype.formatOutput=function(e){var t=this;return Array.isArray(e)?e.map((function(e){return t.outputFormatter&&e?t.outputFormatter(e):e})):this.outputFormatter&&e?this.outputFormatter(e):e},g.prototype.toPayload=function(e){var t=this.getCall(e),r=this.extractCallback(e),n=this.formatInput(e);this.validateArgs(n);var i={method:t,params:n,callback:r};return this.transformPayload&&(i=this.transformPayload(i)),i},g.prototype._confirmTransaction=function(e,t,r){var n=this,o=!1,a=!0,c=0,l=0,b=null,v=null,w=null,A=r.params[0]&&"object"===(0,u.default)(r.params[0])&&r.params[0].gas?r.params[0].gas:null,S=!!r.params[0]&&"object"===(0,u.default)(r.params[0])&&r.params[0].data&&r.params[0].from&&!r.params[0].to,k=S&&r.params[0].data.length>2,E=[new g({name:"getBlockByNumber",call:"eth_getBlockByNumber",params:2,inputFormatter:[h.inputBlockNumberFormatter,function(e){return!!e}],outputFormatter:h.outputBlockFormatter}),new g({name:"getTransactionReceipt",call:"eth_getTransactionReceipt",params:1,inputFormatter:[null],outputFormatter:h.outputTransactionReceiptFormatter}),new g({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[h.inputAddressFormatter,h.inputDefaultBlockNumberFormatter]}),new g({name:"getTransactionByHash",call:"eth_getTransactionByHash",params:1,inputFormatter:[null],outputFormatter:h.outputTransactionFormatter}),new m({name:"subscribe",type:"eth",subscriptions:{newBlockHeaders:{subscriptionName:"newHeads",params:0,outputFormatter:h.outputBlockFormatter}}})],_={};E.forEach((function(e){e.attachToObject(_),e.requestManager=n.requestManager}));var M=function(u,m,g,E,M){if(!g)return M||(M={unsubscribe:function(){clearInterval(b),clearTimeout(v)}}),(u?p.resolve(u):_.getTransactionReceipt(t)).catch((function(t){M.unsubscribe(),o=!0,d._fireError({message:"Failed to check for transaction receipt:",data:t},e.eventEmitter,e.reject)})).then(function(){var t=(0,s.default)(i.default.mark((function t(r){var o,s,c;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r&&r.blockHash){t.next=2;break}throw new Error("Receipt missing or blockHash null");case 2:if(n.extraFormatters&&n.extraFormatters.receiptFormatter&&(r=n.extraFormatters.receiptFormatter(r)),!(e.eventEmitter.listeners("confirmation").length>0)){t.next=28;break}if(void 0!==u&&0===l){t.next=25;break}return t.next=7,_.getBlockByNumber("latest");case 7:if(s=t.sent,c=s?s.hash:null,!m){t.next=24;break}if(!w){t.next=17;break}return t.next=13,_.getBlockByNumber(w.number+1);case 13:(o=t.sent)&&(w=o,e.eventEmitter.emit("confirmation",l,r,c)),t.next=22;break;case 17:return t.next=19,_.getBlockByNumber(r.blockNumber);case 19:o=t.sent,w=o,e.eventEmitter.emit("confirmation",l,r,c);case 22:t.next=25;break;case 24:e.eventEmitter.emit("confirmation",l,r,c);case 25:(m&&o||!m)&&l++,a=!1,l===n.transactionConfirmationBlocks+1&&(M.unsubscribe(),e.eventEmitter.removeAllListeners());case 28:return t.abrupt("return",r);case 29:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).then(function(){var t=(0,s.default)(i.default.mark((function t(r){var s;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!S||o){t.next=19;break}if(r.contractAddress){t.next=5;break}return a&&(M.unsubscribe(),o=!0),d._fireError(f.NoContractAddressFoundError(r),e.eventEmitter,e.reject,null,r),t.abrupt("return");case 5:return t.prev=5,t.next=8,_.getCode(r.contractAddress);case 8:s=t.sent,t.next=13;break;case 11:t.prev=11,t.t0=t.catch(5);case 13:if(s){t.next=15;break}return t.abrupt("return");case 15:!0===r.status&&k||s.length>2?(e.eventEmitter.emit("receipt",r),n.extraFormatters&&n.extraFormatters.contractDeployFormatter?e.resolve(n.extraFormatters.contractDeployFormatter(r)):e.resolve(r),a&&e.eventEmitter.removeAllListeners()):d._fireError(f.ContractCodeNotStoredError(r),e.eventEmitter,e.reject,null,r),a&&M.unsubscribe(),o=!0;case 19:return t.abrupt("return",r);case 20:case"end":return t.stop()}}),t,null,[[5,11]])})));return function(e){return t.apply(this,arguments)}}()).then(function(){var t=(0,s.default)(i.default.mark((function t(s){var u,c,l,p;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(S||o){t.next=35;break}if(s.outOfGas||A&&A===s.gasUsed||!0!==s.status&&"0x1"!==s.status&&void 0!==s.status){t.next=7;break}e.eventEmitter.emit("receipt",s),e.resolve(s),a&&e.eventEmitter.removeAllListeners(),t.next=33;break;case 7:if(JSON.stringify(s,null,2),!1!==s.status&&"0x0"!==s.status){t.next=32;break}if(t.prev=9,u=null,!n.handleRevert||"eth_sendTransaction"!==n.call&&"eth_sendRawTransaction"!==n.call){t.next=24;break}return c=r.params[0],"eth_sendRawTransaction"===n.call&&(l=r.params[0],p=y.parse(l),c=h.inputTransactionFormatter({data:p.data,to:p.to,from:p.from,gas:p.gasLimit.toHexString(),gasPrice:p.gasPrice?p.gasPrice.toHexString():void 0,value:p.value.toHexString()})),t.next=16,n.getRevertReason(c,s.blockNumber);case 16:if(!(u=t.sent)){t.next=21;break}d._fireError(f.TransactionRevertInstructionError(u.reason,u.signature,s),e.eventEmitter,e.reject,null,s),t.next=22;break;case 21:throw!1;case 22:t.next=25;break;case 24:throw!1;case 25:t.next=30;break;case 27:t.prev=27,t.t0=t.catch(9),d._fireError(f.TransactionRevertedWithoutReasonError(s),e.eventEmitter,e.reject,null,s);case 30:t.next=33;break;case 32:d._fireError(f.TransactionOutOfGasError(s),e.eventEmitter,e.reject,null,s);case 33:a&&M.unsubscribe(),o=!0;case 35:case"end":return t.stop()}}),t,null,[[9,27]])})));return function(e){return t.apply(this,arguments)}}()).catch((function(){c++,m?c-1>=n.transactionPollingTimeout&&(M.unsubscribe(),o=!0,d._fireError(f.TransactionError("Transaction was not mined within "+n.transactionPollingTimeout+" seconds, please make sure your transaction was properly sent. Be aware that it might still be mined!"),e.eventEmitter,e.reject)):c-1>=n.transactionBlockTimeout&&(M.unsubscribe(),o=!0,d._fireError(f.TransactionError("Transaction was not mined within "+n.transactionBlockTimeout+" blocks, please make sure your transaction was properly sent. Be aware that it might still be mined!"),e.eventEmitter,e.reject))}));M.unsubscribe(),o=!0,d._fireError({message:"Failed to subscribe to new newBlockHeaders to confirm the transaction receipts.",data:g},e.eventEmitter,e.reject)},T=function(e){var t=!1,r=function(){b=setInterval(M.bind(null,e,!0),n.transactionPollingInterval)};if(!this.requestManager.provider.on)return r();_.subscribe("newBlockHeaders",(function(n,i,o){if(t=!0,n||!i)return r();M(e,!1,n,0,o)})),v=setTimeout((function(){t||r()}),1e3*this.blockHeaderTimeout)}.bind(this);_.getTransactionReceipt(t).then((function(t){t&&t.blockHash?(e.eventEmitter.listeners("confirmation").length>0&&T(t),M(t,!1)):o||T()})).catch((function(){o||T()}))};var b=function(e,t){return"number"==typeof e?t.wallet[e]:e&&"object"===(0,u.default)(e)&&e.address&&e.privateKey?e:t.wallet[e.toLowerCase()]};function v(e,t){return new Promise((function(r,n){try{var i=new g({name:"getBlockByNumber",call:"eth_getBlockByNumber",params:2,inputFormatter:[function(e){return e?d.toHex(e):"latest"},function(){return!1}]}).createFunction(e.requestManager),a=new g({name:"getGasPrice",call:"eth_gasPrice",params:0}).createFunction(e.requestManager);Promise.all([i(),a()]).then((function(e){var n=(0,o.default)(e,2),i=n[0],a=n[1];if(("0x2"===t.type||void 0===t.type)&&i&&i.baseFeePerGas){var s,u;t.gasPrice?(s=t.gasPrice,u=t.gasPrice,delete t.gasPrice):(s=t.maxPriorityFeePerGas||"0x9502F900",u=t.maxFeePerGas||d.toHex(d.toBN(i.baseFeePerGas).mul(d.toBN(2)).add(d.toBN(s)))),r({maxFeePerGas:u,maxPriorityFeePerGas:s})}else{if(t.maxPriorityFeePerGas||t.maxFeePerGas)throw Error("Network doesn't support eip-1559");r({gasPrice:a})}}))}catch(e){n(e)}}))}g.prototype.buildCall=function(){var e=this,t="eth_sendTransaction"===e.call||"eth_sendRawTransaction"===e.call,r="eth_call"===e.call,n=function(){var n=Array.prototype.slice.call(arguments),i=p(!t),o=e.toPayload(n);e.hexFormat=!1,"eth_getTransactionReceipt"===e.call&&(e.hexFormat=o.params.length{"use strict";var n=r(8008),i=function(e){var t,r,i=new Promise((function(){t=arguments[0],r=arguments[1]}));if(e)return{resolve:t,reject:r,eventEmitter:i};var o=new n;return i._events=o._events,i.emit=o.emit,i.on=o.on,i.once=o.once,i.off=o.off,i.listeners=o.listeners,i.addListener=o.addListener,i.removeListener=o.removeListener,i.removeAllListeners=o.removeAllListeners,{resolve:t,reject:r,eventEmitter:i}};i.resolve=function(e){var t=i(!0);return t.resolve(e),t.eventEmitter},e.exports=i},5229:(e,t,r)=>{"use strict";var n=r(8155),i=r(1314).errors,o=function(e){this.requestManager=e,this.requests=[]};o.prototype.add=function(e){this.requests.push(e)},o.prototype.execute=function(){var e=this.requests,t=this._sortResponses.bind(this);this.requestManager.sendBatch(e,(function(r,o){o=t(o),e.map((function(e,t){return o[t]||{}})).forEach((function(t,r){if(e[r].callback){if(t&&t.error)return e[r].callback(i.ErrorResponse(t));if(!n.isValidResponse(t))return e[r].callback(i.InvalidResponse(t));try{e[r].callback(null,e[r].format?e[r].format(t.result):t.result)}catch(t){e[r].callback(t)}}}))}))},o.prototype._sortResponses=function(e){return(e||[]).sort((function(e,t){return e.id-t.id}))},e.exports=o},9764:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=null,o="object"===("undefined"==typeof globalThis?"undefined":(0,n.default)(globalThis))?globalThis:void 0;if(!o)try{o=Function("return this")()}catch(e){o=self}void 0!==o.ethereum?i=o.ethereum:void 0!==o.web3&&o.web3.currentProvider&&(o.web3.currentProvider.sendAsync&&(o.web3.currentProvider.send=o.web3.currentProvider.sendAsync,delete o.web3.currentProvider.sendAsync),!o.web3.currentProvider.on&&o.web3.currentProvider.connection&&"ipcProviderWrapper"===o.web3.currentProvider.connection.constructor.name&&(o.web3.currentProvider.on=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");"data"===e?this.connection.on("data",(function(e){var r="";e=e.toString();try{r=JSON.parse(e)}catch(r){return t(new Error("Couldn't parse response data"+e))}r.id||-1===r.method.indexOf("_subscription")||t(null,r)})):this.connection.on(e,t)}),i=o.web3.currentProvider),e.exports=i},2033:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(5058).callbackify,o=r(1314).errors,a=r(8155),s=r(5229),u=r(9764),c=function e(t,r){this.provider=null,this.providers=e.providers,this.setProvider(t,r),this.subscriptions=new Map};c.givenProvider=u,c.providers={WebsocketProvider:r(7651),HttpProvider:r(4565),IpcProvider:r(2683)},c.prototype.setProvider=function(e,t){var r=this;if(e&&"string"==typeof e&&this.providers)if(/^http(s)?:\/\//i.test(e))e=new this.providers.HttpProvider(e);else if(/^ws(s)?:\/\//i.test(e))e=new this.providers.WebsocketProvider(e);else if(e&&"object"===(0,n.default)(t)&&"function"==typeof t.connect)e=new this.providers.IpcProvider(e,t);else if(e)throw new Error("Can't autodetect provider for \""+e+'"');this.provider&&this.provider.connected&&this.clearSubscriptions(),this.provider=e||null,this.provider&&this.provider.on&&("function"==typeof e.request?this.provider.on("message",(function(e){if(e&&"eth_subscription"===e.type&&e.data){var t=e.data;t.subscription&&r.subscriptions.has(t.subscription)&&r.subscriptions.get(t.subscription).callback(null,t.result)}})):this.provider.on("data",(function(e,t){(e=e||t).method&&e.params&&e.params.subscription&&r.subscriptions.has(e.params.subscription)&&r.subscriptions.get(e.params.subscription).callback(null,e.params.result)})),this.provider.on("connect",(function(){r.subscriptions.forEach((function(e){e.subscription.resubscribe()}))})),this.provider.on("error",(function(e){r.subscriptions.forEach((function(t){t.callback(e)}))})),this.provider.on("disconnect",(function(e){r._isCleanCloseEvent(e)&&!r._isIpcCloseError(e)||(r.subscriptions.forEach((function(t){t.callback(o.ConnectionCloseError(e)),r.subscriptions.delete(t.subscription.id)})),r.provider&&r.provider.emit&&r.provider.emit("error",o.ConnectionCloseError(e))),r.provider&&r.provider.emit&&r.provider.emit("end",e)})))},c.prototype.send=function(e,t){if(t=t||function(){},!this.provider)return t(o.InvalidProvider());var r=e.method,n=e.params,s=a.toPayload(r,n),u=this._jsonrpcResultCallback(t,s);if(this.provider.request)i(this.provider.request.bind(this.provider))({method:r,params:n},t);else if(this.provider.sendAsync)this.provider.sendAsync(s,u);else{if(!this.provider.send)throw new Error("Provider does not have a request or send method to use.");this.provider.send(s,u)}},c.prototype.sendBatch=function(e,t){if(!this.provider)return t(o.InvalidProvider());var r=a.toBatchPayload(e);this.provider[this.provider.sendAsync?"sendAsync":"send"](r,(function(e,r){return e?t(e):Array.isArray(r)?void t(null,r):t(o.InvalidResponse(r))}))},c.prototype.addSubscription=function(e,t){if(!this.provider.on)throw new Error("The provider doesn't support subscriptions: "+this.provider.constructor.name);this.subscriptions.set(e.id,{callback:t,subscription:e})},c.prototype.removeSubscription=function(e,t){if(this.subscriptions.has(e)){var r=this.subscriptions.get(e).subscription.options.type;return this.subscriptions.delete(e),void this.send({method:r+"_unsubscribe",params:[e]},t)}"function"==typeof t&&t(null)},c.prototype.clearSubscriptions=function(e){try{var t=this;return this.subscriptions.size>0&&this.subscriptions.forEach((function(r,n){e&&"syncing"===r.name||t.removeSubscription(n)})),this.provider.reset&&this.provider.reset(),!0}catch(e){throw new Error("Error while clearing subscriptions: ".concat(e))}},c.prototype._isCleanCloseEvent=function(e){return"object"===(0,n.default)(e)&&([1e3].includes(e.code)||!0===e.wasClean)},c.prototype._isIpcCloseError=function(e){return"boolean"==typeof e&&e},c.prototype._jsonrpcResultCallback=function(e,t){return function(r,n){return n&&n.id&&t.id!==n.id?e(new Error("Wrong response id ".concat(n.id," (expected: ").concat(t.id,") in ").concat(JSON.stringify(t)))):r?e(r):n&&n.error?e(o.ErrorResponse(n)):a.isValidResponse(n)?void e(null,n.result):e(o.InvalidResponse(n))}},e.exports={Manager:c,BatchManager:s}},8155:e=>{"use strict";var t={messageId:Math.floor(Math.random()*Number.MAX_SAFE_INTEGER),toPayload:function(e,r){if(!e)throw new Error('JSONRPC method should be specified for params: "'+JSON.stringify(r)+'"!');return t.messageId===Number.MAX_SAFE_INTEGER?t.messageId=Math.floor(Math.random()*Number.MAX_SAFE_INTEGER):t.messageId++,{jsonrpc:"2.0",id:t.messageId,method:e,params:r||[]}},isValidResponse:function(e){return Array.isArray(e)?e.every(t):t(e);function t(e){return!(!e||e.error||"2.0"!==e.jsonrpc||"number"!=typeof e.id&&"string"!=typeof e.id||void 0===e.result)}},toBatchPayload:function(e){return e.map((function(e){return t.toPayload(e.method,e.params)}))}};e.exports=t},4178:(e,t,r)=>{"use strict";var n=r(2929),i=function(e){this.name=e.name,this.type=e.type,this.subscriptions=e.subscriptions||{},this.requestManager=null};i.prototype.setRequestManager=function(e){this.requestManager=e},i.prototype.attachToObject=function(e){var t=this.buildCall(),r=this.name.split(".");r.length>1?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},i.prototype.buildCall=function(){var e=this;return function(){e.subscriptions[arguments[0]]||console.warn("Subscription "+JSON.stringify(arguments[0])+" doesn't exist. Subscribing anyway.");var t=new n({subscription:e.subscriptions[arguments[0]]||{},requestManager:e.requestManager,type:e.type});return t.subscribe.apply(t,arguments)}},e.exports={subscriptions:i,subscription:n}},2929:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1314).errors,o=r(8008),a=r(1314).formatters;function s(e){return e}function u(e){o.call(this),this.id=null,this.callback=s,this.arguments=null,this.lastBlock=null,this.options={subscription:e.subscription,type:e.type,requestManager:e.requestManager}}u.prototype=Object.create(o.prototype),u.prototype.constructor=u,u.prototype._extractCallback=function(e){if("function"==typeof e[e.length-1])return e.pop()},u.prototype._validateArgs=function(e){var t=this.options.subscription;if(t||(t={}),t.params||(t.params=0),e.length!==t.params)throw i.InvalidNumberOfParams(e.length,t.params,t.subscriptionName)},u.prototype._formatInput=function(e){var t=this.options.subscription;return t&&t.inputFormatter?t.inputFormatter.map((function(t,r){return t?t(e[r]):e[r]})):e},u.prototype._formatOutput=function(e){var t=this.options.subscription;return t&&t.outputFormatter&&e?t.outputFormatter(e):e},u.prototype._toPayload=function(e){var t=[];if(this.callback=this._extractCallback(e)||s,this.subscriptionMethod||(this.subscriptionMethod=e.shift(),this.options.subscription.subscriptionName&&(this.subscriptionMethod=this.options.subscription.subscriptionName)),this.arguments||(this.arguments=this._formatInput(e),this._validateArgs(this.arguments),e=[]),t.push(this.subscriptionMethod),t=t.concat(this.arguments),e.length)throw new Error("Only a callback is allowed as parameter on an already instantiated subscription.");return{method:this.options.type+"_subscribe",params:t}},u.prototype.unsubscribe=function(e){this.options.requestManager.removeSubscription(this.id,e),this.id=null,this.lastBlock=null,this.removeAllListeners()},u.prototype.subscribe=function(){var e=this,t=Array.prototype.slice.call(arguments),r=this._toPayload(t);if(!r)return this;if(!this.options.requestManager.provider)return setTimeout((function(){var t=new Error("No provider set.");e.callback(t,null,e),e.emit("error",t)}),0),this;if(!this.options.requestManager.provider.on)return setTimeout((function(){var t=new Error("The current provider doesn't support subscriptions: "+e.options.requestManager.provider.constructor.name);e.callback(t,null,e),e.emit("error",t)}),0),this;if(this.lastBlock&&this.options.params&&"object"===(0,n.default)(this.options.params)&&(r.params[1]=this.options.params,r.params[1].fromBlock=a.inputBlockNumberFormatter(this.lastBlock+1)),this.id&&this.unsubscribe(),this.options.params=r.params[1],"logs"===r.params[0]&&r.params[1]&&"object"===(0,n.default)(r.params[1])&&r.params[1].hasOwnProperty("fromBlock")&&isFinite(r.params[1].fromBlock)){var i=Object.assign({},r.params[1]);this.options.requestManager.send({method:"eth_getLogs",params:[i]},(function(t,r){t?setTimeout((function(){e.callback(t,null,e),e.emit("error",t)}),0):r.forEach((function(t){var r=e._formatOutput(t);e.callback(null,r,e),e.emit("data",r)}))}))}return"object"===(0,n.default)(r.params[1])&&delete r.params[1].fromBlock,this.options.requestManager.send(r,(function(t,i){!t&&i?(e.id=i,e.method=r.params[0],e.options.requestManager.addSubscription(e,(function(t,r){t?(e.callback(t,!1,e),e.emit("error",t)):(Array.isArray(r)||(r=[r]),r.forEach((function(t){var r=e._formatOutput(t);if(e.lastBlock=r&&"object"===(0,n.default)(r)?r.blockNumber:null,"function"==typeof e.options.subscription.subscriptionHandler)return e.options.subscription.subscriptionHandler.call(e,r);e.emit("data",r),e.callback(null,r,e)})))})),e.emit("connected",i)):setTimeout((function(){e.callback(t,!1,e),e.emit("error",t)}),0)})),this},u.prototype.resubscribe=function(){this.options.requestManager.removeSubscription(this.id),this.id=null,this.subscribe(this.callback)},e.exports=u},9907:(e,t,r)=>{"use strict";var n=r(1314).formatters,i=r(3349),o=r(8161);e.exports=function(e){var t=function(t){var r;return t.property?(e[t.property]||(e[t.property]={}),r=e[t.property]):r=e,t.methods&&t.methods.forEach((function(t){t instanceof i||(t=new i(t)),t.attachToObject(r),t.setRequestManager(e._requestManager)})),e};return t.formatters=n,t.utils=o,t.Method=i,t}},606:(e,t,r)=>{"use strict";var n=r(2033),i=r(9907);e.exports={packageInit:function(e,t){if(t=Array.prototype.slice.call(t),!e)throw new Error('You need to instantiate using the "new" keyword.');Object.defineProperty(e,"currentProvider",{get:function(){return e._provider},set:function(t){return e.setProvider(t)},enumerable:!0,configurable:!0}),t[0]&&t[0]._requestManager?e._requestManager=t[0]._requestManager:e._requestManager=new n.Manager(t[0],t[1]),e.givenProvider=n.Manager.givenProvider,e.providers=n.Manager.providers,e._provider=e._requestManager.provider,e.setProvider||(e.setProvider=function(t,r){return e._requestManager.setProvider(t,r),e._provider=e._requestManager.provider,!0}),e.setRequestManager=function(t){e._requestManager=t,e._provider=t.provider},e.BatchRequest=n.BatchManager.bind(null,e._requestManager),e.extend=i(e)},addProviders:function(e){e.givenProvider=n.Manager.givenProvider,e.providers=n.Manager.providers}}},9901:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(9033).Buffer,o=r(8161),a=r(2914).RQ,s=r(2914)._R,u=new a((function(e,t){return!e.match(/^u?int/)||Array.isArray(t)||t&&"object"===(0,n.default)(t)&&"BN"===t.constructor.name?t:t.toString()}));function c(){}var l=function(){};l.prototype.encodeFunctionSignature=function(e){return("function"==typeof e||"object"===(0,n.default)(e)&&e)&&(e=o._jsonInterfaceMethodToString(e)),o.sha3(e).slice(0,10)},l.prototype.encodeEventSignature=function(e){return("function"==typeof e||"object"===(0,n.default)(e)&&e)&&(e=o._jsonInterfaceMethodToString(e)),o.sha3(e)},l.prototype.encodeParameter=function(e,t){return this.encodeParameters([e],[t])},l.prototype.encodeParameters=function(e,t){var r=this;return e=r.mapTypes(e),t=t.map((function(t,i){var o=e[i];return"object"===(0,n.default)(o)&&o.type&&(o=o.type),t=r.formatParam(o,t),"string"==typeof o&&o.includes("tuple")&&function e(t,n){if("array"===t.name){if(!t.type.match(/\[(\d+)\]/))return n.map((function(r){return e(u._getCoder(s.from(t.type.replace("[]",""))),r)}));var i=parseInt(t.type.match(/\[(\d+)\]/)[1]);if(n.length!==i)throw new Error("Array length does not matches with the given input");return n.map((function(r){return e(u._getCoder(s.from(t.type.replace(/\[\d+\]/,""))),r)}))}t.coders.forEach((function(t,i){"tuple"===t.name?e(t,n[i]):n[i]=r.formatParam(t.name,n[i])}))}(u._getCoder(s.from(o)),t),t})),u.encode(e,t)},l.prototype.mapTypes=function(e){var t=this,r=[];return e.forEach((function(e){if("object"===(0,n.default)(e)&&"function"===e.type&&(e=Object.assign({},e,{type:"bytes24"})),t.isSimplifiedStructFormat(e)){var i=Object.keys(e)[0];r.push(Object.assign(t.mapStructNameAndType(i),{components:t.mapStructToCoderFormat(e[i])}))}else r.push(e)})),r},l.prototype.isSimplifiedStructFormat=function(e){return"object"===(0,n.default)(e)&&void 0===e.components&&void 0===e.name},l.prototype.mapStructNameAndType=function(e){var t="tuple";return e.indexOf("[]")>-1&&(t="tuple[]",e=e.slice(0,-2)),{type:t,name:e}},l.prototype.mapStructToCoderFormat=function(e){var t=this,r=[];return Object.keys(e).forEach((function(i){"object"!==(0,n.default)(e[i])?r.push({name:i,type:e[i]}):r.push(Object.assign(t.mapStructNameAndType(i),{components:t.mapStructToCoderFormat(e[i])}))})),r},l.prototype.formatParam=function(e,t){var r=this,n=new RegExp(/^bytes([0-9]*)$/),a=new RegExp(/^bytes([0-9]*)\[\]$/),s=new RegExp(/^(u?int)([0-9]*)$/),u=new RegExp(/^(u?int)([0-9]*)\[\]$/);if(o.isBN(t)||o.isBigNumber(t))return t.toString(10);if(e.match(a)||e.match(u))return t.map((function(t){return r.formatParam(e.replace("[]",""),t)}));var c=e.match(s);if(c){var l=parseInt(c[2]||"256");l/80&&(!t||"0x"===t||"0X"===t))throw new Error("Returned values aren't valid, did it run Out of Gas? You might also see this error if you are not using the correct ABI for the contract you are retrieving data from, requesting data from a block number that does not exist, or querying a node which is not fully synced.");var i=u.decode(this.mapTypes(e),"0x"+t.replace(/0x/i,""),r),o=new c;return o.__length__=0,e.forEach((function(e,t){var r=i[o.__length__],a="object"===(0,n.default)(e)&&e.type&&"string"===e.type;r="0x"!==r||a||"string"==typeof e&&"string"===e?r:null,o[t]=r,("function"==typeof e||e&&"object"===(0,n.default)(e))&&e.name&&(o[e.name]=r),o.__length__++})),o},l.prototype.decodeLog=function(e,t,r){var n=this;r=Array.isArray(r)?r:[r],t=t||"";var i=[],o=[],a=0;e.forEach((function(e,t){e.indexed?(o[t]=["bool","int","uint","address","fixed","ufixed"].find((function(t){return-1!==e.type.indexOf(t)}))?n.decodeParameter(e.type,r[a]):r[a],a++):i[t]=e}));var s=t,u=s?this.decodeParametersWith(i,s,!0):[],l=new c;return l.__length__=0,e.forEach((function(e,t){l[t]="string"===e.type?"":null,void 0!==u[t]&&(l[t]=u[t]),void 0!==o[t]&&(l[t]=o[t]),e.name&&(l[e.name]=l[t]),l.__length__++})),l};var f=new l;e.exports=f},9819:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(3106)),a=i(r(3355)),s=i(r(775)),u=i(r(4519));function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function l(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r0){var l,h="Signer Error: ",d=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return f(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?f(e,t):void 0}}(e))){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}(c);try{for(d.s();!(l=d.n()).done;){var p=l.value;h+="".concat(h," ").concat(p,".")}}catch(e){d.e(e)}finally{d.f()}throw new Error(h)}var m="0x"+u.serialize().toString("hex"),y=b.keccak256(m),g={messageHash:"0x"+n.from(u.getMessageToSign(!0)).toString("hex"),v:"0x"+u.v.toString("hex"),r:"0x"+u.r.toString("hex"),s:"0x"+u.s.toString("hex"),rawTransaction:m,transactionHash:y};return r(null,g),g}catch(e){return r(e),Promise.reject(e)}}return e.type=function(e){var t,r=void 0!==e.maxFeePerGas||void 0!==e.maxPriorityFeePerGas;if(void 0!==e.type?t=b.toHex(e.type):void 0===e.type&&r&&(t="0x2"),void 0!==e.gasPrice&&("0x2"===t||r))throw Error("eip-1559 transactions don't support gasPrice");if(("0x1"===t||"0x0"===t)&&r)throw Error("pre-eip-1559 transaction don't support maxFeePerGas/maxPriorityFeePerGas");return r||e.common&&e.common.hardfork&&e.common.hardfork.toLowerCase()===S.London||e.hardfork&&e.hardfork.toLowerCase()===S.London?t="0x2":(e.accessList||e.common&&e.common.hardfork&&e.common.hardfork.toLowerCase()===S.Berlin||e.hardfork&&e.hardfork.toLowerCase()===S.Berlin)&&(t="0x1"),t}(e),void 0!==e.nonce&&void 0!==e.chainId&&(void 0!==e.gasPrice||void 0!==e.maxFeePerGas&&void 0!==e.maxPriorityFeePerGas)&&s?Promise.resolve(c(e)):Promise.all([E(e.common)||E(e.common.customChain.chainId)?E(e.chainId)?i._ethereumCall.getChainId():e.chainId:void 0,E(e.nonce)?i._ethereumCall.getTransactionCount(i.privateKeyToAccount(t).address):e.nonce,E(s)?i._ethereumCall.getNetworkId():1,T(i,e)]).then((function(t){var r=(0,u.default)(t,4),n=r[0],i=r[1],o=r[2],a=r[3];if(E(n)&&E(e.common)&&E(e.common.customChain.chainId)||E(i)||E(o)||E(a))throw new Error('One of the values "chainId", "networkId", "gasPrice", or "nonce" couldn\'t be fetched: '+JSON.stringify(t));return c(l(l(l({},e),E(e.common)||E(e.common.customChain.chainId)?{chainId:n}:{}),{},{nonce:i,networkId:o},a))}))},M.prototype.recoverTransaction=function(e){var t=n.from(e.slice(2),"hex"),r=w.fromSerializedData(t);return b.toChecksumAddress(r.getSenderAddress().toString("hex"))},M.prototype.hashMessage=function(e){var t=b.isHexStrict(e)?e:b.utf8ToHex(e),r=b.hexToBytes(t),i=n.from(r),o="Ethereum Signed Message:\n"+r.length,a=n.from(o),s=n.concat([a,i]);return k.bufferToHex(k.keccak256(s))},M.prototype.sign=function(e,t){if(t.startsWith("0x")||(t="0x"+t),66!==t.length)throw new Error("Private key must be 32 bytes long");var r=this.hashMessage(e),n=p.sign(r,t),i=p.decodeSignature(n);return{message:e,messageHash:r,v:i[0],r:i[1],s:i[2],signature:n}},M.prototype.recover=function(e,t,r){var n=[].slice.apply(arguments);return e&&"object"===(0,a.default)(e)?this.recover(e.messageHash,p.encodeSignature([e.v,e.r,e.s]),!0):(r||(e=this.hashMessage(e)),n.length>=4?(r="boolean"==typeof(r=n.slice(-1)[0])&&!!r,this.recover(e,p.encodeSignature(n.slice(1,4)),r)):p.recover(e,t))},M.prototype.decrypt=function(e,t,r){if("string"!=typeof t)throw new Error("No password given.");var i,s,u=e&&"object"===(0,a.default)(e)?e:JSON.parse(r?e.toLowerCase():e);if(3!==u.version)throw new Error("Not a valid V3 wallet");if("scrypt"===u.crypto.kdf)s=u.crypto.kdfparams,i=y.syncScrypt(n.from(t),n.from(s.salt,"hex"),s.n,s.r,s.p,s.dklen);else{if("pbkdf2"!==u.crypto.kdf)throw new Error("Unsupported key derivation scheme");if("hmac-sha256"!==(s=u.crypto.kdfparams).prf)throw new Error("Unsupported parameters to PBKDF2");i=m.pbkdf2Sync(n.from(t),n.from(s.salt,"hex"),s.c,s.dklen,"sha256")}var c=n.from(u.crypto.ciphertext,"hex");if(b.sha3(n.from([].concat((0,o.default)(i.slice(16,32)),(0,o.default)(c)))).replace("0x","")!==u.crypto.mac)throw new Error("Key derivation failed - possibly wrong password");var l=m.createDecipheriv(u.crypto.cipher,i.slice(0,16),n.from(u.crypto.cipherparams.iv,"hex")),f="0x"+n.from([].concat((0,o.default)(l.update(c)),(0,o.default)(l.final()))).toString("hex");return this.privateKeyToAccount(f,!0)},M.prototype.encrypt=function(e,t,r){var i,a=this.privateKeyToAccount(e,!0),s=(r=r||{}).salt||m.randomBytes(32),u=r.iv||m.randomBytes(16),c=r.kdf||"scrypt",l={dklen:r.dklen||32,salt:s.toString("hex")};if("pbkdf2"===c)l.c=r.c||262144,l.prf="hmac-sha256",i=m.pbkdf2Sync(n.from(t),n.from(l.salt,"hex"),l.c,l.dklen,"sha256");else{if("scrypt"!==c)throw new Error("Unsupported kdf");l.n=r.n||8192,l.r=r.r||8,l.p=r.p||1,i=y.syncScrypt(n.from(t),n.from(l.salt,"hex"),l.n,l.r,l.p,l.dklen)}var f=m.createCipheriv(r.cipher||"aes-128-ctr",i.slice(0,16),u);if(!f)throw new Error("Unsupported cipher");var h=n.from([].concat((0,o.default)(f.update(n.from(a.privateKey.replace("0x",""),"hex"))),(0,o.default)(f.final()))),d=b.sha3(n.from([].concat((0,o.default)(i.slice(16,32)),(0,o.default)(h)))).replace("0x","");return{version:3,id:g.v4({random:r.uuid||m.randomBytes(16)}),address:a.address.toLowerCase().replace("0x",""),crypto:{ciphertext:h.toString("hex"),cipherparams:{iv:u.toString("hex")},cipher:r.cipher||"aes-128-ctr",kdf:c,kdfparams:l,mac:d.toString("hex")}}},x.prototype._findSafeIndex=function(e){return e=e||0,this.hasOwnProperty(e)?this._findSafeIndex(e+1):e},x.prototype._currentIndexes=function(){return Object.keys(this).map((function(e){return parseInt(e)})).filter((function(e){return e<9e20}))},x.prototype.create=function(e,t){for(var r=0;r{"use strict";var n=r(8847),i=n(r(775)),o=n(r(3355));function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t0&&e.topics.length!==n+1&&(t={anonymous:!0,inputs:[]})}var i=t.anonymous?e.topics:e.topics.slice(1);return r.returnValues=m.decodeLog(t.inputs,e.data,i),delete r.returnValues.__length__,r.event=t.name,r.signature=t.anonymous||!e.topics[0]?null:e.topics[0],r.raw={data:r.data,topics:r.topics},delete r.data,delete r.topics,r},y.prototype._encodeMethodABI=function(){var e=this._method.signature,t=this.arguments||[],r=!1,n=this._parent.options.jsonInterface.filter((function(t){return"constructor"===e&&t.type===e||(t.signature===e||t.signature===e.replace("0x","")||t.name===e)&&"function"===t.type})).map((function(e){var n=Array.isArray(e.inputs)?e.inputs.length:0;if(n!==t.length)throw new Error("The number of arguments is not matching the methods required number. You need to pass "+n+" arguments.");return"function"===e.type&&(r=e.signature),Array.isArray(e.inputs)?e.inputs:[]})).map((function(e){return m.encodeParameters(e,t).replace("0x","")}))[0]||"";if("constructor"===e){if(!this._deployData)throw new Error("The contract has no contract data option set. This is necessary to append the constructor parameters.");return this._deployData.startsWith("0x")||(this._deployData="0x"+this._deployData),this._deployData+n}var i=r?r+n:n;if(!i)throw new Error("Couldn't find a matching contract method named \""+this._method.name+'".');return i},y.prototype._decodeMethodReturn=function(e,t){if(!t)return null;t=t.length>=2?t.slice(2):t;var r=m.decodeParameters(e,t);return 1===r.__length__?r[0]:(delete r.__length__,r)},y.prototype.deploy=function(e,t){if((e=e||{}).arguments=e.arguments||[],!(e=this._getOrSetDefaultOptions(e)).data){if("function"==typeof t)return t(d.ContractMissingDeployDataError());throw d.ContractMissingDeployDataError()}var r=this.options.jsonInterface.find((function(e){return"constructor"===e.type}))||{};return r.signature="constructor",this._createTxObject.apply({method:r,parent:this,deployData:e.data,_ethAccounts:this.constructor._ethAccounts},e.arguments)},y.prototype._generateEventOptions=function(){var e=Array.prototype.slice.call(arguments),t=this._getCallback(e),r="object"===(!!e[e.length-1]&&(0,o.default)(e[e.length-1]))?e.pop():{},n="string"==typeof e[0]?e[0]:"allevents",i="allevents"===n.toLowerCase()?{name:"ALLEVENTS",jsonInterface:this.options.jsonInterface}:this.options.jsonInterface.find((function(e){return"event"===e.type&&(e.name===n||e.signature==="0x"+n.replace("0x",""))}));if(!i)throw d.ContractEventDoesNotExistError(n);if(!l.isAddress(this.options.address))throw d.ContractNoAddressDefinedError();return{params:this._encodeEventABI(i,r),event:i,callback:t}},y.prototype.clone=function(){return new this.constructor(this.options.jsonInterface,this.options.address,this.options)},y.prototype.once=function(e,t,r){var n=Array.prototype.slice.call(arguments);if(!(r=this._getCallback(n)))throw d.ContractOnceRequiresCallbackError();t&&delete t.fromBlock,this._on(e,t,(function(e,t,n){n.unsubscribe(),"function"==typeof r&&r(e,t,n)}))},y.prototype._on=function(){var e=this._generateEventOptions.apply(this,arguments);e.params&&e.params.toBlock&&(delete e.params.toBlock,console.warn("Invalid option: toBlock. Use getPastEvents for specific range.")),this._checkListener("newListener",e.event.name),this._checkListener("removeListener",e.event.name);var t=new f({subscription:{params:1,inputFormatter:[h.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event),subscriptionHandler:function(e){e.removed?this.emit("changed",e):this.emit("data",e),"function"==typeof this.callback&&this.callback(null,e,this)}},type:"eth",requestManager:this._requestManager});return t.subscribe("logs",e.params,e.callback||function(){}),t},y.prototype.getPastEvents=function(){var e=this._generateEventOptions.apply(this,arguments),t=new c({name:"getPastLogs",call:"eth_getLogs",params:1,inputFormatter:[h.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event)});t.setRequestManager(this._requestManager);var r=t.buildCall();return t=null,r(e.params,e.callback)},y.prototype._createTxObject=function(){var e=Array.prototype.slice.call(arguments),t={};if("function"===this.method.type&&(t.call=this.parent._executeMethod.bind(t,"call"),t.call.request=this.parent._executeMethod.bind(t,"call",!0)),t.send=this.parent._executeMethod.bind(t,"send"),t.send.request=this.parent._executeMethod.bind(t,"send",!0),t.encodeABI=this.parent._encodeMethodABI.bind(t),t.estimateGas=this.parent._executeMethod.bind(t,"estimate"),t.createAccessList=this.parent._executeMethod.bind(t,"createAccessList"),e&&this.method.inputs&&e.length!==this.method.inputs.length){if(this.nextMethod)return this.nextMethod.apply(null,e);throw d.InvalidNumberOfParams(e.length,this.method.inputs.length,this.method.name)}return t.arguments=e||[],t._method=this.method,t._parent=this.parent,t._ethAccounts=this.parent.constructor._ethAccounts||this._ethAccounts,this.deployData&&(t._deployData=this.deployData),t},y.prototype._processExecuteArguments=function(e,t){var r={};if(r.type=e.shift(),r.callback=this._parent._getCallback(e),"call"!==r.type||!0===e[e.length-1]||"string"!=typeof e[e.length-1]&&!isFinite(e[e.length-1])||(r.defaultBlock=e.pop()),r.options="object"===(!!e[e.length-1]&&(0,o.default)(e[e.length-1]))?e.pop():{},r.generateRequest=!0===e[e.length-1]&&e.pop(),r.options=this._parent._getOrSetDefaultOptions(r.options),r.options.data=this.encodeABI(),!this._deployData&&!l.isAddress(this._parent.options.address))throw d.ContractNoAddressDefinedError();return this._deployData||(r.options.to=this._parent.options.address),r.options.data?r:l._fireError(new Error("Couldn't find a matching contract method, or the number of parameters is wrong."),t.eventEmitter,t.reject,r.callback)},y.prototype._executeMethod=function(){var e=this,t=this._parent._processExecuteArguments.call(this,Array.prototype.slice.call(arguments),r),r=p("send"!==t.type),n=e.constructor._ethAccounts||e._ethAccounts;if(t.generateRequest){var i={params:[h.inputCallFormatter.call(this._parent,t.options)],callback:t.callback};return"call"===t.type?(i.params.push(h.inputDefaultBlockNumberFormatter.call(this._parent,t.defaultBlock)),i.method="eth_call",i.format=this._parent._decodeMethodReturn.bind(null,this._method.outputs)):i.method="eth_sendTransaction",i}switch(t.type){case"createAccessList":if(!l.isAddress(t.options.from))return l._fireError(d.ContractNoFromAddressDefinedError(),r.eventEmitter,r.reject,t.callback);var o=new c({name:"createAccessList",call:"eth_createAccessList",params:2,inputFormatter:[h.inputTransactionFormatter,h.inputDefaultBlockNumberFormatter],requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock}).createFunction();return o(t.options,t.callback);case"estimate":var a=new c({name:"estimateGas",call:"eth_estimateGas",params:1,inputFormatter:[h.inputCallFormatter],outputFormatter:l.hexToNumber,requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock}).createFunction();return a(t.options,t.callback);case"call":var s=new c({name:"call",call:"eth_call",params:2,inputFormatter:[h.inputCallFormatter,h.inputDefaultBlockNumberFormatter],outputFormatter:function(t){return e._parent._decodeMethodReturn(e._method.outputs,t)},requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock,handleRevert:e._parent.handleRevert,abiCoder:m}).createFunction();return s(t.options,t.defaultBlock,t.callback);case"send":if(!l.isAddress(t.options.from))return l._fireError(d.ContractNoFromAddressDefinedError(),r.eventEmitter,r.reject,t.callback);if("boolean"==typeof this._method.payable&&!this._method.payable&&t.options.value&&t.options.value>0)return l._fireError(new Error("Can not send value to non-payable contract method or constructor"),r.eventEmitter,r.reject,t.callback);var u={receiptFormatter:function(t){if(Array.isArray(t.logs)){var r=t.logs.map((function(t){return e._parent._decodeEventABI.call({name:"ALLEVENTS",jsonInterface:e._parent.options.jsonInterface},t)}));t.events={};var n=0;r.forEach((function(e){e.event?t.events[e.event]?Array.isArray(t.events[e.event])?t.events[e.event].push(e):t.events[e.event]=[t.events[e.event],e]:t.events[e.event]=e:(t.events[n]=e,n++)})),delete t.logs}return t},contractDeployFormatter:function(t){var r=e._parent.clone();return r.options.address=t.contractAddress,r}},f=new c({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[h.inputTransactionFormatter],requestManager:e._parent._requestManager,accounts:e.constructor._ethAccounts||e._ethAccounts,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock,transactionBlockTimeout:e._parent.transactionBlockTimeout,transactionConfirmationBlocks:e._parent.transactionConfirmationBlocks,transactionPollingTimeout:e._parent.transactionPollingTimeout,transactionPollingInterval:e._parent.transactionPollingInterval,defaultCommon:e._parent.defaultCommon,defaultChain:e._parent.defaultChain,defaultHardfork:e._parent.defaultHardfork,handleRevert:e._parent.handleRevert,extraFormatters:u,abiCoder:m}).createFunction();return f(t.options,t.callback);default:throw new Error('Method "'+t.type+'" not implemented.')}},e.exports=y},6764:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(2247)),o=n(r(5698)),a=r(5160),s=r(1314).formatters,u=r(8161),c=r(1841),l=r(2867),f=r(2689);function h(e){this.eth=e;var t=null;this._detectedAddress=null,this._lastSyncCheck=null,Object.defineProperty(this,"registry",{get:function(){return new c(this)},enumerable:!0}),Object.defineProperty(this,"resolverMethodHandler",{get:function(){return new l(this.registry)},enumerable:!0}),Object.defineProperty(this,"registryAddress",{get:function(){return t},set:function(e){t=null!==e?s.inputAddressFormatter(e):e},enumerable:!0})}h.prototype.supportsInterface=function(e,t,r){return this.getResolver(e).then((function(e){return u.isHexStrict(t)||(t=u.sha3(t).slice(0,10)),e.methods.supportsInterface(t).call(r)})).catch((function(e){if("function"!=typeof r)throw e;r(e,null)}))},h.prototype.resolver=function(e,t){return this.registry.resolver(e,t)},h.prototype.getResolver=function(e,t){return this.registry.getResolver(e,t)},h.prototype.setResolver=function(e,t,r,n){return this.registry.setResolver(e,t,r,n)},h.prototype.setRecord=function(e,t,r,n,i,o){return this.registry.setRecord(e,t,r,n,i,o)},h.prototype.setSubnodeRecord=function(e,t,r,n,i,o,a){return this.registry.setSubnodeRecord(e,t,r,n,i,o,a)},h.prototype.setApprovalForAll=function(e,t,r,n){return this.registry.setApprovalForAll(e,t,r,n)},h.prototype.isApprovedForAll=function(e,t,r){return this.registry.isApprovedForAll(e,t,r)},h.prototype.recordExists=function(e,t){return this.registry.recordExists(e,t)},h.prototype.setSubnodeOwner=function(e,t,r,n,i){return this.registry.setSubnodeOwner(e,t,r,n,i)},h.prototype.getTTL=function(e,t){return this.registry.getTTL(e,t)},h.prototype.setTTL=function(e,t,r,n){return this.registry.setTTL(e,t,r,n)},h.prototype.getOwner=function(e,t){return this.registry.getOwner(e,t)},h.prototype.setOwner=function(e,t,r,n){return this.registry.setOwner(e,t,r,n)},h.prototype.getAddress=function(e,t){return this.resolverMethodHandler.method(e,"addr",[]).call(t)},h.prototype.setAddress=function(e,t,r,n){return this.resolverMethodHandler.method(e,"setAddr",[t]).send(r,n)},h.prototype.getPubkey=function(e,t){return this.resolverMethodHandler.method(e,"pubkey",[],null,t).call(t)},h.prototype.setPubkey=function(e,t,r,n,i){return this.resolverMethodHandler.method(e,"setPubkey",[t,r]).send(n,i)},h.prototype.getContent=function(e,t){return this.resolverMethodHandler.method(e,"content",[]).call(t)},h.prototype.setContent=function(e,t,r,n){return this.resolverMethodHandler.method(e,"setContent",[t]).send(r,n)},h.prototype.getContenthash=function(e,t){return this.resolverMethodHandler.method(e,"contenthash",[],f.decode).call(t)},h.prototype.setContenthash=function(e,t,r,n){var i;try{i=f.encode(t)}catch(e){var o=new Error("Could not encode "+t+". See docs for supported hash protocols.");if("function"==typeof n)return void n(o,null);throw o}return this.resolverMethodHandler.method(e,"setContenthash",[i]).send(r,n)},h.prototype.getMultihash=function(e,t){return this.resolverMethodHandler.method(e,"multihash",[]).call(t)},h.prototype.setMultihash=function(e,t,r,n){return this.resolverMethodHandler.method(e,"multihash",[t]).send(r,n)},h.prototype.checkNetwork=(0,o.default)(i.default.mark((function e(){var t,r,n,o,s;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=new Date/1e3,this._lastSyncCheck&&!(t-this._lastSyncCheck>3600)){e.next=9;break}return e.next=4,this.eth.getBlock("latest");case 4:if(r=e.sent,!((n=t-r.timestamp)>3600)){e.next=8;break}throw new Error("Network not synced; last block was "+n+" seconds ago");case 8:this._lastSyncCheck=t;case 9:if(!this.registryAddress){e.next=11;break}return e.abrupt("return",this.registryAddress);case 11:if(this._detectedAddress){e.next=20;break}return e.next=14,this.eth.net.getNetworkType();case 14:if(o=e.sent,void 0!==(s=a.addresses[o])){e.next=18;break}throw new Error("ENS is not supported on network "+o);case 18:return this._detectedAddress=s,e.abrupt("return",this._detectedAddress);case 20:return e.abrupt("return",this._detectedAddress);case 21:case"end":return e.stop()}}),e,this)}))),e.exports=h},5160:e=>{"use strict";e.exports={addresses:{main:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",ropsten:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",rinkeby:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",goerli:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},interfaceIds:{addr:"0x3b3b57de",setAddr:"0x3b3b57de",pubkey:"0xc8690233",setPubkey:"0xc8690233",contenthash:"0xbc1c58d1",setContenthash:"0xbc1c58d1",content:"0xd8389dc5",setContent:"0xd8389dc5"}}},1841:(e,t,r)=>{"use strict";var n=r(8164),i=r(1006),o=r(282),a=r(1314).formatters,s=r(8161),u=r(3205),c=r(8384);function l(e){var t=this;this.ens=e,this.contract=e.checkNetwork().then((function(e){var r=new n(u,e);return r.setProvider(t.ens.eth.currentProvider),r}))}l.prototype.owner=function(e,t){return console.warn('Deprecated: Please use the "getOwner" method instead of "owner".'),this.getOwner(e,t)},l.prototype.getOwner=function(e,t){var r=new o(!0);return this.contract.then((function(t){return t.methods.owner(i.hash(e)).call()})).then((function(e){"function"!=typeof t?r.resolve(e):t(e,e)})).catch((function(e){"function"!=typeof t?r.reject(e):t(e,null)})),r.eventEmitter},l.prototype.setOwner=function(e,t,r,n){var s=new o(!0);return this.contract.then((function(n){return n.methods.setOwner(i.hash(e),a.inputAddressFormatter(t)).send(r)})).then((function(e){"function"!=typeof n?s.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?s.reject(e):n(e,null)})),s.eventEmitter},l.prototype.getTTL=function(e,t){var r=new o(!0);return this.contract.then((function(t){return t.methods.ttl(i.hash(e)).call()})).then((function(e){"function"!=typeof t?r.resolve(e):t(e,e)})).catch((function(e){"function"!=typeof t?r.reject(e):t(e,null)})),r.eventEmitter},l.prototype.setTTL=function(e,t,r,n){var a=new o(!0);return this.contract.then((function(n){return n.methods.setTTL(i.hash(e),t).send(r)})).then((function(e){"function"!=typeof n?a.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?a.reject(e):n(e,null)})),a.eventEmitter},l.prototype.setSubnodeOwner=function(e,t,r,n,u){var c=new o(!0);return s.isHexStrict(t)||(t=s.sha3(t)),this.contract.then((function(o){return o.methods.setSubnodeOwner(i.hash(e),t,a.inputAddressFormatter(r)).send(n)})).then((function(e){"function"!=typeof u?c.resolve(e):u(e,e)})).catch((function(e){"function"!=typeof u?c.reject(e):u(e,null)})),c.eventEmitter},l.prototype.setRecord=function(e,t,r,n,s,u){var c=new o(!0);return this.contract.then((function(o){return o.methods.setRecord(i.hash(e),a.inputAddressFormatter(t),a.inputAddressFormatter(r),n).send(s)})).then((function(e){"function"!=typeof u?c.resolve(e):u(e,e)})).catch((function(e){"function"!=typeof u?c.reject(e):u(e,null)})),c.eventEmitter},l.prototype.setSubnodeRecord=function(e,t,r,n,u,c,l){var f=new o(!0);return s.isHexStrict(t)||(t=s.sha3(t)),this.contract.then((function(o){return o.methods.setSubnodeRecord(i.hash(e),t,a.inputAddressFormatter(r),a.inputAddressFormatter(n),u).send(c)})).then((function(e){"function"!=typeof l?f.resolve(e):l(e,e)})).catch((function(e){"function"!=typeof l?f.reject(e):l(e,null)})),f.eventEmitter},l.prototype.setApprovalForAll=function(e,t,r,n){var i=new o(!0);return this.contract.then((function(n){return n.methods.setApprovalForAll(a.inputAddressFormatter(e),t).send(r)})).then((function(e){"function"!=typeof n?i.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?i.reject(e):n(e,null)})),i.eventEmitter},l.prototype.isApprovedForAll=function(e,t,r){var n=new o(!0);return this.contract.then((function(r){return r.methods.isApprovedForAll(a.inputAddressFormatter(e),a.inputAddressFormatter(t)).call()})).then((function(e){"function"!=typeof r?n.resolve(e):r(e,e)})).catch((function(e){"function"!=typeof r?n.reject(e):r(e,null)})),n.eventEmitter},l.prototype.recordExists=function(e,t){var r=new o(!0);return this.contract.then((function(t){return t.methods.recordExists(i.hash(e)).call()})).then((function(e){"function"!=typeof t?r.resolve(e):t(e,e)})).catch((function(e){"function"!=typeof t?r.reject(e):t(e,null)})),r.eventEmitter},l.prototype.resolver=function(e,t){return console.warn('Deprecated: Please use the "getResolver" method instead of "resolver".'),this.getResolver(e,t)},l.prototype.getResolver=function(e,t){var r=this;return this.contract.then((function(t){return t.methods.resolver(i.hash(e)).call()})).then((function(e){var i=new n(c,e);if(i.setProvider(r.ens.eth.currentProvider),"function"!=typeof t)return i;t(i,i)})).catch((function(e){if("function"!=typeof t)throw e;t(e,null)}))},l.prototype.setResolver=function(e,t,r,n){var s=new o(!0);return this.contract.then((function(n){return n.methods.setResolver(i.hash(e),a.inputAddressFormatter(t)).send(r)})).then((function(e){"function"!=typeof n?s.resolve(e):n(e,e)})).catch((function(e){"function"!=typeof n?s.reject(e):n(e,null)})),s.eventEmitter},e.exports=l},715:(e,t,r)=>{"use strict";var n=r(6764);e.exports=n},2867:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(2247)),o=n(r(5698)),a=r(282),s=r(1006),u=r(1314).errors,c=r(5160).interfaceIds;function l(e){this.registry=e}l.prototype.method=function(e,t,r,n,i){return{call:this.call.bind({ensName:e,methodName:t,methodArguments:r,callback:i,parent:this,outputFormatter:n}),send:this.send.bind({ensName:e,methodName:t,methodArguments:r,callback:i,parent:this})}},l.prototype.call=function(e){var t=this,r=new a,n=this.parent.prepareArguments(this.ensName,this.methodArguments),s=this.outputFormatter||null;return this.parent.registry.getResolver(this.ensName).then(function(){var a=(0,o.default)(i.default.mark((function o(a){return i.default.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,t.parent.checkInterfaceSupport(a,t.methodName);case 2:t.parent.handleCall(r,a.methods[t.methodName],n,s,e);case 3:case"end":return i.stop()}}),o)})));return function(e){return a.apply(this,arguments)}}()).catch((function(t){"function"!=typeof e?r.reject(t):e(t,null)})),r.eventEmitter},l.prototype.send=function(e,t){var r=this,n=new a,s=this.parent.prepareArguments(this.ensName,this.methodArguments);return this.parent.registry.getResolver(this.ensName).then(function(){var a=(0,o.default)(i.default.mark((function o(a){return i.default.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,r.parent.checkInterfaceSupport(a,r.methodName);case 2:r.parent.handleSend(n,a.methods[r.methodName],s,e,t);case 3:case"end":return i.stop()}}),o)})));return function(e){return a.apply(this,arguments)}}()).catch((function(e){"function"!=typeof t?n.reject(e):t(e,null)})),n.eventEmitter},l.prototype.handleCall=function(e,t,r,n,i){return t.apply(this,r).call().then((function(t){n&&(t=n(t)),"function"!=typeof i?e.resolve(t):i(t,t)})).catch((function(t){"function"!=typeof i?e.reject(t):i(t,null)})),e},l.prototype.handleSend=function(e,t,r,n,i){return t.apply(this,r).send(n).on("sending",(function(){e.eventEmitter.emit("sending")})).on("sent",(function(){e.eventEmitter.emit("sent")})).on("transactionHash",(function(t){e.eventEmitter.emit("transactionHash",t)})).on("confirmation",(function(t,r){e.eventEmitter.emit("confirmation",t,r)})).on("receipt",(function(t){e.eventEmitter.emit("receipt",t),e.resolve(t),"function"==typeof i&&i(t,t)})).on("error",(function(t){e.eventEmitter.emit("error",t),"function"!=typeof i?e.reject(t):i(t,null)})),e},l.prototype.prepareArguments=function(e,t){var r=s.hash(e);return t.length>0?(t.unshift(r),t):[r]},l.prototype.checkInterfaceSupport=function(){var e=(0,o.default)(i.default.mark((function e(t,r){var n;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(c[r]){e.next=2;break}return e.abrupt("return");case 2:return n=!1,e.prev=3,e.next=6,t.methods.supportsInterface(c[r]).call();case 6:n=e.sent,e.next=12;break;case 9:e.prev=9,e.t0=e.catch(3),console.warn('Could not verify interface of resolver contract at "'+t.options.address+'". ');case 12:if(n){e.next=14;break}throw u.ResolverMethodMissingError(t.options.address,r);case 14:case"end":return e.stop()}}),e,null,[[3,9]])})));return function(t,r){return e.apply(this,arguments)}}(),e.exports=l},2689:(e,t,r)=>{"use strict";var n=r(4308);e.exports={decode:function(e){var t=null,r=null,i=null;if(e&&e.error)return{protocolType:null,decoded:e.error};if(e)try{t=n.decode(e);var o=n.getCodec(e);"ipfs-ns"===o?r="ipfs":"swarm-ns"===o?r="bzz":"onion"===o?r="onion":"onion3"===o?r="onion3":t=e}catch(e){i=e.message}return{protocolType:r,decoded:t,error:i}},encode:function(e){var t,r,i=!1;if(e){var o=e.match(/^(ipfs|bzz|onion|onion3):\/\/(.*)/)||e.match(/\/(ipfs)\/(.*)/);o&&(r=o[1],t=o[2]);try{if("ipfs"===r)t.length>=4&&(i="0x"+n.fromIpfs(t));else if("bzz"===r)t.length>=4&&(i="0x"+n.fromSwarm(t));else if("onion"===r)16===t.length&&(i="0x"+n.encode("onion",t));else{if("onion3"!==r)throw new Error("Could not encode content hash: unsupported content type");56===t.length&&(i="0x"+n.encode("onion3",t))}}catch(e){throw e}}return i}}},3205:e=>{"use strict";e.exports=[{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"resolver",outputs:[{name:"",type:"address"}],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"owner",outputs:[{name:"",type:"address"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"label",type:"bytes32"},{name:"owner",type:"address"}],name:"setSubnodeOwner",outputs:[],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"ttl",type:"uint64"}],name:"setTTL",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"ttl",outputs:[{name:"",type:"uint64"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"resolver",type:"address"}],name:"setResolver",outputs:[],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"owner",type:"address"}],name:"setOwner",outputs:[],payable:!1,type:"function"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"owner",type:"address"}],name:"Transfer",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!0,name:"label",type:"bytes32"},{indexed:!1,name:"owner",type:"address"}],name:"NewOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"resolver",type:"address"}],name:"NewResolver",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"ttl",type:"uint64"}],name:"NewTTL",type:"event"},{constant:!1,inputs:[{internalType:"bytes32",name:"node",type:"bytes32"},{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"resolver",type:"address"},{internalType:"uint64",name:"ttl",type:"uint64"}],name:"setRecord",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!1,inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{constant:!0,inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{internalType:"bytes32",name:"node",type:"bytes32"}],name:"recordExists",outputs:[{internalType:"bool",name:"",type:"bool"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{internalType:"bytes32",name:"node",type:"bytes32"},{internalType:"bytes32",name:"label",type:"bytes32"},{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"resolver",type:"address"},{internalType:"uint64",name:"ttl",type:"uint64"}],name:"setSubnodeRecord",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"}]},8384:e=>{"use strict";e.exports=[{constant:!0,inputs:[{name:"interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{name:"",type:"bool"}],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"},{name:"contentTypes",type:"uint256"}],name:"ABI",outputs:[{name:"contentType",type:"uint256"},{name:"data",type:"bytes"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"hash",type:"bytes"}],name:"setMultihash",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"multihash",outputs:[{name:"",type:"bytes"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"x",type:"bytes32"},{name:"y",type:"bytes32"}],name:"setPubkey",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"content",outputs:[{name:"ret",type:"bytes32"}],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"addr",outputs:[{name:"ret",type:"address"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"contentType",type:"uint256"},{name:"data",type:"bytes"}],name:"setABI",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"name",outputs:[{name:"ret",type:"string"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"name",type:"string"}],name:"setName",outputs:[],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"hash",type:"bytes32"}],name:"setContent",outputs:[],payable:!1,type:"function"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"pubkey",outputs:[{name:"x",type:"bytes32"},{name:"y",type:"bytes32"}],payable:!1,type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"addr",type:"address"}],name:"setAddr",outputs:[],payable:!1,type:"function"},{inputs:[{name:"ensAddr",type:"address"}],payable:!1,type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"a",type:"address"}],name:"AddrChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"hash",type:"bytes32"}],name:"ContentChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"name",type:"string"}],name:"NameChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!0,name:"contentType",type:"uint256"}],name:"ABIChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"x",type:"bytes32"},{indexed:!1,name:"y",type:"bytes32"}],name:"PubkeyChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"node",type:"bytes32"},{indexed:!1,name:"hash",type:"bytes"}],name:"ContenthashChanged",type:"event"},{constant:!0,inputs:[{name:"node",type:"bytes32"}],name:"contenthash",outputs:[{name:"",type:"bytes"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{name:"node",type:"bytes32"},{name:"hash",type:"bytes"}],name:"setContenthash",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"}]},6:(e,t,r)=>{"use strict";var n=r(8847),i=n(r(9721)),o=n(r(8985)),a=r(8161),s=r(1734),u=function(e){var t="A".charCodeAt(0),r="Z".charCodeAt(0);return(e=(e=e.toUpperCase()).slice(4)+e.slice(0,4)).split("").map((function(e){var n=e.charCodeAt(0);return n>=t&&n<=r?n-t+10:e})).join("")},c=function(e){for(var t,r=e;r.length>2;)t=r.slice(0,9),r=parseInt(t,10)%97+r.slice(t.length);return parseInt(r,10)%97},l=function(){function e(t){(0,i.default)(this,e),this._iban=t}return(0,o.default)(e,[{key:"isValid",value:function(){return/^XE[0-9]{2}(ETH[0-9A-Z]{13}|[0-9A-Z]{30,31})$/.test(this._iban)&&1===c(u(this._iban))}},{key:"isDirect",value:function(){return 34===this._iban.length||35===this._iban.length}},{key:"isIndirect",value:function(){return 20===this._iban.length}},{key:"checksum",value:function(){return this._iban.slice(2,4)}},{key:"institution",value:function(){return this.isIndirect()?this._iban.slice(7,11):""}},{key:"client",value:function(){return this.isIndirect()?this._iban.slice(11):""}},{key:"toAddress",value:function(){if(this.isDirect()){var e=this._iban.slice(4),t=new s(e,36);return a.toChecksumAddress(t.toString(16,20))}return""}},{key:"toString",value:function(){return this._iban}}],[{key:"toAddress",value:function(t){if(!(t=new e(t)).isDirect())throw new Error("IBAN is indirect and can't be converted");return t.toAddress()}},{key:"toIban",value:function(t){return e.fromAddress(t).toString()}},{key:"fromAddress",value:function(t){if(!a.isAddress(t))throw new Error("Provided address is not a valid address: "+t);t=t.replace("0x","").replace("0X","");var r=function(e,t){for(var r=e;r.length<30;)r="0"+r;return r}(new s(t,16).toString(36));return e.fromBban(r.toUpperCase())}},{key:"fromBban",value:function(t){return new e("XE"+("0"+(98-c(u("XE00"+t)))).slice(-2)+t)}},{key:"createIndirect",value:function(t){return e.fromBban("ETH"+t.institution+t.identifier)}},{key:"isValid",value:function(t){return new e(t).isValid()}}]),e}();e.exports=l},6306:(e,t,r)=>{"use strict";var n=r(606),i=r(3349),o=r(8161),a=r(473),s=r(1314).formatters,u=function(){var e=this;n.packageInit(this,arguments),this.net=new a(this);var t=null,r="latest";Object.defineProperty(this,"defaultAccount",{get:function(){return t},set:function(e){return e&&(t=o.toChecksumAddress(s.inputAddressFormatter(e))),u.forEach((function(e){e.defaultAccount=t})),e},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return r},set:function(e){return r=e,u.forEach((function(e){e.defaultBlock=r})),e},enumerable:!0});var u=[new i({name:"getAccounts",call:"personal_listAccounts",params:0,outputFormatter:o.toChecksumAddress}),new i({name:"newAccount",call:"personal_newAccount",params:1,inputFormatter:[null],outputFormatter:o.toChecksumAddress}),new i({name:"unlockAccount",call:"personal_unlockAccount",params:3,inputFormatter:[s.inputAddressFormatter,null,null]}),new i({name:"lockAccount",call:"personal_lockAccount",params:1,inputFormatter:[s.inputAddressFormatter]}),new i({name:"importRawKey",call:"personal_importRawKey",params:2}),new i({name:"sendTransaction",call:"personal_sendTransaction",params:2,inputFormatter:[s.inputTransactionFormatter,null]}),new i({name:"signTransaction",call:"personal_signTransaction",params:2,inputFormatter:[s.inputTransactionFormatter,null]}),new i({name:"sign",call:"personal_sign",params:3,inputFormatter:[s.inputSignFormatter,s.inputAddressFormatter,null]}),new i({name:"ecRecover",call:"personal_ecRecover",params:2,inputFormatter:[s.inputSignFormatter,null]})];u.forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager),t.defaultBlock=e.defaultBlock,t.defaultAccount=e.defaultAccount}))};n.addProviders(u),e.exports=u},8130:e=>{"use strict";e.exports=function(e){var t,r=this;return this.net.getId().then((function(e){return t=e,r.getBlock(0)})).then((function(r){var n="private";return"0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3"===r.hash&&1===t&&(n="main"),"0x41941023680923e0fe4d74a34bdac8141f2540e3ae90623718e47d66d1ca4a2d"===r.hash&&3===t&&(n="ropsten"),"0x6341fd3daf94b748c72ced5a5b26028f2474f5f00d824504e4fa37a75767e177"===r.hash&&4===t&&(n="rinkeby"),"0xbf7e331f7f7c1dd2e05159666b3bf8bc7a8a3a9eb1d518969eab529dd9b88c1a"===r.hash&&5===t&&(n="goerli"),"0xa3c565fc15c7478862d50ccd6561e3c06b24cc509bf388941c25ea985ce32cb9"===r.hash&&42===t&&(n="kovan"),"function"==typeof e&&e(null,n),n})).catch((function(t){if("function"!=typeof e)throw t;e(t)}))}},6748:(e,t,r)=>{"use strict";var n=r(606),i=r(1314),o=r(4178).subscriptions,a=r(3349),s=r(8161),u=r(473),c=r(715),l=r(6306),f=r(8164),h=r(6),d=r(9819),p=r(9901),m=r(8130),y=i.formatters,g=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getBlockByHash":"eth_getBlockByNumber"},b=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getTransactionByBlockHashAndIndex":"eth_getTransactionByBlockNumberAndIndex"},v=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getUncleByBlockHashAndIndex":"eth_getUncleByBlockNumberAndIndex"},w=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getBlockTransactionCountByHash":"eth_getBlockTransactionCountByNumber"},A=function(e){return"string"==typeof e[0]&&0===e[0].indexOf("0x")?"eth_getUncleCountByBlockHash":"eth_getUncleCountByBlockNumber"},S=function(){var e=this;n.packageInit(this,arguments);var t=this.setRequestManager;this.setRequestManager=function(r){return t(r),e.net.setRequestManager(r),e.personal.setRequestManager(r),e.accounts.setRequestManager(r),e.Contract._requestManager=e._requestManager,e.Contract.currentProvider=e._provider,!0};var r=this.setProvider;this.setProvider=function(){r.apply(e,arguments),e.setRequestManager(e._requestManager),e.ens._detectedAddress=null,e.ens._lastSyncCheck=null};var i,S,k,E=!1,_=null,M="latest",T=50,x=24,P=750,I=1e3,O=10,R=100;Object.defineProperty(this,"handleRevert",{get:function(){return E},set:function(t){E=t,e.Contract.handleRevert=E,N.forEach((function(e){e.handleRevert=E}))},enumerable:!0}),Object.defineProperty(this,"defaultCommon",{get:function(){return k},set:function(t){k=t,e.Contract.defaultCommon=k,N.forEach((function(e){e.defaultCommon=k}))},enumerable:!0}),Object.defineProperty(this,"defaultHardfork",{get:function(){return S},set:function(t){S=t,e.Contract.defaultHardfork=S,N.forEach((function(e){e.defaultHardfork=S}))},enumerable:!0}),Object.defineProperty(this,"defaultChain",{get:function(){return i},set:function(t){i=t,e.Contract.defaultChain=i,N.forEach((function(e){e.defaultChain=i}))},enumerable:!0}),Object.defineProperty(this,"transactionPollingTimeout",{get:function(){return P},set:function(t){P=t,e.Contract.transactionPollingTimeout=P,N.forEach((function(e){e.transactionPollingTimeout=P}))},enumerable:!0}),Object.defineProperty(this,"transactionPollingInterval",{get:function(){return I},set:function(t){I=t,e.Contract.transactionPollingInterval=I,N.forEach((function(e){e.transactionPollingInterval=I}))},enumerable:!0}),Object.defineProperty(this,"transactionConfirmationBlocks",{get:function(){return x},set:function(t){x=t,e.Contract.transactionConfirmationBlocks=x,N.forEach((function(e){e.transactionConfirmationBlocks=x}))},enumerable:!0}),Object.defineProperty(this,"transactionBlockTimeout",{get:function(){return T},set:function(t){T=t,e.Contract.transactionBlockTimeout=T,N.forEach((function(e){e.transactionBlockTimeout=T}))},enumerable:!0}),Object.defineProperty(this,"blockHeaderTimeout",{get:function(){return O},set:function(t){O=t,e.Contract.blockHeaderTimeout=O,N.forEach((function(e){e.blockHeaderTimeout=O}))},enumerable:!0}),Object.defineProperty(this,"defaultAccount",{get:function(){return _},set:function(t){return t&&(_=s.toChecksumAddress(y.inputAddressFormatter(t))),e.Contract.defaultAccount=_,e.personal.defaultAccount=_,N.forEach((function(e){e.defaultAccount=_})),t},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return M},set:function(t){return M=t,e.Contract.defaultBlock=M,e.personal.defaultBlock=M,N.forEach((function(e){e.defaultBlock=M})),t},enumerable:!0}),Object.defineProperty(this,"maxListenersWarningThreshold",{get:function(){return R},set:function(t){e.currentProvider&&e.currentProvider.setMaxListeners&&(R=t,e.currentProvider.setMaxListeners(t))},enumerable:!0}),this.clearSubscriptions=e._requestManager.clearSubscriptions.bind(e._requestManager),this.removeSubscriptionById=e._requestManager.removeSubscription.bind(e._requestManager),this.net=new u(this),this.net.getNetworkType=m.bind(this),this.accounts=new d(this),this.personal=new l(this),this.personal.defaultAccount=this.defaultAccount,this.maxListenersWarningThreshold=R;var C=this,B=function(){f.apply(this,arguments);var e=this,t=C.setProvider;C.setProvider=function(){t.apply(C,arguments),n.packageInit(e,[C])}};B.setProvider=function(){f.setProvider.apply(this,arguments)},B.prototype=Object.create(f.prototype),B.prototype.constructor=B,this.Contract=B,this.Contract.defaultAccount=this.defaultAccount,this.Contract.defaultBlock=this.defaultBlock,this.Contract.transactionBlockTimeout=this.transactionBlockTimeout,this.Contract.transactionConfirmationBlocks=this.transactionConfirmationBlocks,this.Contract.transactionPollingTimeout=this.transactionPollingTimeout,this.Contract.transactionPollingInterval=this.transactionPollingInterval,this.Contract.blockHeaderTimeout=this.blockHeaderTimeout,this.Contract.handleRevert=this.handleRevert,this.Contract._requestManager=this._requestManager,this.Contract._ethAccounts=this.accounts,this.Contract.currentProvider=this._requestManager.provider,this.Iban=h,this.abi=p,this.ens=new c(this);var N=[new a({name:"getNodeInfo",call:"web3_clientVersion"}),new a({name:"getProtocolVersion",call:"eth_protocolVersion",params:0}),new a({name:"getCoinbase",call:"eth_coinbase",params:0}),new a({name:"isMining",call:"eth_mining",params:0}),new a({name:"getHashrate",call:"eth_hashrate",params:0,outputFormatter:s.hexToNumber}),new a({name:"isSyncing",call:"eth_syncing",params:0,outputFormatter:y.outputSyncingFormatter}),new a({name:"getGasPrice",call:"eth_gasPrice",params:0,outputFormatter:y.outputBigNumberFormatter}),new a({name:"getFeeHistory",call:"eth_feeHistory",params:3,inputFormatter:[s.numberToHex,y.inputBlockNumberFormatter,null]}),new a({name:"getAccounts",call:"eth_accounts",params:0,outputFormatter:s.toChecksumAddress}),new a({name:"getBlockNumber",call:"eth_blockNumber",params:0,outputFormatter:s.hexToNumber}),new a({name:"getBalance",call:"eth_getBalance",params:2,inputFormatter:[y.inputAddressFormatter,y.inputDefaultBlockNumberFormatter],outputFormatter:y.outputBigNumberFormatter}),new a({name:"getStorageAt",call:"eth_getStorageAt",params:3,inputFormatter:[y.inputAddressFormatter,s.numberToHex,y.inputDefaultBlockNumberFormatter]}),new a({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[y.inputAddressFormatter,y.inputDefaultBlockNumberFormatter]}),new a({name:"getBlock",call:g,params:2,inputFormatter:[y.inputBlockNumberFormatter,function(e){return!!e}],outputFormatter:y.outputBlockFormatter}),new a({name:"getUncle",call:v,params:2,inputFormatter:[y.inputBlockNumberFormatter,s.numberToHex],outputFormatter:y.outputBlockFormatter}),new a({name:"getBlockTransactionCount",call:w,params:1,inputFormatter:[y.inputBlockNumberFormatter],outputFormatter:s.hexToNumber}),new a({name:"getBlockUncleCount",call:A,params:1,inputFormatter:[y.inputBlockNumberFormatter],outputFormatter:s.hexToNumber}),new a({name:"getTransaction",call:"eth_getTransactionByHash",params:1,inputFormatter:[null],outputFormatter:y.outputTransactionFormatter}),new a({name:"getTransactionFromBlock",call:b,params:2,inputFormatter:[y.inputBlockNumberFormatter,s.numberToHex],outputFormatter:y.outputTransactionFormatter}),new a({name:"getTransactionReceipt",call:"eth_getTransactionReceipt",params:1,inputFormatter:[null],outputFormatter:y.outputTransactionReceiptFormatter}),new a({name:"getTransactionCount",call:"eth_getTransactionCount",params:2,inputFormatter:[y.inputAddressFormatter,y.inputDefaultBlockNumberFormatter],outputFormatter:s.hexToNumber}),new a({name:"sendSignedTransaction",call:"eth_sendRawTransaction",params:1,inputFormatter:[null],abiCoder:p}),new a({name:"signTransaction",call:"eth_signTransaction",params:1,inputFormatter:[y.inputTransactionFormatter]}),new a({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[y.inputTransactionFormatter],abiCoder:p}),new a({name:"sign",call:"eth_sign",params:2,inputFormatter:[y.inputSignFormatter,y.inputAddressFormatter],transformPayload:function(e){return e.params.reverse(),e}}),new a({name:"call",call:"eth_call",params:2,inputFormatter:[y.inputCallFormatter,y.inputDefaultBlockNumberFormatter],abiCoder:p}),new a({name:"estimateGas",call:"eth_estimateGas",params:1,inputFormatter:[y.inputCallFormatter],outputFormatter:s.hexToNumber}),new a({name:"submitWork",call:"eth_submitWork",params:3}),new a({name:"getWork",call:"eth_getWork",params:0}),new a({name:"getPastLogs",call:"eth_getLogs",params:1,inputFormatter:[y.inputLogFormatter],outputFormatter:y.outputLogFormatter}),new a({name:"getChainId",call:"eth_chainId",params:0,outputFormatter:s.hexToNumber}),new a({name:"requestAccounts",call:"eth_requestAccounts",params:0,outputFormatter:s.toChecksumAddress}),new a({name:"getProof",call:"eth_getProof",params:3,inputFormatter:[y.inputAddressFormatter,y.inputStorageKeysFormatter,y.inputDefaultBlockNumberFormatter],outputFormatter:y.outputProofFormatter}),new a({name:"getPendingTransactions",call:"eth_pendingTransactions",params:0,outputFormatter:y.outputTransactionFormatter}),new a({name:"createAccessList",call:"eth_createAccessList",params:2,inputFormatter:[y.inputTransactionFormatter,y.inputDefaultBlockNumberFormatter]}),new o({name:"subscribe",type:"eth",subscriptions:{newBlockHeaders:{subscriptionName:"newHeads",params:0,outputFormatter:y.outputBlockFormatter},pendingTransactions:{subscriptionName:"newPendingTransactions",params:0},logs:{params:1,inputFormatter:[y.inputLogFormatter],outputFormatter:y.outputLogFormatter,subscriptionHandler:function(e){e.removed?this.emit("changed",e):this.emit("data",e),"function"==typeof this.callback&&this.callback(null,e,this)}},syncing:{params:0,outputFormatter:y.outputSyncingFormatter,subscriptionHandler:function(e){var t=this;!0!==this._isSyncing?(this._isSyncing=!0,this.emit("changed",t._isSyncing),"function"==typeof this.callback&&this.callback(null,t._isSyncing,this),setTimeout((function(){t.emit("data",e),"function"==typeof t.callback&&t.callback(null,e,t)}),0)):(this.emit("data",e),"function"==typeof t.callback&&this.callback(null,e,this),clearTimeout(this._isSyncingTimeout),this._isSyncingTimeout=setTimeout((function(){e.currentBlock>e.highestBlock-200&&(t._isSyncing=!1,t.emit("changed",t._isSyncing),"function"==typeof t.callback&&t.callback(null,t._isSyncing,t))}),500))}}}})];N.forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager,e.accounts),t.defaultBlock=e.defaultBlock,t.defaultAccount=e.defaultAccount,t.transactionBlockTimeout=e.transactionBlockTimeout,t.transactionConfirmationBlocks=e.transactionConfirmationBlocks,t.transactionPollingTimeout=e.transactionPollingTimeout,t.transactionPollingInterval=e.transactionPollingInterval,t.handleRevert=e.handleRevert}))};n.addProviders(S),e.exports=S},473:(e,t,r)=>{"use strict";var n=r(606),i=r(3349),o=r(8161),a=function(){var e=this;n.packageInit(this,arguments),[new i({name:"getId",call:"net_version",params:0,outputFormatter:parseInt}),new i({name:"isListening",call:"net_listening",params:0}),new i({name:"getPeerCount",call:"net_peerCount",params:0,outputFormatter:o.hexToNumber})].forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager)}))};n.addProviders(a),e.exports=a},4565:(e,t,r)=>{"use strict";var n=r(1314).errors,i=r(9519),o=r(912);r(2439),r(4258).polyfill(),void 0===r.g||r.g.AbortController||r(3368);var a=function(e,t){t=t||{},this.withCredentials=t.withCredentials,this.timeout=t.timeout||0,this.headers=t.headers,this.agent=t.agent,this.connected=!1;var r=!1!==t.keepAlive;this.host=e||"http://localhost:8545",this.agent||("https"===this.host.substring(0,5)?this.httpsAgent=new o.Agent({keepAlive:r}):this.httpAgent=new i.Agent({keepAlive:r}))};a.prototype.send=function(e,t){var r,i={method:"POST",body:JSON.stringify(e)},o={};if("undefined"!=typeof AbortController?r=new AbortController:"undefined"!=typeof window&&void 0!==window.AbortController&&(r=new window.AbortController),void 0!==r&&(i.signal=r.signal),"undefined"==typeof XMLHttpRequest){var a={httpsAgent:this.httpsAgent,httpAgent:this.httpAgent};this.agent&&(a.httpsAgent=this.agent.https,a.httpAgent=this.agent.http),"https"===this.host.substring(0,5)?i.agent=a.httpsAgent:i.agent=a.httpAgent}this.headers&&this.headers.forEach((function(e){o[e.name]=e.value})),o["Content-Type"]||(o["Content-Type"]="application/json"),this.withCredentials?i.credentials="include":i.credentials="omit",i.headers=o,this.timeout>0&&void 0!==r&&(this.timeoutId=setTimeout((function(){r.abort()}),this.timeout)),fetch(this.host,i).then(function(e){void 0!==this.timeoutId&&clearTimeout(this.timeoutId),e.json().then((function(e){t(null,e)})).catch((function(r){t(n.InvalidResponse(e))}))}.bind(this)).catch(function(e){void 0!==this.timeoutId&&clearTimeout(this.timeoutId),"AbortError"===e.name&&t(n.ConnectionTimeout(this.timeout)),t(n.InvalidConnection(this.host))}.bind(this))},a.prototype.disconnect=function(){},a.prototype.supportsSubscriptions=function(){return!1},e.exports=a},2683:(e,t,r)=>{"use strict";var n=r(1314).errors,i=r(3150),o=function(e,t){var r=this;this.responseCallbacks={},this.notificationCallbacks=[],this.path=e,this.connected=!1,this.connection=t.connect({path:this.path}),this.addDefaultEvents();var n=function(e){var t=null;Array.isArray(e)?e.forEach((function(e){r.responseCallbacks[e.id]&&(t=e.id)})):t=e.id,t||-1===e.method.indexOf("_subscription")?r.responseCallbacks[t]&&(r.responseCallbacks[t](null,e),delete r.responseCallbacks[t]):r.notificationCallbacks.forEach((function(t){"function"==typeof t&&t(e)}))};"Socket"===t.constructor.name?i(this.connection).done(n):this.connection.on("data",(function(e){r._parseResponse(e.toString()).forEach(n)}))};o.prototype.addDefaultEvents=function(){var e=this;this.connection.on("connect",(function(){e.connected=!0})),this.connection.on("close",(function(){e.connected=!1})),this.connection.on("error",(function(){e._timeout()})),this.connection.on("end",(function(){e._timeout()})),this.connection.on("timeout",(function(){e._timeout()}))},o.prototype._parseResponse=function(e){var t=this,r=[];return e.replace(/\}[\n\r]?\{/g,"}|--|{").replace(/\}\][\n\r]?\[\{/g,"}]|--|[{").replace(/\}[\n\r]?\[\{/g,"}|--|[{").replace(/\}\][\n\r]?\{/g,"}]|--|{").split("|--|").forEach((function(e){t.lastChunk&&(e=t.lastChunk+e);var i=null;try{i=JSON.parse(e)}catch(r){return t.lastChunk=e,clearTimeout(t.lastChunkTimeout),void(t.lastChunkTimeout=setTimeout((function(){throw t._timeout(),n.InvalidResponse(e)}),15e3))}clearTimeout(t.lastChunkTimeout),t.lastChunk=null,i&&r.push(i)})),r},o.prototype._addResponseCallback=function(e,t){var r=e.id||e[0].id,n=e.method||e[0].method;this.responseCallbacks[r]=t,this.responseCallbacks[r].method=n},o.prototype._timeout=function(){for(var e in this.responseCallbacks)this.responseCallbacks.hasOwnProperty(e)&&(this.responseCallbacks[e](n.InvalidConnection("on IPC")),delete this.responseCallbacks[e])},o.prototype.reconnect=function(){this.connection.connect({path:this.path})},o.prototype.send=function(e,t){this.connection.writable||this.connection.connect({path:this.path}),this.connection.write(JSON.stringify(e)),this._addResponseCallback(e,t)},o.prototype.on=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");"data"===e?this.notificationCallbacks.push(t):this.connection.on(e,t)},o.prototype.once=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");this.connection.once(e,t)},o.prototype.removeListener=function(e,t){var r=this;"data"===e?this.notificationCallbacks.forEach((function(e,n){e===t&&r.notificationCallbacks.splice(n,1)})):this.connection.removeListener(e,t)},o.prototype.removeAllListeners=function(e){"data"===e?this.notificationCallbacks=[]:this.connection.removeAllListeners(e)},o.prototype.reset=function(){this._timeout(),this.notificationCallbacks=[],this.connection.removeAllListeners("error"),this.connection.removeAllListeners("end"),this.connection.removeAllListeners("timeout"),this.addDefaultEvents()},o.prototype.supportsSubscriptions=function(){return!0},e.exports=o},360:(e,t,r)=>{"use strict";var n=r(9142),i=r(9033).Buffer,o=r(8847)(r(3355)),a="[object process]"===Object.prototype.toString.call(void 0!==n?n:0),s="undefined"!=typeof navigator&&"ReactNative"===navigator.product,u=null,c=null;if(a||s){u=function(e){return i.from(e).toString("base64")};var l=r(1143);if(l.URL){var f=l.URL;c=function(e){return new f(e)}}else c=r(1143).parse}else u=btoa.bind("object"===("undefined"==typeof globalThis?"undefined":(0,o.default)(globalThis))?globalThis:self),c=function(e){return new URL(e)};e.exports={parseURL:c,btoa:u}},7651:(e,t,r)=>{"use strict";var n=r(8008),i=r(360),o=r(1314).errors,a=r(1158).w3cwebsocket,s=function(e,t){n.call(this),t=t||{},this.url=e,this._customTimeout=t.timeout||15e3,this.headers=t.headers||{},this.protocol=t.protocol||void 0,this.reconnectOptions=Object.assign({auto:!1,delay:5e3,maxAttempts:!1,onTimeout:!1},t.reconnect),this.clientConfig=t.clientConfig||void 0,this.requestOptions=t.requestOptions||void 0,this.DATA="data",this.CLOSE="close",this.ERROR="error",this.CONNECT="connect",this.RECONNECT="reconnect",this.connection=null,this.requestQueue=new Map,this.responseQueue=new Map,this.reconnectAttempts=0,this.reconnecting=!1;var r=i.parseURL(e);r.username&&r.password&&(this.headers.authorization="Basic "+i.btoa(r.username+":"+r.password)),r.auth&&(this.headers.authorization="Basic "+i.btoa(r.auth)),Object.defineProperty(this,"connected",{get:function(){return this.connection&&this.connection.readyState===this.connection.OPEN},enumerable:!0}),this.connect()};(s.prototype=Object.create(n.prototype)).constructor=s,s.prototype.connect=function(){this.connection=new a(this.url,this.protocol,void 0,this.headers,this.requestOptions,this.clientConfig),this._addSocketListeners()},s.prototype._onMessage=function(e){var t=this;this._parseResponse("string"==typeof e.data?e.data:"").forEach((function(e){if(e.method&&-1!==e.method.indexOf("_subscription"))t.emit(t.DATA,e);else{var r=e.id;Array.isArray(e)&&(r=e[0].id),t.responseQueue.has(r)&&(void 0!==t.responseQueue.get(r).callback&&t.responseQueue.get(r).callback(!1,e),t.responseQueue.delete(r))}}))},s.prototype._onConnect=function(){if(this.emit(this.CONNECT),this.reconnectAttempts=0,this.reconnecting=!1,this.requestQueue.size>0){var e=this;this.requestQueue.forEach((function(t,r){e.send(t.payload,t.callback),e.requestQueue.delete(r)}))}},s.prototype._onClose=function(e){var t=this;!this.reconnectOptions.auto||[1e3,1001].includes(e.code)&&!1!==e.wasClean?(this.emit(this.CLOSE,e),this.requestQueue.size>0&&this.requestQueue.forEach((function(r,n){r.callback(o.ConnectionNotOpenError(e)),t.requestQueue.delete(n)})),this.responseQueue.size>0&&this.responseQueue.forEach((function(r,n){r.callback(o.InvalidConnection("on WS",e)),t.responseQueue.delete(n)})),this._removeSocketListeners(),this.removeAllListeners()):this.reconnect()},s.prototype._addSocketListeners=function(){this.connection.addEventListener("message",this._onMessage.bind(this)),this.connection.addEventListener("open",this._onConnect.bind(this)),this.connection.addEventListener("close",this._onClose.bind(this))},s.prototype._removeSocketListeners=function(){this.connection.removeEventListener("message",this._onMessage),this.connection.removeEventListener("open",this._onConnect),this.connection.removeEventListener("close",this._onClose)},s.prototype._parseResponse=function(e){var t=this,r=[];return e.replace(/\}[\n\r]?\{/g,"}|--|{").replace(/\}\][\n\r]?\[\{/g,"}]|--|[{").replace(/\}[\n\r]?\[\{/g,"}|--|[{").replace(/\}\][\n\r]?\{/g,"}]|--|{").split("|--|").forEach((function(e){t.lastChunk&&(e=t.lastChunk+e);var n=null;try{n=JSON.parse(e)}catch(r){return t.lastChunk=e,clearTimeout(t.lastChunkTimeout),void(t.lastChunkTimeout=setTimeout((function(){t.reconnectOptions.auto&&t.reconnectOptions.onTimeout?t.reconnect():(t.emit(t.ERROR,o.ConnectionTimeout(t._customTimeout)),t.requestQueue.size>0&&t.requestQueue.forEach((function(e,r){e.callback(o.ConnectionTimeout(t._customTimeout)),t.requestQueue.delete(r)})))}),t._customTimeout))}clearTimeout(t.lastChunkTimeout),t.lastChunk=null,n&&r.push(n)})),r},s.prototype.send=function(e,t){var r=e.id,n={payload:e,callback:t};if(Array.isArray(e)&&(r=e[0].id),this.connection.readyState===this.connection.CONNECTING||this.reconnecting)this.requestQueue.set(r,n);else{if(this.connection.readyState!==this.connection.OPEN)return this.requestQueue.delete(r),this.emit(this.ERROR,o.ConnectionNotOpenError()),void n.callback(o.ConnectionNotOpenError());this.responseQueue.set(r,n),this.requestQueue.delete(r);try{this.connection.send(JSON.stringify(n.payload))}catch(e){n.callback(e),this.responseQueue.delete(r)}}},s.prototype.reset=function(){this.responseQueue.clear(),this.requestQueue.clear(),this.removeAllListeners(),this._removeSocketListeners(),this._addSocketListeners()},s.prototype.disconnect=function(e,t){this._removeSocketListeners(),this.connection.close(e||1e3,t)},s.prototype.supportsSubscriptions=function(){return!0},s.prototype.reconnect=function(){var e=this;this.reconnecting=!0,this.responseQueue.size>0&&this.responseQueue.forEach((function(t,r){t.callback(o.PendingRequestsOnReconnectingError()),e.responseQueue.delete(r)})),!this.reconnectOptions.maxAttempts||this.reconnectAttempts0&&this.requestQueue.forEach((function(t,r){t.callback(o.MaxAttemptsReachedOnReconnectingError()),e.requestQueue.delete(r)})))},e.exports=s},2565:(e,t,r)=>{"use strict";var n=r(606),i=r(4178).subscriptions,o=r(3349),a=r(473),s=function(){var e=this;n.packageInit(this,arguments);var t=this.setRequestManager;this.setRequestManager=function(r){return t(r),e.net.setRequestManager(r),!0};var r=this.setProvider;this.setProvider=function(){r.apply(e,arguments),e.setRequestManager(e._requestManager)},this.net=new a(this),[new i({name:"subscribe",type:"shh",subscriptions:{messages:{params:1}}}),new o({name:"getVersion",call:"shh_version",params:0}),new o({name:"getInfo",call:"shh_info",params:0}),new o({name:"setMaxMessageSize",call:"shh_setMaxMessageSize",params:1}),new o({name:"setMinPoW",call:"shh_setMinPoW",params:1}),new o({name:"markTrustedPeer",call:"shh_markTrustedPeer",params:1}),new o({name:"newKeyPair",call:"shh_newKeyPair",params:0}),new o({name:"addPrivateKey",call:"shh_addPrivateKey",params:1}),new o({name:"deleteKeyPair",call:"shh_deleteKeyPair",params:1}),new o({name:"hasKeyPair",call:"shh_hasKeyPair",params:1}),new o({name:"getPublicKey",call:"shh_getPublicKey",params:1}),new o({name:"getPrivateKey",call:"shh_getPrivateKey",params:1}),new o({name:"newSymKey",call:"shh_newSymKey",params:0}),new o({name:"addSymKey",call:"shh_addSymKey",params:1}),new o({name:"generateSymKeyFromPassword",call:"shh_generateSymKeyFromPassword",params:1}),new o({name:"hasSymKey",call:"shh_hasSymKey",params:1}),new o({name:"getSymKey",call:"shh_getSymKey",params:1}),new o({name:"deleteSymKey",call:"shh_deleteSymKey",params:1}),new o({name:"newMessageFilter",call:"shh_newMessageFilter",params:1}),new o({name:"getFilterMessages",call:"shh_getFilterMessages",params:1}),new o({name:"deleteMessageFilter",call:"shh_deleteMessageFilter",params:1}),new o({name:"post",call:"shh_post",params:1,inputFormatter:[null]}),new o({name:"unsubscribe",call:"shh_unsubscribe",params:1})].forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager)}))};s.prototype.clearSubscriptions=function(){this._requestManager.clearSubscriptions()},n.addProviders(s),e.exports=s},8161:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(7130),o=r(323),a=r(747),s=r(5010),u=r(1734),c=function e(t,r){var i=[];return r.forEach((function(r){if("object"===(0,n.default)(r.components)){if("tuple"!==r.type.substring(0,5))throw new Error("components found but type is not tuple; report on GitHub");var o="",a=r.type.indexOf("[");a>=0&&(o=r.type.substring(a));var s=e(t,r.components);Array.isArray(s)&&t?i.push("tuple("+s.join(",")+")"+o):t?i.push("("+s+")"):i.push("("+s.join(",")+")"+o)}else i.push(r.type)})),i},l=function(e){if(!o.isHexStrict(e))throw new Error("The parameter must be a valid HEX string.");var t="",r=0,n=e.length;for("0x"===e.substring(0,2)&&(r=2);r7?r+=e[n].toUpperCase():r+=e[n];return r},toHex:o.toHex,toBN:o.toBN,bytesToHex:o.bytesToHex,hexToBytes:o.hexToBytes,hexToNumberString:o.hexToNumberString,hexToNumber:o.hexToNumber,toDecimal:o.hexToNumber,numberToHex:o.numberToHex,fromDecimal:o.numberToHex,hexToUtf8:o.hexToUtf8,hexToString:o.hexToUtf8,toUtf8:o.hexToUtf8,stripHexPrefix:o.stripHexPrefix,utf8ToHex:o.utf8ToHex,stringToHex:o.utf8ToHex,fromUtf8:o.utf8ToHex,hexToAscii:l,toAscii:l,asciiToHex:f,fromAscii:f,unitMap:i.unitMap,toWei:function(e,t){if(t=h(t),!o.isBN(e)&&"string"!=typeof e)throw new Error("Please pass numbers as strings or BN objects to avoid precision errors.");return o.isBN(e)?i.toWei(e,t):i.toWei(e,t).toString(10)},fromWei:function(e,t){if(t=h(t),!o.isBN(e)&&"string"!=typeof e)throw new Error("Please pass numbers as strings or BN objects to avoid precision errors.");return o.isBN(e)?i.fromWei(e,t):i.fromWei(e,t).toString(10)},padLeft:o.leftPad,leftPad:o.leftPad,padRight:o.rightPad,rightPad:o.rightPad,toTwosComplement:o.toTwosComplement,isBloom:o.isBloom,isUserEthereumAddressInBloom:o.isUserEthereumAddressInBloom,isContractAddressInBloom:o.isContractAddressInBloom,isTopic:o.isTopic,isTopicInBloom:o.isTopicInBloom,isInBloom:o.isInBloom,compareBlockNumbers:function(e,t){if(e===t)return 0;if("genesis"!==e&&"earliest"!==e&&0!==e||"genesis"!==t&&"earliest"!==t&&0!==t){if("genesis"===e||"earliest"===e||0===e)return-1;if("genesis"===t||"earliest"===t||0===t)return 1;if("latest"===e||"finalized"===e)return"pending"===t?-1:1;if("latest"===t||"finalized"===t)return"pending"===e?1:-1;if("pending"===e)return 1;if("pending"===t)return-1;if("safe"===e||"safe"===t)return;var r=new u(e),n=new u(t);return r.lt(n)?-1:r.eq(n)?0:1}return 0},toNumber:o.toNumber}},747:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(1734),o=r(323),a=function(e){var t=(0,n.default)(e);if("string"===t)return o.isHexStrict(e)?new i(e.replace(/0x/i,""),16):new i(e,10);if("number"===t)return new i(e);if(o.isBigNumber(e))return new i(e.toString(10));if(o.isBN(e))return e;throw new Error(e+" is not a number")},s=function(e,t,r){var n,s;if("bytes"===(e=function(e){return e.startsWith("int[")?"int256"+e.slice(3):"int"===e?"int256":e.startsWith("uint[")?"uint256"+e.slice(4):"uint"===e?"uint256":e.startsWith("fixed[")?"fixed128x128"+e.slice(5):"fixed"===e?"fixed128x128":e.startsWith("ufixed[")?"ufixed128x128"+e.slice(6):"ufixed"===e?"ufixed128x128":e}(e))){if(t.replace(/^0x/i,"").length%2!=0)throw new Error("Invalid bytes characters "+t.length);return t}if("string"===e)return o.utf8ToHex(t);if("bool"===e)return t?"01":"00";if(e.startsWith("address")){if(n=r?64:40,!o.isAddress(t))throw new Error(t+" is not a valid address, or the checksum is invalid.");return o.leftPad(t.toLowerCase(),n)}if(n=function(e){var t=/^\D+(\d+).*$/.exec(e);return t?parseInt(t[1],10):null}(e),e.startsWith("bytes")){if(!n)throw new Error("bytes[] not yet supported in solidity");if(r&&(n=32),n<1||n>32||n256)throw new Error("Invalid uint"+n+" size");if((s=a(t)).bitLength()>n)throw new Error("Supplied uint exceeds width: "+n+" vs "+s.bitLength());if(s.lt(new i(0)))throw new Error("Supplied uint "+s.toString()+" is negative");return n?o.leftPad(s.toString("hex"),n/8*2):s}if(e.startsWith("int")){if(n%8||n<8||n>256)throw new Error("Invalid int"+n+" size");if((s=a(t)).bitLength()>n)throw new Error("Supplied int exceeds width: "+n+" vs "+s.bitLength());return s.lt(new i(0))?s.toTwos(n).toString("hex"):n?o.leftPad(s.toString("hex"),n/8*2):s}throw new Error("Unsupported or invalid type: "+e)},u=function(e){if(Array.isArray(e))throw new Error("Autodetection of array types is not supported.");var t,r,a="";if(e&&"object"===(0,n.default)(e)&&(e.hasOwnProperty("v")||e.hasOwnProperty("t")||e.hasOwnProperty("value")||e.hasOwnProperty("type"))?(t=e.hasOwnProperty("t")?e.t:e.type,a=e.hasOwnProperty("v")?e.v:e.value):(t=o.toHex(e,!0),a=o.toHex(e),t.startsWith("int")||t.startsWith("uint")||(t="bytes")),!t.startsWith("int")&&!t.startsWith("uint")||"string"!=typeof a||/^(-)?0x/i.test(a)||(a=new i(a)),Array.isArray(a)){if(r=function(e){var t=/^\D+\d*\[(\d+)\]$/.exec(e);return t?parseInt(t[1],10):null}(t),r&&a.length!==r)throw new Error(t+" is not matching the given array "+JSON.stringify(a));r=a.length}return Array.isArray(a)?a.map((function(e){return s(t,e,r).toString("hex").replace("0x","")})).join(""):s(t,a,r).toString("hex").replace("0x","")};e.exports={soliditySha3:function(){var e=Array.prototype.slice.call(arguments),t=e.map(u);return o.sha3("0x"+t.join(""))},soliditySha3Raw:function(){return o.sha3Raw("0x"+Array.prototype.slice.call(arguments).map(u).join(""))},encodePacked:function(){var e=Array.prototype.slice.call(arguments),t=e.map(u);return"0x"+t.join("").toLowerCase()}}},323:(e,t,r)=>{"use strict";var n=r(9033).Buffer,i=r(8847),o=i(r(4519)),a=i(r(3355)),s=r(1734),u=r(7277),c=r(8632),l=r(3062),f=r(9313),h=function(e){return s.isBN(e)},d=function(e){return e&&e.constructor&&"BigNumber"===e.constructor.name},p=function(e){try{return u.apply(null,arguments)}catch(t){throw new Error(t+' Given value: "'+e+'"')}},m=function(e){return!!/^(0x)?[0-9a-f]{40}$/i.test(e)&&(!(!/^(0x|0X)?[0-9a-f]{40}$/.test(e)&&!/^(0x|0X)?[0-9A-F]{40}$/.test(e))||y(e))},y=function(e){e=e.replace(/^0x/i,"");for(var t=E(e.toLowerCase()).replace(/^0x/i,""),r=0;r<40;r++)if(parseInt(t[r],16)>7&&e[r].toUpperCase()!==e[r]||parseInt(t[r],16)<=7&&e[r].toLowerCase()!==e[r])return!1;return!0},g=function(e){var t="";e=(e=(e=(e=(e=c.encode(e)).replace(/^(?:\u0000)*/,"")).split("").reverse().join("")).replace(/^(?:\u0000)*/,"")).split("").reverse().join("");for(var r=0;r>>4).toString(16)),t.push((15&e[r]).toString(16));return"0x"+t.join("")},isHex:S,isHexStrict:A,stripHexPrefix:function(e){return 0!==e&&S(e)?e.replace(/^(-)?0x/i,"$1"):e},leftPad:function(e,t,r){var n=/^0x/i.test(e)||"number"==typeof e,i=t-(e=e.toString(16).replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(n?"0x":"")+new Array(i).join(r||"0")+e},rightPad:function(e,t,r){var n=/^0x/i.test(e)||"number"==typeof e,i=t-(e=e.toString(16).replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(n?"0x":"")+e+new Array(i).join(r||"0")},toTwosComplement:function(e){return"0x"+p(e).toTwos(256).toString(16,64)},sha3:E,sha3Raw:function(e){return null===(e=E(e))?k:e},toNumber:function(e){return"number"==typeof e?e:b(w(e))}}},7001:(e,t,r)=>{"use strict";var n=r(8920).i8,i=r(606),o=r(6748),a=r(473),s=r(6306),u=r(2565),c=r(2463),l=r(8161),f=function(){var e=this;i.packageInit(this,arguments),this.version=n,this.utils=l,this.eth=new o(this),this.shh=new u(this),this.bzz=new c(this);var t=this.setProvider;this.setProvider=function(r,n){return t.apply(e,arguments),e.eth.setRequestManager(e._requestManager),e.shh.setRequestManager(e._requestManager),e.bzz.setProvider(r),!0}};f.version=n,f.utils=l,f.modules={Eth:o,Net:a,Personal:s,Shh:u,Bzz:c},i.addProviders(f),e.exports=f},9214:()=>{},2361:()=>{},4616:()=>{},8768:e=>{"use strict";e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r{"use strict";e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},7907:(e,t,r)=>{"use strict";var n=r(8768);e.exports=function(e){if(Array.isArray(e))return n(e)},e.exports.__esModule=!0,e.exports.default=e.exports},8975:e=>{"use strict";e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},5698:e=>{"use strict";function t(e,t,r,n,i,o,a){try{var s=e[o](a),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}e.exports=function(e){return function(){var r=this,n=arguments;return new Promise((function(i,o){var a=e.apply(r,n);function s(e){t(a,i,o,s,u,"next",e)}function u(e){t(a,i,o,s,u,"throw",e)}s(void 0)}))}},e.exports.__esModule=!0,e.exports.default=e.exports},9721:e=>{"use strict";e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},4727:(e,t,r)=>{"use strict";var n=r(8746),i=r(6923);function o(t,r,a){return i()?(e.exports=o=Reflect.construct.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=o=function(e,t,r){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return r&&n(o,r.prototype),o},e.exports.__esModule=!0,e.exports.default=e.exports),o.apply(null,arguments)}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},8985:(e,t,r)=>{"use strict";var n=r(2310);function i(e,t){for(var r=0;r{"use strict";var n=r(2310);e.exports=function(e,t,r){return(t=n(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},e.exports.__esModule=!0,e.exports.default=e.exports},119:(e,t,r)=>{"use strict";var n=r(7460);function i(){return"undefined"!=typeof Reflect&&Reflect.get?(e.exports=i=Reflect.get.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=i=function(e,t,r){var i=n(e,t);if(i){var o=Object.getOwnPropertyDescriptor(i,t);return o.get?o.get.call(arguments.length<3?e:r):o.value}},e.exports.__esModule=!0,e.exports.default=e.exports),i.apply(this,arguments)}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports},1949:e=>{"use strict";function t(r){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},5163:(e,t,r)=>{"use strict";var n=r(8746);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&n(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},8847:e=>{"use strict";e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},6923:e=>{"use strict";e.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.__esModule=!0,e.exports.default=e.exports},1642:e=>{"use strict";e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports.default=e.exports},1436:e=>{"use strict";e.exports=function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,o,a,s=[],u=!0,c=!1;try{if(o=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=o.call(r)).done)&&(s.push(n.value),s.length!==t);u=!0);}catch(e){c=!0,i=e}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(c)throw i}}return s}},e.exports.__esModule=!0,e.exports.default=e.exports},2966:e=>{"use strict";e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},2344:e=>{"use strict";e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},4650:(e,t,r)=>{"use strict";var n=r(3355).default,i=r(8975);e.exports=function(e,t){if(t&&("object"===n(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return i(e)},e.exports.__esModule=!0,e.exports.default=e.exports},2028:(e,t,r)=>{"use strict";var n=r(3355).default;function i(){e.exports=i=function(){return t},e.exports.__esModule=!0,e.exports.default=e.exports;var t={},r=Object.prototype,o=r.hasOwnProperty,a=Object.defineProperty||function(e,t,r){e[t]=r.value},s="function"==typeof Symbol?Symbol:{},u=s.iterator||"@@iterator",c=s.asyncIterator||"@@asyncIterator",l=s.toStringTag||"@@toStringTag";function f(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{f({},"")}catch(e){f=function(e,t,r){return e[t]=r}}function h(e,t,r,n){var i=t&&t.prototype instanceof m?t:m,o=Object.create(i.prototype),s=new x(n||[]);return a(o,"_invoke",{value:E(e,r,s)}),o}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=h;var p={};function m(){}function y(){}function g(){}var b={};f(b,u,(function(){return this}));var v=Object.getPrototypeOf,w=v&&v(v(P([])));w&&w!==r&&o.call(w,u)&&(b=w);var A=g.prototype=m.prototype=Object.create(b);function S(e){["next","throw","return"].forEach((function(t){f(e,t,(function(e){return this._invoke(t,e)}))}))}function k(e,t){function r(i,a,s,u){var c=d(e[i],e,a);if("throw"!==c.type){var l=c.arg,f=l.value;return f&&"object"==n(f)&&o.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,s,u)}),(function(e){r("throw",e,s,u)})):t.resolve(f).then((function(e){l.value=e,s(l)}),(function(e){return r("throw",e,s,u)}))}u(c.arg)}var i;a(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,i){r(e,n,t,i)}))}return i=i?i.then(o,o):o()}})}function E(e,t,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return{value:void 0,done:!0}}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var s=_(a,r);if(s){if(s===p)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=d(e,t,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===p)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function _(e,t){var r=t.method,n=e.iterator[r];if(void 0===n)return t.delegate=null,"throw"===r&&e.iterator.return&&(t.method="return",t.arg=void 0,_(e,t),"throw"===t.method)||"return"!==r&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+r+"' method")),p;var i=d(n,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,p;var o=i.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,p):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,p)}function M(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function T(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function x(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(M,this),this.reset(!0)}function P(e){if(e){var t=e[u];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,n=function t(){for(;++r=0;--n){var i=this.tryEntries[n],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var s=o.call(i,"catchLoc"),u=o.call(i,"finallyLoc");if(s&&u){if(this.prev=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&o.call(n,"finallyLoc")&&this.prev=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),T(r),p}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var i=n.arg;T(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:P(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=void 0),p}},t}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports},8746:e=>{"use strict";function t(r,n){return e.exports=t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,t(r,n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},4519:(e,t,r)=>{"use strict";var n=r(2338),i=r(1436),o=r(6906),a=r(2966);e.exports=function(e,t){return n(e)||i(e,t)||o(e,t)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},7460:(e,t,r)=>{"use strict";var n=r(1949);e.exports=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=n(e)););return e},e.exports.__esModule=!0,e.exports.default=e.exports},3106:(e,t,r)=>{"use strict";var n=r(7907),i=r(1642),o=r(6906),a=r(2344);e.exports=function(e){return n(e)||i(e)||o(e)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},9662:(e,t,r)=>{"use strict";var n=r(3355).default;e.exports=function(e,t){if("object"!==n(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var i=r.call(e,t||"default");if("object"!==n(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},2310:(e,t,r)=>{"use strict";var n=r(3355).default,i=r(9662);e.exports=function(e){var t=i(e,"string");return"symbol"===n(t)?t:String(t)},e.exports.__esModule=!0,e.exports.default=e.exports},3355:e=>{"use strict";function t(r){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},6906:(e,t,r)=>{"use strict";var n=r(8768);e.exports=function(e,t){if(e){if("string"==typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},2247:(e,t,r)=>{"use strict";var n=r(8847)(r(3355)),i=r(2028)();e.exports=i;try{regeneratorRuntime=i}catch(e){"object"===("undefined"==typeof globalThis?"undefined":(0,n.default)(globalThis))?globalThis.regeneratorRuntime=i:Function("r","regeneratorRuntime = r")(i)}},3604:(e,t,r)=>{"use strict";var n=["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],i="undefined"==typeof globalThis?r.g:globalThis;e.exports=function(){for(var e=[],t=0;t{"use strict";e.exports=JSON.parse('{"name":"goerli","chainId":5,"networkId":5,"defaultHardfork":"istanbul","consensus":{"type":"poa","algorithm":"clique","clique":{"period":15,"epoch":30000}},"comment":"Cross-client PoA test network","url":"https://github.com/goerli/testnet","genesis":{"hash":"0xbf7e331f7f7c1dd2e05159666b3bf8bc7a8a3a9eb1d518969eab529dd9b88c1a","timestamp":"0x5c51a607","gasLimit":10485760,"difficulty":1,"nonce":"0x0000000000000000","extraData":"0x22466c6578692069732061207468696e6722202d204166726900000000000000e0a2bd4258d2768837baa26a28fe71dc079f84c70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","stateRoot":"0x5d6cded585e73c4e322c30c2f782a336316f17dd85a4863b9d838d2d4b8b3008"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0xa3f5ab08"},{"name":"homestead","block":0,"forkHash":"0xa3f5ab08"},{"name":"tangerineWhistle","block":0,"forkHash":"0xa3f5ab08"},{"name":"spuriousDragon","block":0,"forkHash":"0xa3f5ab08"},{"name":"byzantium","block":0,"forkHash":"0xa3f5ab08"},{"name":"constantinople","block":0,"forkHash":"0xa3f5ab08"},{"name":"petersburg","block":0,"forkHash":"0xa3f5ab08"},{"name":"istanbul","block":1561651,"forkHash":"0xc25efa5c"},{"name":"berlin","block":4460644,"forkHash":"0x757a1c47"},{"name":"london","block":5062605,"forkHash":"0xb8c6299d"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"51.141.78.53","port":30303,"id":"011f758e6552d105183b1761c5e2dea0111bc20fd5f6422bc7f91e0fabbec9a6595caf6239b37feb773dddd3f87240d99d859431891e4a642cf2a0a9e6cbb98a","location":"","comment":"Upstream bootnode 1"},{"ip":"13.93.54.137","port":30303,"id":"176b9417f511d05b6b2cf3e34b756cf0a7096b3094572a8f6ef4cdcb9d1f9d00683bf0f83347eebdf3b81c3521c2332086d9592802230bf528eaf606a1d9677b","location":"","comment":"Upstream bootnode 2"},{"ip":"94.237.54.114","port":30313,"id":"46add44b9f13965f7b9875ac6b85f016f341012d84f975377573800a863526f4da19ae2c620ec73d11591fa9510e992ecc03ad0751f53cc02f7c7ed6d55c7291","location":"","comment":"Upstream bootnode 3"},{"ip":"18.218.250.66","port":30313,"id":"b5948a2d3e9d486c4d75bf32713221c2bd6cf86463302339299bd227dc2e276cd5a1c7ca4f43a0e9122fe9af884efed563bd2a1fd28661f3b5f5ad7bf1de5949","location":"","comment":"Upstream bootnode 4"},{"ip":"3.11.147.67","port":30303,"id":"a61215641fb8714a373c80edbfa0ea8878243193f57c96eeb44d0bc019ef295abd4e044fd619bfc4c59731a73fb79afe84e9ab6da0c743ceb479cbb6d263fa91","location":"","comment":"Ethereum Foundation bootnode"},{"ip":"51.15.116.226","port":30303,"id":"a869b02cec167211fb4815a82941db2e7ed2936fd90e78619c53eb17753fcf0207463e3419c264e2a1dd8786de0df7e68cf99571ab8aeb7c4e51367ef186b1dd","location":"","comment":"Goerli Initiative bootnode"},{"ip":"51.15.119.157","port":30303,"id":"807b37ee4816ecf407e9112224494b74dd5933625f655962d892f2f0f02d7fbbb3e2a94cf87a96609526f30c998fd71e93e2f53015c558ffc8b03eceaf30ee33","location":"","comment":"Goerli Initiative bootnode"},{"ip":"51.15.119.157","port":40303,"id":"a59e33ccd2b3e52d578f1fbd70c6f9babda2650f0760d6ff3b37742fdcdfdb3defba5d56d315b40c46b70198c7621e63ffa3f987389c7118634b0fefbbdfa7fd","location":"","comment":"Goerli Initiative bootnode"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.goerli.ethdisco.net"]}')},7098:e=>{"use strict";e.exports=JSON.parse('{"name":"kovan","chainId":42,"networkId":42,"defaultHardfork":"istanbul","consensus":{"type":"poa","algorithm":"aura","aura":{}},"comment":"Parity PoA test network","url":"https://kovan-testnet.github.io/website/","genesis":{"hash":"0xa3c565fc15c7478862d50ccd6561e3c06b24cc509bf388941c25ea985ce32cb9","timestamp":null,"gasLimit":6000000,"difficulty":131072,"nonce":"0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","extraData":"0x","stateRoot":"0x2480155b48a1cea17d67dbfdfaafe821c1d19cdd478c5358e8ec56dec24502b2"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0x010ffe56"},{"name":"homestead","block":0,"forkHash":"0x010ffe56"},{"name":"tangerineWhistle","block":0,"forkHash":"0x010ffe56"},{"name":"spuriousDragon","block":0,"forkHash":"0x010ffe56"},{"name":"byzantium","block":5067000,"forkHash":"0x7f83c620"},{"name":"constantinople","block":9200000,"forkHash":"0xa94e3dc4"},{"name":"petersburg","block":10255201,"forkHash":"0x186874aa"},{"name":"istanbul","block":14111141,"forkHash":"0x7f6599a6"},{"name":"berlin","block":null,"forkHash":null},{"name":"london","block":null,"forkHash":null},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"116.203.116.241","port":30303,"id":"16898006ba2cd4fa8bf9a3dfe32684c178fa861df144bfc21fe800dc4838a03e342056951fa9fd533dcb0be1219e306106442ff2cf1f7e9f8faa5f2fc1a3aa45","location":"","comment":"1"},{"ip":"3.217.96.11","port":30303,"id":"2909846f78c37510cc0e306f185323b83bb2209e5ff4fdd279d93c60e3f365e3c6e62ad1d2133ff11f9fd6d23ad9c3dad73bb974d53a22f7d1ac5b7dea79d0b0","location":"","comment":"2"},{"ip":"108.61.170.124","port":30303,"id":"740e1c8ea64e71762c71a463a04e2046070a0c9394fcab5891d41301dc473c0cff00ebab5a9bc87fbcb610ab98ac18225ff897bc8b7b38def5975d5ceb0a7d7c","location":"","comment":"3"},{"ip":"157.230.31.163","port":30303,"id":"2909846f78c37510cc0e306f185323b83bb2209e5ff4fdd279d93c60e3f365e3c6e62ad1d2133ff11f9fd6d23ad9c3dad73bb974d53a22f7d1ac5b7dea79d0b0","location":"","comment":"4"}]}')},7295:e=>{"use strict";e.exports=JSON.parse('{"name":"mainnet","chainId":1,"networkId":1,"defaultHardfork":"istanbul","consensus":{"type":"pow","algorithm":"ethash","ethash":{}},"comment":"The Ethereum main chain","url":"https://ethstats.net/","genesis":{"hash":"0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3","timestamp":null,"gasLimit":5000,"difficulty":17179869184,"nonce":"0x0000000000000042","extraData":"0x11bbe8db4e347b4e8c937c1c8370e4b5ed33adb3db69cbdb7a38e1e50b1b82fa","stateRoot":"0xd7f8974fb5ac78d9ac099b9ad5018bedc2ce0a72dad1827a1709da30580f0544"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0xfc64ec04"},{"name":"homestead","block":1150000,"forkHash":"0x97c2c34c"},{"name":"dao","block":1920000,"forkHash":"0x91d1f948"},{"name":"tangerineWhistle","block":2463000,"forkHash":"0x7a64da13"},{"name":"spuriousDragon","block":2675000,"forkHash":"0x3edd5b10"},{"name":"byzantium","block":4370000,"forkHash":"0xa00bc324"},{"name":"constantinople","block":7280000,"forkHash":"0x668db0af"},{"name":"petersburg","block":7280000,"forkHash":"0x668db0af"},{"name":"istanbul","block":9069000,"forkHash":"0x879d6e30"},{"name":"muirGlacier","block":9200000,"forkHash":"0xe029e991"},{"name":"berlin","block":12244000,"forkHash":"0x0eb440f6"},{"name":"london","block":12965000,"forkHash":"0xb715077d"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"18.138.108.67","port":30303,"id":"d860a01f9722d78051619d1e2351aba3f43f943f6f00718d1b9baa4101932a1f5011f16bb2b1bb35db20d6fe28fa0bf09636d26a87d31de9ec6203eeedb1f666","location":"ap-southeast-1-001","comment":"bootnode-aws-ap-southeast-1-001"},{"ip":"3.209.45.79","port":30303,"id":"22a8232c3abc76a16ae9d6c3b164f98775fe226f0917b0ca871128a74a8e9630b458460865bab457221f1d448dd9791d24c4e5d88786180ac185df813a68d4de","location":"us-east-1-001","comment":"bootnode-aws-us-east-1-001"},{"ip":"34.255.23.113","port":30303,"id":"ca6de62fce278f96aea6ec5a2daadb877e51651247cb96ee310a318def462913b653963c155a0ef6c7d50048bba6e6cea881130857413d9f50a621546b590758","location":"eu-west-1-001","comment":"bootnode-aws-eu-west-1-001"},{"ip":"35.158.244.151","port":30303,"id":"279944d8dcd428dffaa7436f25ca0ca43ae19e7bcf94a8fb7d1641651f92d121e972ac2e8f381414b80cc8e5555811c2ec6e1a99bb009b3f53c4c69923e11bd8","location":"eu-central-1-001","comment":"bootnode-aws-eu-central-1-001"},{"ip":"52.187.207.27","port":30303,"id":"8499da03c47d637b20eee24eec3c356c9a2e6148d6fe25ca195c7949ab8ec2c03e3556126b0d7ed644675e78c4318b08691b7b57de10e5f0d40d05b09238fa0a","location":"australiaeast-001","comment":"bootnode-azure-australiaeast-001"},{"ip":"191.234.162.198","port":30303,"id":"103858bdb88756c71f15e9b5e09b56dc1be52f0a5021d46301dbbfb7e130029cc9d0d6f73f693bc29b665770fff7da4d34f3c6379fe12721b5d7a0bcb5ca1fc1","location":"brazilsouth-001","comment":"bootnode-azure-brazilsouth-001"},{"ip":"52.231.165.108","port":30303,"id":"715171f50508aba88aecd1250af392a45a330af91d7b90701c436b618c86aaa1589c9184561907bebbb56439b8f8787bc01f49a7c77276c58c1b09822d75e8e8","location":"koreasouth-001","comment":"bootnode-azure-koreasouth-001"},{"ip":"104.42.217.25","port":30303,"id":"5d6d7cd20d6da4bb83a1d28cadb5d409b64edf314c0335df658c1a54e32c7c4a7ab7823d57c39b6a757556e68ff1df17c748b698544a55cb488b52479a92b60f","location":"westus-001","comment":"bootnode-azure-westus-001"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.mainnet.ethdisco.net"]}')},439:e=>{"use strict";e.exports=JSON.parse('{"name":"rinkeby","chainId":4,"networkId":4,"defaultHardfork":"istanbul","consensus":{"type":"poa","algorithm":"clique","clique":{"period":15,"epoch":30000}},"comment":"PoA test network","url":"https://www.rinkeby.io","genesis":{"hash":"0x6341fd3daf94b748c72ced5a5b26028f2474f5f00d824504e4fa37a75767e177","timestamp":"0x58ee40ba","gasLimit":4700000,"difficulty":1,"nonce":"0x0000000000000000","extraData":"0x52657370656374206d7920617574686f7269746168207e452e436172746d616e42eb768f2244c8811c63729a21a3569731535f067ffc57839b00206d1ad20c69a1981b489f772031b279182d99e65703f0076e4812653aab85fca0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","stateRoot":"0x53580584816f617295ea26c0e17641e0120cab2f0a8ffb53a866fd53aa8e8c2d"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0x3b8e0691"},{"name":"homestead","block":1,"forkHash":"0x60949295"},{"name":"tangerineWhistle","block":2,"forkHash":"0x8bde40dd"},{"name":"spuriousDragon","block":3,"forkHash":"0xcb3a64bb"},{"name":"byzantium","block":1035301,"forkHash":"0x8d748b57"},{"name":"constantinople","block":3660663,"forkHash":"0xe49cab14"},{"name":"petersburg","block":4321234,"forkHash":"0xafec6b27"},{"name":"istanbul","block":5435345,"forkHash":"0xcbdb8838"},{"name":"berlin","block":8290928,"forkHash":"0x6910c8bd"},{"name":"london","block":8897988,"forkHash":"0x8e29f2f3"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"52.169.42.101","port":30303,"id":"a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf","location":"","comment":"IE"},{"ip":"52.3.158.184","port":30303,"id":"343149e4feefa15d882d9fe4ac7d88f885bd05ebb735e547f12e12080a9fa07c8014ca6fd7f373123488102fe5e34111f8509cf0b7de3f5b44339c9f25e87cb8","location":"","comment":"INFURA"},{"ip":"159.89.28.211","port":30303,"id":"b6b28890b006743680c52e64e0d16db57f28124885595fa03a562be1d2bf0f3a1da297d56b13da25fb992888fd556d4c1a27b1f39d531bde7de1921c90061cc6","location":"","comment":"AKASHA"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.rinkeby.ethdisco.net"]}')},1227:e=>{"use strict";e.exports=JSON.parse('{"name":"ropsten","chainId":3,"networkId":3,"defaultHardfork":"istanbul","consensus":{"type":"pow","algorithm":"ethash","ethash":{}},"comment":"PoW test network","url":"https://github.com/ethereum/ropsten","genesis":{"hash":"0x41941023680923e0fe4d74a34bdac8141f2540e3ae90623718e47d66d1ca4a2d","timestamp":null,"gasLimit":16777216,"difficulty":1048576,"nonce":"0x0000000000000042","extraData":"0x3535353535353535353535353535353535353535353535353535353535353535","stateRoot":"0x217b0bbcfb72e2d57e28f33cb361b9983513177755dc3f33ce3e7022ed62b77b"},"hardforks":[{"name":"chainstart","block":0,"forkHash":"0x30c7ddbc"},{"name":"homestead","block":0,"forkHash":"0x30c7ddbc"},{"name":"tangerineWhistle","block":0,"forkHash":"0x30c7ddbc"},{"name":"spuriousDragon","block":10,"forkHash":"0x63760190"},{"name":"byzantium","block":1700000,"forkHash":"0x3ea159c7"},{"name":"constantinople","block":4230000,"forkHash":"0x97b544f3"},{"name":"petersburg","block":4939394,"forkHash":"0xd6e2149b"},{"name":"istanbul","block":6485846,"forkHash":"0x4bc66396"},{"name":"muirGlacier","block":7117117,"forkHash":"0x6727ef90"},{"name":"berlin","block":9812189,"forkHash":"0xa157d377"},{"name":"london","block":10499401,"forkHash":"0x7119b6b3"},{"name":"merge","block":null,"forkash":null},{"name":"shanghai","block":null,"forkash":null}],"bootstrapNodes":[{"ip":"52.176.7.10","port":30303,"id":"30b7ab30a01c124a6cceca36863ece12c4f5fa68e3ba9b0b51407ccc002eeed3b3102d20a88f1c1d3c3154e2449317b8ef95090e77b312d5cc39354f86d5d606","location":"","comment":"US-Azure geth"},{"ip":"52.176.100.77","port":30303,"id":"865a63255b3bb68023b6bffd5095118fcc13e79dcf014fe4e47e065c350c7cc72af2e53eff895f11ba1bbb6a2b33271c1116ee870f266618eadfc2e78aa7349c","location":"","comment":"US-Azure parity"},{"ip":"52.232.243.152","port":30303,"id":"6332792c4a00e3e4ee0926ed89e0d27ef985424d97b6a45bf0f23e51f0dcb5e66b875777506458aea7af6f9e4ffb69f43f3778ee73c81ed9d34c51c4b16b0b0f","location":"","comment":"Parity"},{"ip":"192.81.208.223","port":30303,"id":"94c15d1b9e2fe7ce56e458b9a3b672ef11894ddedd0c6f247e0f1d3487f52b66208fb4aeb8179fce6e3a749ea93ed147c37976d67af557508d199d9594c35f09","location":"","comment":"@gpip"}],"dnsNetworks":["enrtree://AKA3AM6LPBYEUDMVNU3BSVQJ5AD45Y7YPOHJLEF6W26QOE4VTUDPE@all.ropsten.ethdisco.net"]}')},7523:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-1559","number":1559,"comment":"Fee market change for ETH 1.0 chain","url":"https://eips.ethereum.org/EIPS/eip-1559","status":"Review","minimumHardfork":"berlin","requiredEIPs":[2930],"gasConfig":{"baseFeeMaxChangeDenominator":{"v":8,"d":"Maximum base fee change denominator"},"elasticityMultiplier":{"v":2,"d":"Maximum block gas target elasticity"},"initialBaseFee":{"v":1000000000,"d":"Initial base fee on first EIP1559 block"}},"gasPrices":{},"vm":{},"pow":{}}')},3339:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2315","number":2315,"comment":"Simple subroutines for the EVM","url":"https://eips.ethereum.org/EIPS/eip-2315","status":"Draft","minimumHardfork":"istanbul","gasConfig":{},"gasPrices":{"beginsub":{"v":2,"d":"Base fee of the BEGINSUB opcode"},"returnsub":{"v":5,"d":"Base fee of the RETURNSUB opcode"},"jumpsub":{"v":10,"d":"Base fee of the JUMPSUB opcode"}},"vm":{},"pow":{}}')},6769:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2537","number":2537,"comment":"BLS12-381 precompiles","url":"https://eips.ethereum.org/EIPS/eip-2537","status":"Draft","minimumHardfork":"chainstart","gasConfig":{},"gasPrices":{"Bls12381G1AddGas":{"v":600,"d":"Gas cost of a single BLS12-381 G1 addition precompile-call"},"Bls12381G1MulGas":{"v":12000,"d":"Gas cost of a single BLS12-381 G1 multiplication precompile-call"},"Bls12381G2AddGas":{"v":4500,"d":"Gas cost of a single BLS12-381 G2 addition precompile-call"},"Bls12381G2MulGas":{"v":55000,"d":"Gas cost of a single BLS12-381 G2 multiplication precompile-call"},"Bls12381PairingBaseGas":{"v":115000,"d":"Base gas cost of BLS12-381 pairing check"},"Bls12381PairingPerPairGas":{"v":23000,"d":"Per-pair gas cost of BLS12-381 pairing check"},"Bls12381MapG1Gas":{"v":5500,"d":"Gas cost of BLS12-381 map field element to G1"},"Bls12381MapG2Gas":{"v":110000,"d":"Gas cost of BLS12-381 map field element to G2"},"Bls12381MultiExpGasDiscount":{"v":[[1,1200],[2,888],[3,764],[4,641],[5,594],[6,547],[7,500],[8,453],[9,438],[10,423],[11,408],[12,394],[13,379],[14,364],[15,349],[16,334],[17,330],[18,326],[19,322],[20,318],[21,314],[22,310],[23,306],[24,302],[25,298],[26,294],[27,289],[28,285],[29,281],[30,277],[31,273],[32,269],[33,268],[34,266],[35,265],[36,263],[37,262],[38,260],[39,259],[40,257],[41,256],[42,254],[43,253],[44,251],[45,250],[46,248],[47,247],[48,245],[49,244],[50,242],[51,241],[52,239],[53,238],[54,236],[55,235],[56,233],[57,232],[58,231],[59,229],[60,228],[61,226],[62,225],[63,223],[64,222],[65,221],[66,220],[67,219],[68,219],[69,218],[70,217],[71,216],[72,216],[73,215],[74,214],[75,213],[76,213],[77,212],[78,211],[79,211],[80,210],[81,209],[82,208],[83,208],[84,207],[85,206],[86,205],[87,205],[88,204],[89,203],[90,202],[91,202],[92,201],[93,200],[94,199],[95,199],[96,198],[97,197],[98,196],[99,196],[100,195],[101,194],[102,193],[103,193],[104,192],[105,191],[106,191],[107,190],[108,189],[109,188],[110,188],[111,187],[112,186],[113,185],[114,185],[115,184],[116,183],[117,182],[118,182],[119,181],[120,180],[121,179],[122,179],[123,178],[124,177],[125,176],[126,176],[127,175],[128,174]],"d":"Discount gas costs of calls to the MultiExp precompiles with `k` (point, scalar) pair"}},"vm":{},"pow":{}}')},7897:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2565","number":2565,"comment":"ModExp gas cost","url":"https://eips.ethereum.org/EIPS/eip-2565","status":"Last call","minimumHardfork":"byzantium","gasConfig":{},"gasPrices":{"modexpGquaddivisor":{"v":3,"d":"Gquaddivisor from modexp precompile for gas calculation"}},"vm":{},"pow":{}}')},2170:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2718","comment":"Typed Transaction Envelope","url":"https://eips.ethereum.org/EIPS/eip-2718","status":"Draft","minimumHardfork":"chainstart","gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},8436:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2929","comment":"Gas cost increases for state access opcodes","url":"https://eips.ethereum.org/EIPS/eip-2929","status":"Draft","minimumHardfork":"chainstart","gasConfig":{},"gasPrices":{"coldsload":{"v":2100,"d":"Gas cost of the first read of storage from a given location (per transaction)"},"coldaccountaccess":{"v":2600,"d":"Gas cost of the first read of a given address (per transaction)"},"warmstorageread":{"v":100,"d":"Gas cost of reading storage locations which have already loaded \'cold\'"},"sstoreCleanGasEIP2200":{"v":2900,"d":"Once per SSTORE operation from clean non-zero to something else"},"sstoreNoopGasEIP2200":{"v":100,"d":"Once per SSTORE operation if the value doesn\'t change"},"sstoreDirtyGasEIP2200":{"v":100,"d":"Once per SSTORE operation if a dirty value is changed"},"sstoreInitRefundEIP2200":{"v":19900,"d":"Once per SSTORE operation for resetting to the original zero value"},"sstoreCleanRefundEIP2200":{"v":4900,"d":"Once per SSTORE operation for resetting to the original non-zero value"},"call":{"v":0,"d":"Base fee of the CALL opcode"},"callcode":{"v":0,"d":"Base fee of the CALLCODE opcode"},"delegatecall":{"v":0,"d":"Base fee of the DELEGATECALL opcode"},"staticcall":{"v":0,"d":"Base fee of the STATICCALL opcode"},"balance":{"v":0,"d":"Base fee of the BALANCE opcode"},"extcodesize":{"v":0,"d":"Base fee of the EXTCODESIZE opcode"},"extcodecopy":{"v":0,"d":"Base fee of the EXTCODECOPY opcode"},"extcodehash":{"v":0,"d":"Base fee of the EXTCODEHASH opcode"},"sload":{"v":0,"d":"Base fee of the SLOAD opcode"},"sstore":{"v":0,"d":"Base fee of the SSTORE opcode"}},"vm":{},"pow":{}}')},6213:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-2930","comment":"Optional access lists","url":"https://eips.ethereum.org/EIPS/eip-2930","status":"Draft","minimumHardfork":"istanbul","requiredEIPs":[2718,2929],"gasConfig":{},"gasPrices":{"accessListStorageKeyCost":{"v":1900,"d":"Gas cost per storage key in an Access List transaction"},"accessListAddressCost":{"v":2400,"d":"Gas cost per storage key in an Access List transaction"}},"vm":{},"pow":{}}')},5491:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3198","number":3198,"comment":"BASEFEE opcode","url":"https://eips.ethereum.org/EIPS/eip-3198","status":"Review","minimumHardfork":"london","gasConfig":{},"gasPrices":{"basefee":{"v":2,"d":"Gas cost of the BASEFEE opcode"}},"vm":{},"pow":{}}')},7852:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3529","comment":"Reduction in refunds","url":"https://eips.ethereum.org/EIPS/eip-3529","status":"Draft","minimumHardfork":"berlin","requiredEIPs":[2929],"gasConfig":{"maxRefundQuotient":{"v":5,"d":"Maximum refund quotient; max tx refund is min(tx.gasUsed/maxRefundQuotient, tx.gasRefund)"}},"gasPrices":{"selfdestructRefund":{"v":0,"d":"Refunded following a selfdestruct operation"},"sstoreClearRefundEIP2200":{"v":4800,"d":"Once per SSTORE operation for clearing an originally existing storage slot"}},"vm":{},"pow":{}}')},1871:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3541","comment":"Reject new contracts starting with the 0xEF byte","url":"https://eips.ethereum.org/EIPS/eip-3541","status":"Draft","minimumHardfork":"berlin","requiredEIPs":[],"gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},7225:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3554","comment":"Reduction in refunds","url":"Difficulty Bomb Delay to December 1st 2021","status":"Draft","minimumHardfork":"muirGlacier","requiredEIPs":[],"gasConfig":{},"gasPrices":{},"vm":{},"pow":{"difficultyBombDelay":{"v":9500000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},8571:e=>{"use strict";e.exports=JSON.parse('{"name":"EIP-3675","number":3675,"comment":"Upgrade consensus to Proof-of-Stake","url":"https://eips.ethereum.org/EIPS/eip-3675","status":"Draft","minimumHardfork":"london","requiredEIPs":[],"gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},15:e=>{"use strict";e.exports=JSON.parse('{"name":"berlin","comment":"HF targeted for July 2020 following the Muir Glacier HF","url":"https://eips.ethereum.org/EIPS/eip-2070","status":"Draft","eips":[2565,2929,2718,2930]}')},6985:e=>{"use strict";e.exports=JSON.parse('{"name":"byzantium","comment":"Hardfork with new precompiles, instructions and other protocol changes","url":"https://eips.ethereum.org/EIPS/eip-609","status":"Final","gasConfig":{},"gasPrices":{"modexpGquaddivisor":{"v":20,"d":"Gquaddivisor from modexp precompile for gas calculation"},"ecAdd":{"v":500,"d":"Gas costs for curve addition precompile"},"ecMul":{"v":40000,"d":"Gas costs for curve multiplication precompile"},"ecPairing":{"v":100000,"d":"Base gas costs for curve pairing precompile"},"ecPairingWord":{"v":80000,"d":"Gas costs regarding curve pairing precompile input length"},"revert":{"v":0,"d":"Base fee of the REVERT opcode"},"staticcall":{"v":700,"d":"Base fee of the STATICCALL opcode"},"returndatasize":{"v":2,"d":"Base fee of the RETURNDATASIZE opcode"},"returndatacopy":{"v":3,"d":"Base fee of the RETURNDATACOPY opcode"}},"vm":{},"pow":{"minerReward":{"v":"3000000000000000000","d":"the amount a miner get rewarded for mining a block"},"difficultyBombDelay":{"v":3000000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},114:e=>{"use strict";e.exports=JSON.parse('{"name":"chainstart","comment":"Start of the Ethereum main chain","url":"","status":"","gasConfig":{"minGasLimit":{"v":5000,"d":"Minimum the gas limit may ever be"},"gasLimitBoundDivisor":{"v":1024,"d":"The bound divisor of the gas limit, used in update calculations"},"maxRefundQuotient":{"v":2,"d":"Maximum refund quotient; max tx refund is min(tx.gasUsed/maxRefundQuotient, tx.gasRefund)"}},"gasPrices":{"base":{"v":2,"d":"Gas base cost, used e.g. for ChainID opcode (Istanbul)"},"tierStep":{"v":[0,2,3,5,8,10,20],"d":"Once per operation, for a selection of them"},"exp":{"v":10,"d":"Base fee of the EXP opcode"},"expByte":{"v":10,"d":"Times ceil(log256(exponent)) for the EXP instruction"},"sha3":{"v":30,"d":"Base fee of the SHA3 opcode"},"sha3Word":{"v":6,"d":"Once per word of the SHA3 operation\'s data"},"sload":{"v":50,"d":"Base fee of the SLOAD opcode"},"sstoreSet":{"v":20000,"d":"Once per SSTORE operation if the zeroness changes from zero"},"sstoreReset":{"v":5000,"d":"Once per SSTORE operation if the zeroness does not change from zero"},"sstoreRefund":{"v":15000,"d":"Once per SSTORE operation if the zeroness changes to zero"},"jumpdest":{"v":1,"d":"Base fee of the JUMPDEST opcode"},"log":{"v":375,"d":"Base fee of the LOG opcode"},"logData":{"v":8,"d":"Per byte in a LOG* operation\'s data"},"logTopic":{"v":375,"d":"Multiplied by the * of the LOG*, per LOG transaction. e.g. LOG0 incurs 0 * c_txLogTopicGas, LOG4 incurs 4 * c_txLogTopicGas"},"create":{"v":32000,"d":"Base fee of the CREATE opcode"},"call":{"v":40,"d":"Base fee of the CALL opcode"},"callStipend":{"v":2300,"d":"Free gas given at beginning of call"},"callValueTransfer":{"v":9000,"d":"Paid for CALL when the value transfor is non-zero"},"callNewAccount":{"v":25000,"d":"Paid for CALL when the destination address didn\'t exist prior"},"selfdestructRefund":{"v":24000,"d":"Refunded following a selfdestruct operation"},"memory":{"v":3,"d":"Times the address of the (highest referenced byte in memory + 1). NOTE: referencing happens on read, write and in instructions such as RETURN and CALL"},"quadCoeffDiv":{"v":512,"d":"Divisor for the quadratic particle of the memory cost equation"},"createData":{"v":200,"d":""},"tx":{"v":21000,"d":"Per transaction. NOTE: Not payable on data of calls between transactions"},"txCreation":{"v":32000,"d":"The cost of creating a contract via tx"},"txDataZero":{"v":4,"d":"Per byte of data attached to a transaction that equals zero. NOTE: Not payable on data of calls between transactions"},"txDataNonZero":{"v":68,"d":"Per byte of data attached to a transaction that is not equal to zero. NOTE: Not payable on data of calls between transactions"},"copy":{"v":3,"d":"Multiplied by the number of 32-byte words that are copied (round up) for any *COPY operation and added"},"ecRecover":{"v":3000,"d":""},"sha256":{"v":60,"d":""},"sha256Word":{"v":12,"d":""},"ripemd160":{"v":600,"d":""},"ripemd160Word":{"v":120,"d":""},"identity":{"v":15,"d":""},"identityWord":{"v":3,"d":""},"stop":{"v":0,"d":"Base fee of the STOP opcode"},"add":{"v":3,"d":"Base fee of the ADD opcode"},"mul":{"v":5,"d":"Base fee of the MUL opcode"},"sub":{"v":3,"d":"Base fee of the SUB opcode"},"div":{"v":5,"d":"Base fee of the DIV opcode"},"sdiv":{"v":5,"d":"Base fee of the SDIV opcode"},"mod":{"v":5,"d":"Base fee of the MOD opcode"},"smod":{"v":5,"d":"Base fee of the SMOD opcode"},"addmod":{"v":8,"d":"Base fee of the ADDMOD opcode"},"mulmod":{"v":8,"d":"Base fee of the MULMOD opcode"},"signextend":{"v":5,"d":"Base fee of the SIGNEXTEND opcode"},"lt":{"v":3,"d":"Base fee of the LT opcode"},"gt":{"v":3,"d":"Base fee of the GT opcode"},"slt":{"v":3,"d":"Base fee of the SLT opcode"},"sgt":{"v":3,"d":"Base fee of the SGT opcode"},"eq":{"v":3,"d":"Base fee of the EQ opcode"},"iszero":{"v":3,"d":"Base fee of the ISZERO opcode"},"and":{"v":3,"d":"Base fee of the AND opcode"},"or":{"v":3,"d":"Base fee of the OR opcode"},"xor":{"v":3,"d":"Base fee of the XOR opcode"},"not":{"v":3,"d":"Base fee of the NOT opcode"},"byte":{"v":3,"d":"Base fee of the BYTE opcode"},"address":{"v":2,"d":"Base fee of the ADDRESS opcode"},"balance":{"v":20,"d":"Base fee of the BALANCE opcode"},"origin":{"v":2,"d":"Base fee of the ORIGIN opcode"},"caller":{"v":2,"d":"Base fee of the CALLER opcode"},"callvalue":{"v":2,"d":"Base fee of the CALLVALUE opcode"},"calldataload":{"v":3,"d":"Base fee of the CALLDATALOAD opcode"},"calldatasize":{"v":2,"d":"Base fee of the CALLDATASIZE opcode"},"calldatacopy":{"v":3,"d":"Base fee of the CALLDATACOPY opcode"},"codesize":{"v":2,"d":"Base fee of the CODESIZE opcode"},"codecopy":{"v":3,"d":"Base fee of the CODECOPY opcode"},"gasprice":{"v":2,"d":"Base fee of the GASPRICE opcode"},"extcodesize":{"v":20,"d":"Base fee of the EXTCODESIZE opcode"},"extcodecopy":{"v":20,"d":"Base fee of the EXTCODECOPY opcode"},"blockhash":{"v":20,"d":"Base fee of the BLOCKHASH opcode"},"coinbase":{"v":2,"d":"Base fee of the COINBASE opcode"},"timestamp":{"v":2,"d":"Base fee of the TIMESTAMP opcode"},"number":{"v":2,"d":"Base fee of the NUMBER opcode"},"difficulty":{"v":2,"d":"Base fee of the DIFFICULTY opcode"},"gaslimit":{"v":2,"d":"Base fee of the GASLIMIT opcode"},"pop":{"v":2,"d":"Base fee of the POP opcode"},"mload":{"v":3,"d":"Base fee of the MLOAD opcode"},"mstore":{"v":3,"d":"Base fee of the MSTORE opcode"},"mstore8":{"v":3,"d":"Base fee of the MSTORE8 opcode"},"sstore":{"v":0,"d":"Base fee of the SSTORE opcode"},"jump":{"v":8,"d":"Base fee of the JUMP opcode"},"jumpi":{"v":10,"d":"Base fee of the JUMPI opcode"},"pc":{"v":2,"d":"Base fee of the PC opcode"},"msize":{"v":2,"d":"Base fee of the MSIZE opcode"},"gas":{"v":2,"d":"Base fee of the GAS opcode"},"push":{"v":3,"d":"Base fee of the PUSH opcode"},"dup":{"v":3,"d":"Base fee of the DUP opcode"},"swap":{"v":3,"d":"Base fee of the SWAP opcode"},"callcode":{"v":40,"d":"Base fee of the CALLCODE opcode"},"return":{"v":0,"d":"Base fee of the RETURN opcode"},"invalid":{"v":0,"d":"Base fee of the INVALID opcode"},"selfdestruct":{"v":0,"d":"Base fee of the SELFDESTRUCT opcode"}},"vm":{"stackLimit":{"v":1024,"d":"Maximum size of VM stack allowed"},"callCreateDepth":{"v":1024,"d":"Maximum depth of call/create stack"},"maxExtraDataSize":{"v":32,"d":"Maximum size extra data may be after Genesis"}},"pow":{"minimumDifficulty":{"v":131072,"d":"The minimum that the difficulty may ever be"},"difficultyBoundDivisor":{"v":2048,"d":"The bound divisor of the difficulty, used in the update calculations"},"durationLimit":{"v":13,"d":"The decision boundary on the blocktime duration used to determine whether difficulty should go up or not"},"epochDuration":{"v":30000,"d":"Duration between proof-of-work epochs"},"timebombPeriod":{"v":100000,"d":"Exponential difficulty timebomb period"},"minerReward":{"v":"5000000000000000000","d":"the amount a miner get rewarded for mining a block"},"difficultyBombDelay":{"v":0,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},5993:e=>{"use strict";e.exports=JSON.parse('{"name":"constantinople","comment":"Postponed hardfork including EIP-1283 (SSTORE gas metering changes)","url":"https://eips.ethereum.org/EIPS/eip-1013","status":"Final","gasConfig":{},"gasPrices":{"netSstoreNoopGas":{"v":200,"d":"Once per SSTORE operation if the value doesn\'t change"},"netSstoreInitGas":{"v":20000,"d":"Once per SSTORE operation from clean zero"},"netSstoreCleanGas":{"v":5000,"d":"Once per SSTORE operation from clean non-zero"},"netSstoreDirtyGas":{"v":200,"d":"Once per SSTORE operation from dirty"},"netSstoreClearRefund":{"v":15000,"d":"Once per SSTORE operation for clearing an originally existing storage slot"},"netSstoreResetRefund":{"v":4800,"d":"Once per SSTORE operation for resetting to the original non-zero value"},"netSstoreResetClearRefund":{"v":19800,"d":"Once per SSTORE operation for resetting to the original zero value"},"shl":{"v":3,"d":"Base fee of the SHL opcode"},"shr":{"v":3,"d":"Base fee of the SHR opcode"},"sar":{"v":3,"d":"Base fee of the SAR opcode"},"extcodehash":{"v":400,"d":"Base fee of the EXTCODEHASH opcode"},"create2":{"v":32000,"d":"Base fee of the CREATE2 opcode"}},"vm":{},"pow":{"minerReward":{"v":"2000000000000000000","d":"The amount a miner gets rewarded for mining a block"},"difficultyBombDelay":{"v":5000000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},7197:e=>{"use strict";e.exports=JSON.parse('{"name":"dao","comment":"DAO rescue hardfork","url":"https://eips.ethereum.org/EIPS/eip-779","status":"Final","gasConfig":{},"gasPrices":{},"vm":{},"pow":{}}')},2800:e=>{"use strict";e.exports=JSON.parse('{"name":"homestead","comment":"Homestead hardfork with protocol and network changes","url":"https://eips.ethereum.org/EIPS/eip-606","status":"Final","gasConfig":{},"gasPrices":{"delegatecall":{"v":40,"d":"Base fee of the DELEGATECALL opcode"}},"vm":{},"pow":{}}')},3166:e=>{"use strict";e.exports=JSON.parse('{"name":"istanbul","comment":"HF targeted for December 2019 following the Constantinople/Petersburg HF","url":"https://eips.ethereum.org/EIPS/eip-1679","status":"Draft","gasConfig":{},"gasPrices":{"blake2Round":{"v":1,"d":"Gas cost per round for the Blake2 F precompile"},"ecAdd":{"v":150,"d":"Gas costs for curve addition precompile"},"ecMul":{"v":6000,"d":"Gas costs for curve multiplication precompile"},"ecPairing":{"v":45000,"d":"Base gas costs for curve pairing precompile"},"ecPairingWord":{"v":34000,"d":"Gas costs regarding curve pairing precompile input length"},"txDataNonZero":{"v":16,"d":"Per byte of data attached to a transaction that is not equal to zero. NOTE: Not payable on data of calls between transactions"},"sstoreSentryGasEIP2200":{"v":2300,"d":"Minimum gas required to be present for an SSTORE call, not consumed"},"sstoreNoopGasEIP2200":{"v":800,"d":"Once per SSTORE operation if the value doesn\'t change"},"sstoreDirtyGasEIP2200":{"v":800,"d":"Once per SSTORE operation if a dirty value is changed"},"sstoreInitGasEIP2200":{"v":20000,"d":"Once per SSTORE operation from clean zero to non-zero"},"sstoreInitRefundEIP2200":{"v":19200,"d":"Once per SSTORE operation for resetting to the original zero value"},"sstoreCleanGasEIP2200":{"v":5000,"d":"Once per SSTORE operation from clean non-zero to something else"},"sstoreCleanRefundEIP2200":{"v":4200,"d":"Once per SSTORE operation for resetting to the original non-zero value"},"sstoreClearRefundEIP2200":{"v":15000,"d":"Once per SSTORE operation for clearing an originally existing storage slot"},"balance":{"v":700,"d":"Base fee of the BALANCE opcode"},"extcodehash":{"v":700,"d":"Base fee of the EXTCODEHASH opcode"},"chainid":{"v":2,"d":"Base fee of the CHAINID opcode"},"selfbalance":{"v":5,"d":"Base fee of the SELFBALANCE opcode"},"sload":{"v":800,"d":"Base fee of the SLOAD opcode"}},"vm":{},"pow":{}}')},1250:e=>{"use strict";e.exports=JSON.parse('{"name":"london","comment":"HF targeted for July 2021 following the Berlin fork","url":"https://github.com/ethereum/eth1.0-specs/blob/master/network-upgrades/mainnet-upgrades/london.md","status":"Draft","eips":[1559,3198,3529,3541]}')},8648:e=>{"use strict";e.exports=JSON.parse('{"name":"merge","comment":"Hardfork to upgrade the consensus mechanism to Proof-of-Stake","url":"https://github.com/ethereum/pm/issues/361","status":"pre-Draft","consensus":{"type":"pos","algorithm":"casper","casper":{}},"eips":[3675]}')},2946:e=>{"use strict";e.exports=JSON.parse('{"name":"muirGlacier","comment":"HF to delay the difficulty bomb","url":"https://eips.ethereum.org/EIPS/eip-2384","status":"Final","gasConfig":{},"gasPrices":{},"vm":{},"pow":{"difficultyBombDelay":{"v":9000000,"d":"the amount of blocks to delay the difficulty bomb with"}}}')},4064:e=>{"use strict";e.exports=JSON.parse('{"name":"petersburg","comment":"Aka constantinopleFix, removes EIP-1283, activate together with or after constantinople","url":"https://eips.ethereum.org/EIPS/eip-1716","status":"Draft","gasConfig":{},"gasPrices":{"netSstoreNoopGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreInitGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreCleanGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreDirtyGas":{"v":null,"d":"Removed along EIP-1283"},"netSstoreClearRefund":{"v":null,"d":"Removed along EIP-1283"},"netSstoreResetRefund":{"v":null,"d":"Removed along EIP-1283"},"netSstoreResetClearRefund":{"v":null,"d":"Removed along EIP-1283"}},"vm":{},"pow":{}}')},5553:e=>{"use strict";e.exports=JSON.parse('{"name":"shanghai","comment":"Next feature hardfork after the London HF","url":"https://github.com/ethereum/pm/issues/356","status":"Pre-Draft","eips":[]}')},716:e=>{"use strict";e.exports=JSON.parse('{"name":"spuriousDragon","comment":"HF with EIPs for simple replay attack protection, EXP cost increase, state trie clearing, contract code size limit","url":"https://eips.ethereum.org/EIPS/eip-607","status":"Final","gasConfig":{},"gasPrices":{"expByte":{"v":50,"d":"Times ceil(log256(exponent)) for the EXP instruction"}},"vm":{"maxCodeSize":{"v":24576,"d":"Maximum length of contract code"}},"pow":{}}')},2302:e=>{"use strict";e.exports=JSON.parse('{"name":"tangerineWhistle","comment":"Hardfork with gas cost changes for IO-heavy operations","url":"https://eips.ethereum.org/EIPS/eip-608","status":"Final","gasConfig":{},"gasPrices":{"sload":{"v":200,"d":"Once per SLOAD operation"},"call":{"v":700,"d":"Once per CALL operation & message call transaction"},"extcodesize":{"v":700,"d":"Base fee of the EXTCODESIZE opcode"},"extcodecopy":{"v":700,"d":"Base fee of the EXTCODECOPY opcode"},"balance":{"v":400,"d":"Base fee of the BALANCE opcode"},"delegatecall":{"v":700,"d":"Base fee of the DELEGATECALL opcode"},"callcode":{"v":700,"d":"Base fee of the CALLCODE opcode"},"selfdestruct":{"v":5000,"d":"Base fee of the SELFDESTRUCT opcode"}},"vm":{},"pow":{}}')},4946:e=>{"use strict";e.exports=JSON.parse('{"aes-128-ecb":{"cipher":"AES","key":128,"iv":0,"mode":"ECB","type":"block"},"aes-192-ecb":{"cipher":"AES","key":192,"iv":0,"mode":"ECB","type":"block"},"aes-256-ecb":{"cipher":"AES","key":256,"iv":0,"mode":"ECB","type":"block"},"aes-128-cbc":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes-192-cbc":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes-256-cbc":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes128":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes192":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes256":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes-128-cfb":{"cipher":"AES","key":128,"iv":16,"mode":"CFB","type":"stream"},"aes-192-cfb":{"cipher":"AES","key":192,"iv":16,"mode":"CFB","type":"stream"},"aes-256-cfb":{"cipher":"AES","key":256,"iv":16,"mode":"CFB","type":"stream"},"aes-128-cfb8":{"cipher":"AES","key":128,"iv":16,"mode":"CFB8","type":"stream"},"aes-192-cfb8":{"cipher":"AES","key":192,"iv":16,"mode":"CFB8","type":"stream"},"aes-256-cfb8":{"cipher":"AES","key":256,"iv":16,"mode":"CFB8","type":"stream"},"aes-128-cfb1":{"cipher":"AES","key":128,"iv":16,"mode":"CFB1","type":"stream"},"aes-192-cfb1":{"cipher":"AES","key":192,"iv":16,"mode":"CFB1","type":"stream"},"aes-256-cfb1":{"cipher":"AES","key":256,"iv":16,"mode":"CFB1","type":"stream"},"aes-128-ofb":{"cipher":"AES","key":128,"iv":16,"mode":"OFB","type":"stream"},"aes-192-ofb":{"cipher":"AES","key":192,"iv":16,"mode":"OFB","type":"stream"},"aes-256-ofb":{"cipher":"AES","key":256,"iv":16,"mode":"OFB","type":"stream"},"aes-128-ctr":{"cipher":"AES","key":128,"iv":16,"mode":"CTR","type":"stream"},"aes-192-ctr":{"cipher":"AES","key":192,"iv":16,"mode":"CTR","type":"stream"},"aes-256-ctr":{"cipher":"AES","key":256,"iv":16,"mode":"CTR","type":"stream"},"aes-128-gcm":{"cipher":"AES","key":128,"iv":12,"mode":"GCM","type":"auth"},"aes-192-gcm":{"cipher":"AES","key":192,"iv":12,"mode":"GCM","type":"auth"},"aes-256-gcm":{"cipher":"AES","key":256,"iv":12,"mode":"GCM","type":"auth"}}')},5207:e=>{"use strict";e.exports=JSON.parse('{"sha224WithRSAEncryption":{"sign":"rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"RSA-SHA224":{"sign":"ecdsa/rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"sha256WithRSAEncryption":{"sign":"rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"RSA-SHA256":{"sign":"ecdsa/rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"sha384WithRSAEncryption":{"sign":"rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"RSA-SHA384":{"sign":"ecdsa/rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"sha512WithRSAEncryption":{"sign":"rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA512":{"sign":"ecdsa/rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA1":{"sign":"rsa","hash":"sha1","id":"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{"sign":"ecdsa","hash":"sha1","id":""},"sha256":{"sign":"ecdsa","hash":"sha256","id":""},"sha224":{"sign":"ecdsa","hash":"sha224","id":""},"sha384":{"sign":"ecdsa","hash":"sha384","id":""},"sha512":{"sign":"ecdsa","hash":"sha512","id":""},"DSA-SHA":{"sign":"dsa","hash":"sha1","id":""},"DSA-SHA1":{"sign":"dsa","hash":"sha1","id":""},"DSA":{"sign":"dsa","hash":"sha1","id":""},"DSA-WITH-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-WITH-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-WITH-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-WITH-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-RIPEMD160":{"sign":"dsa","hash":"rmd160","id":""},"ripemd160WithRSA":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"RSA-RIPEMD160":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"md5WithRSAEncryption":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"},"RSA-MD5":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"}}')},1308:e=>{"use strict";e.exports=JSON.parse('{"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}')},3630:e=>{"use strict";e.exports=JSON.parse('{"identity":0,"ip4":4,"tcp":6,"sha1":17,"sha2-256":18,"sha2-512":19,"sha3-512":20,"sha3-384":21,"sha3-256":22,"sha3-224":23,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"blake3":30,"dccp":33,"murmur3-128":34,"murmur3-32":35,"ip6":41,"ip6zone":42,"path":47,"multicodec":48,"multihash":49,"multiaddr":50,"multibase":51,"dns":53,"dns4":54,"dns6":55,"dnsaddr":56,"protobuf":80,"cbor":81,"raw":85,"dbl-sha2-256":86,"rlp":96,"bencode":99,"dag-pb":112,"dag-cbor":113,"libp2p-key":114,"git-raw":120,"torrent-info":123,"torrent-file":124,"leofcoin-block":129,"leofcoin-tx":130,"leofcoin-pr":131,"sctp":132,"dag-jose":133,"dag-cose":134,"eth-block":144,"eth-block-list":145,"eth-tx-trie":146,"eth-tx":147,"eth-tx-receipt-trie":148,"eth-tx-receipt":149,"eth-state-trie":150,"eth-account-snapshot":151,"eth-storage-trie":152,"bitcoin-block":176,"bitcoin-tx":177,"bitcoin-witness-commitment":178,"zcash-block":192,"zcash-tx":193,"stellar-block":208,"stellar-tx":209,"md4":212,"md5":213,"bmt":214,"decred-block":224,"decred-tx":225,"ipld-ns":226,"ipfs-ns":227,"swarm-ns":228,"ipns-ns":229,"zeronet":230,"secp256k1-pub":231,"bls12_381-g1-pub":234,"bls12_381-g2-pub":235,"x25519-pub":236,"ed25519-pub":237,"dash-block":240,"dash-tx":241,"swarm-manifest":250,"swarm-feed":251,"udp":273,"p2p-webrtc-star":275,"p2p-webrtc-direct":276,"p2p-stardust":277,"p2p-circuit":290,"dag-json":297,"udt":301,"utp":302,"unix":400,"p2p":421,"ipfs":421,"https":443,"onion":444,"onion3":445,"garlic64":446,"garlic32":447,"tls":448,"quic":460,"ws":477,"wss":478,"p2p-websocket-star":479,"http":480,"json":512,"messagepack":513,"libp2p-peer-record":769,"sha2-256-trunc254-padded":4114,"ripemd-128":4178,"ripemd-160":4179,"ripemd-256":4180,"ripemd-320":4181,"x11":4352,"sm3-256":21325,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"skein256-8":45825,"skein256-16":45826,"skein256-24":45827,"skein256-32":45828,"skein256-40":45829,"skein256-48":45830,"skein256-56":45831,"skein256-64":45832,"skein256-72":45833,"skein256-80":45834,"skein256-88":45835,"skein256-96":45836,"skein256-104":45837,"skein256-112":45838,"skein256-120":45839,"skein256-128":45840,"skein256-136":45841,"skein256-144":45842,"skein256-152":45843,"skein256-160":45844,"skein256-168":45845,"skein256-176":45846,"skein256-184":45847,"skein256-192":45848,"skein256-200":45849,"skein256-208":45850,"skein256-216":45851,"skein256-224":45852,"skein256-232":45853,"skein256-240":45854,"skein256-248":45855,"skein256-256":45856,"skein512-8":45857,"skein512-16":45858,"skein512-24":45859,"skein512-32":45860,"skein512-40":45861,"skein512-48":45862,"skein512-56":45863,"skein512-64":45864,"skein512-72":45865,"skein512-80":45866,"skein512-88":45867,"skein512-96":45868,"skein512-104":45869,"skein512-112":45870,"skein512-120":45871,"skein512-128":45872,"skein512-136":45873,"skein512-144":45874,"skein512-152":45875,"skein512-160":45876,"skein512-168":45877,"skein512-176":45878,"skein512-184":45879,"skein512-192":45880,"skein512-200":45881,"skein512-208":45882,"skein512-216":45883,"skein512-224":45884,"skein512-232":45885,"skein512-240":45886,"skein512-248":45887,"skein512-256":45888,"skein512-264":45889,"skein512-272":45890,"skein512-280":45891,"skein512-288":45892,"skein512-296":45893,"skein512-304":45894,"skein512-312":45895,"skein512-320":45896,"skein512-328":45897,"skein512-336":45898,"skein512-344":45899,"skein512-352":45900,"skein512-360":45901,"skein512-368":45902,"skein512-376":45903,"skein512-384":45904,"skein512-392":45905,"skein512-400":45906,"skein512-408":45907,"skein512-416":45908,"skein512-424":45909,"skein512-432":45910,"skein512-440":45911,"skein512-448":45912,"skein512-456":45913,"skein512-464":45914,"skein512-472":45915,"skein512-480":45916,"skein512-488":45917,"skein512-496":45918,"skein512-504":45919,"skein512-512":45920,"skein1024-8":45921,"skein1024-16":45922,"skein1024-24":45923,"skein1024-32":45924,"skein1024-40":45925,"skein1024-48":45926,"skein1024-56":45927,"skein1024-64":45928,"skein1024-72":45929,"skein1024-80":45930,"skein1024-88":45931,"skein1024-96":45932,"skein1024-104":45933,"skein1024-112":45934,"skein1024-120":45935,"skein1024-128":45936,"skein1024-136":45937,"skein1024-144":45938,"skein1024-152":45939,"skein1024-160":45940,"skein1024-168":45941,"skein1024-176":45942,"skein1024-184":45943,"skein1024-192":45944,"skein1024-200":45945,"skein1024-208":45946,"skein1024-216":45947,"skein1024-224":45948,"skein1024-232":45949,"skein1024-240":45950,"skein1024-248":45951,"skein1024-256":45952,"skein1024-264":45953,"skein1024-272":45954,"skein1024-280":45955,"skein1024-288":45956,"skein1024-296":45957,"skein1024-304":45958,"skein1024-312":45959,"skein1024-320":45960,"skein1024-328":45961,"skein1024-336":45962,"skein1024-344":45963,"skein1024-352":45964,"skein1024-360":45965,"skein1024-368":45966,"skein1024-376":45967,"skein1024-384":45968,"skein1024-392":45969,"skein1024-400":45970,"skein1024-408":45971,"skein1024-416":45972,"skein1024-424":45973,"skein1024-432":45974,"skein1024-440":45975,"skein1024-448":45976,"skein1024-456":45977,"skein1024-464":45978,"skein1024-472":45979,"skein1024-480":45980,"skein1024-488":45981,"skein1024-496":45982,"skein1024-504":45983,"skein1024-512":45984,"skein1024-520":45985,"skein1024-528":45986,"skein1024-536":45987,"skein1024-544":45988,"skein1024-552":45989,"skein1024-560":45990,"skein1024-568":45991,"skein1024-576":45992,"skein1024-584":45993,"skein1024-592":45994,"skein1024-600":45995,"skein1024-608":45996,"skein1024-616":45997,"skein1024-624":45998,"skein1024-632":45999,"skein1024-640":46000,"skein1024-648":46001,"skein1024-656":46002,"skein1024-664":46003,"skein1024-672":46004,"skein1024-680":46005,"skein1024-688":46006,"skein1024-696":46007,"skein1024-704":46008,"skein1024-712":46009,"skein1024-720":46010,"skein1024-728":46011,"skein1024-736":46012,"skein1024-744":46013,"skein1024-752":46014,"skein1024-760":46015,"skein1024-768":46016,"skein1024-776":46017,"skein1024-784":46018,"skein1024-792":46019,"skein1024-800":46020,"skein1024-808":46021,"skein1024-816":46022,"skein1024-824":46023,"skein1024-832":46024,"skein1024-840":46025,"skein1024-848":46026,"skein1024-856":46027,"skein1024-864":46028,"skein1024-872":46029,"skein1024-880":46030,"skein1024-888":46031,"skein1024-896":46032,"skein1024-904":46033,"skein1024-912":46034,"skein1024-920":46035,"skein1024-928":46036,"skein1024-936":46037,"skein1024-944":46038,"skein1024-952":46039,"skein1024-960":46040,"skein1024-968":46041,"skein1024-976":46042,"skein1024-984":46043,"skein1024-992":46044,"skein1024-1000":46045,"skein1024-1008":46046,"skein1024-1016":46047,"skein1024-1024":46048,"poseidon-bls12_381-a2-fc1":46081,"poseidon-bls12_381-a2-fc1-sc":46082,"zeroxcert-imprint-256":52753,"fil-commitment-unsealed":61697,"fil-commitment-sealed":61698,"holochain-adr-v0":8417572,"holochain-adr-v1":8483108,"holochain-key-v0":9728292,"holochain-key-v1":9793828,"holochain-sig-v0":10645796,"holochain-sig-v1":10711332}')},9799:e=>{"use strict";e.exports=JSON.parse('{"modp1":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},"modp2":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},"modp5":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},"modp14":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},"modp15":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},"modp16":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},"modp17":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},"modp18":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}')},8597:e=>{"use strict";e.exports={i8:"6.5.4"}},4070:e=>{"use strict";e.exports=JSON.parse('{"identity":0,"ip4":4,"tcp":6,"sha1":17,"sha2-256":18,"sha2-512":19,"sha3-512":20,"sha3-384":21,"sha3-256":22,"sha3-224":23,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"dccp":33,"murmur3-128":34,"murmur3-32":35,"ip6":41,"ip6zone":42,"path":47,"multicodec":48,"multihash":49,"multiaddr":50,"multibase":51,"dns":53,"dns4":54,"dns6":55,"dnsaddr":56,"protobuf":80,"cbor":81,"raw":85,"dbl-sha2-256":86,"rlp":96,"bencode":99,"dag-pb":112,"dag-cbor":113,"libp2p-key":114,"git-raw":120,"torrent-info":123,"torrent-file":124,"leofcoin-block":129,"leofcoin-tx":130,"leofcoin-pr":131,"sctp":132,"eth-block":144,"eth-block-list":145,"eth-tx-trie":146,"eth-tx":147,"eth-tx-receipt-trie":148,"eth-tx-receipt":149,"eth-state-trie":150,"eth-account-snapshot":151,"eth-storage-trie":152,"bitcoin-block":176,"bitcoin-tx":177,"zcash-block":192,"zcash-tx":193,"stellar-block":208,"stellar-tx":209,"md4":212,"md5":213,"bmt":214,"decred-block":224,"decred-tx":225,"ipld-ns":226,"ipfs-ns":227,"swarm-ns":228,"ipns-ns":229,"zeronet":230,"ed25519-pub":237,"dash-block":240,"dash-tx":241,"swarm-manifest":250,"swarm-feed":251,"udp":273,"p2p-webrtc-star":275,"p2p-webrtc-direct":276,"p2p-stardust":277,"p2p-circuit":290,"dag-json":297,"udt":301,"utp":302,"unix":400,"p2p":421,"ipfs":421,"https":443,"onion":444,"onion3":445,"garlic64":446,"garlic32":447,"tls":448,"quic":460,"ws":477,"wss":478,"p2p-websocket-star":479,"http":480,"json":512,"messagepack":513,"x11":4352,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"skein256-8":45825,"skein256-16":45826,"skein256-24":45827,"skein256-32":45828,"skein256-40":45829,"skein256-48":45830,"skein256-56":45831,"skein256-64":45832,"skein256-72":45833,"skein256-80":45834,"skein256-88":45835,"skein256-96":45836,"skein256-104":45837,"skein256-112":45838,"skein256-120":45839,"skein256-128":45840,"skein256-136":45841,"skein256-144":45842,"skein256-152":45843,"skein256-160":45844,"skein256-168":45845,"skein256-176":45846,"skein256-184":45847,"skein256-192":45848,"skein256-200":45849,"skein256-208":45850,"skein256-216":45851,"skein256-224":45852,"skein256-232":45853,"skein256-240":45854,"skein256-248":45855,"skein256-256":45856,"skein512-8":45857,"skein512-16":45858,"skein512-24":45859,"skein512-32":45860,"skein512-40":45861,"skein512-48":45862,"skein512-56":45863,"skein512-64":45864,"skein512-72":45865,"skein512-80":45866,"skein512-88":45867,"skein512-96":45868,"skein512-104":45869,"skein512-112":45870,"skein512-120":45871,"skein512-128":45872,"skein512-136":45873,"skein512-144":45874,"skein512-152":45875,"skein512-160":45876,"skein512-168":45877,"skein512-176":45878,"skein512-184":45879,"skein512-192":45880,"skein512-200":45881,"skein512-208":45882,"skein512-216":45883,"skein512-224":45884,"skein512-232":45885,"skein512-240":45886,"skein512-248":45887,"skein512-256":45888,"skein512-264":45889,"skein512-272":45890,"skein512-280":45891,"skein512-288":45892,"skein512-296":45893,"skein512-304":45894,"skein512-312":45895,"skein512-320":45896,"skein512-328":45897,"skein512-336":45898,"skein512-344":45899,"skein512-352":45900,"skein512-360":45901,"skein512-368":45902,"skein512-376":45903,"skein512-384":45904,"skein512-392":45905,"skein512-400":45906,"skein512-408":45907,"skein512-416":45908,"skein512-424":45909,"skein512-432":45910,"skein512-440":45911,"skein512-448":45912,"skein512-456":45913,"skein512-464":45914,"skein512-472":45915,"skein512-480":45916,"skein512-488":45917,"skein512-496":45918,"skein512-504":45919,"skein512-512":45920,"skein1024-8":45921,"skein1024-16":45922,"skein1024-24":45923,"skein1024-32":45924,"skein1024-40":45925,"skein1024-48":45926,"skein1024-56":45927,"skein1024-64":45928,"skein1024-72":45929,"skein1024-80":45930,"skein1024-88":45931,"skein1024-96":45932,"skein1024-104":45933,"skein1024-112":45934,"skein1024-120":45935,"skein1024-128":45936,"skein1024-136":45937,"skein1024-144":45938,"skein1024-152":45939,"skein1024-160":45940,"skein1024-168":45941,"skein1024-176":45942,"skein1024-184":45943,"skein1024-192":45944,"skein1024-200":45945,"skein1024-208":45946,"skein1024-216":45947,"skein1024-224":45948,"skein1024-232":45949,"skein1024-240":45950,"skein1024-248":45951,"skein1024-256":45952,"skein1024-264":45953,"skein1024-272":45954,"skein1024-280":45955,"skein1024-288":45956,"skein1024-296":45957,"skein1024-304":45958,"skein1024-312":45959,"skein1024-320":45960,"skein1024-328":45961,"skein1024-336":45962,"skein1024-344":45963,"skein1024-352":45964,"skein1024-360":45965,"skein1024-368":45966,"skein1024-376":45967,"skein1024-384":45968,"skein1024-392":45969,"skein1024-400":45970,"skein1024-408":45971,"skein1024-416":45972,"skein1024-424":45973,"skein1024-432":45974,"skein1024-440":45975,"skein1024-448":45976,"skein1024-456":45977,"skein1024-464":45978,"skein1024-472":45979,"skein1024-480":45980,"skein1024-488":45981,"skein1024-496":45982,"skein1024-504":45983,"skein1024-512":45984,"skein1024-520":45985,"skein1024-528":45986,"skein1024-536":45987,"skein1024-544":45988,"skein1024-552":45989,"skein1024-560":45990,"skein1024-568":45991,"skein1024-576":45992,"skein1024-584":45993,"skein1024-592":45994,"skein1024-600":45995,"skein1024-608":45996,"skein1024-616":45997,"skein1024-624":45998,"skein1024-632":45999,"skein1024-640":46000,"skein1024-648":46001,"skein1024-656":46002,"skein1024-664":46003,"skein1024-672":46004,"skein1024-680":46005,"skein1024-688":46006,"skein1024-696":46007,"skein1024-704":46008,"skein1024-712":46009,"skein1024-720":46010,"skein1024-728":46011,"skein1024-736":46012,"skein1024-744":46013,"skein1024-752":46014,"skein1024-760":46015,"skein1024-768":46016,"skein1024-776":46017,"skein1024-784":46018,"skein1024-792":46019,"skein1024-800":46020,"skein1024-808":46021,"skein1024-816":46022,"skein1024-824":46023,"skein1024-832":46024,"skein1024-840":46025,"skein1024-848":46026,"skein1024-856":46027,"skein1024-864":46028,"skein1024-872":46029,"skein1024-880":46030,"skein1024-888":46031,"skein1024-896":46032,"skein1024-904":46033,"skein1024-912":46034,"skein1024-920":46035,"skein1024-928":46036,"skein1024-936":46037,"skein1024-944":46038,"skein1024-952":46039,"skein1024-960":46040,"skein1024-968":46041,"skein1024-976":46042,"skein1024-984":46043,"skein1024-992":46044,"skein1024-1000":46045,"skein1024-1008":46046,"skein1024-1016":46047,"skein1024-1024":46048,"holochain-adr-v0":8417572,"holochain-adr-v1":8483108,"holochain-key-v0":9728292,"holochain-key-v1":9793828,"holochain-sig-v0":10645796,"holochain-sig-v1":10711332}')},2562:e=>{"use strict";e.exports=JSON.parse('{"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}')},9794:e=>{"use strict";e.exports={version:"1.0.34"}},8920:e=>{"use strict";e.exports={i8:"1.8.2"}}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={id:n,loaded:!1,exports:{}};return e[n](o,o.exports,r),o.loaded=!0,o.exports}return r.amdO={},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),r(7001)})(),e.exports=t()},47529:e=>{e.exports=function(){for(var e={},r=0;r{"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}},34411:(e,t,r)=>{"use strict";function n(e){var t=this;if(t instanceof n||(t=new n),t.tail=null,t.head=null,t.length=0,e&&"function"==typeof e.forEach)e.forEach((function(e){t.push(e)}));else if(arguments.length>0)for(var r=0,i=arguments.length;r1)r=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");n=this.head.next,r=this.head.value}for(var i=0;null!==n;i++)r=e(r,n.value,i),n=n.next;return r},n.prototype.reduceReverse=function(e,t){var r,n=this.tail;if(arguments.length>1)r=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");n=this.tail.prev,r=this.tail.value}for(var i=this.length-1;null!==n;i--)r=e(r,n.value,i),n=n.prev;return r},n.prototype.toArray=function(){for(var e=new Array(this.length),t=0,r=this.head;null!==r;t++)e[t]=r.value,r=r.next;return e},n.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,r=this.tail;null!==r;t++)e[t]=r.value,r=r.prev;return e},n.prototype.slice=function(e,t){(t=t||this.length)<0&&(t+=this.length),(e=e||0)<0&&(e+=this.length);var r=new n;if(tthis.length&&(t=this.length);for(var i=0,o=this.head;null!==o&&ithis.length&&(t=this.length);for(var i=this.length,o=this.tail;null!==o&&i>t;i--)o=o.prev;for(;null!==o&&i>e;i--,o=o.prev)r.push(o.value);return r},n.prototype.splice=function(e,t,...r){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var n=0,o=this.head;null!==o&&n{const n=r(2655),i=r(84071),o=r(63857),a=r(95200),s=r(33904),{BLOCKCHAINS_RENAME_PAIRS:u}=r(16381);e.exports=class{constructor(e){const t=e.blockchain?.name,r=e;t&&Object.keys(u).includes(t)&&(r.blockchain.name=u[t]),this.initializeServices(r)}initializeServices(e){this.blockchainService=this.initializeBlockchainService(e),this.nodeApiService=this.initializeNodeApiService(e),this.inputService=new s(e),this.validationService=new o}getServices(){return{blockchainService:this.blockchainService,nodeApiService:this.nodeApiService,validationService:this.validationService,inputService:this.inputService}}initializeNodeApiService(e){return e.communicationType&&n[e.communicationType]?new n[e.communicationType](e):new n.Default(e)}initializeBlockchainService(e){return a.nodeSupported()?new i.Node(e):a.nodeSupported()||window.ethereum||!e.blockchain?.privateKey?new i.Browser(e):new i.Node(e)}}},84071:(e,t,r)=>{const n=r(73597),i=r(38238);e.exports={Browser:n,Node:i}},92788:(e,t,r)=>{const n=r(37918),i=r(9669),o=r(84064),a=r(67448),s=r(60082),u=r(26758),c=r(44664),l=r(74066),f=r(64776),h=r(65177),d=r(11926),p=r(50575),m=r(12936),y=r(64004),g=r(88767),{OPERATIONS_STEP_STATUS:b,DEFAULT_GAS_PRICE:v}=r(16381),w=r(54209);e.exports=class{constructor(e={}){this.config=e,this.events={},this.abis={},this.abis.AssertionStorage=o,this.abis.Hub=a,this.abis.ServiceAgreementV1=s,this.abis.ServiceAgreementStorageProxy=u,this.abis.ContentAssetStorage=c,this.abis.UnfinalizedStateStorage=l,this.abis.ContentAsset=f,this.abis.Token=h,this.abis.Paranet=d,this.abis.ParanetsRegistry=p,this.abis.ParanetIncentivesPoolFactory=m,this.abis.ParanetNeuroIncentivesPool=y,this.abis.ParanetKnowledgeMinersRegistry=g,this.abis.ContentAsset.filter((e=>"event"===e.type)).forEach((e=>{const t=e.inputs.map((e=>e.internalType));this.events[e.name]={hash:n.utils.keccak256(`${e.name}(${t})`),inputs:e.inputs}}))}initializeWeb3(){return{}}async decodeEventLogs(){}async getPublicKey(){}async ensureBlockchainInfo(e){if(!this[e.name]){this[e.name]={contracts:{[e.hubContract]:{}},contractAddresses:{[e.hubContract]:{Hub:e.hubContract}}};const t=await this.getWeb3Instance(e);this[e.name].contracts[e.hubContract].Hub=new t.eth.Contract(this.abis.Hub,e.hubContract,{from:e.publicKey})}}async getWeb3Instance(e){if(!this[e.name].web3){const t={transactionPollingTimeout:e.transactionPollingTimeout};await this.initializeWeb3(e.name,e.rpc,t)}return this[e.name].web3}async getNetworkGasPrice(e){await this.ensureBlockchainInfo(e);const t=await this.getWeb3Instance(e);try{let r;if(e.name.startsWith("otp"))r=await t.eth.getGasPrice();else if(e.name.startsWith("base"))r=await t.eth.getGasPrice();else if(e.name.startsWith("gnosis")){const t=await i.get(e.gasPriceOracleLink);"100"===e.name.split(":")[1]?r=Number(t.data.result,10):"10200"===e.name.split(":")[1]&&(r=Math.round(1e9*t.data.average))}else r=n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei");return r}catch(t){return console.warn(`Failed to fetch the gas price from the network: ${t}. Using default value: 2 Gwei.`),n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei")}}async callContractFunction(e,t,r,n){await this.ensureBlockchainInfo(n);let i=await this.getContractInstance(e,n);try{return await i.methods[t](...r).call()}catch(o){if(/revert|VM Exception/i.test(o.message)){let o;try{o=await i.methods.status().call()}catch(e){o=!1}if(!o&&"ParanetNeuroIncentivesPool"!==e)return await this.updateContractInstance(e,n,!0),i=await this.getContractInstance(e,n),i.methods[t](...r).call()}throw o}}async prepareTransaction(e,t,r,n){await this.ensureBlockchainInfo(n);const i=await this.getWeb3Instance(n),o=await this.getPublicKey(n),a=await e.methods[t](...r).encodeABI();let s,u=Number(await e.methods[t](...r).estimateGas({from:o}));if(u=Math.round(u*n.gasLimitMultiplier),n.previousTxGasPrice&&n.retryTx)s=Math.round(1.2*n.previousTxGasPrice);else if(n.forceReplaceTxs){const e=await i.eth.getTransactionCount(o,"pending"),t=await i.eth.getTransactionCount(o,"latest");if(e>t){const e=await i.eth.getBlock("pending",!0),r=Object.values(e.transactions).find((e=>e.from.toLowerCase()===o.toLowerCase()&&e.nonce===t));s=r?Math.round(1.2*Number(r.gasPrice)):Math.round(1.2*(n.gasPrice||await this.getNetworkGasPrice(n)))}}else s=n.gasPrice||await this.getNetworkGasPrice(n);return n.simulateTxs&&await i.eth.call({to:e.options.address,data:a,from:o,gasPrice:s,gas:u}),{from:o,to:e.options.address,data:a,gasPrice:s,gas:u}}async getContractAddress(e,t,r=!1){return await this.ensureBlockchainInfo(t),!r&&this[t.name].contractAddresses[t.hubContract][e]||(this[t.name].contractAddresses[t.hubContract][e]=await this.callContractFunction("Hub",e.includes("AssetStorage")?"getAssetStorageAddress":"getContractAddress",[e],t)),this[t.name].contractAddresses[t.hubContract][e]}async updateContractInstance(e,t,r=!1){if(await this.ensureBlockchainInfo(t),await this.getContractAddress(e,t,r),r||!this[t.name].contracts[t.hubContract][e]){const r=await this.getWeb3Instance(t);this[t.name].contracts[t.hubContract][e]=await new r.eth.Contract(this.abis[e],this[t.name].contractAddresses[t.hubContract][e],{from:t.publicKey})}}async getContractInstance(e,t){return await this.updateContractInstance(e,t),this[t.name].contracts[t.hubContract][e]}async increaseServiceAgreementV1Allowance(e,t,r,n){const i=await this.callContractFunction("Token","allowance",[e,t],n),o=BigInt(r)-BigInt(i);return o>0?(await this.executeContractFunction("Token","increaseAllowance",[t,o],n),{allowanceIncreased:!0,allowanceGap:o}):{allowanceIncreased:!1,allowanceGap:o}}async createAsset(e,t,r,n,i=w){const o=await this.getPublicKey(n);let a,s=!1,u=0;try{let c;a=await this.getContractAddress("ServiceAgreementV1",n),({allowanceIncreased:s,allowanceGap:u}=await this.increaseServiceAgreementV1Allowance(o,a,e.tokenAmount,n)),i.afterHook({status:b.INCREASE_ALLOWANCE_COMPLETED}),c=null==t&&null==r?await this.executeContractFunction("ContentAsset","createAsset",[Object.values(e)],n):await this.executeContractFunction("Paranet","mintKnowledgeAsset",[t,r,Object.values(e)],n);let{tokenId:l}=await this.decodeEventLogs(c,"AssetMinted",n);return l=parseInt(l,10),i.afterHook({status:b.CREATE_ASSET_COMPLETED,data:{tokenId:l}}),l}catch(e){throw s&&await this.executeContractFunction("Token","decreaseAllowance",[a,u],n),e}}async updateAsset(e,t,r,n,i,o,a){const s=await this.getPublicKey(a);let u,c=!1,l=0;try{return u=await this.getContractAddress("ServiceAgreementV1",a),({allowanceIncreased:c,allowanceGap:l}=await this.increaseServiceAgreementV1Allowance(s,u,o,a)),this.executeContractFunction("ContentAsset","updateAssetState",[e,t,r,n,i,o],a)}catch(e){throw c&&await this.executeContractFunction("Token","decreaseAllowance",[u,l],a),e}}async hasPendingUpdate(e,t){return this.callContractFunction("UnfinalizedStateStorage","hasPendingUpdate",[e],t)}async cancelAssetUpdate(e,t){return this.executeContractFunction("ContentAsset","cancelAssetStateUpdate",[e],t)}async getLatestAssertionId(e,t){return this.callContractFunction("ContentAssetStorage","getLatestAssertionId",[e],t)}async getUnfinalizedState(e,t){return this.callContractFunction("UnfinalizedStateStorage","getUnfinalizedState",[e],t)}async getAssetOwner(e,t){return this.callContractFunction("ContentAssetStorage","ownerOf",[e],t)}async burnAsset(e,t){return this.executeContractFunction("ContentAsset","burnAsset",[e],t)}async extendAssetStoringPeriod(e,t,r,n){const i=await this.getPublicKey(n);let o,a=!1,s=0;try{return o=await this.getContractAddress("ServiceAgreementV1",n),({allowanceIncreased:a,allowanceGap:s}=await this.increaseServiceAgreementV1Allowance(i,o,r,n)),this.executeContractFunction("ContentAsset","extendAssetStoringPeriod",[e,t,r],n)}catch(e){throw a&&await this.executeContractFunction("Token","decreaseAllowance",[o,s],n),e}}async addTokens(e,t,r){const n=await this.getPublicKey(r);let i,o=!1,a=0;try{return i=await this.getContractAddress("ServiceAgreementV1",r),({allowanceIncreased:o,allowanceGap:a}=await this.increaseServiceAgreementV1Allowance(n,i,t,r)),this.executeContractFunction("ContentAsset","increaseAssetTokenAmount",[e,t],r)}catch(e){throw o&&await this.executeContractFunction("Token","decreaseAllowance",[i,a],r),e}}async addUpdateTokens(e,t,r){const n=await this.getPublicKey(r);let i,o=!1,a=0;try{return i=await this.getContractAddress("ServiceAgreementV1",r),({allowanceIncreased:o,allowanceGap:a}=await this.increaseServiceAgreementV1Allowance(n,i,t,r)),this.executeContractFunction("ContentAsset","increaseAssetUpdateTokenAmount",[e,t],r)}catch(e){throw o&&await this.executeContractFunction("Token","decreaseAllowance",[i,a],r),e}}async getAssertionIdByIndex(e,t,r){return this.callContractFunction("ContentAssetStorage","getAssertionIdByIndex",[e,t],r)}async getAssertionIds(e,t){return this.callContractFunction("ContentAssetStorage","getAssertionIds",[e],t)}async getAssertionIssuer(e,t,r,n){return this.callContractFunction("ContentAssetStorage","getAssertionIssuer",[e,t,r],n)}async getAgreementData(e,t){const r=await this.callContractFunction("ServiceAgreementStorageProxy","getAgreementData",[e],t);return{startTime:Number(r[0]),epochsNumber:Number(r[1]),epochLength:Number(r[2]),tokenAmount:r[3][0],addedTokenAmount:r[3][1],scoreFunctionId:r[4][0],proofWindowOffsetPerc:r[4][1]}}async getAssertionSize(e,t){return this.callContractFunction("AssertionStorage","getAssertionSize",[e],t)}async registerParanet(e,t){return this.executeContractFunction("Paranet","registerParanet",Object.values(e),t)}async deployNeuroIncentivesPool(e,t){return this.executeContractFunction("ParanetIncentivesPoolFactory","deployNeuroIncentivesPool",Object.values(e),t)}async registerParanetService(e,t){return this.executeContractFunction("Paranet","registerParanetService",Object.values(e),t)}async addParanetServices(e,t){return this.executeContractFunction("Paranet","addParanetServices",Object.values(e),t)}async submitToParanet(e,t){return this.executeContractFunction("Paranet","submitKnowledgeAsset",Object.values(e),t)}async getUpdatingKnowledgeAssetStates(e,t){return this.callContractFunction("ParanetKnowledgeMinersRegistry","getUpdatingKnowledgeAssetStates",Object.values(e),t)}async updateClaimableRewards(e,t){return this.executeContractFunction("Paranet","processUpdatedKnowledgeAssetStatesMetadata",Object.values(e),t)}async getIncentivesPoolAddress(e,t){return this.callContractFunction("ParanetsRegistry","getIncentivesPoolAddress",Object.values(e),t)}async getNeuroIncentivesPoolAddress(e,t){return this.getIncentivesPoolAddress({paranetId:e,incentivesPoolType:"Neuroweb"},t)}async setIncentivesPool(e,t){if(await this.ensureBlockchainInfo(t),this[t.name].contractAddresses[t.hubContract].ParanetNeuroIncentivesPool!==e){this[t.name].contractAddresses[t.hubContract].ParanetNeuroIncentivesPool=e;const r=await this.getWeb3Instance(t);this[t.name].contracts[t.hubContract].ParanetNeuroIncentivesPool=await new r.eth.Contract(this.abis.ParanetNeuroIncentivesPool,this[t.name].contractAddresses[t.hubContract].ParanetNeuroIncentivesPool,{from:t.publicKey})}}async claimKnowledgeMinerReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.executeContractFunction("ParanetNeuroIncentivesPool","claimKnowledgeMinerReward",[],t)}async claimVoterReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.executeContractFunction("ParanetNeuroIncentivesPool","claimIncentivizationProposalVoterReward",[],t)}async claimOperatorReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.executeContractFunction("ParanetNeuroIncentivesPool","claimParanetOperatorReward",[],t)}async getClaimableKnowledgeMinerReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableKnowledgeMinerRewardAmount",[],t)}async getClaimableAllKnowledgeMinersReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableAllKnowledgeMinersRewardAmount",[],t)}async getClaimableVoterReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableProposalVoterRewardAmount",[],t)}async getClaimableAllVotersReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableAllProposalVotersRewardAmount",[],t)}async getClaimableOperatorReward(e,t){const r=await this.getNeuroIncentivesPoolAddress(e,t);return await this.setIncentivesPool(r,t),this.callContractFunction("ParanetNeuroIncentivesPool","getClaimableParanetOperatorRewardAmount",[],t)}async isParanetKnowledgeMiner(e,t,r){const n=await this.getNeuroIncentivesPoolAddress(t,r);return await this.setIncentivesPool(n,r),this.callContractFunction("ParanetNeuroIncentivesPool","isKnowledgeMiner",[e],r)}async isParanetOperator(e,t,r){const n=await this.getNeuroIncentivesPoolAddress(t,r);return await this.setIncentivesPool(n,r),this.callContractFunction("ParanetNeuroIncentivesPool","isParanetOperator",[e],r)}async isParanetProposalVoter(e,t,r){const n=await this.getNeuroIncentivesPoolAddress(t,r);return await this.setIncentivesPool(n,r),this.callContractFunction("ParanetNeuroIncentivesPool","isProposalVoter",[e],r)}async getChainId(e){await this.ensureBlockchainInfo(e);return(await this.getWeb3Instance(e)).eth.getChainId()}async getBlockchainTimestamp(e){if(!e.name.startsWith("hardhat"))return Math.floor(Date.now()/1e3);return(await this.getLatestBlock(e)).timestamp}async getGasPrice(e){await this.ensureBlockchainInfo(e);const t=await this.getWeb3Instance(e);try{let r;if(e.name.startsWith("otp")||e.name.startsWith("base"))r=await t.eth.getGasPrice();else if(e.name.startsWith("gnosis")){const t=await i.get(e.gasPriceOracleLink);"100"===e.name.split(":")[1]?r=Number(t.result,10):"10200"===e.name.split(":")[1]&&(r=Math.round(1e9*t.data.average))}else r=n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei");return r}catch(t){return console.warn(`Failed to fetch the gas price from the network: ${t}. Using default value: 2 Gwei.`),n.utils.toWei(e.name.startsWith("otp")?v.OTP:v.GNOSIS,"Gwei")}}async getWalletBalances(e){await this.ensureBlockchainInfo(e);const t=await this.getWeb3Instance(e),r=await this.getPublicKey(e);return{blockchainToken:await t.eth.getBalance(r),trac:await this.callContractFunction("Token","balanceOf",[await this.getPublicKey(e)],e)}}async getLatestBlock(e){await this.ensureBlockchainInfo(e);const t=await this.getWeb3Instance(e),r=await t.eth.getBlockNumber();return t.eth.getBlock(r)}convertToWei(e){return n.utils.toWei(e.toString(),"ether")}}},73597:(e,t,r)=>{const n=r(37918),i=r(92788),{WEBSOCKET_PROVIDER_OPTIONS:o}=r(16381);e.exports=class extends i{constructor(e={}){super(e),this.config=e}async initializeWeb3(e,t){if(void 0!==window.web3&&window.web3||console.error("No web3 implementation injected, please inject your own Web3 implementation."),window.ethereum){this[e].web3=new n(window.ethereum);try{await window.ethereum.enable()}catch(e){console.error(e)}}else if(t.startsWith("ws")){const r=(new n).providers.WebsocketProvider(t,o);this[e].web3=new n(r)}else this[e].web3=new n(t)}async decodeEventLogs(e,t,r){await this.ensureBlockchainInfo(r);const n=await this.getWeb3Instance(r);let i;const{hash:o,inputs:a}=this.events[t],s=Object.values(e.events);for(const e of s)if(e.raw.topics&&e.raw.topics.length>0&&e.raw.topics[0]===o){i=n.eth.abi.decodeLog(a,e.raw.data,e.raw.topics.slice(1));break}return i}async executeContractFunction(e,t,r,n){await this.ensureBlockchainInfo(n);let i,o=await this.getContractInstance(e,n);try{return i=await this.prepareTransaction(o,t,r,n),await o.methods[t](...r).send(i)}catch(a){if(/revert|VM Exception/i.test(a.message)){let a;try{a=await o.methods.status().call()}catch(e){a=!1}if(!a){await this.updateContractInstance(e,n,!0),o=await this.getContractInstance(e,n);const a=await this.getWeb3Instance(n);return await a.eth.call({to:o.options.address,data:i.data,from:i.from}),o.methods[t](...r).send(i)}}throw a}}async getPublicKey(){return this.getAccount()}async getAccount(){if(!this.account){if(!window.ethereum)throw Error("This operation can be performed only by using Metamask accounts.");const e=await window.ethereum.request({method:"eth_requestAccounts"}).catch((()=>console.error("There was an error fetching your accounts")));[this.account]=e}return this.account}async transferAsset(e,t,r){return this.executeContractFunction("ContentAssetStorage","transferFrom",[await this.getAccount(),t,e],r)}}},38238:(e,t,r)=>{const n=r(37918),{TRANSACTION_RETRY_ERRORS:i,WEBSOCKET_PROVIDER_OPTIONS:o}=r(16381),a=r(92788);e.exports=class extends a{constructor(e={}){super(e),this.config=e,this.events={},this.abis.ContentAsset.filter((e=>"event"===e.type)).forEach((e=>{const t=e.inputs.map((e=>e.internalType));this.events[e.name]={hash:n.utils.keccak256(`${e.name}(${t})`),inputs:e.inputs}}))}initializeWeb3(e,t,r){if(t.startsWith("ws")){const r=new n.providers.WebsocketProvider(t,o);this[e].web3=new n(r)}else this[e].web3=new n(t);r.transactionPollingTimeout&&(this[e].web3.eth.transactionPollingTimeout=r.transactionPollingTimeout)}async decodeEventLogs(e,t,r){await this.ensureBlockchainInfo(r);const n=await this.getWeb3Instance(r);let i;const{hash:o,inputs:a}=this.events[t];for(const t of e.logs)if(t.topics&&t.topics.length>0&&t.topics[0]===o){i=n.eth.abi.decodeLog(a,t.data,t.topics.slice(1));break}return i}async getPublicKey(e){return e?.publicKey}async executeContractFunction(e,t,r,n){await this.ensureBlockchainInfo(n);const o=await this.getWeb3Instance(n);let a,s,u=await this.getContractInstance(e,n),c=!1,l=!1;for(;void 0===a;)try{const e=await this.prepareTransaction(u,t,r,n);s=e.gasPrice,c=!0;const i=await o.eth.accounts.signTransaction(e,n.privateKey);a=await o.eth.sendSignedTransaction(i.rawTransaction)}catch(t){if(c&&!l&&n.handleNotMinedError&&i.some((e=>t.message.toLowerCase().includes(e))))l=!0,n.retryTx=!0,n.previousTxGasPrice=s;else{if(l||!/revert|VM Exception/i.test(t.message))throw t;{let r;try{r=await u.methods.status().call()}catch(e){r=!1}if(r||"ParanetNeuroIncentivesPool"===e)throw t;await this.updateContractInstance(e,n,!0),u=await this.getContractInstance(e,n),l=!0,n.retryTx=!0}}}return a}async transferAsset(e,t,r){return this.executeContractFunction("ContentAssetStorage","transferFrom",[r.publicKey,t,e],r)}}},33904:(e,t,r)=>{const{DEFAULT_PARAMETERS:n,DEFAULT_PROXIMITY_SCORE_FUNCTIONS_PAIR_IDS:i,BLOCKCHAINS:o,LOW_BID_SUGGESTION:a}=r(16381);e.exports=class{constructor(e={}){this.config=e}getBidSuggestionArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),epochsNum:this.getEpochsNum(e),hashFunctionId:this.getHashFunctionId(e),authToken:this.getAuthToken(e),bidSuggestionRange:this.getBidSuggestionRange(e)}}getAssetCreateArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),epochsNum:this.getEpochsNum(e),hashFunctionId:this.getHashFunctionId(e),scoreFunctionId:this.getScoreFunctionId(e),immutable:this.getImmutable(e),tokenAmount:this.getTokenAmount(e),authToken:this.getAuthToken(e),paranetUAL:this.getParanetUAL(e)}}getAssetGetArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),state:this.getState(e),contentType:this.getContentType(e),validate:this.getValidate(e),outputFormat:this.getOutputFormat(e),authToken:this.getAuthToken(e),hashFunctionId:this.getHashFunctionId(e)}}getAssetUpdateArguments(e){return{blockchain:this.getBlockchain(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),hashFunctionId:this.getHashFunctionId(e),scoreFunctionId:this.getScoreFunctionId(e),tokenAmount:this.getTokenAmount(e),authToken:this.getAuthToken(e)}}getQueryArguments(e){return{graphLocation:this.getGraphLocation(e),graphState:this.getGraphState(e),endpoint:this.getEndpoint(e),port:this.getPort(e),maxNumberOfRetries:this.getMaxNumberOfRetries(e),frequency:this.getFrequency(e),authToken:this.getAuthToken(e)}}getParanetCreateArguments(e){return{blockchain:this.getBlockchain(e),paranetName:this.getParanetName(e),paranetDescription:this.getParanetDescription(e)}}getParanetDeployIncentivesContractArguments(e){return{blockchain:this.getBlockchain(e),incentiveType:this.getIncentiveType(e),tracToNeuroEmissionMultiplier:this.getTracToNeuroEmissionMultiplier(e),operatorRewardPercentage:this.getOperatorRewardPercentage(e),incentivizationProposalVotersRewardPercentage:this.getIncentivizationProposalVotersRewardPercentage(e)}}getParanetCreateServiceArguments(e){return{blockchain:this.getBlockchain(e),paranetServiceName:this.getParanetServiceName(e),paranetServiceDescription:this.getParanetServiceDescription(e),paranetServiceAddresses:this.getParanetServiceAddresses(e)}}getParanetRoleCheckArguments(e){return{blockchain:this.getBlockchain(e),roleAddress:this.getRoleAddress(e)}}getBlockchain(e){const t=e.environment??this.config.environment??n.ENVIRONMENT,r=e.blockchain?.name??this.config.blockchain?.name??null,i=e.blockchain?.rpc??this.config.blockchain?.rpc??o[t][r]?.rpc,a=e.blockchain?.hubContract??this.config.blockchain?.hubContract??o[t][r]?.hubContract,s=e.blockchain?.publicKey??this.config.blockchain?.publicKey??null,u=e.blockchain?.privateKey??this.config.blockchain?.privateKey??null,c=e.blockchain?.handleNotMinedError??this.config.blockchain?.handleNotMinedError??n.HANDLE_NOT_MINED_ERROR;return{name:r,rpc:i,hubContract:a,publicKey:s,privateKey:u,gasLimitMultiplier:e.blockchain?.gasLimitMultiplier??this.config.blockchain?.gasLimitMultiplier??n.GAS_LIMIT_MULTIPLIER,gasPrice:e.blockchain?.gasPrice??this.config.blockchain?.gasPrice??void 0,transactionPollingTimeout:e.blockchain?.transactionPollingTimeout??this.config.blockchain?.transactionPollingTimeout??null,handleNotMinedError:c,simulateTxs:e.blockchain?.simulateTxs??this.config.blockchain?.simulateTxs??n.SIMULATE_TXS,forceReplaceTxs:e.blockchain?.forceReplaceTxs??this.config.blockchain?.forceReplaceTxs??n.FORCE_REPLACE_TXS,gasPriceOracleLink:e.blockchain?.gasPriceOracleLink??this.config.blockchain?.gasPriceOracleLink??o[t][r]?.gasPriceOracleLink??void 0}}getGraphLocation(e){return e.graphLocation??e.paranetUAL??this.config.graphLocation??n.GRAPH_LOCATION}getGraphState(e){return e.graphState??this.config.graphState??n.GRAPH_STATE}getEndpoint(e){return e.endpoint??this.config.endpoint??null}getPort(e){return e.port??this.config.port??n.PORT}getFrequency(e){return e.frequency??this.config.frequency??n.FREQUENCY}getHashFunctionId(e){return e.hashFunctionId??this.config.hashFunctionId??n.HASH_FUNCTION_ID}getScoreFunctionId(e){const t=e.environment??this.config.environment??n.ENVIRONMENT,r=this.getBlockchain(e).name;return i[t][r]}getEpochsNum(e){return e.epochsNum??this.config.epochsNum??null}getImmutable(e){return e.immutable??this.config.immutable??n.IMMUTABLE}getTokenAmount(e){return e.tokenAmount??this.config.tokenAmount??null}getState(e){return e.state??this.config.state??n.STATE}getContentType(e){return e.contentType??this.config.contentType??n.CONTENT_TYPE}getValidate(e){return e.validate??this.config.validate??n.VALIDATE}getOutputFormat(e){return e.outputFormat??this.config.outputFormat??n.OUTPUT_FORMAT}getMaxNumberOfRetries(e){return e.maxNumberOfRetries??this.config.maxNumberOfRetries??n.MAX_NUMBER_OF_RETRIES}getAuthToken(e){return e.auth?.token??this.config?.auth?.token??null}getBidSuggestionRange(e){return e.bidSuggestionRange??a}getParanetUAL(e){return e.paranetUAL??this.config.paranetUAL??null}getParanetName(e){return e.paranetName??null}getParanetDescription(e){return e.paranetDescription??null}getTracToNeuroEmissionMultiplier(e){return e.tracToNeuroEmissionMultiplier??null}getIncentivizationProposalVotersRewardPercentage(e){return 100*e.incentivizationProposalVotersRewardPercentage??null}getOperatorRewardPercentage(e){return 100*e.operatorRewardPercentage??null}getIncentiveType(e){return e.incentiveType??null}getParanetServiceName(e){return e.paranetServiceName??null}getParanetServiceDescription(e){return e.paranetServiceDescription??null}getParanetServiceAddresses(e){return e.paranetServiceAddresses??[]}getRoleAddress(e){return e.roleAddress??null}}},64420:(e,t,r)=>{const n=r(9669),{OPERATION_STATUSES:i}=r(16381),{sleepForMilliseconds:o}=r(95200);e.exports=class{constructor(e={}){this.config=e}async info(e,t,r){try{return await n({method:"get",url:`${e}:${t}/info`,headers:this.prepareRequestConfig(r)})}catch(e){throw Error(`Unable to get node info: ${e.message}`)}}async getBidSuggestion(e,t,r,i,o,a,s,u,c,l){try{const f={blockchain:i,epochsNumber:o,assertionSize:a,contentAssetStorageAddress:s,firstAssertionId:u,hashFunctionId:c};null!=l&&(f.bidSuggestionRange=l);return(await n({method:"get",url:`${e}:${t}/bid-suggestion`,params:f,headers:this.prepareRequestConfig(r)})).data.bidSuggestion}catch(e){throw Error(`Unable to get bid suggestion: ${e.message}`)}}async localStore(e,t,r,i){try{return(await n({method:"post",url:`${e}:${t}/local-store`,data:i,headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to store locally: ${e.message}`)}}async publish(e,t,r,i,o,a,s,u,c){try{return(await n({method:"post",url:`${e}:${t}/publish`,data:{assertionId:i,assertion:o,blockchain:a,contract:s,tokenId:u,hashFunctionId:c},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to publish: ${e.message}`)}}async get(e,t,r,i,o,a){try{return(await n({method:"post",url:`${e}:${t}/get`,data:{id:i,state:o,hashFunctionId:a},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to get assertion: ${e.message}`)}}async update(e,t,r,i,o,a,s,u,c){try{return(await n({method:"post",url:`${e}:${t}/update`,data:{assertionId:i,assertion:o,blockchain:a,contract:s,tokenId:u,hashFunctionId:c},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to update: ${e.message}`)}}async query(e,t,r,i,o,a){try{return(await n({method:"post",url:`${e}:${t}/query`,data:{query:i,type:o,repository:a},headers:this.prepareRequestConfig(r)})).data.operationId}catch(e){throw Error(`Unable to query: ${e.message}`)}}async getOperationResult(e,t,r,a,s,u,c){await o(500);let l={status:i.PENDING},f=0;const h={method:"get",url:`${e}:${t}/${a}/${c}`,headers:this.prepareRequestConfig(r)};do{if(f>s){l.data={...l.data,data:{errorType:"DKG_CLIENT_ERROR",errorMessage:"Unable to get results. Max number of retries reached."}};break}f+=1,await o(1e3*u),l=await n(h)}while(l.data.status!==i.COMPLETED&&l.data.status!==i.FAILED);return l.data}prepareRequestConfig(e){return e?{Authorization:`Bearer ${e}`}:{}}}},67601:e=>{e.exports=class{publish(){}getOperationResult(){}}},2655:(e,t,r)=>{const n=r(67601),i=r(64420);e.exports={Sockets:n,Https:i,Http:i,Default:i}},95200:(e,t,r)=>{const n=r(36805),{GRAPH_LOCATIONS:i,GRAPH_STATES:o,OT_NODE_TRIPLE_STORE_REPOSITORIES:a}=r(16381);e.exports={nodeSupported:()=>"undefined"==typeof window,isEmptyObject:function(e){return 0===Object.keys(e).length&&e.constructor===Object},toNumber:e=>parseInt(e.slice(2),16),deriveUAL:(e,t,r)=>`did:dkg:${e.toLowerCase()}/${t.toLowerCase()}/${r}`,resolveUAL(e){const t=e.split(":"),r=(3===t.length?t[2]:`${t[2]}:${t[3]}`).split("/");if(3!==r.length)throw new Error(`UAL doesn't have correct format: ${e}`);return{blockchain:r[0],contract:r[1],tokenId:parseInt(r[2],10)}},deriveRepository(e,t){switch(e+t){case i.PUBLIC_KG+o.CURRENT:return a.PUBLIC_CURRENT;case i.PUBLIC_KG+o.HISTORICAL:return a.PUBLIC_HISTORY;case i.LOCAL_KG+o.CURRENT:return a.PRIVATE_CURRENT;case i.LOCAL_KG+o.HISTORICAL:return a.PRIVATE_HISTORY;default:return e}},async sleepForMilliseconds(e){await new Promise((t=>setTimeout(t,e)))},capitalizeFirstLetter:e=>e[0].toUpperCase()+e.slice(1),getOperationStatusObject:(e,t)=>({operationId:t,...e.data?.errorType?{status:e.status,...e.data}:{status:e.status}}),async toNQuads(e,t){const r={algorithm:"URDNA2015",format:"application/n-quads"};t&&(r.inputFormat=t);return(await n.canonize(e,r)).split("\n").filter((e=>""!==e))},toJSONLD:async e=>n.fromRDF(e,{algorithm:"URDNA2015",format:"application/n-quads"})}},63857:(e,t,r)=>{const{ASSET_STATES:n,CONTENT_TYPES:i,GRAPH_LOCATIONS:o,GRAPH_STATES:a,MAX_FILE_SIZE:s,OPERATIONS:u,GET_OUTPUT_FORMATS:c,QUERY_TYPES:l,BID_SUGGESTION_RANGE_ENUM:f}=r(16381),{nodeSupported:h}=r(95200);e.exports=class{validateNodeInfo(e,t,r){this.validateEndpoint(e),this.validatePort(t),this.validateAuthToken(r)}validateGraphQuery(e,t,r,n,i,o,a,s,u){this.validateQueryString(e),this.validateQueryType(t),this.validateGraphLocation(r),this.validateGraphState(n),this.validateEndpoint(i),this.validatePort(o),this.validateMaxNumberOfRetries(a),this.validateFrequency(s),this.validateAuthToken(u)}validateIsValidUAL(e){this.validateBlockchain(e)}validateSetAllowance(e){this.validateBlockchain(e)}validateIncreaseAllowance(e){this.validateBlockchain(e)}validateDecreaseAllowance(e){this.validateBlockchain(e)}validateAssetCreate(e,t,r,n,i,o,a,s,c,l,f,h,d){this.validateContent(e),this.validateBlockchain(t,u.PUBLISH),this.validateEndpoint(r),this.validatePort(n),this.validateMaxNumberOfRetries(i),this.validateFrequency(o),this.validateEpochsNum(a),this.validateHashFunctionId(s),this.validateScoreFunctionId(c),this.validateImmutable(l),this.validateTokenAmount(f),this.validateAuthToken(h),this.validateParanetUAL(d)}validateAssetGet(e,t,r,n,i,o,a,s,c,l,f,h){this.validateUAL(e),this.validateBlockchain(t,u.GET),this.validateEndpoint(r),this.validatePort(n),this.validateMaxNumberOfRetries(i),this.validateFrequency(o),this.validateState(a),this.validateContentType(s),this.validateHashFunctionId(c),this.validateValidate(l),this.validateOutputFormat(f),this.validateAuthToken(h)}validateAssetUpdate(e,t,r,n,i,o,a,s,c,l){this.validateContent(e),this.validateBlockchain(t,u.UPDATE),this.validateEndpoint(r),this.validatePort(n),this.validateMaxNumberOfRetries(i),this.validateFrequency(o),this.validateHashFunctionId(a),this.validateScoreFunctionId(s),this.validateTokenAmount(c),this.validateAuthToken(l)}validateWaitAssetUpdateFinalization(e,t,r,n){this.validateUAL(e),this.validateBlockchain(t),this.validateFrequency(r),this.validateMaxNumberOfRetries(n)}validateAssetUpdateCancel(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetTransfer(e,t,r){this.validateUAL(e),this.validateNewOwner(t),this.validateBlockchain(r)}validateAssetGetOwner(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetGetStateIssuer(e,t,r){this.validateUAL(e),this.validateStateIndex(t),this.validateBlockchain(r)}validateAssetGetStates(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetGetLatestStateIssuer(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateAssetBurn(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateExtendAssetStoringPeriod(e,t,r,n){this.validateUAL(e),this.validateEpochsNum(t),this.validateTokenAmount(r),this.validateBlockchain(n)}validateAddTokens(e,t,r){this.validateUAL(e),this.validateTokenAmount(t),this.validateBlockchain(r)}validateParanetCreate(e,t,r,n){this.validateUAL(e),this.validateBlockchain(t),this.validateParanetName(r),this.validateParanetDescription(n)}validateDeployIncentivesContract(e,t,r,n,i){this.validateUAL(e),this.validateBlockchain(t),this.validateTracToNeuroEmissionMultiplier(r),this.validateOperatorRewardPercentage(n),this.validateIncentivizationProposalVotersRewardPercentage(i)}validateParanetRewardArguments(e,t){this.validateUAL(e),this.validateBlockchain(t)}validateParanetRoleCheckArguments(e,t,r){this.validateAddress(e),this.validateUAL(t),this.validateBlockchain(r)}validateParanetCreateServiceArguments(e,t,r,n,i){this.validateUAL(e),this.validateBlockchain(i),this.validateParanetServiceName(t),this.validateParanetServiceDescription(r),this.validateParanetServiceAddresses(n)}validateParanetAddServicesArguments(e,t,r){this.validateUAL(e),this.validateBlockchain(r);for(const e of t)this.validateUAL(e)}validateSubmitToParanet(e,t,r){this.validateUAL(e),this.validateUAL(t),this.validateBlockchain(r)}validateRequiredParam(e,t){if(null==t)throw Error(`${e} is missing.`)}validateParamType(e,t,r){const n=Array.isArray(r);let i=t;if(n&&r.includes("number")){const e=parseInt(t,10);i=Number.isNaN(e)?t:e}else"number"===r&&(i=parseInt(t,10));const o=n?r:[r];if(!o.some((e=>typeof i===e)))throw new Error(`${e} must be of type ${o.join(" or ")}.`)}validateQueryString(e){this.validateRequiredParam("queryString",e),this.validateParamType("queryString",e,"string")}validateQueryType(e){this.validateRequiredParam("queryType",e);const t=Object.values(l);if(!t.includes(e))throw Error(`Invalid query Type: available query types: ${t}`)}validateGraphLocation(e){this.validateRequiredParam("graphLocation",e);const t=Object.keys(o);if(!t.includes(e)&&!this.validateUAL(e))throw Error(`Invalid graph location: available locations are valid Paranet UAL or: ${t}`)}validateGraphState(e){this.validateRequiredParam("graphState",e);const t=Object.keys(a);if(!t.includes(e))throw Error(`Invalid graph state: available states: ${t}`)}validateUAL(e){this.validateRequiredParam("UAL",e),this.validateParamType("UAL",e,"string");const t=e.split(":");if(3!==(3===t.length?t[2]:`${t[2]}:${t[3]}`).split("/")?.length)throw Error("Invalid UAL.");return!0}validateStateIndex(e){if(this.validateRequiredParam("stateIndex",e),this.validateParamType("stateIndex",e,"number"),e<0)throw Error("Invalid state index.")}validateObjectType(e){if(!e||"object"!=typeof e)throw Error("Content must be an object")}validateContent(e){this.validateRequiredParam("content",e);const t=Object.keys(e);if(!(1===t.length&&(t.includes("public")||t.includes("private"))||2===t.length&&(t.includes("public")||t.includes("private"))))throw Error('content keys can only be "public", "private" or both.');if(!e.public&&!e.private)throw Error("Public or private content must be defined")}validateAssertionSizeInBytes(e){if(e>s)throw Error(`File size limit is ${s/1048576}MB.`)}validateEndpoint(e){if(this.validateRequiredParam("endpoint",e),this.validateParamType("endpoint",e,"string"),!e.startsWith("http")&&!e.startsWith("ws"))throw Error('Endpoint should start with either "http" or "ws"')}validatePort(e){this.validateRequiredParam("port",e),this.validateParamType("port",e,"number")}validateMaxNumberOfRetries(e){this.validateRequiredParam("maxNumberOfRetries",e),this.validateParamType("maxNumberOfRetries",e,"number")}validateFrequency(e){this.validateRequiredParam("frequency",e),this.validateParamType("frequency",e,"number")}validateState(e){this.validateRequiredParam("state",e),this.validateParamType("state",e,["number","string"]);const t=Object.values(n);if("string"==typeof e&&!t.includes(e.toUpperCase())&&"number"!=typeof e&&!/^0x[a-fA-F0-9]{64}$/.test(e))throw Error(`Invalid state, available states: ${t},numerical or hash.`)}validateContentType(e){this.validateRequiredParam("contentType",e);const t=Object.values(i);if(!t.includes(e))throw Error(`Invalid content visibility! Available parameters: ${t}`)}validateEpochsNum(e){this.validateRequiredParam("epochsNum",e),this.validateParamType("epochsNum",e,"number")}validateHashFunctionId(e){this.validateRequiredParam("hashFunctionId",e),this.validateParamType("hashFunctionId",e,"number")}validateScoreFunctionId(e){this.validateRequiredParam("scoreFunctionId",e),this.validateParamType("scoreFunctionId",e,"number")}validateImmutable(e){this.validateRequiredParam("immutable",e),this.validateParamType("immutable",e,"boolean")}validateTokenAmount(e){null!=e&&this.validateParamType("tokenAmount",e,"number")}validateGasPrice(e){null!=e&&this.validateParamType("gasPrice",e,"number")}validateTransactionPollingTimeout(e){null!=e&&this.validateParamType("tokenAmount",e,"number")}validateAuthToken(e){null!=e&&this.validateParamType("authToken",e,"string")}validateParanetUAL(e){null!=e&&this.validateUAL(e)}validateValidate(e){this.validateRequiredParam("validate",e),this.validateParamType("validate",e,"boolean")}validateOutputFormat(e){this.validateRequiredParam("outputFormat",e);const t=Object.values(c);if(!t.includes(e))throw Error(`Invalid query Type: available query types: ${t}`)}validateBlockchain(e,t){this.validateRequiredParam("blockchain",e),this.validateRequiredParam("blockchain name",e.name),this.validateRequiredParam("blockchain hub contract",e.hubContract),this.validateGasPrice(e.gasPrice),this.validateTransactionPollingTimeout(e.transactionPollingTimeout),h()&&(this.validateRequiredParam("blockchain rpc",e.rpc),t!==u.GET&&(this.validateRequiredParam("blockchain public key",e.publicKey),this.validateRequiredParam("blockchain private key",e.privateKey)))}validateNewOwner(e){this.validateRequiredParam("newOwner",e),this.validateParamType("newOwner",e,"string")}validateGetBidSuggestion(e){this.validateBidSuggestionRange(e)}validateBidSuggestionRange(e){if(!f.includes(e))throw Error(`Invalid bidSuggestionRange parametar: supported parametars ${f}`)}validateParanetName(e){this.validateRequiredParam("paranetName",e),this.validateParamType("paranetName",e,"string")}validateParanetDescription(e){this.validateRequiredParam("paranetDescription",e),this.validateParamType("paranetDescription",e,"string")}validateTracToNeuroEmissionMultiplier(e){this.validateRequiredParam("tracToNeuroEmissionMultiplier",e),this.validateParamType("tracToNeuroEmissionMultiplier",e,"number")}validateIncentivizationProposalVotersRewardPercentage(e){if(this.validateRequiredParam("incentivizationProposalVotersRewardPercentage",e),this.validateParamType("incentivizationProposalVotersRewardPercentage",e,"number"),e>1e4||e<0)throw Error("Invalid percentage value for incentivization proposal voters reward.")}validateOperatorRewardPercentage(e){if(this.validateRequiredParam("operatorRewardPercentage",e),this.validateParamType("operatorRewardPercentage",e,"number"),e>1e4||e<0)throw Error("Invalid percentage value for operator reward.")}validateParanetServiceName(e){this.validateRequiredParam("paranetServiceName",e),this.validateParamType("paranetServiceName",e,"string")}validateParanetServiceDescription(e){this.validateRequiredParam("paranetServiceDescription",e),this.validateParamType("paranetServiceDescription",e,"string")}validateParanetServiceAddresses(e){if(0!==e.length)for(const t of e)this.validateAddress(t)}validateAddress(e){this.validateRequiredParam("address",e),this.validateParamType("address",e,"string")}}},54209:e=>{e.exports={afterHook:()=>{}}},69159:()=>{},80950:()=>{},46601:()=>{},89214:()=>{},8623:()=>{},7748:()=>{},85568:()=>{},47444:()=>{},47911:()=>{},59477:()=>{},32859:()=>{},3996:()=>{},56619:()=>{},28325:()=>{},84574:()=>{},24654:()=>{},77108:()=>{},97670:()=>{},52361:()=>{},94616:()=>{},40030:(e,t)=>{"use strict";function r(e){return function(e){let t=0;return()=>e[t++]}(function(e){let t=0;function r(){return e[t++]<<8|e[t++]}let n=r(),i=1,o=[0,1];for(let e=1;e>--u&1}const f=2**31,h=f>>>1,d=f-1;let p=0;for(let e=0;e<31;e++)p=p<<1|l();let m=[],y=0,g=f;for(;;){let e=Math.floor(((p-y+1)*i-1)/g),t=0,r=n;for(;r-t>1;){let n=t+r>>>1;e>>1|l(),a=a<<1^h,s=(s^h)<<1|h|1;y=a,g=1+s-a}let b=n-4;return m.map((t=>{switch(t-b){case 3:return b+65792+(e[s++]<<16|e[s++]<<8|e[s++]);case 2:return b+256+(e[s++]<<8|e[s++]);case 1:return b+e[s++];default:return t-1}}))}(function(e){let t=[];[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"].forEach(((e,r)=>t[e.charCodeAt(0)]=r));let r=e.length,n=new Uint8Array(6*r>>3);for(let i=0,o=0,a=0,s=0;i=8&&(n[o++]=s>>(a-=8));return n}(e)))}function n(e){return 1&e?~e>>1:e>>1}function i(e,t){let r=Array(e);for(let i=0,o=0;i{let t=o(e);if(t.length)return t}))}function s(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(l(r,e))}for(;;){let r=e()-1;if(r<0)break;t.push(f(r,e))}return t.flat()}function u(e){let t=[];for(;;){let r=e(t.length);if(!r)break;t.push(r)}return t}function c(e,t,r){let n=Array(e).fill().map((()=>[]));for(let o=0;on[t].push(e)));return n}function l(e,t){let r=1+t(),n=t(),i=u(t);return c(i.length,1+e,t).flatMap(((e,t)=>{let[o,...a]=e;return Array(i[t]).fill().map(((e,t)=>{let i=t*n;return[o+t*r,a.map((e=>e+i))]}))}))}function f(e,t){return c(1+t(),1+e,t).map((e=>[e[0],e.slice(1)]))}Object.defineProperty(t,"__esModule",{value:!0});var h=r("AEIRrQh1DccBuQJ+APkBMQDiASoAnADQAHQAngBmANQAaACKAEQAgwBJAHcAOQA9ACoANQAmAGMAHgAvACgAJQAWACwAGQAjAB8ALwAVACgAEQAdAAkAHAARABgAFwA7ACcALAAtADcAEwApABAAHQAfABAAGAAeABsAFwAUBLoF3QEXE7k3ygXaALgArkYBbgCsCAPMAK6GNjY2NjFiAQ0ODBDyAAQHRgbrOAVeBV8APTI5B/a9GAUNz8gAFQPPBeelYALMCjYCjqgCht8/lW+QAsXSAoP5ASbmEADytAFIAjSUCkaWAOoA6QocAB7bwM8TEkSkBCJ+AQQCQBjED/IQBjDwDASIbgwDxAeuBzQAsgBwmO+snIYAYgaaAioG8AAiAEIMmhcCqgLKQiDWCMIwA7gCFAIA9zRyqgCohB8AHgQsAt4dASQAwBnUBQEQIFM+CZ4JjyUiIVbATOqDSQAaABMAHAAVclsAKAAVAE71HN89+gI5X8qc5jUKFyRfVAJfPfMAGgATABwAFXIgY0CeAMPyACIAQAzMFsKqAgHavwViBekC0KYCxLcCClMjpGwUehp0TPwAwhRuAugAEjQ0kBfQmAKBggETIgDEFG4C6AASNAFPUCyYTBEDLgIFMBDecB60Ad5KAHgyEn4COBYoAy4uwD5yAEDoAfwsAM4OqLwBImqIALgMAAwCAIraUAUi3HIeAKgu2AGoBgYGBgYrNAOiAG4BCiA+9Dd7BB8eALEBzgIoAgDmMhJ6OvpQtzOoLjVPBQAGAS4FYAVftr8FcDtkQhlBWEiee5pmZqH/EhoDzA4s+H4qBKpSAlpaAnwisi4BlqqsPGIDTB4EimgQANgCBrJGNioCBzACQGQAcgFoJngAiiQgAJwBUL4ALnAeAbbMAz40KEoEWgF2YAZsAmwA+FAeAzAIDABQSACyAABkAHoAMrwGDvr2IJSGBgAQKAAwALoiTgHYAeIOEjiXf4HvABEAGAA7AEQAPzp3gNrHEGYQYwgFTRBMc0EVEgKzD60L7BEcDNgq0tPfADSwB/IDWgfyA1oDWgfyB/IDWgfyA1oDWgNaA1ocEfAh2scQZg9PBHQFlQWSBN0IiiZQEYgHLwjZVBR0JRxOA0wBAyMsSSM7mjMSJUlME00KCAM2SWyufT8DTjGyVPyQqQPSMlY5cwgFHngSpwAxD3ojNbxOhXpOcacKUk+1tYZJaU5uAsU6rz//CigJmm/Cd1UGRBAeJ6gQ+gw2AbgBPg3wS9sE9AY+BMwfgBkcD9CVnwioLeAM8CbmLqSAXSP4KoYF8Ev3POALUFFrD1wLaAnmOmaBUQMkARAijgrgDTwIcBD2CsxuDegRSAc8A9hJnQCoBwQLFB04FbgmE2KvCww5egb+GvkLkiayEyx6/wXWGiQGUAEsGwIA0i7qhbNaNFwfT2IGBgsoI8oUq1AjDShAunhLGh4HGCWsApRDc0qKUTkeliH5PEANaS4WUX8H+DwIGVILhDyhRq5FERHVPpA9SyJMTC8EOIIsMieOCdIPiAy8fHUBXAkkCbQMdBM0ERo3yAg8BxwwlycnGAgkRphgnQT6ogP2E9QDDgVCCUQHFgO4HDATMRUsBRCBJ9oC9jbYLrYCklaDARoFzg8oH+IQU0fjDuwIngJoA4Yl7gAwFSQAGiKeCEZmAGKP21MILs4IympvI3cDahTqZBF2B5QOWgeqHDYVwhzkcMteDoYLKKayCV4BeAmcAWIE5ggMNV6MoyBEZ1aLWxieIGRBQl3/AjQMaBWiRMCHewKOD24SHgE4AXYHPA0EAnoR8BFuEJgI7oYHNbgz+zooBFIhhiAUCioDUmzRCyom/Az7bAGmEmUDDzRAd/FnrmC5JxgABxwyyEFjIfQLlU/QDJ8axBhFVDEZ5wfCA/Ya9iftQVoGAgOmBhY6UDPxBMALbAiOCUIATA6mGgfaGG0KdIzTATSOAbqcA1qUhgJykgY6Bw4Aag6KBXzoACACqgimAAgA0gNaADwCsAegABwAiEQBQAMqMgEk6AKSA5YINM4BmDIB9iwEHsYMGAD6Om5NAsO0AoBtZqUF4FsCkQJMOAFQKAQIUUpUA7J05ADeAE4GFuJKARiuTc4d5kYB4nIuAMoA/gAIOAcIRAHQAfZwALoBYgs0CaW2uAFQ7CwAhgAYbgHaAowA4AA4AIL0AVYAUAVc/AXWAlJMARQ0Gy5aZAG+AyIBNgEQAHwGzpCozAoiBHAH1gIQHhXkAu8xB7gEAyLiE9BCyAK94VgAMhkKOwqqCqlgXmM2CTR1PVMAER+rPso/UQVUO1Y7WztWO1s7VjtbO1Y7WztWO1sDmsLlwuUKb19IYe4MqQ3XRMs6TBPeYFRgNRPLLboUxBXRJVkZQBq/Jwgl51UMDwct1mYzCC80eBe/AEIpa4NEY4keMwpOHOpTlFT7LR4AtEulM7INrxsYREMFSnXwYi0WEQolAmSEAmJFXlCyAF43IwKh+gJomwJmDAKfhzgeDgJmPgJmKQRxBIIDfxYDfpU5CTl6GjmFOiYmAmwgAjI5OA0CbcoCbbHyjQI2akguAWoA4QDkAE0IB5sMkAEBDsUAELgCdzICdqVCAnlORgJ4vSBf3kWxRvYCfEICessCfQwCfPNIA0iAZicALhhJW0peGBpKzwLRBALQz0sqA4hSA4fpRMiRNQLypF0GAwOxS9FMMCgG0k1PTbICi0ICitvEHgogRmoIugKOOgKOX0OahAKO3AKOX3tRt1M4AA1S11SIApP+ApMPAOwAH1UhVbJV0wksHimYiTLkeGlFPjwCl6IC77VYJKsAXCgClpICln+fAKxZr1oMhFAAPgKWuAKWUVxHXNQCmc4CmWdczV0KHAKcnjnFOqACnBkCn54CnruNACASNC0SAp30Ap6VALhAYTdh8gKe1gKgcQGsAp6iIgKeUahjy2QqKC4CJ7ICJoECoP4CoE/aAqYyAqXRAqgCAIACp/Vof2i0AAZMah9q1AKs5gKssQKtagKtBQJXIAJV3wKx5NoDH1FsmgKywBACsusabONtZm1LYgMl0AK2Xz5CbpMDKUgCuGECuUoYArktenA5cOQCvRwDLbUDMhQCvotyBQMzdAK+HXMlc1ICw84CwwdzhXROOEh04wM8qgADPJ0DPcICxX8CxkoCxhOMAshsVALIRwLJUgLJMQJkoALd1Xh8ZHixeShL0wMYpmcFAmH3GfaVJ3sOXpVevhQCz24Cz28yTlbV9haiAMmwAs92ASztA04Vfk4IAtwqAtuNAtJSA1JfA1NiAQQDVY+AjEIDzhnwY0h4AoLRg5AC2soC2eGEE4RMpz8DhqgAMgNkEYZ0XPwAWALfaALeu3Z6AuIy7RcB8zMqAfSeAfLVigLr9gLpc3wCAur8AurnAPxKAbwC7owC65+WrZcGAu5CA4XjmHxw43GkAvMGAGwDjhmZlgL3FgORcQOSigL3mwL53AL4aZofmq6+OpshA52GAv79AR4APJ8fAJ+2AwWQA6ZtA6bcANTIAwZtoYuiCAwDDEwBIAEiB3AGZLxqCAC+BG7CFI4ethAAGng8ACYDNrIDxAwQA4yCAWYqJACM8gAkAOamCqKUCLoGIqbIBQCuBRjCBfAkREUEFn8Fbz5FRzJCKEK7X3gYX8MAlswFOQCQUyCbwDstYDkYutYONhjNGJDJ/QVeBV8FXgVfBWoFXwVeBV8FXgVfBV4FXwVeBV9NHAjejG4JCQkKa17wMgTQA7gGNsLCAMIErsIA7kcwFrkFTT5wPndCRkK9X3w+X+8AWBgzsgCNBcxyzAOm7kaBRC0qCzIdLj08fnTfccH4GckscAFy13U3HgVmBXHJyMm/CNZQYgcHBwqDXoSSxQA6P4gAChbYBuy0KgwAjMoSAwgUAOVsJEQrJlFCuELDSD8qXy5gPS4/KgnIRAUKSz9KPn8+iD53PngCkELDUElCX9JVVnFUETNyWzYCcQASdSZf5zpBIgluogppKjJDJC1CskLDMswIzANf0BUmNRAPEAMGAQYpfqTfcUE0UR7JssmzCWzI0tMKZ0FmD+wQqhgAk5QkTEIsG7BtQM4/Cjo/Sj53QkYcDhEkU05zYjM0Wui8GQqE9CQyQkYcZA9REBU6W0pJPgs7SpwzCogiNEJGG/wPWikqHzc4BwyPaPBlCnhk0GASYDQqdQZKYCBACSIlYLoNCXIXbFVgVBgIBQZk7mAcYJxghGC6YFJgmG8WHga8FdxcsLxhC0MdsgHCMtTICSYcByMKJQGAAnMBNjecWYcCAZEKv04hAOsqdJUR0RQErU3xAaICjqNWBUdmAP4ARBEHOx1egRKsEysmwbZOAFYTOwMAHBO+NVsC2RJLbBEiAN9VBnwEESVhADgAvQKhLgsWdrIgAWIBjQoDA+D0FgaxBlEGwAAky1ywYRC7aBOQCy1GDsIBwgEpCU4DYQUvLy8nJSYoMxktDSgTlABbAnVel1CcCHUmBA94TgHadRbVWCcgsLdN8QcYBVNmAP4ARBEHgQYNK3MRjhKsPzc0zrZdFBIAZsMSAGpKblAoIiLGADgAvQKhLi1CFdUClxiCAVDCWM90eY7epaIO/KAVRBvzEuASDQ8iAwHOCUEQmgwXMhM9EgBCALrVAQkAqwDoAJuRNgAbAGIbzTVzfTEUyAIXCUIrStroIyUSG4QCggTIEbHxcwA+QDQOrT8u1agjB8IQABBBLtUYIAB9suEjD8IhThzUqHclAUQqZiMC8qAPBFPz6x9sDMMNAQhDCkUABccLRAJSDcIIww1DLtWoMQrDCUMPkhroBCIOwgyYCCILwhZCAKcQwgsFGKd74wA7cgtCDEMAAq0JwwUi1/UMBQ110QaCAAfCEmIYEsMBCADxCAAAexViDRbSG/x2F8IYQgAuwgLyqMIAHsICXCcxhgABwgAC6hVDFcIr8qPCz6hCCgKlJ1IAAmIA5+QZwqViFb/LAPsaggioBRH/dwDfwqfCGOIBGsKjknl5BwKpoooAEsINGxIAA5oAbcINAAvCp0IIGkICwQionNEPAgfHqUIFAOGCL71txQNPAAPyABXCAAcCAAnCAGmSABrCAA7CCRjCjnAWAgABYgAOcgAuUiUABsIAF8IIKAANUQC6wi0AA8IADqIq8gCyYQAcIgAbwgAB8gqoAAXNCxwV4gAHogBCwgEJAGnCAAuCAB3CAAjCCagABdEAbqYZ3ACYCCgABdEAAUIAB+IAHaIIKAAGoQAJggAbMgBtIgDmwocACGIACEIAFMIDAGkCCSgABtEA45IACUILqA7L+2YAB0IAbqNATwBOAArCCwADQgAJtAM+AAciABmCAAISpwIACiIACkIACgKn8gbCAAkiAAMSABBCBwAUQgARcgAPkgAN8gANwgAZEg0WIgAVQgBuoha6AcIAwQATQgBpMhEA4VIAAkIABFkAF4IFIgAG1wAYwgQlAYIvWQBATAC2DwcUDHkALzF3AasMCGUCcyoTBgQQDnZSc2YxkCYFhxsFaTQ9A6gKuwYI3wAdAwIKdQF9eU5ZGygDVgIcRQEzBgp6TcSCWYFHADAAOAgAAgAAAFoR4gCClzMBMgB97BQYOU0IUQBeDAAIVwEOkdMAf0IEJ6wAYQDdHACcbz4mkgDUcrgA1tsBHQ/JfHoiH10kENgBj5eyKVpaVE8ZQ8mQAAAAhiM+RzAy5xieVgB5ATAsNylJIBYDN1wE/sz1AFJs4wBxAngCRhGBOs54NTXcAgEMFxkmCxsOsrMAAAMCBAICABnRAgAqAQAFBQUFBQUEBAQEBAQDBAUGBwgDBAQEBAMBASEAigCNAJI8AOcAuADZAKFDAL8ArwCqAKUA6wCjANcAoADkAQUBAADEAH4AXwDPANEBAADbAO8AjQCmAS4A5wDcANkKAAgOMTrZ2dnZu8Xh0tXTSDccAU8BWTRMAVcBZgFlAVgBSVBISm0SAVAaDA8KOT0SDQAmEyosLjE9Pz9CQkJDRBNFBSNWVlZWWFhXWC5ZWlxbWyJiZmZlZ2Ypa211dHd3d3d3d3l5eXl5eXl5eXl5e3t8e3phAEPxAEgAmQB3ADEAZfcAjQBWAFYANgJz7gCKAAT39wBjAJLxAJ4ATgBhAGP+/q8AhACEAGgAVQCwACMAtQCCAj0CQAD7AOYA/QD9AOcA/gDoAOgA5wDlAC4CeAFQAT8BPQFTAT0BPQE9ATgBNwE3ATcBGwFXFgAwDwcAAFIeER0KHB0VAI0AlQClAFAAaR8CMAB1AG4AlgMSAyQxAx5IRU4wAJACTgDGAlYCoQC/ApMCkwKTApMCkwKTAogCkwKTApMCkwKTApMCkgKSApUCnQKUApMCkwKRApECkQKQAnIB0QKUApoCkwKTApIbfhACAPsKA5oCXgI3HAFRFToC3RYPMBgBSzwYUpYBeKlBAWZeAQIDPEwBAwCWMB4flnEAMGcAcAA1AJADm8yS8LWLYQzBMhXJARgIpNx7MQsEKmEBuQDkhYeGhYeFiImJhYqNi4WMj42HjomPiZCFkYWShZORlIWVhZaJl4WYhZmFmoWbipyPnYmehQCJK6cAigRCBD8EQQREBEIESARFBEAERgRIBEcEQwRFBEgAqgOOANBYANYCEwD9YQD9ASAA/QD7APsA/AD72wOLKmzFAP0A+wD7APwA+yMAkGEA/QCQASAA/QCQAvMA/QCQ2wOLKmzFIwD+YQEgAP0A/QD7APsA/AD7AP4A+wD7APwA+9sDiypsxSMAkGEBIAD9AJAA/QCQAvMA/QCQ2wOLKmzFIwJKAT0CUQFAAlLIA6UC8wOl2wOLKmzFIwCQYQEgA6UAkAOlAJAC8wOlAJDbA4sqbMUjBDcAkAQ4AJANlDh0JwEzAJAHRXUKKgEEAM1hCQBbYQAFGjkJAJAJRN8AUAkAkAkAnW0/6mOd3brkH5dB9mNQ/eNThoJ1CP8EZzy46pMulzRpOAZDJDXL2yXaVtAh1MxM82zfnsL/FXSaOaxJlgv345IW0Dfon3fzkx0WByY6wfCroENsWq/bORcfBvtlWbGzP5ju+gqE1DjyFssbkkSeqLAdrCkLOfItA7XNe1PctDPFKoNd/aZ6IQq6JTB6IrDBZ5/nJIbTHMeaaIWRoDvc42ORs9KtvcQWZd+Nv1D2C/hrzaOrFUjpItLWRI4x3GmzQqZbVH5LoCEJpk3hzt1pmM7bPitwOPG8gTKLVFszSrDZyLmfq8LkwkSUhIQlN4nFJUEhU2N7NBTOGk4Y2q9A2M7ps8jcevOKfycp9u3DyCe9hCt7i5HV8U5pm5LnVnKnyzbIyAN/LU4aqT3JK+e9JsdusAsUCgAuCnc4IwbgPBg4EPGOv5gR8D+96c8fLb09f7L6ON2k+Zxe/Y0AYoZIZ8yuu1At7f70iuSFoFmyPpwDU/4lQ+mHkFmq/CwtE7A979KNdD8zaHSx4HoxWsM8vl+2brNxN0QtIUvOfNGAYyv1R5DaM1JAR0C+Ugp6/cNq4pUDyDPKJjFeP4/L1TBoOJak3PVlmDCi/1oF8k1mnzTCz15BdAvmFjQrjide74m2NW1NG/qRrzhbNwwejlhnPfRn4mIfYmXzj5Fbu3C2TUpnYg+djp65dxZJ8XhwUqJ8JYrrR4WtrHKdKjz0i77K+QitukOAZSfFIwvBr1GKYpSukYTqF4gNtgaNDqh78ZDH4Qerglo3VpTLT0wOglaX6bDNhfs04jHVcMfCHwIb+y5bAaBvh2RARFYEjxjr1xTfU09JEjdY1vfcPrPVmnBBSDPj9TcZ1V/Dz8fvy0WLWZM0JPbRL0hLSPeVoC8hgQIGaeE6AYVZnnqm62/wt00pDl5Nw/nDo+bF1tC4qo5DryXVn8ffL3kuT51e+VcBTGiibvP+vqX50dppfxyNORSr48S5WXV8fzcsgjRQH6zjl+nuUYFVloiEnZOPDpHD/7ILh3JuFCdvAi2ANXYXjTDA5Up6YLihbc7d+dBlI9+mdgr8m8+3/Dp26W/Jssn7b9/pOEP4i+/9TsPI9m2NfNKwEI35mqKV+HpZ+W69Y8sM/sIA9Ltvhd+evQTUUfSkYxki28/CBT0cT96HrlrSrE+V9RzhskX0CsDsCfHffBVybkxmHOFOgaUurWNQ2AcZbi1WjkZzYArWZBHFd1SYwtqQ0DIZt7OV40ewQxCr/LgxAc8dLJeAJFseWJq9XiOp21hLv/HhsFbYbg3zCR8JmonZjhuKYrS/KJc30vnOL2CM+GfogNWug2DstZPzauCNeeD8zlP8wxPyfLHYQB/J+wQE3aDpXH/5tdIQpLn3JXNJYZFiXInGB7FqxRxHYJ/re/lHprE5sngUMm11uOIA3bbtkk06I8DYxuwPD+e4sAeNfor0DkWmiCQFiNptkmiD2xGO1kIKGr/Tuu4bHe6z2NaS7Ih0c+Gpv+QbLY9ea122BXNSitM41sxUSlnWl+uJBIFoLqt66v/VfGIQos2lzhOOLDuScVxcyrqH3/FI4vaYB0b8gFHLXtxyX/9JpUCYNwlLZ1v5CeB99l0F795R5wl5UHRq1OYyKqsoIY07wJz2CT0TOf5/JRBPtJIIk5pOJ60SHayS9kMSKbI3fLLYztsY3B4MlSyoEfc9gL4yJVrPo+OGGunCK4p15UbCArJP/PQgUWDW4l+2P/tCqRRy2flIZL/nVeY/vyAfILUM5qEGfcFXXXrAit7skwDEFnD7mL1ATtyrz7HcodhzP7gShFhazIPm7X0+mTCeSWfrOr5WcvJfip19JRRLfXjuQpQjcNCuXo8kqkxQ68ukJQoxlnfjevc0WcKnGpUvyY54eJTS1IRWDqfHANukJLw56ts5yS6Nea7IrL6/78aKmZsch4Q694ujxgx5+0PhlGpzWimajpvkBOOUQlHLkJorzqu4e768L9nJtZWYturb7dsBxjzlNhd/gZcBuRgIUSdgZjg7Rx+f/zLcs4mAa3qDbJNUQVNbSg+dm0L3KH1uhesTPaErVYjZ8Isvfr+zfiX3DT0PlaOv+hdGvLUIlKSEcYHPMs0NtTGzyqMe74yciNFdAVZVzol/XtLsEqivKqfW7zWTCNCvZkPnnBlMv3UHW5RNNEJfuyR3MvYH/9E6gcts5GAwKIgCaBQ+V2Eh9O0IJkxFksPI1V9obqDKCpmPM55mLd+VQgRqgD+9XvsUxjbh/AXXPxOpc0FXFyJzc85aa1VQZa90LAWR4oinrBaOBr8DymCpFbdXMTn7Cv18S0hMR7T/o5VkRqN1g1/dvaDdZsRArO3bopkfee4efLF+hyVdcX4u3aNGTkWvLRafW+sXPktA1lla4UkSB7uJIULfxy/RAflk2miyw9xq9uVGgCNzqCv4iX+AUchfMkZdEgRZ9TZ+1CPTH2jXjMXjFl/+bEPzSjM7zPKKWhyZUgQG1lpp+DNz+Zz+85kD59q99U5R4B3vuI9WenCWqroy2U2Ruq6I+di5N/v9SmYnqJ5H1HLWCbIg6iVrn3s2gFBVFhrc1zzNqoFe275K3Jy1T0Mc5yeE1iRwO2b1L/j/S8jyvGDz6B3NMFEHErGHMM2+oJ5LobazyWEitdgMjQnsd0cjYrCqRpx8idpfwRq6hz/LleX6obpuJh/AGIu4sxD35hwkIEr5ShH8xro7tTDYK1GPHGylK6rp7NCG0lMr7YqwziMUBwXv0zPW667f3/IRLJRD7mkuwUP6mpkxyVjNlcBiAX12r//+WTuzWxsue7bsjRp7xFjpR2tRLqGHLvjYt3TpeybR82K61iLn+pOSWDfUv/HU8ecBtML+Gbz0v9vmlxSgZeBBzbGeP1KSqsH14ZM2kibgDhbS21hIALSOYFCE9LY+2CNvtzT2QuSJMiKP3zwvvs+/JkDwTg0jHVE0XH//U0nu5HKQtCL2KGDQYUgT7qIMVN/OoWqEz1oeG4wG7InZg47NE7rfHB2i7rkpYCUzaPfVtDYgTEPNpa8gXHI2Pp8A6YB8OYHkXDZMMcOL3rJD0Hxk+mRlsSJ12/7T52IcFst5zRc7uDJtQTXBdm9GvsvyXcBbMfKXWqsDSeEnFyPUXZGTafti4a0it8SN1qXxzBmzj+gVZ/FojNy+x73AuuqtJ/oaMZF6m5kbW6ItpfnUT/BrQunS+gLjTTUz0d8jTMpAfFQ40RQi9uM5qdFYzqk85hqSH1zsPOhiO5CN+hNZvL/RIs7m7LyLDuV80ZtyHHqVEngTVPBctHQhmcPjM30m1veDmHCXEpjybWAbgj3TqLUPNazzdHgxYmNuT7trWFcGOi7iTeL5YeK2yp2H98yoLN+skqhffZI/5n/ivceo44wJRY8bzC6DGwdgkMOulYhzW5m6OKyK2Mg+E3YE19L8ngE08TdAuNu0mIzd6kw0i03zzm4oqfVSZjZyxXnBhvt0v89EmnArya/UvHQrdQxBDAJagK2y+OqgBqzQ4FnUeiKfb7HFoUvFSknWhwq58TpBlVRZ0B0A7QWz7X4GLHcbdh5kFI/PKJ91OEh/kmnMEdh+Z23myFH8sXjR/KaHttrpz80N+bl0HM17RX48UjUWslrYHYW7oiHVgcGqTBoTrqK4JYwTTArFO1/APJ8DnEYf+wD92Dw15a9wrPxyJA88yYcv9RypzXLKAWmMuE0KAtIGjfKx1GbRQIq0AkttuRpBO7p4SGrTZuAOat3hTxXEcIKh3HgC1d88K7bz1+Jsi+y7tL/7zc0ZxCBB3hSxvP90GkUp1Lm2wuESafZyFy4Opir+o3gMWtDSuLF3LRHXTUGkKQtvARnwam8BuKv8Q2fHH/cEwPCQd3dhzgri8eTezRsQoGz6ha+S4E7ZzDB/LXwl04vA70NeVsf5rmv1TLvcQSNIBk3U6Qh6Bm+0905B91hopTLnTJRWZkUmbckEw0woG81azyw6LZaBL5Qx2HPvd3LHGLpN6mPZlto50NwW2zFOkgoPKV1gr142teD9aok2HNkPMepl3NIi78ShnAlJCzjZplteUoqz0+iUEOym1LZGGFHMBkc6/5f+sRCCFZZW6KrEby64o/ZfefQAPP6b5ko2fuujIv7uonIKXN6XiJsZmcOeGxteQ+b/ope3Z1HFeXYoW1AJrU/OiCpsyQP1Pr1BdQKFzS0oYnLCAweSnIh7qMFMRBMY7BcnJ5oskUbbRNiosqMzCYUAZPbo8tjCCsCBm5SoGcTHBMXcE+yQpl/OfBkcTw3oa4X7V+ohEh/Zkcv0cqc8sY40IsOW6lLiIrvYND/exZbRlOMgaHvb/QQKaY0k6Aamee2o3LVARCbIP4RoSd7u3CXkG+Iz6iFLfsN38F9xU4n3ueeVgiRs3jw70SMWu1QzDdiLsKtU1qvaLhv7dUbnLimdqYG+pa2aRZ8A6Q9JSr3yTs1MiAvfFHPQJTiqpI/hVUMmL6gPj6eL7lH0IkLCNcaogBA0TGfO0wO6ddf8Fju0L3YbRrWe8J3IewsNBCbpC2b6etQRJnSGLuWDiFoBez9hJHw6+bMQQGQS8YV/kzQ5AFHEqPaMgOjyR5zaHtlOBI4mjo8gdNItHUHQ7Bzq/E/xV1B+L0uoRcLIEj4hcv0yWQTwWLHzoFrvEZPygABpc4rnVjhfcBw5wOvaVVtgiG5qjklrTY1ZaXHkasyVYBd+lgo6zEHMumfK8XR2eD0cVn5w8l1uxGz2ACwtFob/CTV/TUx1kCKp+QROanLrNBiSPTxAf1eOFE+JifgAJ+pyrFqS/0wKlPWUVKlB2Bhu1Ggx2cvfdiR49VIsgBNnE75pf5lpFaQuz8+VPreUd/HLlW8kDSr25AnETsVRrOycLBPYD9/j/7Z0KKdOjtrM71AT+VsjD3D97aUDP5WrHp1DWghsk/lS/hp2VMwo0eqoEerLL/4/SlmyjStwWVDqF6jHC89niCwr1tMSe8GxeC9wjzMKmE7ZtdHOWqqc1OoTI24eVQc++crbyxSU4TxiB+vWoaAUpYQxZ06KKIPq6EvN/rN4DZ0/tQWYVqZ3FTIftPBfIuOWX3PonIKTUArpSvfmQRpkWD00wc3AQS98i4ZYaUbI+DGv90tuEKRjb2ocfdddC21YGUATYQmzelz7JqWBAQqKrWYdWEJlfPeRFZHtUm2MaISZsoOvURowxJKveGRegmBiKZ3d1cMFioJL33RoIKT0eDeK8FH/ybAhZU5TQIsWYmjyeT7EOLL5xZuRPf4qRIo6bbLtFOV6SX60fR8Smys/u1D5DjkmHJyr/woVAvBP2dxGo9gH1LgIm8XlFF1KSYvfj+0w7aTEfoFpcO+Jv3Ssbv8wwkED5JEC+jdln2dzToPNRtWiPbRb8f8G4aZX1j/2Vdbu7jM3gAVD5BKR+yJaOwLtwJodwjWu5di47tnNs9ahpnCUzVMObQfbTqMNs64MGANlgyihKjhwZ6p1Jsnro0/SfkOk6wx+HgUB6Mz9cUiF7KrJkhxnOVjCCcqPZglIojIRoDtkd2AkLNZC88GdP2qZV/1N6PBAe+fpgWZ36oHnewQ8CHdXcxbwQVjOn8U3qD9+e7FzWpg135vgdEMZ9fH5agDnNzdjKFZQ4tDsJs/S6Lk8FqjFJpHMjaRU6FI/DBDM0g+RRkxNoUvm14JAn5dgd6aVHt1aMkSXiJVenbm2FfrIEaFKHtm1erv1BJ5056ULL8AMGLmHav4yxg6F6n5oBq7bdP6zEr6f+QTDJ/KE1XfoG24JvVk2GL7Fb+me27otVFnq1e/2wEuqv6X+2zLQuJQszy5YJi/M5888fMy34L6z8ykD5sCHgzliAoAtEeoaFmnPT63kOYrZWspxYzqQBu/QKNyQ8e4QwKJUCVazmIUp6/zpLA3bWH2ch7QZN0rzWGxMRl3K1osWeETxL95TZSG/atM8LB9B92/71+g9UGWDPfD+lu/KdOQ85rocuHe91/gHA/iprG9PZ2juX49kaRxZ+1/sB3Ck35eWYBFsmCl0wC4QZWX5c5QMuSAEz1CJj0JWArSReV4D/vrgLw+EyhBB6aA4+B34PdlDaTLpm9q9Pkl+bzVWrSO+7uVrIECzsvk8RcmfmNSJretRcoI7ZcIfAqwciU9nJ8O4u1EgkcMOzC/MM2l6OYZRrGcqXCitp4LPXruVPzeD402JGV9grZyz9wJolMLC/YCcWs9CjiWv+DNRLaoSgD5M8T4PzmG8cXYM4jPo5SG1wY3QK/4wzVPrc33wI+AcGI//yXgvyBjocGrl768DMaYCGglwIit4r6t6ulwhwHJ4KeV3VHjspXXG4DIlDR2HNFvPaqkBViIvr433qZPuUINp6oi1LyVVC+EE1j6+wab8uPMeAo6e9uWYequvZynhnYazrvrDQJVkK3KZRoSR5BHi6vOC+AVCujMiQ1GVzGDZ4RFv8jFm7z5CU0iPH2JeXqUzqaKKP4P7osPkcIL99Y7fP3l+TzeFXO2kSpLIJW51oEY8DRIhqexGnxj0nmtGOseStuViIE2mJge45LENf77xjuI7egRNpzthNiajnuqikg0aQS1JqlIZf+hwSUlOp8BEQ0y3xiTOJkohBP3eyYiPDlZpFY88EWOpp4+hC/tQdhrQ56h2VJ2XA6vhPAbj+wH6iA2XYuTvRV25N8wNPQuA0Vzzem2ADZPFK2vr8l0I3GTV3fUN4S6FFYygW2Pu98f+lsgPf67rwVCbgMFAACW3P10GbxnK3SNuNK+VlPRiL7U3dK1o3spH/MFfDkgXuXjxDTxJrYctqHdwUg4rhUCNA13lGjuhJDatpFb/mExsBWS46aLFtROqVm8xQNPXK6A2rRfazJSWpIyh+FMmorXPXYnHQ7YLOmD4B5QTI8rzp7OomiarnaFs5syYjQ0ucc7g1/JzT446IFlDtpUL7DP9bLRCLJryUvi5R71/qX7ycqRSwunQ7+tfJz44Na3aJNszaMEZ/BV4iOGopabYdmvAPe+kIdGCNq5Q8fg8Ld0VNNXV0ZiiGej7zSA+pexy6wKC5k4rZa0k+qaN8bKq3oJWMQCSGaK7PrwMvA8t8BZTzjDqXcFTAIeRtl0SdlGSuAziVXItFcgAkeqwuNsbsrUZFcU6KUZLmvG415kHa0AwMFW2cNSUvPR0U9iCPh0nyslT92B5slYXiDWeSXvxHXItvjI8z5KCIVTIHqGZsbDBTr7WdHzcUAI1ipR86H3o0p2wPhfp7xg9oWOxWIK4a5BWdaV9OAPc0XuvlbwitCVtZDzZxGhIOl77ZgrRYR7LZQFE+Ih23hW3gI914ekkjgbKCi2bsqSAvij6GGj5p+k6evQtJp3qVh9vg+jiJvFCGcKBCITMWpqHZNKfE6IT0dKntS0rhu0DB5D9qIS0/RboNLsx2DlRMlx1QIBeBpHJNKdCL9uWM9eS7RJXKNOpraULtutuJYOl0apdE4LxfsyRSZb6fJkd51SHrI7lLB4vEg4fifJ1dqcWSeY4DgcyjrUcymK+gd3o+qj+3gHKWlLVdMUr3IeF8aClYBq+eeCV9Y7n1Ye8yL7rEvxY7jAlLwucKQ51pu59N8we8XwrbXPChBHXP4LnD3kDwQ85w1DKghtwvpO609fZOrPq8Q7GOOAjHhfR5VqvpoFne8oMHbCrWb1L0IdATo+h1PFeLLI8wc+FEyftLvskCdOtxKfAx3IEJXzBfWTKq5viKP/uu99dxnEpoNJhRtjSZGwOTWr7Ys44++P58O+nkYxd1Gcqm8G3Gh7AHSCxiPNyJWijI/lECrKrAXgBqkRShvdkd7IfoqUlziFDiglx+jdHnmRVmGnk3p/3n78M/HkzFUGZOS07cPnPn9jAnBWl4qDrB1ECf9idIKOdkJTKcZ690nuLW2yDsqwNpgrlT+wx2gv+Engha74lfVqbwqS15FRwuFDfq3bVCZcPy78TL2pH/DOdHeL9MFAtyybQNwHaO781rnJZAhR4M+AYWoSoa0EjQ99xivreM+FKwd7Jp/FC2vvvcq1z3RnRau/BM5KGkBPBSUBOzTNdfaJS/PWTDb1jRSgn2MuY3pVZbY9peHBVI3Ce/u70hg4f7MCVeAjYJfzTkDVLuB6jyjZs5Kko3u39ozgLK4LuwSbUrNIU5cl6Bs3De62AE084XRsm64Gs5W1ofxsWIZ9cYl8PNa5zQHl9ls5aiIKN0rHIIzBnLr03Kle2qq+n/gLDAzvF89vdZCvUFEHRoi9n33O3i49UWyeHP+ZAeRf+psM867nfqON092zE4Pj7AbLtvIUFJFr1y9Le0CL2flc7LUqbgGzOw4/q3vA/cJO5JeI8S+8bc1Y7pqYSzoEWSFn5G7EoPHTGHPMU6SeLKEeli+i8dHY3lWxSrIOU2y0TNo1SeRYewhVx05OXeVDf0xhHNckqp0arRk+bgToeSaHbVZ5nj3IH3m2oayt3sXY78qSPcDpc/5C7VXDRj6bROvvBG5JCsKl/yeMPAUn1flMsmr/FaFdb7gVUXnhLa+/Ilj87PpCC6rILQ6wkIP1ywEg0PztSEzbsJoRwQzDaxkiTN27YDnsy/YKfe6jKcqZWs64skzUAHIt+nXxju0dUVtbCSDAUXYw78Yd4bJKuYU8gbzLzgL4XIUC2HcPIVCUYvM7cybOBFVBdeGR4cOVB7QbGnohTRpiPrGqi1a8QXFBYqENawROuR43OG8dl+Jx4TpwAoi2kkPXW7b/ARSs4DO/z4H6oTIUpN3+/K6Iuc49C4/Uf1NxQTEE91VP8RnLKTpxjywMe2VxM1l4YGXSFY80HUAKIdqczBnnLMPklFV8mrr5hFDypn5TAT00ruU6AjDPNvncoVzX4ac6wAzTwrNH7oz1XLH1wzjQs5k7hcNLbznXQGB7M+rXxKtZXPrz1Ar+OxYGDkJvElknZsHD/IcxRd7ujmmLYpDDbverynroCnSKVQWEGjHL57PaI/WokvhYRpPMk4ni2EUhjDuIF+IU2R0fs40i+66bw8sz8OzyC2eFAxxicd2n5Juta2eWa9KtObD7xLmPvtK+8cjQt+NLjcZCTt+Ss9p1od0bklVgaIV1qJbWxUOr6iUzLDzFefYxAtyRcBr53IaDB25n60KQdhroQWMUpuWSUpELSFxiu4vgQeRoEZe78/ua3TlrszB8sLVZoecnV9YMYz+HkZA/pLqbFhzurB52Wl/WEM6sVk4q04OnzWZFi76JkcGgeeUyYUIwhCDMdIfTUdD4wQpYm3LBw0sp33CVK2q305jeyzgGnBzSMXjesm4XjcEhhrjPSLtwqqoaFCqD5DlHYhoTVafWtBUQXoNfDk19IFxq8sImCcqgMhOToIZUO2530aasY908dMX2nTMFjgv+lapdI8k/e0a7pFw6X3Tgf0m99bbCpOzVgRu2Dw/13CehVfFj+8BeKP6SZV4g/qiX42NWP568PzMajFm2ANmKtHjEIAIc2hc1iecBR9elGP4LmAQwAVmZT8kWc7JSY0ag583ch/Z16krGrjn2YdIaa22egy4/niU6m0WAG3K/yP65cfL//CP+JzcnoLHQFb/KJQeBrEbR1/IKo+YOFXWIQ8ghNxYdMwa49NeXzFqFOIXTmk3w/v5KneS8sGHiPGACh0DE9a1uLAochB79g3IqYObhlswemMucZnAE7dBkp5OAfToa5gHFbIPcec0fVWEOOLftQXsuffyv3wo1LWDDm+SyNMWgSEWtjMyYkjLjTkUtmj7DQlfbpHf38lDvoEN9d2ALxnWCjph4jvfEIRbHvltKbvE2BiYlz45mnJPeFrwZcBny3k0/pyXNrSbEIWvvZw14Y0Fqy4tba1Fu0yNNYaf47jfnz7VCCxKsrJz5oz3F8jXUdQqFu+gDq6EzvKDipXf/3NmcsCC74VB3OgHPgN7W9cU54pjGFDMfifl3m5Vhy21uk1U2nYCrddrifkpwGLYmLSSQAAjC6M3yB1fc6KHpgDnMXh2bYX2ns+Qma+DBgyCkZ0TqZK8Mp2Sryx7HdMM74X9hrwYhQbwlK+zgATAXRzQyS+hK4OTnP17/cyJ2WzY6DChYWGJYXGCnEdMswF5VTYQdSyTpdLXYuh+x2Qr7DR3H2x+YdP0qsLAzYJIWKwrrKkpBgWCmgNCn5t+QbWqf/LoLuvjgDFLtMoxNK5axIA9kammelvwh5ZI52ktrEm/OVEESPQPZGHAIhP7oWDBnGnuzG45XOTpZWsxwNO4UiyxH8riTvQq4JVq5GwX3yqVCbSR0ef/gVYDgiYaiD2EAAxuEPKyXTp/HhL96eVTpaDqFEoV2x1PP/UMcs/XqeGc1gZQG1ot6YxaIEWHanYavH9YdLFjlyU5yrYALVg/sxBjT39oD+BIXvf4LTbvvvpX3srxckEX1XAM9s2uajUTlpPq32mcx4T+sibdQEHQV2WmgwMhbYovh7WWTPfLF03ZbV5a+ElsSIyH6kgJ8+D6aN/6f+ZstkZOYZYx9GbagcrEqwNblz0iZ9NTyvIAeNn3Oup7rtyD4wVE0PoqcnR/LoSK1s1esmOGPjs3zHB8xW4iL8IrhqAJfsWNBYW9TGR11C3KZJaN7MP4O5Ykmpvw94hHzVmsYA68RQdFYfPlFOgCNBoSdy5ODcv11l9bLs135M4okEc4/e8hQczcz2PWipIVSBxa/5sr9xyTFbjG4xm8f4LmrAhD1uEDGrFDl/6X7Nw7/WZPW7fZJGYN8eZ68Td5KGfJyKjD+pTysvTi+8Q8R0L9wKAxAUrYswdvAuiNeenxSplQZjYTxbcH/wP97fOY215SozY3UDRhv7lomztURB2O2UriTX3oAiTKoInkHQietZyhBQ9wMTVHgMrxOP5T/0gN14eFTz0m2D6/iJMbXYGHdIkKEGV2Voa8k/hVNvAVAZKrDEXthUxotwYkYysTDk8j27XEVy+4a30jopuAp5+/xWYb0ne6lwKZwR3j6kDXroOOtrHqWlkJHSWLoPEQJQo/ARzR8UBZSckmeBPn3gJwY62Zo2dyy1AyRRDQBFAJKH9KX+7auP8U8XDo7mMSzq5ZxmaJ5bLpNg4ZM7938SAjMHcu1yB4+lkHnVLnIp86AOPgigH+ZFDRq1QuKWK3pK5JkLDJdakj176NCbjXDASt1h/t1p+GHyKbAoevHSnHuPfoBmQ3nJrDjOhPfwVYi8V5r0KB8BsrfFu8BvhYCbNrvCVnd4Q8RktqIR/ZilioC6g3++L7PHzuXa8NFSF5zd+ISzGLTjrfaKXsBFCkkK0ksSDbl91yXUghMFOskQBeUoo7o3wuIsE29goRIORuJ4b1jSumvR0gR8B21iyW1G4FqHkZOlWz9zq5FnaJX1WbeAxe2DfGSAnw4cqDwg3LFalk6eH89Sdc41Fr6voEa0hfwdkb54yOM7WevDugT1FRzEqdg9zZZ44ZAKGH3ZyqFve3SE4UDN6tLmIFTdIwMrtYRXWBQDB7vvqOuYj7cN31av64+jg/g1uce+am3TOl0cUUL6s0l35FJ9p8vJcG+G8lAFqC0pdmd/aaWYpqDLvB5LEasLMgbPN2N+Wvkh6HYxPOrZEfoxQX/67AzcWOR0K3eYGOgQhyWL7cwKGlxmY/E2b8CKi6Ssgok+7B+zTtq/DXmaDAHRnwbwvCDJ9pITO5RQgBuprEWT0avZv7QjbzITYD8Fzgy4TSYG3z9tLso0Z7MfgHDLKU+kHrzxWkBPwJRydKMXG4AaCA7mlAmjzpNhGOrMGZGZlHSjPbmO5jPd/lKBrViZ0BaXMmqaFOwA/f03O04qQX6MSVA37+SA5Pne/KP7caLJKuOCJXoXpzArUrYesMVc/RXnOv03YrwKgPlR2SjpqIycyulmodZBy6gVc1jA9y6lJqWgR6SY6tc24sVcYuh2GaTeikYJnhr2d6BiL3oLx8M8wuJBdI3FRVIIAx4XougScOw2xWgwUoSYKeLUHc310kVBzSE/vFeHAjlUil8KZftctMgwGjwrhMbjDbK4rB32fTe9jnsqijdp5kOwkD9+klel+lNh3joAFQ");const d=new Map([[8217,"apostrophe"],[8260,"fraction slash"],[12539,"middle dot"]]);function p(e){return`{${function(e){return e.toString(16).toUpperCase().padStart(2,"0")}(e)}}`}function m(e){let t=[];for(let r=0,n=e.length;r>24&255}function w(e){return 16777215&e}const A=new Map(a(b).flatMap(((e,t)=>e.map((e=>[e,t+1<<24]))))),S=new Set(o(b)),k=new Map,E=new Map;for(let[e,t]of s(b)){if(!S.has(e)&&2==t.length){let[r,n]=t,i=E.get(r);i||(i=new Map,E.set(r,i)),i.set(n,e)}k.set(e,t.reverse())}const _=44032,M=4352,T=4449,x=4519,P=28,I=588;function O(e){return e>=_&&e<55204}function R(e,t){if(e>=M&&e<4371&&t>=T&&t<4470)return _+(e-M)*I+(t-T)*P;if(O(e)&&t>x&&t<4547&&(e-_)%P==0)return e+(t-x);{let r=E.get(e);return r&&(r=r.get(t),r)?r:-1}}function C(e){let t=[],r=[],n=!1;function i(e){let r=A.get(e);r&&(n=!0,e|=r),t.push(e)}for(let n of e)for(;;){if(n<128)t.push(n);else if(O(n)){let e=n-_,t=e%I/P|0,r=e%P;i(M+(e/I|0)),i(T+t),r>0&&i(x+r)}else{let e=k.get(n);e?r.push(...e):i(n)}if(!r.length)break;n=r.pop()}if(n&&t.length>1){let e=v(t[0]);for(let r=1;r0&&i>=e)0==e?(t.push(n,...r),r.length=0,n=a):r.push(a),i=e;else{let o=R(n,a);o>=0?n=o:0==i&&0==e?(t.push(n),n=a):(r.push(a),i=e)}}return n>=0&&t.push(n,...r),t}(C(e))}const L=65039,U=".";function F(){return new Set(o(h))}const D=new Map(s(h)),j=F(),H=F(),J=F(),z=F(),G=a(h);function q(){return new Set([o(h).map((e=>G[e])),o(h)].flat(2))}const K=h(),V=u((e=>{let t=u(h).map((e=>e+96));if(t.length){let r=e>=K;t[0]-=32,t=y(t),r&&(t=`Restricted[${t}]`);let n=q(),i=q(),o=[...n,...i].sort(((e,t)=>e-t));return{N:t,P:n,M:h()-1,R:r,V:new Set(o)}}})),X=F(),Q=new Map;[...X,...F()].sort(((e,t)=>e-t)).map(((e,t,r)=>{let n=h(),i=r[t]=n?r[t-n]:{V:[],M:new Map};i.V.push(e),X.has(e)||Q.set(e,i)}));for(let{V:e,M:t}of new Set(Q.values())){let r=[];for(let t of e){let e=V.filter((e=>e.V.has(t))),n=r.find((({G:t})=>e.some((e=>t.has(e)))));n||(n={G:new Set,V:[]},r.push(n)),n.V.push(t),e.forEach((e=>n.G.add(e)))}let n=r.flatMap((({G:e})=>[...e]));for(let{G:e,V:i}of r){let r=new Set(n.filter((t=>!e.has(t))));for(let e of i)t.set(e,r)}}let W=new Set,Z=new Set;for(let e of V)for(let t of e.V)(W.has(t)?Z:W).add(t);for(let e of W)Q.has(e)||Z.has(e)||Q.set(e,1);const Y=new Set([...W,...B(W)]),$=o(h),ee=function e(t){let r=u((()=>{let t=o(h).map((e=>$[e]));if(t.length)return e(t)})).sort(((e,t)=>t.Q.size-e.Q.size)),n=h(),i=n%3;n=n/3|0;let a=1&n;return n>>=1,{B:r,V:i,F:a,S:1&n,C:2&n,Q:new Set(t)}}([]);class te extends Array{get is_emoji(){return!0}}function re(e,t=p){let r=[];oe(e[0])&&r.push("◌");let n=0,i=e.length;for(let o=0;o0;)if(95!==e[--t])throw new Error("underscore allowed only at start")}function oe(e){return H.has(e)}function ae(e){return J.has(e)}function se(e,t){let r=0;return e.split(U).map((e=>{let n,i=m(e),o={input:i,offset:r};r+=i.length+1;try{let e,r=o.tokens=he(i,N),a=r.length;if(!a)throw new Error("empty label");{let i=r[0],s=a>1||i.is_emoji;if(!s&&i.every((e=>e<128)))n=i,ie(n),function(e){if(e.length>=4&&45==e[2]&&45==e[3])throw new Error("invalid label extension")}(n),e="ASCII";else if(s&&(o.emoji=!0,i=r.flatMap((e=>e.is_emoji?[]:e))),n=r.flatMap((e=>!t&&e.is_emoji?de(e):e)),ie(n),i.length){if(H.has(n[0]))throw fe("leading combining mark");for(let e=1;ee.V.has(r)));if(!e.length)throw t===V?ce(r):le(t[0],r);if(t=e,1==e.length)break}return t}(t);!function(e,t){let{V:r,M:n}=e;for(let n of t)if(!r.has(n))throw le(e,n);if(n>=0){for(let r=1,i=B(t).length;rn)throw new Error(`too many combining marks: ${e.N} "${y(t.slice(r-1,o))}" (${o-r}/${n})`);r=o}}}(o,i),function(e,t){let r,n=[];for(let e of t){let t=Q.get(e);if(1===t)return;if(t){let n=t.M.get(e);if(r=r?r.filter((e=>n.has(e))):[...n],!r.length)return}else n.push(e)}if(r)for(let t of r)if(n.every((e=>t.V.has(e))))throw new Error(`whole-script confusable: ${e.N}/${t.N}`)}(o,t),e=o.N}else e="Emoji"}o.type=e}catch(e){o.error=e}return o.output=n,o}))}function ue(e){return e.map((({input:t,error:r,output:n})=>{if(r){let n=r.message;throw new Error(1==e.length?n:`Invalid label "${re(t)}": ${n}`)}return y(n)})).join(U)}function ce(e){return new Error(`disallowed character: ${ne(e)}`)}function le(e,t){let r=ne(t),n=V.find((e=>e.P.has(t)));return n&&(r=`${n.N} ${r}`),new Error(`illegal mixture: ${e.N} + ${r}`)}function fe(e){return new Error(`illegal placement: ${e}`)}function he(e,t){let r=[],n=[];for(e=e.slice().reverse();e.length;){let i=pe(e);if(i)n.length&&(r.push(t(n)),n=[]),r.push(i);else{let t=e.pop();if(Y.has(t))n.push(t);else{let e=D.get(t);if(e)n.push(...e);else if(!j.has(t))throw ce(t)}}}return n.length&&r.push(t(n)),r}function de(e){return e.filter((e=>e!=L))}function pe(e,t){let r,n,i=ee,o=[],a=e.length;for(t&&(t.length=0);a;){let s=e[--a];if(i=i.B.find((e=>e.Q.has(s))),!i)break;if(i.S)n=s;else if(i.C&&s===n)break;o.push(s),i.F&&(o.push(L),a>0&&e[a-1]==L&&a--),i.V&&(r=me(o,i),t&&t.push(...e.slice(a).reverse()),e.length=a)}return r}function me(e,t){let r=te.from(e);return 2==t.V&&r.splice(1,1),r}const ye="valid",ge="mapped",be="ignored";function ve(e){return e==ye||e==ge}function we(e){return e.some((e=>z.has(e)))}function Ae(e){for(let t=0;te.cps))})}return e}t.ens_beautify=function(e){let t=se(e,!0);for(let{type:e,output:r,error:n}of t)if(!n&&"Greek"!==e){let e=0;for(;;){let t=r.indexOf(958,e);if(t<0)break;r[t]=926,e=t+1}}return ue(t)},t.ens_emoji=function(){let e=[];return function t(r,n,i){if(r.S)i=n[n.length-1];else if(r.C&&i===n[n.length-1])return;r.F&&n.push(L);r.V&&e.push(me(n,r));for(let e of r.B)for(let r of e.Q)t(e,[...n,r],i)}(ee,[]),e.sort(g)},t.ens_normalize=function(e){return ue(se(e))},t.ens_normalize_fragment=function(e,t){let r=t?B:N;return e.split(U).map((e=>y(he(m(e),r).flatMap((e=>e.is_emoji?de(e):e))))).join(U)},t.ens_split=se,t.ens_tokenize=function e(t,{nf:r=!0}={}){let n=m(t).reverse(),i=[],o=[];for(;n.length;){let e=pe(n,i);if(e)o.push({type:"emoji",emoji:e,input:i.slice(),cps:de(e)});else{let e=n.pop();if(46==e)o.push({type:"stop",cp:e});else if(Y.has(e))o.push({type:ye,cps:[e]});else if(j.has(e))o.push({type:be,cp:e});else{let t=D.get(e);t?o.push({type:ge,cp:e,cps:t.slice()}):o.push({type:"disallowed",cp:e})}}}if(r)for(let t=0,r=-1;tve(e.type)?e.cps:[])),s=N(a);g(s,a)?(o.splice(r,n-r,{type:"nfc",input:a,cps:s,tokens0:Ae(i),tokens:e(y(s),{nf:!1})}),t=r):t=n-1,r=-1}else r=t;else n.type!==be&&(r=-1)}return Ae(o)},t.is_combining_mark=oe,t.nfc=N,t.nfd=B,t.safe_str_from_cps=re,t.should_escape=ae},40517:function(e,t){"use strict";var r,n,i,o=this&&this.__classPrivateFieldSet||function(e,t,r,n,i){if("m"===n)throw new TypeError("Private method is not writable");if("a"===n&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===n?i.call(e,r):i?i.value=r:t.set(e,r),r},a=this&&this.__classPrivateFieldGet||function(e,t,r,n){if("a"===r&&!n)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?n:"a"===r?n.call(e):n?n.value:t.get(e)};Object.defineProperty(t,"__esModule",{value:!0}),t.AES=void 0;const s={16:10,24:12,32:14},u=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],c=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],l=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],f=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],h=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],d=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],p=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],m=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],y=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],g=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],b=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],v=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],w=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],A=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],S=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function k(e){const t=[];for(let r=0;r>2,a(this,i,"f")[d][e%4]=h[e],a(this,n,"f")[t-d][e%4]=h[e];let p,m=0,y=f;for(;y>16&255]<<24^c[p>>8&255]<<16^c[255&p]<<8^c[p>>24&255]^u[m]<<24,m+=1,8!=f)for(let e=1;e>8&255]<<8^c[p>>16&255]<<16^c[p>>24&255]<<24;for(let e=f/2+1;e>2,r=y%4,a(this,i,"f")[e][r]=h[o],a(this,n,"f")[t-e][r]=h[o++],y++}for(let e=1;e>24&255]^w[p>>16&255]^A[p>>8&255]^S[255&p]}get key(){return a(this,r,"f").slice()}encrypt(e){if(16!=e.length)throw new TypeError("invalid plaintext size (must be 16 bytes)");const t=a(this,i,"f").length-1,r=[0,0,0,0];let n=k(e);for(let e=0;e<4;e++)n[e]^=a(this,i,"f")[0][e];for(let e=1;e>24&255]^h[n[(t+1)%4]>>16&255]^d[n[(t+2)%4]>>8&255]^p[255&n[(t+3)%4]]^a(this,i,"f")[e][t];n=r.slice()}const o=new Uint8Array(16);let s=0;for(let e=0;e<4;e++)s=a(this,i,"f")[t][e],o[4*e]=255&(c[n[e]>>24&255]^s>>24),o[4*e+1]=255&(c[n[(e+1)%4]>>16&255]^s>>16),o[4*e+2]=255&(c[n[(e+2)%4]>>8&255]^s>>8),o[4*e+3]=255&(c[255&n[(e+3)%4]]^s);return o}decrypt(e){if(16!=e.length)throw new TypeError("invalid ciphertext size (must be 16 bytes)");const t=a(this,n,"f").length-1,r=[0,0,0,0];let i=k(e);for(let e=0;e<4;e++)i[e]^=a(this,n,"f")[0][e];for(let e=1;e>24&255]^y[i[(t+3)%4]>>16&255]^g[i[(t+2)%4]>>8&255]^b[255&i[(t+1)%4]]^a(this,n,"f")[e][t];i=r.slice()}const o=new Uint8Array(16);let s=0;for(let e=0;e<4;e++)s=a(this,n,"f")[t][e],o[4*e]=255&(l[i[e]>>24&255]^s>>24),o[4*e+1]=255&(l[i[(e+3)%4]>>16&255]^s>>16),o[4*e+2]=255&(l[i[(e+2)%4]>>8&255]^s>>8),o[4*e+3]=255&(l[255&i[(e+1)%4]]^s);return o}}t.AES=E,r=new WeakMap,n=new WeakMap,i=new WeakMap},93260:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pkcs7Strip=t.pkcs7Pad=t.OFB=t.ECB=t.CTR=t.CFB=t.CBC=t.ModeOfOperation=t.AES=void 0;var n=r(40517);Object.defineProperty(t,"AES",{enumerable:!0,get:function(){return n.AES}});var i=r(2868);Object.defineProperty(t,"ModeOfOperation",{enumerable:!0,get:function(){return i.ModeOfOperation}});var o=r(52805);Object.defineProperty(t,"CBC",{enumerable:!0,get:function(){return o.CBC}});var a=r(73169);Object.defineProperty(t,"CFB",{enumerable:!0,get:function(){return a.CFB}});var s=r(83310);Object.defineProperty(t,"CTR",{enumerable:!0,get:function(){return s.CTR}});var u=r(89915);Object.defineProperty(t,"ECB",{enumerable:!0,get:function(){return u.ECB}});var c=r(22023);Object.defineProperty(t,"OFB",{enumerable:!0,get:function(){return c.OFB}});var l=r(99533);Object.defineProperty(t,"pkcs7Pad",{enumerable:!0,get:function(){return l.pkcs7Pad}}),Object.defineProperty(t,"pkcs7Strip",{enumerable:!0,get:function(){return l.pkcs7Strip}})},52805:function(e,t,r){"use strict";var n,i,o=this&&this.__classPrivateFieldSet||function(e,t,r,n,i){if("m"===n)throw new TypeError("Private method is not writable");if("a"===n&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===n?i.call(e,r):i?i.value=r:t.set(e,r),r},a=this&&this.__classPrivateFieldGet||function(e,t,r,n){if("a"===r&&!n)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?n:"a"===r?n.call(e):n?n.value:t.get(e)};Object.defineProperty(t,"__esModule",{value:!0}),t.CBC=void 0;const s=r(2868);class u extends s.ModeOfOperation{constructor(e,t){if(super("ECC",e,u),n.set(this,void 0),i.set(this,void 0),t){if(t.length%16)throw new TypeError("invalid iv size (must be 16 bytes)");o(this,n,new Uint8Array(t),"f")}else o(this,n,new Uint8Array(16),"f");o(this,i,this.iv,"f")}get iv(){return new Uint8Array(a(this,n,"f"))}encrypt(e){if(e.length%16)throw new TypeError("invalid plaintext size (must be multiple of 16 bytes)");const t=new Uint8Array(e.length);for(let r=0;rNumber.MAX_SAFE_INTEGER)throw new TypeError("invalid counter initial integer value");for(let t=15;t>=0;--t)s(this,o,"f")[t]=e%256,e=Math.floor(e/256)}setCounterBytes(e){if(16!==e.length)throw new TypeError("invalid counter initial Uint8Array value length");s(this,o,"f").set(e)}increment(){for(let e=15;e>=0;e--){if(255!==s(this,o,"f")[e]){s(this,o,"f")[e]++;break}s(this,o,"f")[e]=0}}encrypt(e){var t,r;const u=new Uint8Array(e);for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ECB=void 0;const n=r(2868);class i extends n.ModeOfOperation{constructor(e){super("ECB",e,i)}encrypt(e){if(e.length%16)throw new TypeError("invalid plaintext size (must be multiple of 16 bytes)");const t=new Uint8Array(e.length);for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ModeOfOperation=void 0;const n=r(40517);t.ModeOfOperation=class{constructor(e,t,r){if(r&&!(this instanceof r))throw new Error(`${e} must be instantiated with "new"`);Object.defineProperties(this,{aes:{enumerable:!0,value:new n.AES(t)},name:{enumerable:!0,value:e}})}}},99533:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pkcs7Strip=t.pkcs7Pad=void 0,t.pkcs7Pad=function(e){const t=16-e.length%16,r=new Uint8Array(e.length+t);r.set(e);for(let n=e.length;n16)throw new TypeError("PKCS#7 padding byte out of range");const r=e.length-t;for(let n=0;n{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="6.1.0"},54760:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AbiCoder=void 0;const n=r(42120),i=r(12900),o=r(32063),a=r(8151),s=r(38583),u=r(5949),c=r(4148),l=r(36341),f=r(96893),h=r(53524),d=r(46701),p=r(66711),m=r(45475),y=r(42120),g=new Map;g.set(0,"GENERIC_PANIC"),g.set(1,"ASSERT_FALSE"),g.set(17,"OVERFLOW"),g.set(18,"DIVIDE_BY_ZERO"),g.set(33,"ENUM_RANGE_ERROR"),g.set(34,"BAD_STORAGE_DATA"),g.set(49,"STACK_UNDERFLOW"),g.set(50,"ARRAY_RANGE_ERROR"),g.set(65,"OUT_OF_MEMORY"),g.set(81,"UNINITIALIZED_FUNCTION_CALL");const b=new RegExp(/^bytes([0-9]*)$/),v=new RegExp(/^(u?int)([0-9]*)$/);let w=null;class A{#e(e){if(e.isArray())return new a.ArrayCoder(this.#e(e.arrayChildren),e.arrayLength,e.name);if(e.isTuple())return new d.TupleCoder(e.components.map((e=>this.#e(e))),e.name);switch(e.baseType){case"address":return new o.AddressCoder(e.name);case"bool":return new s.BooleanCoder(e.name);case"string":return new h.StringCoder(e.name);case"bytes":return new u.BytesCoder(e.name);case"":return new l.NullCoder(e.name)}let t=e.type.match(v);if(t){let r=parseInt(t[2]||"256");return(0,n.assertArgument)(0!==r&&r<=256&&r%8==0,"invalid "+t[1]+" bit length","param",e),new f.NumberCoder(r/8,"int"===t[1],e.name)}if(t=e.type.match(b),t){let r=parseInt(t[1]);return(0,n.assertArgument)(0!==r&&r<=32,"invalid bytes length","param",e),new c.FixedBytesCoder(r,e.name)}(0,n.assertArgument)(!1,"invalid type","type",e.type)}getDefaultValue(e){const t=e.map((e=>this.#e(p.ParamType.from(e))));return new d.TupleCoder(t,"_").defaultValue()}encode(e,t){(0,n.assertArgumentCount)(t.length,e.length,"types/values length mismatch");const r=e.map((e=>this.#e(p.ParamType.from(e)))),o=new d.TupleCoder(r,"_"),a=new i.Writer;return o.encode(a,t),a.data}decode(e,t,r){const n=e.map((e=>this.#e(p.ParamType.from(e))));return new d.TupleCoder(n,"_").decode(new i.Reader(t,r))}static defaultAbiCoder(){return null==w&&(w=new A),w}static getBuiltinCallException(e,t,r){return function(e,t,r,n){let i="missing revert data",o=null,a=null;if(r){i="execution reverted";const e=(0,y.getBytes)(r);if(r=(0,y.hexlify)(r),0===e.length)i+=" (no data present; likely require(false) occurred",o="require(false)";else if(e.length%32!=4)i+=" (could not decode reason; invalid data length)";else if("0x08c379a0"===(0,y.hexlify)(e.slice(0,4)))try{o=n.decode(["string"],e.slice(4))[0],a={signature:"Error(string)",name:"Error",args:[o]},i+=`: ${JSON.stringify(o)}`}catch(e){i+=" (could not decode reason; invalid string data)"}else if("0x4e487b71"===(0,y.hexlify)(e.slice(0,4)))try{const t=Number(n.decode(["uint256"],e.slice(4))[0]);a={signature:"Panic(uint256)",name:"Panic",args:[t]},o=`Panic due to ${g.get(t)||"UNKNOWN"}(${t})`,i+=`: ${o}`}catch(e){i+=" (could not decode panic code)"}else i+=" (unknown custom error)"}const s={to:t.to?(0,m.getAddress)(t.to):null,data:t.data||"0x"};return t.from&&(s.from=(0,m.getAddress)(t.from)),(0,y.makeError)(i,"CALL_EXCEPTION",{action:e,data:r,reason:o,transaction:s,invocation:null,revert:a})}(e,t,r,A.defaultAbiCoder())}}t.AbiCoder=A},12472:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBytes32String=t.encodeBytes32String=void 0;const n=r(42120);t.encodeBytes32String=function(e){const t=(0,n.toUtf8Bytes)(e);if(t.length>31)throw new Error("bytes32 string must be less than 32 bytes");return(0,n.zeroPadBytes)(t,32)},t.decodeBytes32String=function(e){const t=(0,n.getBytes)(e,"bytes");if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");let r=31;for(;0===t[r-1];)r--;return(0,n.toUtf8String)(t.slice(0,r))}},12900:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Reader=t.Writer=t.Coder=t.checkResultErrors=t.Result=t.WordSize=void 0;const n=r(42120);t.WordSize=32;const i=new Uint8Array(t.WordSize),o=["then"],a={};function s(e,t){const r=new Error(`deferred error during ABI decoding triggered accessing ${e}`);throw r.error=t,r}class u extends Array{#t;constructor(...e){const t=e[0];let r=e[1],i=(e[2]||[]).slice(),u=!0;t!==a&&(r=e,i=[],u=!1),super(r.length),r.forEach(((e,t)=>{this[t]=e}));const c=i.reduce(((e,t)=>("string"==typeof t&&e.set(t,(e.get(t)||0)+1),e)),new Map);if(this.#t=Object.freeze(r.map(((e,t)=>{const r=i[t];return null!=r&&1===c.get(r)?r:null}))),u)return Object.freeze(this),new Proxy(this,{get:(e,t,r)=>{if("string"==typeof t){if(t.match(/^[0-9]+$/)){const r=(0,n.getNumber)(t,"%index");if(r<0||r>=this.length)throw new RangeError("out of result range");const i=e[r];return i instanceof Error&&s(`index ${r}`,i),i}if(o.indexOf(t)>=0)return Reflect.get(e,t,r);const i=e[t];if(i instanceof Function)return function(...t){return i.apply(this===r?e:this,t)};if(!(t in e))return e.getValue.apply(this===r?e:this,[t])}return Reflect.get(e,t,r)}})}toArray(){const e=[];return this.forEach(((t,r)=>{t instanceof Error&&s(`index ${r}`,t),e.push(t)})),e}toObject(){return this.#t.reduce(((e,t,r)=>((0,n.assert)(null!=t,"value at index ${ index } unnamed","UNSUPPORTED_OPERATION",{operation:"toObject()"}),t in e||(e[t]=this.getValue(t)),e)),{})}slice(e,t){null==e&&(e=0),e<0&&(e+=this.length)<0&&(e=0),null==t&&(t=this.length),t<0&&(t+=this.length)<0&&(t=0),t>this.length&&(t=this.length);const r=[],n=[];for(let i=e;i{this.#r[e]=c(t)}}};class l{allowLoose;#r;#o;constructor(e,t){(0,n.defineProperties)(this,{allowLoose:!!t}),this.#r=(0,n.getBytesCopy)(e),this.#o=0}get data(){return(0,n.hexlify)(this.#r)}get dataLength(){return this.#r.length}get consumed(){return this.#o}get bytes(){return new Uint8Array(this.#r)}#a(e,r,i){let o=Math.ceil(r/t.WordSize)*t.WordSize;return this.#o+o>this.#r.length&&(this.allowLoose&&i&&this.#o+r<=this.#r.length?o=r:(0,n.assert)(!1,"data out-of-bounds","BUFFER_OVERRUN",{buffer:(0,n.getBytesCopy)(this.#r),length:this.#r.length,offset:this.#o+o})),this.#r.slice(this.#o,this.#o+o)}subReader(e){return new l(this.#r.slice(this.#o+e),this.allowLoose)}readBytes(e,t){let r=this.#a(0,e,!!t);return this.#o+=r.length,r.slice(0,e)}readValue(){return(0,n.toBigInt)(this.readBytes(t.WordSize))}readIndex(){return(0,n.toNumber)(this.readBytes(t.WordSize))}}t.Reader=l},32063:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AddressCoder=void 0;const n=r(45475),i=r(90358),o=r(3762),a=r(12900);class s extends a.Coder{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,t){let r=o.Typed.dereference(t,"string");try{r=(0,n.getAddress)(r)}catch(e){return this._throwError(e.message,t)}return e.writeValue(r)}decode(e){return(0,n.getAddress)((0,i.toBeHex)(e.readValue(),20))}}t.AddressCoder=s},56347:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AnonymousCoder=void 0;const n=r(12900);class i extends n.Coder{coder;constructor(e){super(e.name,e.type,"_",e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,t){return this.coder.encode(e,t)}decode(e){return this.coder.decode(e)}}t.AnonymousCoder=i},8151:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ArrayCoder=t.unpack=t.pack=void 0;const n=r(42120),i=r(3762),o=r(12900),a=r(56347);function s(e,t,r){let i=[];if(Array.isArray(r))i=r;else if(r&&"object"==typeof r){let e={};i=t.map((t=>{const i=t.localName;return(0,n.assert)(i,"cannot encode object for signature with missing names","INVALID_ARGUMENT",{argument:"values",info:{coder:t},value:r}),(0,n.assert)(!e[i],"cannot encode object for signature with duplicate names","INVALID_ARGUMENT",{argument:"values",info:{coder:t},value:r}),e[i]=!0,r[i]}))}else(0,n.assertArgument)(!1,"invalid tuple value","tuple",r);(0,n.assertArgument)(t.length===i.length,"types/value length mismatch","tuple",r);let a=new o.Writer,s=new o.Writer,u=[];t.forEach(((e,t)=>{let r=i[t];if(e.dynamic){let t=s.length;e.encode(s,r);let n=a.writeUpdatableValue();u.push((e=>{n(e+t)}))}else e.encode(a,r)})),u.forEach((e=>{e(a.length)}));let c=e.appendWriter(a);return c+=e.appendWriter(s),c}function u(e,t){let r=[],i=[],a=e.subReader(0);return t.forEach((t=>{let o=null;if(t.dynamic){let r=e.readIndex(),i=a.subReader(r);try{o=t.decode(i)}catch(e){if((0,n.isError)(e,"BUFFER_OVERRUN"))throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}}else try{o=t.decode(e)}catch(e){if((0,n.isError)(e,"BUFFER_OVERRUN"))throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}if(null==o)throw new Error("investigate");r.push(o),i.push(t.localName||null)})),o.Result.fromItems(r,i)}t.pack=s,t.unpack=u;class c extends o.Coder{coder;length;constructor(e,t,r){super("array",e.type+"["+(t>=0?t:"")+"]",r,-1===t||e.dynamic),(0,n.defineProperties)(this,{coder:e,length:t})}defaultValue(){const e=this.coder.defaultValue(),t=[];for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BooleanCoder=void 0;const n=r(3762),i=r(12900);class o extends i.Coder{constructor(e){super("bool","bool",e,!1)}defaultValue(){return!1}encode(e,t){const r=n.Typed.dereference(t,"bool");return e.writeValue(r?1:0)}decode(e){return!!e.readValue()}}t.BooleanCoder=o},5949:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BytesCoder=t.DynamicBytesCoder=void 0;const n=r(42120),i=r(12900);class o extends i.Coder{constructor(e,t){super(e,e,t,!0)}defaultValue(){return"0x"}encode(e,t){t=(0,n.getBytesCopy)(t);let r=e.writeValue(t.length);return r+=e.writeBytes(t),r}decode(e){return e.readBytes(e.readIndex(),!0)}}t.DynamicBytesCoder=o;t.BytesCoder=class extends o{constructor(e){super("bytes",e)}decode(e){return(0,n.hexlify)(super.decode(e))}}},4148:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FixedBytesCoder=void 0;const n=r(42120),i=r(3762),o=r(12900);class a extends o.Coder{size;constructor(e,t){let r="bytes"+String(e);super(r,r,t,!1),(0,n.defineProperties)(this,{size:e},{size:"number"})}defaultValue(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+2*this.size)}encode(e,t){let r=(0,n.getBytesCopy)(i.Typed.dereference(t,this.type));return r.length!==this.size&&this._throwError("incorrect data length",t),e.writeBytes(r)}decode(e){return(0,n.hexlify)(e.readBytes(this.size))}}t.FixedBytesCoder=a},36341:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NullCoder=void 0;const n=r(12900),i=new Uint8Array([]);class o extends n.Coder{constructor(e){super("null","",e,!1)}defaultValue(){return null}encode(e,t){return null!=t&&this._throwError("not null",t),e.writeBytes(i)}decode(e){return e.readBytes(0),null}}t.NullCoder=o},96893:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NumberCoder=void 0;const n=r(42120),i=r(3762),o=r(12900),a=BigInt(0),s=BigInt(1),u=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");class c extends o.Coder{size;signed;constructor(e,t,r){const i=(t?"int":"uint")+8*e;super(i,i,r,!1),(0,n.defineProperties)(this,{size:e,signed:t},{size:"number",signed:"boolean"})}defaultValue(){return 0}encode(e,t){let r=(0,n.getBigInt)(i.Typed.dereference(t,this.type)),c=(0,n.mask)(u,8*o.WordSize);if(this.signed){let e=(0,n.mask)(c,8*this.size-1);(r>e||r<-(e+s))&&this._throwError("value out-of-bounds",t),r=(0,n.toTwos)(r,8*o.WordSize)}else(r(0,n.mask)(c,8*this.size))&&this._throwError("value out-of-bounds",t);return e.writeValue(r)}decode(e){let t=(0,n.mask)(e.readValue(),8*this.size);return this.signed&&(t=(0,n.fromTwos)(t,8*this.size)),t}}t.NumberCoder=c},53524:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StringCoder=void 0;const n=r(82119),i=r(3762),o=r(5949);class a extends o.DynamicBytesCoder{constructor(e){super("string",e)}defaultValue(){return""}encode(e,t){return super.encode(e,(0,n.toUtf8Bytes)(i.Typed.dereference(t,"string")))}decode(e){return(0,n.toUtf8String)(super.decode(e))}}t.StringCoder=a},46701:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TupleCoder=void 0;const n=r(39290),i=r(3762),o=r(12900),a=r(8151);class s extends o.Coder{coders;constructor(e,t){let r=!1;const i=[];e.forEach((e=>{e.dynamic&&(r=!0),i.push(e.type)}));super("tuple","tuple("+i.join(",")+")",t,r),(0,n.defineProperties)(this,{coders:Object.freeze(e.slice())})}defaultValue(){const e=[];this.coders.forEach((t=>{e.push(t.defaultValue())}));const t=this.coders.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach(((r,n)=>{let i=r.localName;i&&1===t[i]&&("length"===i&&(i="_length"),null==e[i]&&(e[i]=e[n]))})),Object.freeze(e)}encode(e,t){const r=i.Typed.dereference(t,"tuple");return(0,a.pack)(e,this.coders,r)}decode(e){return(0,a.unpack)(e,this.coders)}}t.TupleCoder=s},66711:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StructFragment=t.FunctionFragment=t.FallbackFragment=t.ConstructorFragment=t.EventFragment=t.ErrorFragment=t.NamedFragment=t.Fragment=t.ParamType=void 0;const n=r(42120),i=r(98336);function o(e){const t=new Set;return e.forEach((e=>t.add(e))),Object.freeze(t)}const a="constant external internal payable private public pure view",s=o(a.split(" ")),u="constructor error event fallback function receive struct",c=o(u.split(" ")),l="calldata memory storage payable indexed",f=o(l.split(" ")),h=o([u,l,"tuple returns",a].join(" ").split(" ")),d={"(":"OPEN_PAREN",")":"CLOSE_PAREN","[":"OPEN_BRACKET","]":"CLOSE_BRACKET",",":"COMMA","@":"AT"},p=new RegExp("^(\\s*)"),m=new RegExp("^([0-9]+)"),y=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)"),g=new RegExp("^([a-zA-Z$_][a-zA-Z0-9$_]*)$"),b=new RegExp("^(address|bool|bytes([0-9]*)|string|u?int([0-9]*))$");class v{#o;#s;get offset(){return this.#o}get length(){return this.#s.length-this.#o}constructor(e){this.#o=0,this.#s=e.slice()}clone(){return new v(this.#s)}reset(){this.#o=0}#u(e=0,t=0){return new v(this.#s.slice(e,t).map((t=>Object.freeze(Object.assign({},t,{match:t.match-e,linkBack:t.linkBack-e,linkNext:t.linkNext-e})))))}popKeyword(e){const t=this.peek();if("KEYWORD"!==t.type||!e.has(t.text))throw new Error(`expected keyword ${t.text}`);return this.pop().text}popType(e){if(this.peek().type!==e)throw new Error(`expected ${e}; got ${JSON.stringify(this.peek())}`);return this.pop().text}popParen(){const e=this.peek();if("OPEN_PAREN"!==e.type)throw new Error("bad start");const t=this.#u(this.#o+1,e.match+1);return this.#o=e.match+1,t}popParams(){const e=this.peek();if("OPEN_PAREN"!==e.type)throw new Error("bad start");const t=[];for(;this.#o=this.#s.length)throw new Error("out-of-bounds");return this.#s[this.#o]}peekKeyword(e){const t=this.peekType("KEYWORD");return null!=t&&e.has(t)?t:null}peekType(e){if(0===this.length)return null;const t=this.peek();return t.type===e?t.text:null}pop(){const e=this.peek();return this.#o++,e}toString(){const e=[];for(let t=this.#o;t`}}function w(e){const t=[],r=t=>{const r=a0&&"NUMBER"===t[t.length-1].type){const r=t.pop().text;e=r+e,t[t.length-1].value=(0,n.getNumber)(r)}if(0===t.length||"BRACKET"!==t[t.length-1].type)throw new Error("missing opening bracket");t[t.length-1].text+=e}}else if(u=s.match(y),u){if(c.text=u[1],a+=c.text.length,h.has(c.text)){c.type="KEYWORD";continue}if(c.text.match(b)){c.type="TYPE";continue}c.type="ID"}else{if(u=s.match(m),!u)throw new Error(`unexpected token ${JSON.stringify(s[0])} at position ${a}`);c.text=u[1],c.type="NUMBER",a+=c.text.length}}return new v(t.map((e=>Object.freeze(e))))}function A(e,t){let r=[];for(const n in t.keys())e.has(n)&&r.push(n);if(r.length>1)throw new Error(`conflicting types: ${r.join(", ")}`)}function S(e,t){if(t.peekKeyword(c)){const r=t.pop().text;if(r!==e)throw new Error(`expected ${e}, got ${r}`)}return t.popType("ID")}function k(e,t){const r=new Set;for(;;){const n=e.peekType("KEYWORD");if(null==n||t&&!t.has(n))break;if(e.pop(),r.has(n))throw new Error(`duplicate keywords: ${JSON.stringify(n)}`);r.add(n)}return Object.freeze(r)}function E(e){let t=k(e,s);return A(t,o("constant payable nonpayable".split(" "))),A(t,o("pure view payable nonpayable".split(" "))),t.has("view")?"view":t.has("pure")?"pure":t.has("payable")?"payable":t.has("nonpayable")?"nonpayable":t.has("constant")?"view":"nonpayable"}function _(e,t){return e.popParams().map((e=>D.from(e,t)))}function M(e){if(e.peekType("AT")){if(e.pop(),e.peekType("NUMBER"))return(0,n.getBigInt)(e.pop().text);throw new Error("invalid gas")}return null}function T(e){if(e.length)throw new Error(`unexpected tokens: ${e.toString()}`)}const x=new RegExp(/^(.*)\[([0-9]*)\]$/);function P(e){const t=e.match(b);if((0,n.assertArgument)(t,"invalid type","type",e),"uint"===e)return"uint256";if("int"===e)return"int256";if(t[2]){const r=parseInt(t[2]);(0,n.assertArgument)(0!==r&&r<=32,"invalid bytes length","type",e)}else if(t[3]){const r=parseInt(t[3]);(0,n.assertArgument)(0!==r&&r<=256&&r%8==0,"invalid numeric width","type",e)}return e}const I={},O=Symbol.for("_ethers_internal"),R="_ParamTypeInternal",C="_ErrorInternal",B="_EventInternal",N="_ConstructorInternal",L="_FallbackInternal",U="_FunctionInternal",F="_StructInternal";class D{name;type;baseType;indexed;components;arrayLength;arrayChildren;constructor(e,t,r,i,o,a,s,u){if((0,n.assertPrivate)(e,I,"ParamType"),Object.defineProperty(this,O,{value:R}),a&&(a=Object.freeze(a.slice())),"array"===i){if(null==s||null==u)throw new Error("")}else if(null!=s||null!=u)throw new Error("");if("tuple"===i){if(null==a)throw new Error("")}else if(null!=a)throw new Error("");(0,n.defineProperties)(this,{name:t,type:r,baseType:i,indexed:o,components:a,arrayLength:s,arrayChildren:u})}format(e){if(null==e&&(e="sighash"),"json"===e){let t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.isTuple()&&(t.components=this.components.map((t=>JSON.parse(t.format(e))))),JSON.stringify(t)}let t="";return this.isArray()?(t+=this.arrayChildren.format(e),t+=`[${this.arrayLength<0?"":String(this.arrayLength)}]`):this.isTuple()?("sighash"!==e&&(t+=this.type),t+="("+this.components.map((t=>t.format(e))).join("full"===e?", ":",")+")"):t+=this.type,"sighash"!==e&&(!0===this.indexed&&(t+=" indexed"),"full"===e&&this.name&&(t+=" "+this.name)),t}isArray(){return"array"===this.baseType}isTuple(){return"tuple"===this.baseType}isIndexable(){return null!=this.indexed}walk(e,t){if(this.isArray()){if(!Array.isArray(e))throw new Error("invalid array value");if(-1!==this.arrayLength&&e.length!==this.arrayLength)throw new Error("array is wrong length");const r=this;return e.map((e=>r.arrayChildren.walk(e,t)))}if(this.isTuple()){if(!Array.isArray(e))throw new Error("invalid tuple value");if(e.length!==this.components.length)throw new Error("array is wrong length");const r=this;return e.map(((e,n)=>r.components[n].walk(e,t)))}return t(this.type,e)}#c(e,t,r,n){if(this.isArray()){if(!Array.isArray(t))throw new Error("invalid array value");if(-1!==this.arrayLength&&t.length!==this.arrayLength)throw new Error("array is wrong length");const i=this.arrayChildren,o=t.slice();return o.forEach(((t,n)=>{i.#c(e,t,r,(e=>{o[n]=e}))})),void n(o)}if(this.isTuple()){const i=this.components;let o;if(Array.isArray(t))o=t.slice();else{if(null==t||"object"!=typeof t)throw new Error("invalid tuple value");o=i.map((e=>{if(!e.name)throw new Error("cannot use object value with unnamed components");if(!(e.name in t))throw new Error(`missing value for component ${e.name}`);return t[e.name]}))}if(o.length!==this.components.length)throw new Error("array is wrong length");return o.forEach(((t,n)=>{i[n].#c(e,t,r,(e=>{o[n]=e}))})),void n(o)}const i=r(this.type,t);i.then?e.push(async function(){n(await i)}()):n(i)}async walkAsync(e,t){const r=[],n=[e];return this.#c(r,e,t,(e=>{n[0]=e})),r.length&&await Promise.all(r),n[0]}static from(e,t){if(D.isParamType(e))return e;if("string"==typeof e)return D.from(w(e),t);if(e instanceof v){let r="",n="",i=null;k(e,o(["tuple"])).has("tuple")||e.peekType("OPEN_PAREN")?(n="tuple",i=e.popParams().map((e=>D.from(e))),r=`tuple(${i.map((e=>e.format())).join(",")})`):(r=P(e.popType("TYPE")),n=r);let a=null,s=null;for(;e.length&&e.peekType("BRACKET");){const t=e.pop();a=new D(I,"",r,n,null,i,s,a),s=t.value,r+=t.text,n="array",i=null}let u=null;if(k(e,f).has("indexed")){if(!t)throw new Error("");u=!0}const c=e.peekType("ID")?e.pop().text:"";if(e.length)throw new Error("leftover tokens");return new D(I,c,r,n,u,i,s,a)}const r=e.name;(0,n.assertArgument)(!r||"string"==typeof r&&r.match(g),"invalid name","obj.name",r);let i=e.indexed;null!=i&&((0,n.assertArgument)(t,"parameter cannot be indexed","obj.indexed",e.indexed),i=!!i);let a=e.type,s=a.match(x);if(s){const t=parseInt(s[2]||"-1"),n=D.from({type:s[1],components:e.components});return new D(I,r||"",a,"array",i,null,t,n)}if("tuple"===a||a.startsWith("tuple(")||a.startsWith("(")){const t=null!=e.components?e.components.map((e=>D.from(e))):null;return new D(I,r||"",a,"tuple",i,t,null,null)}return a=P(e.type),new D(I,r||"",a,a,i,null,null,null)}static isParamType(e){return e&&e[O]===R}}t.ParamType=D;class j{type;inputs;constructor(e,t,r){(0,n.assertPrivate)(e,I,"Fragment"),r=Object.freeze(r.slice()),(0,n.defineProperties)(this,{type:t,inputs:r})}static from(e){if("string"==typeof e){try{j.from(JSON.parse(e))}catch(e){}return j.from(w(e))}if(e instanceof v){switch(e.peekKeyword(c)){case"constructor":return q.from(e);case"error":return z.from(e);case"event":return G.from(e);case"fallback":case"receive":return K.from(e);case"function":return V.from(e);case"struct":return X.from(e)}}else if("object"==typeof e){switch(e.type){case"constructor":return q.from(e);case"error":return z.from(e);case"event":return G.from(e);case"fallback":case"receive":return K.from(e);case"function":return V.from(e);case"struct":return X.from(e)}(0,n.assert)(!1,`unsupported type: ${e.type}`,"UNSUPPORTED_OPERATION",{operation:"Fragment.from"})}(0,n.assertArgument)(!1,"unsupported frgament object","obj",e)}static isConstructor(e){return q.isFragment(e)}static isError(e){return z.isFragment(e)}static isEvent(e){return G.isFragment(e)}static isFunction(e){return V.isFragment(e)}static isStruct(e){return X.isFragment(e)}}t.Fragment=j;class H extends j{name;constructor(e,t,r,i){super(e,t,i),(0,n.assertArgument)("string"==typeof r&&r.match(g),"invalid identifier","name",r),i=Object.freeze(i.slice()),(0,n.defineProperties)(this,{name:r})}}function J(e,t){return"("+t.map((t=>t.format(e))).join("full"===e?", ":",")+")"}t.NamedFragment=H;class z extends H{constructor(e,t,r){super(e,"error",t,r),Object.defineProperty(this,O,{value:C})}get selector(){return(0,i.id)(this.format("sighash")).substring(0,10)}format(e){if(null==e&&(e="sighash"),"json"===e)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});const t=[];return"sighash"!==e&&t.push("error"),t.push(this.name+J(e,this.inputs)),t.join(" ")}static from(e){if(z.isFragment(e))return e;if("string"==typeof e)return z.from(w(e));if(e instanceof v){const t=S("error",e),r=_(e);return T(e),new z(I,t,r)}return new z(I,e.name,e.inputs?e.inputs.map(D.from):[])}static isFragment(e){return e&&e[O]===C}}t.ErrorFragment=z;class G extends H{anonymous;constructor(e,t,r,i){super(e,"event",t,r),Object.defineProperty(this,O,{value:B}),(0,n.defineProperties)(this,{anonymous:i})}get topicHash(){return(0,i.id)(this.format("sighash"))}format(e){if(null==e&&(e="sighash"),"json"===e)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});const t=[];return"sighash"!==e&&t.push("event"),t.push(this.name+J(e,this.inputs)),"sighash"!==e&&this.anonymous&&t.push("anonymous"),t.join(" ")}static getTopicHash(e,t){t=(t||[]).map((e=>D.from(e)));return new G(I,e,t,!1).topicHash}static from(e){if(G.isFragment(e))return e;if("string"==typeof e)return G.from(w(e));if(e instanceof v){const t=S("event",e),r=_(e,!0),n=!!k(e,o(["anonymous"])).has("anonymous");return T(e),new G(I,t,r,n)}return new G(I,e.name,e.inputs?e.inputs.map((e=>D.from(e,!0))):[],!!e.anonymous)}static isFragment(e){return e&&e[O]===B}}t.EventFragment=G;class q extends j{payable;gas;constructor(e,t,r,i,o){super(e,t,r),Object.defineProperty(this,O,{value:N}),(0,n.defineProperties)(this,{payable:i,gas:o})}format(e){if((0,n.assert)(null!=e&&"sighash"!==e,"cannot format a constructor for sighash","UNSUPPORTED_OPERATION",{operation:"format(sighash)"}),"json"===e)return JSON.stringify({type:"constructor",stateMutability:this.payable?"payable":"undefined",payable:this.payable,gas:null!=this.gas?this.gas:void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});const t=[`constructor${J(e,this.inputs)}`];return t.push(this.payable?"payable":"nonpayable"),null!=this.gas&&t.push(`@${this.gas.toString()}`),t.join(" ")}static from(e){if(q.isFragment(e))return e;if("string"==typeof e)return q.from(w(e));if(e instanceof v){k(e,o(["constructor"]));const t=_(e),r=!!k(e,o(["payable"])).has("payable"),n=M(e);return T(e),new q(I,"constructor",t,r,n)}return new q(I,"constructor",e.inputs?e.inputs.map(D.from):[],!!e.payable,null!=e.gas?e.gas:null)}static isFragment(e){return e&&e[O]===N}}t.ConstructorFragment=q;class K extends j{payable;constructor(e,t,r){super(e,"fallback",t),Object.defineProperty(this,O,{value:L}),(0,n.defineProperties)(this,{payable:r})}format(e){const t=0===this.inputs.length?"receive":"fallback";if("json"===e){const e=this.payable?"payable":"nonpayable";return JSON.stringify({type:t,stateMutability:e})}return`${t}()${this.payable?" payable":""}`}static from(e){if(K.isFragment(e))return e;if("string"==typeof e)return K.from(w(e));if(e instanceof v){const t=e.toString(),r=e.peekKeyword(o(["fallback","receive"]));(0,n.assertArgument)(r,"type must be fallback or receive","obj",t);if("receive"===e.popKeyword(o(["fallback","receive"]))){const t=_(e);return(0,n.assertArgument)(0===t.length,"receive cannot have arguments","obj.inputs",t),k(e,o(["payable"])),T(e),new K(I,[],!0)}let i=_(e);i.length?(0,n.assertArgument)(1===i.length&&"bytes"===i[0].type,"invalid fallback inputs","obj.inputs",i.map((e=>e.format("minimal"))).join(", ")):i=[D.from("bytes")];const a=E(e);if((0,n.assertArgument)("nonpayable"===a||"payable"===a,"fallback cannot be constants","obj.stateMutability",a),k(e,o(["returns"])).has("returns")){const t=_(e);(0,n.assertArgument)(1===t.length&&"bytes"===t[0].type,"invalid fallback outputs","obj.outputs",t.map((e=>e.format("minimal"))).join(", "))}return T(e),new K(I,i,"payable"===a)}if("receive"===e.type)return new K(I,[],!0);if("fallback"===e.type){const t=[D.from("bytes")],r="payable"===e.stateMutability;return new K(I,t,r)}(0,n.assertArgument)(!1,"invalid fallback description","obj",e)}static isFragment(e){return e&&e[O]===L}}t.FallbackFragment=K;class V extends H{constant;outputs;stateMutability;payable;gas;constructor(e,t,r,i,o,a){super(e,"function",t,i),Object.defineProperty(this,O,{value:U}),o=Object.freeze(o.slice());const s="view"===r||"pure"===r,u="payable"===r;(0,n.defineProperties)(this,{constant:s,gas:a,outputs:o,payable:u,stateMutability:r})}get selector(){return(0,i.id)(this.format("sighash")).substring(0,10)}format(e){if(null==e&&(e="sighash"),"json"===e)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:null!=this.gas?this.gas:void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e)))),outputs:this.outputs.map((t=>JSON.parse(t.format(e))))});const t=[];return"sighash"!==e&&t.push("function"),t.push(this.name+J(e,this.inputs)),"sighash"!==e&&("nonpayable"!==this.stateMutability&&t.push(this.stateMutability),this.outputs&&this.outputs.length&&(t.push("returns"),t.push(J(e,this.outputs))),null!=this.gas&&t.push(`@${this.gas.toString()}`)),t.join(" ")}static getSelector(e,t){t=(t||[]).map((e=>D.from(e)));return new V(I,e,"view",t,[],null).selector}static from(e){if(V.isFragment(e))return e;if("string"==typeof e)return V.from(w(e));if(e instanceof v){const t=S("function",e),r=_(e),n=E(e);let i=[];k(e,o(["returns"])).has("returns")&&(i=_(e));const a=M(e);return T(e),new V(I,t,n,r,i,a)}return new V(I,e.name,e.stateMutability,e.inputs?e.inputs.map(D.from):[],e.outputs?e.outputs.map(D.from):[],null!=e.gas?e.gas:null)}static isFragment(e){return e&&e[O]===U}}t.FunctionFragment=V;class X extends H{constructor(e,t,r){super(e,"struct",t,r),Object.defineProperty(this,O,{value:F})}format(){throw new Error("@TODO")}static from(e){if("string"==typeof e)return X.from(w(e));if(e instanceof v){const t=S("struct",e),r=_(e);return T(e),new X(I,t,r)}return new X(I,e.name,e.inputs?e.inputs.map(D.from):[])}static isFragment(e){return e&&e[O]===F}}t.StructFragment=X},93707:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Typed=t.Result=t.TransactionDescription=t.LogDescription=t.ErrorDescription=t.Interface=t.Indexed=t.checkResultErrors=t.StructFragment=t.ParamType=t.NamedFragment=t.FunctionFragment=t.Fragment=t.FallbackFragment=t.EventFragment=t.ErrorFragment=t.ConstructorFragment=t.encodeBytes32String=t.decodeBytes32String=t.AbiCoder=void 0;var n=r(54760);Object.defineProperty(t,"AbiCoder",{enumerable:!0,get:function(){return n.AbiCoder}});var i=r(12472);Object.defineProperty(t,"decodeBytes32String",{enumerable:!0,get:function(){return i.decodeBytes32String}}),Object.defineProperty(t,"encodeBytes32String",{enumerable:!0,get:function(){return i.encodeBytes32String}});var o=r(66711);Object.defineProperty(t,"ConstructorFragment",{enumerable:!0,get:function(){return o.ConstructorFragment}}),Object.defineProperty(t,"ErrorFragment",{enumerable:!0,get:function(){return o.ErrorFragment}}),Object.defineProperty(t,"EventFragment",{enumerable:!0,get:function(){return o.EventFragment}}),Object.defineProperty(t,"FallbackFragment",{enumerable:!0,get:function(){return o.FallbackFragment}}),Object.defineProperty(t,"Fragment",{enumerable:!0,get:function(){return o.Fragment}}),Object.defineProperty(t,"FunctionFragment",{enumerable:!0,get:function(){return o.FunctionFragment}}),Object.defineProperty(t,"NamedFragment",{enumerable:!0,get:function(){return o.NamedFragment}}),Object.defineProperty(t,"ParamType",{enumerable:!0,get:function(){return o.ParamType}}),Object.defineProperty(t,"StructFragment",{enumerable:!0,get:function(){return o.StructFragment}});var a=r(16401);Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return a.checkResultErrors}}),Object.defineProperty(t,"Indexed",{enumerable:!0,get:function(){return a.Indexed}}),Object.defineProperty(t,"Interface",{enumerable:!0,get:function(){return a.Interface}}),Object.defineProperty(t,"ErrorDescription",{enumerable:!0,get:function(){return a.ErrorDescription}}),Object.defineProperty(t,"LogDescription",{enumerable:!0,get:function(){return a.LogDescription}}),Object.defineProperty(t,"TransactionDescription",{enumerable:!0,get:function(){return a.TransactionDescription}}),Object.defineProperty(t,"Result",{enumerable:!0,get:function(){return a.Result}});var s=r(3762);Object.defineProperty(t,"Typed",{enumerable:!0,get:function(){return s.Typed}})},16401:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Interface=t.Indexed=t.ErrorDescription=t.TransactionDescription=t.LogDescription=t.Result=t.checkResultErrors=void 0;const n=r(96965),i=r(98336),o=r(42120),a=r(54760),s=r(12900);Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return s.checkResultErrors}}),Object.defineProperty(t,"Result",{enumerable:!0,get:function(){return s.Result}});const u=r(66711),c=r(3762);class l{fragment;name;signature;topic;args;constructor(e,t,r){const n=e.name,i=e.format();(0,o.defineProperties)(this,{fragment:e,name:n,signature:i,topic:t,args:r})}}t.LogDescription=l;class f{fragment;name;args;signature;selector;value;constructor(e,t,r,n){const i=e.name,a=e.format();(0,o.defineProperties)(this,{fragment:e,name:i,args:r,signature:a,selector:t,value:n})}}t.TransactionDescription=f;class h{fragment;name;args;signature;selector;constructor(e,t,r){const n=e.name,i=e.format();(0,o.defineProperties)(this,{fragment:e,name:n,args:r,signature:i,selector:t})}}t.ErrorDescription=h;class d{hash;_isIndexed;static isIndexed(e){return!(!e||!e._isIndexed)}constructor(e){(0,o.defineProperties)(this,{hash:e,_isIndexed:!0})}}t.Indexed=d;const p={0:"generic panic",1:"assert(false)",17:"arithmetic overflow",18:"division or modulo by zero",33:"enum overflow",34:"invalid encoded storage byte array accessed",49:"out-of-bounds array access; popping on an empty array",50:"out-of-bounds access of an array or bytesN",65:"out of memory",81:"uninitialized function"},m={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:e=>`reverted with reason string ${JSON.stringify(e)}`},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"],reason:e=>{let t="unknown panic code";return e>=0&&e<=255&&p[e.toString()]&&(t=p[e.toString()]),`reverted with panic code 0x${e.toString(16)} (${t})`}}};class y{fragments;deploy;fallback;receive;#l;#f;#h;#d;constructor(e){let t=[];t="string"==typeof e?JSON.parse(e):e,this.#h=new Map,this.#l=new Map,this.#f=new Map;const r=[];for(const e of t)try{r.push(u.Fragment.from(e))}catch(e){console.log("EE",e)}(0,o.defineProperties)(this,{fragments:Object.freeze(r)});let n=null,i=!1;this.#d=this.getAbiCoder(),this.fragments.forEach(((e,t)=>{let r;switch(e.type){case"constructor":return this.deploy?void console.log("duplicate definition - constructor"):void(0,o.defineProperties)(this,{deploy:e});case"fallback":return void(0===e.inputs.length?i=!0:((0,o.assertArgument)(!n||e.payable!==n.payable,"conflicting fallback fragments",`fragments[${t}]`,e),n=e,i=n.payable));case"function":r=this.#h;break;case"event":r=this.#f;break;case"error":r=this.#l;break;default:return}const a=e.format();r.has(a)||r.set(a,e)})),this.deploy||(0,o.defineProperties)(this,{deploy:u.ConstructorFragment.from("constructor()")}),(0,o.defineProperties)(this,{fallback:n,receive:i})}format(e){const t=e?"minimal":"full";return this.fragments.map((e=>e.format(t)))}formatJson(){const e=this.fragments.map((e=>e.format("json")));return JSON.stringify(e.map((e=>JSON.parse(e))))}getAbiCoder(){return a.AbiCoder.defaultAbiCoder()}#p(e,t,r){if((0,o.isHexString)(e)){const t=e.toLowerCase();for(const e of this.#h.values())if(t===e.selector)return e;return null}if(-1===e.indexOf("(")){const n=[];for(const[t,r]of this.#h)t.split("(")[0]===e&&n.push(r);if(t){const e=t.length>0?t[t.length-1]:null;let r=t.length,i=!0;c.Typed.isTyped(e)&&"overrides"===e.type&&(i=!1,r--);for(let e=n.length-1;e>=0;e--){const t=n[e].inputs.length;t===r||i&&t===r-1||n.splice(e,1)}for(let e=n.length-1;e>=0;e--){const r=n[e].inputs;for(let i=0;i=r.length){if("overrides"===t[i].type)continue;n.splice(e,1);break}if(t[i].type!==r[i].baseType){n.splice(e,1);break}}}}if(1===n.length&&t&&t.length!==n[0].inputs.length){const e=t[t.length-1];(null==e||Array.isArray(e)||"object"!=typeof e)&&n.splice(0,1)}if(0===n.length)return null;if(n.length>1&&r){const t=n.map((e=>JSON.stringify(e.format()))).join(", ");(0,o.assertArgument)(!1,`ambiguous function description (i.e. matches ${t})`,"key",e)}return n[0]}const n=this.#h.get(u.FunctionFragment.from(e).format());return n||null}getFunctionName(e){const t=this.#p(e,null,!1);return(0,o.assertArgument)(t,"no matching function","key",e),t.name}getFunction(e,t){return this.#p(e,t||null,!0)}forEachFunction(e){const t=Array.from(this.#h.keys());t.sort(((e,t)=>e.localeCompare(t)));for(let r=0;r=0;e--)n[e].inputs.length=0;e--){const r=n[e].inputs;for(let i=0;i1&&r){const t=n.map((e=>JSON.stringify(e.format()))).join(", ");(0,o.assertArgument)(!1,`ambiguous event description (i.e. matches ${t})`,"key",e)}return n[0]}const n=this.#f.get(u.EventFragment.from(e).format());return n||null}getEventName(e){const t=this.#m(e,null,!1);return(0,o.assertArgument)(t,"no matching event","key",e),t.name}getEvent(e,t){return this.#m(e,t||null,!0)}forEachEvent(e){const t=Array.from(this.#f.keys());t.sort(((e,t)=>e.localeCompare(t)));for(let r=0;r1){const r=t.map((e=>JSON.stringify(e.format()))).join(", ");(0,o.assertArgument)(!1,`ambiguous error description (i.e. ${r})`,"name",e)}return t[0]}if("Error(string)"===(e=u.ErrorFragment.from(e).format()))return u.ErrorFragment.from("error Error(string)");if("Panic(uint256)"===e)return u.ErrorFragment.from("error Panic(uint256)");const r=this.#l.get(e);return r||null}forEachError(e){const t=Array.from(this.#l.keys());t.sort(((e,t)=>e.localeCompare(t)));for(let r=0;r"string"===e.type?(0,i.id)(t):"bytes"===e.type?(0,n.keccak256)((0,o.hexlify)(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=(0,o.toBeHex)(t)),"address"===e.type&&this.#d.encode(["address"],[t]),(0,o.zeroPadValue)((0,o.hexlify)(t),32));for(t.forEach(((t,n)=>{const i=e.inputs[n];i.indexed?null==t?r.push(null):"array"===i.baseType||"tuple"===i.baseType?(0,o.assertArgument)(!1,"filtering with tuples or arrays not supported","contract."+i.name,t):Array.isArray(t)?r.push(t.map((e=>a(i,e)))):r.push(a(i,t)):(0,o.assertArgument)(null==t,"cannot filter non-indexed parameters; must be null","contract."+i.name,t)}));r.length&&null===r[r.length-1];)r.pop();return r}encodeEventLog(e,t){if("string"==typeof e){const t=this.getEvent(e);(0,o.assertArgument)(t,"unknown event","eventFragment",e),e=t}const r=[],a=[],s=[];return e.anonymous||r.push(e.topicHash),(0,o.assertArgument)(t.length===e.inputs.length,"event arguments/values mismatch","values",t),e.inputs.forEach(((e,o)=>{const u=t[o];if(e.indexed)if("string"===e.type)r.push((0,i.id)(u));else if("bytes"===e.type)r.push((0,n.keccak256)(u));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");r.push(this.#d.encode([e.type],[u]))}else a.push(e),s.push(u)})),{data:this.#d.encode(a,s),topics:r}}decodeEventLog(e,t,r){if("string"==typeof e){const t=this.getEvent(e);(0,o.assertArgument)(t,"unknown event","eventFragment",e),e=t}if(null!=r&&!e.anonymous){const t=e.topicHash;(0,o.assertArgument)((0,o.isHexString)(r[0],32)&&r[0].toLowerCase()===t,"fragment/topic mismatch","topics[0]",r[0]),r=r.slice(1)}const n=[],i=[],a=[];e.inputs.forEach(((e,t)=>{e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(n.push(u.ParamType.from({type:"bytes32",name:e.name})),a.push(!0)):(n.push(e),a.push(!1)):(i.push(e),a.push(!1))}));const c=null!=r?this.#d.decode(n,(0,o.concat)(r)):null,l=this.#d.decode(i,t,!0),f=[],h=[];let p=0,m=0;return e.inputs.forEach(((e,t)=>{let r=null;if(e.indexed)if(null==c)r=new d(null);else if(a[t])r=new d(c[m++]);else try{r=c[m++]}catch(e){r=e}else try{r=l[p++]}catch(e){r=e}f.push(r),h.push(e.name||null)})),s.Result.fromItems(f,h)}parseTransaction(e){const t=(0,o.getBytes)(e.data,"tx.data"),r=(0,o.getBigInt)(null!=e.value?e.value:0,"tx.value"),n=this.getFunction((0,o.hexlify)(t.slice(0,4)));if(!n)return null;const i=this.#d.decode(n.inputs,t.slice(4));return new f(n,n.selector,i,r)}parseCallResult(e){throw new Error("@TODO")}parseLog(e){const t=this.getEvent(e.topics[0]);return!t||t.anonymous?null:new l(t,t.topicHash,this.decodeEventLog(t,e.data,e.topics))}parseError(e){const t=(0,o.hexlify)(e),r=this.getError((0,o.dataSlice)(t,0,4));if(!r)return null;const n=this.#d.decode(r.inputs,(0,o.dataSlice)(t,4));return new h(r,r.selector,n)}static from(e){return e instanceof y?e:"string"==typeof e?new y(JSON.parse(e)):"function"==typeof e.format?new y(e.format("json")):new y(e)}}t.Interface=y},3762:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Typed=void 0;const n=r(42120),i={};function o(e,t){let r=!1;return t<0&&(r=!0,t*=-1),new u(i,`${r?"":"u"}int${t}`,e,{signed:r,width:t})}function a(e,t){return new u(i,`bytes${t||""}`,e,{size:t})}const s=Symbol.for("_ethers_typed");class u{type;value;#y;_typedSymbol;constructor(e,t,r,o){null==o&&(o=null),(0,n.assertPrivate)(i,e,"Typed"),(0,n.defineProperties)(this,{_typedSymbol:s,type:t,value:r}),this.#y=o,this.format()}format(){if("array"===this.type)throw new Error("");if("dynamicArray"===this.type)throw new Error("");return"tuple"===this.type?`tuple(${this.value.map((e=>e.format())).join(",")})`:this.type}defaultValue(){return 0}minValue(){return 0}maxValue(){return 0}isBigInt(){return!!this.type.match(/^u?int[0-9]+$/)}isData(){return this.type.startsWith("bytes")}isString(){return"string"===this.type}get tupleName(){if("tuple"!==this.type)throw TypeError("not a tuple");return this.#y}get arrayLength(){if("array"!==this.type)throw TypeError("not an array");return!0===this.#y?-1:!1===this.#y?this.value.length:null}static from(e,t){return new u(i,e,t)}static uint8(e){return o(e,8)}static uint16(e){return o(e,16)}static uint24(e){return o(e,24)}static uint32(e){return o(e,32)}static uint40(e){return o(e,40)}static uint48(e){return o(e,48)}static uint56(e){return o(e,56)}static uint64(e){return o(e,64)}static uint72(e){return o(e,72)}static uint80(e){return o(e,80)}static uint88(e){return o(e,88)}static uint96(e){return o(e,96)}static uint104(e){return o(e,104)}static uint112(e){return o(e,112)}static uint120(e){return o(e,120)}static uint128(e){return o(e,128)}static uint136(e){return o(e,136)}static uint144(e){return o(e,144)}static uint152(e){return o(e,152)}static uint160(e){return o(e,160)}static uint168(e){return o(e,168)}static uint176(e){return o(e,176)}static uint184(e){return o(e,184)}static uint192(e){return o(e,192)}static uint200(e){return o(e,200)}static uint208(e){return o(e,208)}static uint216(e){return o(e,216)}static uint224(e){return o(e,224)}static uint232(e){return o(e,232)}static uint240(e){return o(e,240)}static uint248(e){return o(e,248)}static uint256(e){return o(e,256)}static uint(e){return o(e,256)}static int8(e){return o(e,-8)}static int16(e){return o(e,-16)}static int24(e){return o(e,-24)}static int32(e){return o(e,-32)}static int40(e){return o(e,-40)}static int48(e){return o(e,-48)}static int56(e){return o(e,-56)}static int64(e){return o(e,-64)}static int72(e){return o(e,-72)}static int80(e){return o(e,-80)}static int88(e){return o(e,-88)}static int96(e){return o(e,-96)}static int104(e){return o(e,-104)}static int112(e){return o(e,-112)}static int120(e){return o(e,-120)}static int128(e){return o(e,-128)}static int136(e){return o(e,-136)}static int144(e){return o(e,-144)}static int152(e){return o(e,-152)}static int160(e){return o(e,-160)}static int168(e){return o(e,-168)}static int176(e){return o(e,-176)}static int184(e){return o(e,-184)}static int192(e){return o(e,-192)}static int200(e){return o(e,-200)}static int208(e){return o(e,-208)}static int216(e){return o(e,-216)}static int224(e){return o(e,-224)}static int232(e){return o(e,-232)}static int240(e){return o(e,-240)}static int248(e){return o(e,-248)}static int256(e){return o(e,-256)}static int(e){return o(e,-256)}static bytes1(e){return a(e,1)}static bytes2(e){return a(e,2)}static bytes3(e){return a(e,3)}static bytes4(e){return a(e,4)}static bytes5(e){return a(e,5)}static bytes6(e){return a(e,6)}static bytes7(e){return a(e,7)}static bytes8(e){return a(e,8)}static bytes9(e){return a(e,9)}static bytes10(e){return a(e,10)}static bytes11(e){return a(e,11)}static bytes12(e){return a(e,12)}static bytes13(e){return a(e,13)}static bytes14(e){return a(e,14)}static bytes15(e){return a(e,15)}static bytes16(e){return a(e,16)}static bytes17(e){return a(e,17)}static bytes18(e){return a(e,18)}static bytes19(e){return a(e,19)}static bytes20(e){return a(e,20)}static bytes21(e){return a(e,21)}static bytes22(e){return a(e,22)}static bytes23(e){return a(e,23)}static bytes24(e){return a(e,24)}static bytes25(e){return a(e,25)}static bytes26(e){return a(e,26)}static bytes27(e){return a(e,27)}static bytes28(e){return a(e,28)}static bytes29(e){return a(e,29)}static bytes30(e){return a(e,30)}static bytes31(e){return a(e,31)}static bytes32(e){return a(e,32)}static address(e){return new u(i,"address",e)}static bool(e){return new u(i,"bool",!!e)}static bytes(e){return new u(i,"bytes",e)}static string(e){return new u(i,"string",e)}static array(e,t){throw new Error("not implemented yet")}static tuple(e,t){throw new Error("not implemented yet")}static overrides(e){return new u(i,"overrides",Object.assign({},e))}static isTyped(e){return e&&e._typedSymbol===s}static dereference(e,t){if(u.isTyped(e)){if(e.type!==t)throw new Error(`invalid type: expecetd ${t}, got ${e.type}`);return e.value}return e}}t.Typed=u},40805:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getIcapAddress=t.getAddress=void 0;const n=r(96965),i=r(42120),o=BigInt(0),a=BigInt(36);function s(e){const t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40);for(let e=0;e<40;e++)r[e]=t[e].charCodeAt(0);const o=(0,i.getBytes)((0,n.keccak256)(r));for(let e=0;e<40;e+=2)o[e>>1]>>4>=8&&(t[e]=t[e].toUpperCase()),(15&o[e>>1])>=8&&(t[e+1]=t[e+1].toUpperCase());return"0x"+t.join("")}const u={};for(let e=0;e<10;e++)u[String(e)]=String(e);for(let e=0;e<26;e++)u[String.fromCharCode(65+e)]=String(10+e);function c(e){let t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((e=>u[e])).join("");for(;t.length>=15;){let e=t.substring(0,15);t=parseInt(e,10)%97+t.substring(e.length)}let r=String(98-parseInt(t,10)%97);for(;r.length<2;)r="0"+r;return r}const l=function(){const e={};for(let t=0;t<36;t++){e["0123456789abcdefghijklmnopqrstuvwxyz"[t]]=BigInt(t)}return e}();function f(e){if((0,i.assertArgument)("string"==typeof e,"invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/)){e.startsWith("0x")||(e="0x"+e);const t=s(e);return(0,i.assertArgument)(!e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)||t===e,"bad address checksum","address",e),t}if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){(0,i.assertArgument)(e.substring(2,4)===c(e),"bad icap checksum","address",e);let t=function(e){e=e.toLowerCase();let t=o;for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolveAddress=t.isAddress=t.isAddressable=void 0;const n=r(42120),i=r(40805);function o(e){return e&&"function"==typeof e.getAddress}async function a(e,t){const r=await t;return null!=r&&"0x0000000000000000000000000000000000000000"!==r||((0,n.assert)("string"!=typeof e,"unconfigured name","UNCONFIGURED_NAME",{value:e}),(0,n.assertArgument)(!1,"invalid AddressLike value; did not resolve to a value address","target",e)),(0,i.getAddress)(r)}t.isAddressable=o,t.isAddress=function(e){try{return(0,i.getAddress)(e),!0}catch(e){}return!1},t.resolveAddress=function(e,t){return"string"==typeof e?e.match(/^0x[0-9a-f]{40}$/i)?(0,i.getAddress)(e):((0,n.assert)(null!=t,"ENS resolution requires a provider","UNSUPPORTED_OPERATION",{operation:"resolveName"}),a(e,t.resolveName(e))):o(e)?a(e,e.getAddress()):e&&"function"==typeof e.then?a(e,e):void(0,n.assertArgument)(!1,"unsupported addressable value","target",e)}},96067:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getCreate2Address=t.getCreateAddress=void 0;const n=r(96965),i=r(42120),o=r(40805);t.getCreateAddress=function(e){const t=(0,o.getAddress)(e.from);let r=(0,i.getBigInt)(e.nonce,"tx.nonce").toString(16);return r="0"===r?"0x":r.length%2?"0x0"+r:"0x"+r,(0,o.getAddress)((0,i.dataSlice)((0,n.keccak256)((0,i.encodeRlp)([t,r])),12))},t.getCreate2Address=function(e,t,r){const a=(0,o.getAddress)(e),s=(0,i.getBytes)(t,"salt"),u=(0,i.getBytes)(r,"initCodeHash");return(0,i.assertArgument)(32===s.length,"salt must be 32 bytes","salt",t),(0,i.assertArgument)(32===u.length,"initCodeHash must be 32 bytes","initCodeHash",r),(0,o.getAddress)((0,i.dataSlice)((0,n.keccak256)((0,i.concat)(["0xff",a,s,u])),12))}},45475:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolveAddress=t.isAddress=t.isAddressable=t.getCreate2Address=t.getCreateAddress=t.getIcapAddress=t.getAddress=void 0;var n=r(40805);Object.defineProperty(t,"getAddress",{enumerable:!0,get:function(){return n.getAddress}}),Object.defineProperty(t,"getIcapAddress",{enumerable:!0,get:function(){return n.getIcapAddress}});var i=r(96067);Object.defineProperty(t,"getCreateAddress",{enumerable:!0,get:function(){return i.getCreateAddress}}),Object.defineProperty(t,"getCreate2Address",{enumerable:!0,get:function(){return i.getCreate2Address}});var o=r(93442);Object.defineProperty(t,"isAddressable",{enumerable:!0,get:function(){return o.isAddressable}}),Object.defineProperty(t,"isAddress",{enumerable:!0,get:function(){return o.isAddress}}),Object.defineProperty(t,"resolveAddress",{enumerable:!0,get:function(){return o.resolveAddress}})},23223:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ZeroAddress=void 0,t.ZeroAddress="0x0000000000000000000000000000000000000000"},90688:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ZeroHash=void 0,t.ZeroHash="0x0000000000000000000000000000000000000000000000000000000000000000"},30087:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MessagePrefix=t.EtherSymbol=t.MaxInt256=t.MinInt256=t.MaxUint256=t.WeiPerEther=t.N=t.ZeroHash=t.ZeroAddress=void 0;var n=r(23223);Object.defineProperty(t,"ZeroAddress",{enumerable:!0,get:function(){return n.ZeroAddress}});var i=r(90688);Object.defineProperty(t,"ZeroHash",{enumerable:!0,get:function(){return i.ZeroHash}});var o=r(24456);Object.defineProperty(t,"N",{enumerable:!0,get:function(){return o.N}}),Object.defineProperty(t,"WeiPerEther",{enumerable:!0,get:function(){return o.WeiPerEther}}),Object.defineProperty(t,"MaxUint256",{enumerable:!0,get:function(){return o.MaxUint256}}),Object.defineProperty(t,"MinInt256",{enumerable:!0,get:function(){return o.MinInt256}}),Object.defineProperty(t,"MaxInt256",{enumerable:!0,get:function(){return o.MaxInt256}});var a=r(82359);Object.defineProperty(t,"EtherSymbol",{enumerable:!0,get:function(){return a.EtherSymbol}}),Object.defineProperty(t,"MessagePrefix",{enumerable:!0,get:function(){return a.MessagePrefix}})},24456:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MaxInt256=t.MinInt256=t.MaxUint256=t.WeiPerEther=t.N=void 0,t.N=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),t.WeiPerEther=BigInt("1000000000000000000"),t.MaxUint256=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),t.MinInt256=BigInt("0x8000000000000000000000000000000000000000000000000000000000000000")*BigInt(-1),t.MaxInt256=BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff")},82359:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MessagePrefix=t.EtherSymbol=void 0,t.EtherSymbol="Ξ",t.MessagePrefix="Ethereum Signed Message:\n"},44350:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Contract=t.BaseContract=t.resolveArgs=t.copyOverrides=void 0;const n=r(93707),i=r(45475),o=r(37143),a=r(42120),s=r(97151),u=BigInt(0);function c(e){return e&&"function"==typeof e.call}function l(e){return e&&"function"==typeof e.estimateGas}function f(e){return e&&"function"==typeof e.resolveName}function h(e){return e&&"function"==typeof e.sendTransaction}class d{#g;fragment;constructor(e,t,r){if((0,a.defineProperties)(this,{fragment:t}),t.inputs.lengthnull==r[t]?null:e.walkAsync(r[t],((e,t)=>"address"===e?(0,i.resolveAddress)(t,o):t)))));return e.interface.encodeFilterTopics(t,n)}()}getTopicFilter(){return this.#g}}function p(e,t){return null==e?null:"function"==typeof e[t]?e:e.provider&&"function"==typeof e.provider[t]?e.provider:null}function m(e){return null==e?null:e.provider||null}async function y(e,t){const r=(0,o.copyRequest)(n.Typed.dereference(e,"overrides"));return(0,a.assertArgument)(null==r.to||(t||[]).indexOf("to")>=0,"cannot override to","overrides.to",r.to),(0,a.assertArgument)(null==r.data||(t||[]).indexOf("data")>=0,"cannot override data","overrides.data",r.data),r.from&&(r.from=await(0,i.resolveAddress)(r.from)),r}async function g(e,t,r){const o=p(e,"resolveName"),a=f(o)?o:null;return await Promise.all(t.map(((e,t)=>e.walkAsync(r[t],((e,t)=>(t=n.Typed.dereference(t,e),"address"===e?(0,i.resolveAddress)(t,a):t))))))}t.copyOverrides=y,t.resolveArgs=g;class b{_contract;constructor(e){(0,a.defineProperties)(this,{_contract:e});return new Proxy(this,{apply:async(e,t,r)=>await e.send(...r)})}async populateTransaction(e){const t=await y(e,["data"]);t.to=await this._contract.getAddress();const r=this._contract.interface,n=r.receive||r.fallback&&r.fallback.payable;return(0,a.assertArgument)(n||(t.value||u)===u,"cannot send value to non-payable contract","overrides.value",t.value),(0,a.assertArgument)(r.fallback||"0x"===(t.data||"0x"),"cannot send data to receive-only contract","overrides.data",t.data),t}async staticCall(e){const t=p(this._contract.runner,"call");(0,a.assert)(c(t),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const r=await this.populateTransaction(e);try{return await t.call(r)}catch(e){if((0,a.isCallException)(e)&&e.data)throw this._contract.interface.makeError(e.data,r);throw e}}async send(e){const t=this._contract.runner;(0,a.assert)(h(t),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const r=await t.sendTransaction(await this.populateTransaction(e)),n=m(this._contract.runner);return new s.ContractTransactionResponse(this._contract.interface,n,r)}async estimateGas(e){const t=p(this._contract.runner,"estimateGas");return(0,a.assert)(l(t),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await t.estimateGas(await this.populateTransaction(e))}}class v extends(function(){return Function}()){name="";_contract;_key;constructor(e,t){super(),(0,a.defineProperties)(this,{name:e.interface.getFunctionName(t),_contract:e,_key:t});return new Proxy(this,{apply:async(e,t,r)=>e.getFragment(...r).constant?await e.staticCall(...r):await e.send(...r)})}get fragment(){const e=this._contract.interface.getFunction(this._key);return(0,a.assert)(e,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),e}getFragment(...e){const t=this._contract.interface.getFunction(this._key,e);return(0,a.assert)(t,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),t}async populateTransaction(...e){const t=this.getFragment(...e);let r={};if(t.inputs.length+1===e.length&&(r=await y(e.pop())),t.inputs.length!==e.length)throw new Error("internal error: fragment inputs doesn't match arguments; should not happen");const n=await g(this._contract.runner,t.inputs,e);return Object.assign({},r,await(0,a.resolveProperties)({to:this._contract.getAddress(),data:this._contract.interface.encodeFunctionData(t,n)}))}async staticCall(...e){const t=await this.staticCallResult(...e);return 1===t.length?t[0]:t}async send(...e){const t=this._contract.runner;(0,a.assert)(h(t),"contract runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const r=await t.sendTransaction(await this.populateTransaction(...e)),n=m(this._contract.runner);return new s.ContractTransactionResponse(this._contract.interface,n,r)}async estimateGas(...e){const t=p(this._contract.runner,"estimateGas");return(0,a.assert)(l(t),"contract runner does not support gas estimation","UNSUPPORTED_OPERATION",{operation:"estimateGas"}),await t.estimateGas(await this.populateTransaction(...e))}async staticCallResult(...e){const t=p(this._contract.runner,"call");(0,a.assert)(c(t),"contract runner does not support calling","UNSUPPORTED_OPERATION",{operation:"call"});const r=await this.populateTransaction(...e);let n="0x";try{n=await t.call(r)}catch(e){if((0,a.isCallException)(e)&&e.data)throw this._contract.interface.makeError(e.data,r);throw e}const i=this.getFragment(...e);return this._contract.interface.decodeFunctionResult(i,n)}}class w extends(function(){return Function}()){name="";_contract;_key;constructor(e,t){return super(),(0,a.defineProperties)(this,{name:e.interface.getEventName(t),_contract:e,_key:t}),new Proxy(this,{apply:(t,r,n)=>new d(e,t.getFragment(...n),n)})}get fragment(){const e=this._contract.interface.getEvent(this._key);return(0,a.assert)(e,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),e}getFragment(...e){const t=this._contract.interface.getEvent(this._key,e);return(0,a.assert)(t,"no matching fragment","UNSUPPORTED_OPERATION",{operation:"fragment"}),t}}const A=Symbol.for("_ethersInternal_contract"),S=new WeakMap;function k(e){return S.get(e[A])}async function E(e,t){let r,n=null;if(Array.isArray(t)){const n=function(t){if((0,a.isHexString)(t,32))return t;const r=e.interface.getEvent(t);return(0,a.assertArgument)(r,"unknown fragment","name",t),r.topicHash};r=t.map((e=>null==e?null:Array.isArray(e)?e.map(n):n(e)))}else"*"===t?r=[null]:"string"==typeof t?(0,a.isHexString)(t,32)?r=[t]:(n=e.interface.getEvent(t),(0,a.assertArgument)(n,"unknown fragment","event",t),r=[n.topicHash]):(i=t)&&"object"==typeof i&&"getTopicFilter"in i&&"function"==typeof i.getTopicFilter&&i.fragment?r=await t.getTopicFilter():"fragment"in t?(n=t.fragment,r=[n.topicHash]):(0,a.assertArgument)(!1,"unknown event name","event",t);var i;r=r.map((e=>{if(null==e)return null;if(Array.isArray(e)){const t=Array.from(new Set(e.map((e=>e.toLowerCase()))).values());return 1===t.length?t[0]:(t.sort(),t)}return e.toLowerCase()}));return{fragment:n,tag:r.map((e=>null==e?"null":Array.isArray(e)?e.join("|"):e)).join("&"),topics:r}}async function _(e,t){const{subs:r}=k(e);return r.get((await E(e,t)).tag)||null}async function M(e,t,r){const n=m(e.runner);(0,a.assert)(n,"contract runner does not support subscribing","UNSUPPORTED_OPERATION",{operation:t});const{fragment:i,tag:o,topics:u}=await E(e,r),{addr:c,subs:l}=k(e);let f=l.get(o);if(!f){const t={address:c||e,topics:u},a=t=>{let n=i;if(null==n)try{n=e.interface.getEvent(t.topics[0])}catch(e){}if(n){const o=n,a=i?e.interface.decodeEventLog(i,t.data,t.topics):[];x(e,r,a,(n=>new s.ContractEventPayload(e,n,r,o,t)))}else x(e,r,[],(n=>new s.ContractUnknownEventPayload(e,n,r,t)))};let h=[];f={tag:o,listeners:[],start:()=>{h.length||h.push(n.on(t,a))},stop:async()=>{if(0==h.length)return;let e=h;h=[],await Promise.all(e),n.off(t,a)}},l.set(o,f)}return f}let T=Promise.resolve();async function x(e,t,r,n){try{await T}catch(e){}const i=async function(e,t,r,n){await T;const i=await _(e,t);if(!i)return!1;const o=i.listeners.length;return i.listeners=i.listeners.filter((({listener:t,once:i})=>{const o=Array.from(r);n&&o.push(n(i?null:t));try{t.call(e,...o)}catch(e){}return!i})),o>0}(e,t,r,n);return T=i,await i}const P=["then"];class I{target;interface;runner;filters;[A];fallback;constructor(e,t,r,i){null==r&&(r=null);const o=n.Interface.from(t);let u;(0,a.defineProperties)(this,{target:e,runner:r,interface:o}),Object.defineProperty(this,A,{value:{}});let c=null,l=null;if(i){const e=m(r);l=new s.ContractTransactionResponse(this.interface,e,i)}let h=new Map;if("string"==typeof e)if((0,a.isHexString)(e))c=e,u=Promise.resolve(e);else{const t=p(r,"resolveName");if(!f(t))throw(0,a.makeError)("contract runner does not support name resolution","UNSUPPORTED_OPERATION",{operation:"resolveName"});u=t.resolveName(e).then((e=>{if(null==e)throw new Error("TODO");return k(this).addr=e,e}))}else u=e.getAddress().then((e=>{if(null==e)throw new Error("TODO");return k(this).addr=e,e}));var d,y;d=this,y={addrPromise:u,addr:c,deployTx:l,subs:h},S.set(d[A],y);const g=new Proxy({},{get:(e,t,r)=>{if(P.indexOf(t)>=0)return Reflect.get(e,t,r);const n=String(t),i=this.getEvent(n);if(i)return i;throw new Error(`unknown contract event: ${n}`)}});return(0,a.defineProperties)(this,{filters:g}),(0,a.defineProperties)(this,{fallback:o.receive||o.fallback?new b(this):null}),new Proxy(this,{get:(e,t,r)=>{if(t in e||P.indexOf(t)>=0)return Reflect.get(e,t,r);const n=String(t),i=e.getFunction(n);if(i)return i;throw new Error(`unknown contract method: ${n}`)}})}connect(e){return new I(this.target,this.interface,e)}async getAddress(){return await k(this).addrPromise}async getDeployedCode(){const e=m(this.runner);(0,a.assert)(e,"runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"getDeployedCode"});const t=await e.getCode(await this.getAddress());return"0x"===t?null:t}async waitForDeployment(){const e=this.deploymentTransaction();if(e)return await e.wait(),this;if(null!=await this.getDeployedCode())return this;const t=m(this.runner);return(0,a.assert)(null!=t,"contract runner does not support .provider","UNSUPPORTED_OPERATION",{operation:"waitForDeployment"}),new Promise(((e,r)=>{const n=async()=>{try{if(null!=await this.getDeployedCode())return e(this);t.once("block",n)}catch(e){r(e)}};n()}))}deploymentTransaction(){return k(this).deployTx}getFunction(e){return"string"!=typeof e&&(e=e.format()),new v(this,e)}getEvent(e){return"string"!=typeof e&&(e=e.format()),new w(this,e)}async queryTransaction(e){throw new Error("@TODO")}async queryFilter(e,t,r){null==t&&(t=0),null==r&&(r="latest");const{addr:n,addrPromise:i}=k(this),u=n||await i,{fragment:c,topics:l}=await E(this,e),f={address:u,topics:l,fromBlock:t,toBlock:r},h=m(this.runner);return(0,a.assert)(h,"contract runner does not have a provider","UNSUPPORTED_OPERATION",{operation:"queryFilter"}),(await h.getLogs(f)).map((e=>{let t=c;if(null==t)try{t=this.interface.getEvent(e.topics[0])}catch(e){}return t?new s.EventLog(e,this.interface,t):new o.Log(e,h)}))}async on(e,t){const r=await M(this,"on",e);return r.listeners.push({listener:t,once:!1}),r.start(),this}async once(e,t){const r=await M(this,"once",e);return r.listeners.push({listener:t,once:!0}),r.start(),this}async emit(e,...t){return await x(this,e,t,null)}async listenerCount(e){if(e){const t=await _(this,e);return t?t.listeners.length:0}const{subs:t}=k(this);let r=0;for(const{listeners:e}of t.values())r+=e.length;return r}async listeners(e){if(e){const t=await _(this,e);return t?t.listeners.map((({listener:e})=>e)):[]}const{subs:t}=k(this);let r=[];for(const{listeners:e}of t.values())r=r.concat(e.map((({listener:e})=>e)));return r}async off(e,t){const r=await _(this,e);if(!r)return this;if(t){const e=r.listeners.map((({listener:e})=>e)).indexOf(t);e>=0&&r.listeners.splice(e,1)}return null!=t&&0!==r.listeners.length||(r.stop(),k(this).subs.delete(r.tag)),this}async removeAllListeners(e){if(e){const t=await _(this,e);if(!t)return this;t.stop(),k(this).subs.delete(t.tag)}else{const{subs:e}=k(this);for(const{tag:t,stop:r}of e.values())r(),e.delete(t)}return this}async addListener(e,t){return await this.on(e,t)}async removeListener(e,t){return await this.off(e,t)}static buildClass(e){return class extends I{constructor(t,r=null){super(t,e,r)}}}static from(e,t,r){null==r&&(r=null);return new this(e,t,r)}}t.BaseContract=I;class O extends(function(){return I}()){}t.Contract=O},31018:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ContractFactory=void 0;const n=r(93707),i=r(45475),o=r(42120),a=r(44350);class s{interface;bytecode;runner;constructor(e,t,r){const i=n.Interface.from(e);t instanceof Uint8Array||("object"==typeof t&&(t=t.object),t.startsWith("0x")||(t="0x"+t)),t=(0,o.hexlify)((0,o.getBytes)(t)),(0,o.defineProperties)(this,{bytecode:t,interface:i,runner:r||null})}async getDeployTransaction(...e){let t={};const r=this.interface.deploy;if(r.inputs.length+1===e.length&&(t=await(0,a.copyOverrides)(e.pop())),r.inputs.length!==e.length)throw new Error("incorrect number of arguments to constructor");const n=await(0,a.resolveArgs)(this.runner,r.inputs,e),i=(0,o.concat)([this.bytecode,this.interface.encodeDeploy(n)]);return Object.assign({},t,{data:i})}async deploy(...e){const t=await this.getDeployTransaction(...e);(0,o.assert)(this.runner&&"function"==typeof this.runner.sendTransaction,"factory runner does not support sending transactions","UNSUPPORTED_OPERATION",{operation:"sendTransaction"});const r=await this.runner.sendTransaction(t),n=(0,i.getCreateAddress)(r);return new a.BaseContract(n,this.interface,this.runner,r)}connect(e){return new s(this.interface,this.bytecode,e)}static fromSolidity(e,t){(0,o.assertArgument)(null!=e,"bad compiler output","output",e),"string"==typeof e&&(e=JSON.parse(e));const r=e.abi;let n="";return e.bytecode?n=e.bytecode:e.evm&&e.evm.bytecode&&(n=e.evm.bytecode),new this(r,n,t)}}t.ContractFactory=s},37252:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EventLog=t.ContractTransactionResponse=t.ContractTransactionReceipt=t.ContractUnknownEventPayload=t.ContractEventPayload=t.ContractFactory=t.Contract=t.BaseContract=void 0;var n=r(44350);Object.defineProperty(t,"BaseContract",{enumerable:!0,get:function(){return n.BaseContract}}),Object.defineProperty(t,"Contract",{enumerable:!0,get:function(){return n.Contract}});var i=r(31018);Object.defineProperty(t,"ContractFactory",{enumerable:!0,get:function(){return i.ContractFactory}});var o=r(97151);Object.defineProperty(t,"ContractEventPayload",{enumerable:!0,get:function(){return o.ContractEventPayload}}),Object.defineProperty(t,"ContractUnknownEventPayload",{enumerable:!0,get:function(){return o.ContractUnknownEventPayload}}),Object.defineProperty(t,"ContractTransactionReceipt",{enumerable:!0,get:function(){return o.ContractTransactionReceipt}}),Object.defineProperty(t,"ContractTransactionResponse",{enumerable:!0,get:function(){return o.ContractTransactionResponse}}),Object.defineProperty(t,"EventLog",{enumerable:!0,get:function(){return o.EventLog}})},97151:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ContractEventPayload=t.ContractUnknownEventPayload=t.ContractTransactionResponse=t.ContractTransactionReceipt=t.EventLog=void 0;const n=r(37143),i=r(42120);class o extends n.Log{interface;fragment;args;constructor(e,t,r){super(e,e.provider);const n=t.decodeEventLog(r,e.data,e.topics);(0,i.defineProperties)(this,{args:n,fragment:r,interface:t})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}t.EventLog=o;class a extends n.TransactionReceipt{#b;constructor(e,t,r){super(r,t),this.#b=e}get logs(){return super.logs.map((e=>{const t=e.topics.length?this.#b.getEvent(e.topics[0]):null;return t?new o(e,this.#b,t):e}))}}t.ContractTransactionReceipt=a;class s extends n.TransactionResponse{#b;constructor(e,t,r){super(r,t),this.#b=e}async wait(e){const t=await super.wait();return null==t?null:new a(this.#b,this.provider,t)}}t.ContractTransactionResponse=s;class u extends i.EventPayload{log;constructor(e,t,r,n){super(e,t,r),(0,i.defineProperties)(this,{log:n})}async getBlock(){return await this.log.getBlock()}async getTransaction(){return await this.log.getTransaction()}async getTransactionReceipt(){return await this.log.getTransactionReceipt()}}t.ContractUnknownEventPayload=u;t.ContractEventPayload=class extends u{constructor(e,t,r,n,a){super(e,t,r,new o(a,e.interface,n));const s=e.interface.decodeEventLog(n,this.log.data,this.log.topics);(0,i.defineProperties)(this,{args:s,fragment:n})}get eventName(){return this.fragment.name}get eventSignature(){return this.fragment.format()}}},84862:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.randomBytes=t.pbkdf2Sync=t.createHmac=t.createHash=void 0;var n=r(55835);Object.defineProperty(t,"createHash",{enumerable:!0,get:function(){return n.createHash}}),Object.defineProperty(t,"createHmac",{enumerable:!0,get:function(){return n.createHmac}}),Object.defineProperty(t,"pbkdf2Sync",{enumerable:!0,get:function(){return n.pbkdf2Sync}}),Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return n.randomBytes}})},76117:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.computeHmac=void 0;const n=r(84862),i=r(42120);let o=!1;const a=function(e,t,r){return(0,n.createHmac)(e,t).update(r).digest()};let s=a;function u(e,t,r){const n=(0,i.getBytes)(t,"key"),o=(0,i.getBytes)(r,"data");return(0,i.hexlify)(s(e,n,o))}t.computeHmac=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new Error("computeHmac is locked");s=e},Object.freeze(u)},96965:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.lock=t.Signature=t.SigningKey=t.scryptSync=t.scrypt=t.pbkdf2=t.sha512=t.sha256=t.ripemd160=t.keccak256=t.randomBytes=t.computeHmac=void 0;const n=r(76117);Object.defineProperty(t,"computeHmac",{enumerable:!0,get:function(){return n.computeHmac}});const i=r(33037);Object.defineProperty(t,"keccak256",{enumerable:!0,get:function(){return i.keccak256}});const o=r(7990);Object.defineProperty(t,"ripemd160",{enumerable:!0,get:function(){return o.ripemd160}});const a=r(64989);Object.defineProperty(t,"pbkdf2",{enumerable:!0,get:function(){return a.pbkdf2}});const s=r(62385);Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return s.randomBytes}});const u=r(16168);Object.defineProperty(t,"scrypt",{enumerable:!0,get:function(){return u.scrypt}}),Object.defineProperty(t,"scryptSync",{enumerable:!0,get:function(){return u.scryptSync}});const c=r(69233);Object.defineProperty(t,"sha256",{enumerable:!0,get:function(){return c.sha256}}),Object.defineProperty(t,"sha512",{enumerable:!0,get:function(){return c.sha512}});var l=r(33106);Object.defineProperty(t,"SigningKey",{enumerable:!0,get:function(){return l.SigningKey}});var f=r(63295);Object.defineProperty(t,"Signature",{enumerable:!0,get:function(){return f.Signature}}),t.lock=function(){n.computeHmac.lock(),i.keccak256.lock(),a.pbkdf2.lock(),s.randomBytes.lock(),o.ripemd160.lock(),u.scrypt.lock(),u.scryptSync.lock(),c.sha256.lock(),c.sha512.lock(),s.randomBytes.lock()}},33037:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.keccak256=void 0;const n=r(85426),i=r(42120);let o=!1;const a=function(e){return(0,n.keccak_256)(e)};let s=a;function u(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(s(t))}t.keccak256=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new TypeError("keccak256 is locked");s=e},Object.freeze(u)},64989:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pbkdf2=void 0;const n=r(84862),i=r(42120);let o=!1;const a=function(e,t,r,i,o){return(0,n.pbkdf2Sync)(e,t,r,i,o)};let s=a;function u(e,t,r,n,o){const a=(0,i.getBytes)(e,"password"),u=(0,i.getBytes)(t,"salt");return(0,i.hexlify)(s(a,u,r,n,o))}t.pbkdf2=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new Error("pbkdf2 is locked");s=e},Object.freeze(u)},62385:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.randomBytes=void 0;const n=r(84862);let i=!1;const o=function(e){return new Uint8Array((0,n.randomBytes)(e))};let a=o;function s(e){return a(e)}t.randomBytes=s,s._=o,s.lock=function(){i=!0},s.register=function(e){if(i)throw new Error("randomBytes is locked");a=e},Object.freeze(s)},7990:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ripemd160=void 0;const n=r(70830),i=r(42120);let o=!1;const a=function(e){return(0,n.ripemd160)(e)};let s=a;function u(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(s(t))}t.ripemd160=u,u._=a,u.lock=function(){o=!0},u.register=function(e){if(o)throw new TypeError("ripemd160 is locked");s=e},Object.freeze(u)},16168:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.scryptSync=t.scrypt=void 0;const n=r(69514),i=r(42120);let o=!1,a=!1;const s=async function(e,t,r,i,o,a,s){return await(0,n.scryptAsync)(e,t,{N:r,r:i,p:o,dkLen:a,onProgress:s})},u=function(e,t,r,i,o,a){return(0,n.scrypt)(e,t,{N:r,r:i,p:o,dkLen:a})};let c=s,l=u;async function f(e,t,r,n,o,a,s){const u=(0,i.getBytes)(e,"passwd"),l=(0,i.getBytes)(t,"salt");return(0,i.hexlify)(await c(u,l,r,n,o,a,s))}function h(e,t,r,n,o,a){const s=(0,i.getBytes)(e,"passwd"),u=(0,i.getBytes)(t,"salt");return(0,i.hexlify)(l(s,u,r,n,o,a))}t.scrypt=f,f._=s,f.lock=function(){a=!0},f.register=function(e){if(a)throw new Error("scrypt is locked");c=e},Object.freeze(f),t.scryptSync=h,h._=u,h.lock=function(){o=!0},h.register=function(e){if(o)throw new Error("scryptSync is locked");l=e},Object.freeze(h)},69233:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha512=t.sha256=void 0;const n=r(84862),i=r(42120),o=function(e){return(0,n.createHash)("sha256").update(e).digest()},a=function(e){return(0,n.createHash)("sha512").update(e).digest()};let s=o,u=a,c=!1,l=!1;function f(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(s(t))}function h(e){const t=(0,i.getBytes)(e,"data");return(0,i.hexlify)(u(t))}t.sha256=f,f._=o,f.lock=function(){c=!0},f.register=function(e){if(c)throw new Error("sha256 is locked");s=e},Object.freeze(f),t.sha512=h,h._=a,h.lock=function(){l=!0},h.register=function(e){if(l)throw new Error("sha512 is locked");u=e},Object.freeze(f)},63295:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Signature=void 0;const n=r(30087),i=r(42120),o=BigInt(0),a=BigInt(1),s=BigInt(2),u=BigInt(27),c=BigInt(28),l=BigInt(35),f={};function h(e){return(0,i.zeroPadValue)((0,i.toBeArray)(e),32)}class d{#v;#w;#A;#S;get r(){return this.#v}set r(e){(0,i.assertArgument)(32===(0,i.dataLength)(e),"invalid r","value",e),this.#v=(0,i.hexlify)(e)}get s(){return this.#w}set s(e){(0,i.assertArgument)(32===(0,i.dataLength)(e),"invalid r","value",e);const t=(0,i.hexlify)(e);(0,i.assertArgument)(parseInt(t.substring(0,3))<8,"non-canonical s","value",t),this.#w=t}get v(){return this.#A}set v(e){const t=(0,i.getNumber)(e,"value");(0,i.assertArgument)(27===t||28===t,"invalid v","v",e),this.#A=t}get networkV(){return this.#S}get legacyChainId(){const e=this.networkV;return null==e?null:d.getChainId(e)}get yParity(){return 27===this.v?0:1}get yParityAndS(){const e=(0,i.getBytes)(this.s);return this.yParity&&(e[0]|=128),(0,i.hexlify)(e)}get compactSerialized(){return(0,i.concat)([this.r,this.yParityAndS])}get serialized(){return(0,i.concat)([this.r,this.s,this.yParity?"0x1c":"0x1b"])}constructor(e,t,r,n){(0,i.assertPrivate)(e,f,"Signature"),this.#v=t,this.#w=r,this.#A=n,this.#S=null}[Symbol.for("nodejs.util.inspect.custom")](){return`Signature { r: "${this.r}", s: "${this.s}", yParity: ${this.yParity}, networkV: ${this.networkV} }`}clone(){const e=new d(f,this.r,this.s,this.v);return this.networkV&&(e.#S=this.networkV),e}toJSON(){const e=this.networkV;return{_type:"signature",networkV:null!=e?e.toString():null,r:this.r,s:this.s,v:this.v}}static getChainId(e){const t=(0,i.getBigInt)(e,"v");return t==u||t==c?o:((0,i.assertArgument)(t>=l,"invalid EIP-155 v","v",e),(t-l)/s)}static getChainIdV(e,t){return(0,i.getBigInt)(e)*s+BigInt(35+t-27)}static getNormalizedV(e){const t=(0,i.getBigInt)(e);return t===o||t===u?27:t===a||t===c?28:((0,i.assertArgument)(t>=l,"invalid v","v",e),t&a?27:28)}static from(e){function t(t,r){(0,i.assertArgument)(t,r,"signature",e)}if(null==e)return new d(f,n.ZeroHash,n.ZeroHash,27);if("string"==typeof e){const r=(0,i.getBytes)(e,"signature");if(64===r.length){const e=(0,i.hexlify)(r.slice(0,32)),t=r.slice(32,64),n=128&t[0]?28:27;return t[0]&=127,new d(f,e,(0,i.hexlify)(t),n)}if(65===r.length){const e=(0,i.hexlify)(r.slice(0,32)),n=r.slice(32,64);t(0==(128&n[0]),"non-canonical s");const o=d.getNormalizedV(r[64]);return new d(f,e,(0,i.hexlify)(n),o)}t(!1,"invalid raw signature length")}if(e instanceof d)return e.clone();const r=e.r;t(null!=r,"missing r");const o=h(r),a=function(e,r){if(null!=e)return h(e);if(null!=r){t((0,i.isHexString)(r,32),"invalid yParityAndS");const e=(0,i.getBytes)(r);return e[0]&=127,(0,i.hexlify)(e)}t(!1,"missing s")}(e.s,e.yParityAndS);t(0==(128&(0,i.getBytes)(a)[0]),"non-canonical s");const{networkV:s,v:u}=function(e,r,n){if(null!=e){const t=(0,i.getBigInt)(e);return{networkV:t>=l?t:void 0,v:d.getNormalizedV(t)}}if(null!=r)return t((0,i.isHexString)(r,32),"invalid yParityAndS"),{v:128&(0,i.getBytes)(r)[0]?28:27};if(null!=n){switch(n){case 0:return{v:27};case 1:return{v:28}}t(!1,"invalid yParity")}t(!1,"missing v")}(e.v,e.yParityAndS,e.yParity),c=new d(f,o,a,u);return s&&(c.#S=s),t(!("yParity"in e&&e.yParity!==c.yParity),"yParity mismatch"),t(!("yParityAndS"in e&&e.yParityAndS!==c.yParityAndS),"yParityAndS mismatch"),c}}t.Signature=d},33106:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.SigningKey=void 0;const a=o(r(79656)),s=r(42120),u=r(76117),c=r(63295);a.utils.hmacSha256Sync=function(e,...t){return(0,s.getBytes)((0,u.computeHmac)("sha256",e,(0,s.concat)(t)))};class l{#k;constructor(e){(0,s.assertArgument)(32===(0,s.dataLength)(e),"invalid private key","privateKey","[REDACTED]"),this.#k=(0,s.hexlify)(e)}get privateKey(){return this.#k}get publicKey(){return l.computePublicKey(this.#k)}get compressedPublicKey(){return l.computePublicKey(this.#k,!0)}sign(e){(0,s.assertArgument)(32===(0,s.dataLength)(e),"invalid digest length","digest",e);const[t,r]=a.signSync((0,s.getBytesCopy)(e),(0,s.getBytesCopy)(this.#k),{recovered:!0,canonical:!0}),n=a.Signature.fromHex(t);return c.Signature.from({r:(0,s.toBeHex)("0x"+n.r.toString(16),32),s:(0,s.toBeHex)("0x"+n.s.toString(16),32),v:r?28:27})}computeSharedSecret(e){const t=l.computePublicKey(e);return console.log(t),(0,s.hexlify)(a.getSharedSecret((0,s.getBytesCopy)(this.#k),(0,s.getBytes)(t)))}static computePublicKey(e,t){let r=(0,s.getBytes)(e,"key");if(32===r.length){const e=a.getPublicKey(r,!!t);return(0,s.hexlify)(e)}if(64===r.length){const e=new Uint8Array(65);e[0]=4,e.set(r,1),r=e}const n=a.Point.fromHex(r);return(0,s.hexlify)(n.toRawBytes(t))}static recoverPublicKey(e,t){(0,s.assertArgument)(32===(0,s.dataLength)(e),"invalid digest length","digest",e);const r=c.Signature.from(t),n=a.Signature.fromCompact((0,s.getBytesCopy)((0,s.concat)([r.r,r.s]))).toDERRawBytes(),i=a.recoverPublicKey((0,s.getBytesCopy)(e),n,r.yParity);if(null!=i)return(0,s.hexlify)(i);(0,s.assertArgument)(!1,"invalid signautre for digest","signature",t)}static addPoints(e,t,r){const n=a.Point.fromHex(l.computePublicKey(e).substring(2)),i=a.Point.fromHex(l.computePublicKey(t).substring(2));return"0x"+n.add(i).toHex(!!r)}}t.SigningKey=l},81097:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha256=t.ripemd160=t.keccak256=t.randomBytes=t.computeHmac=t.EventLog=t.ContractUnknownEventPayload=t.ContractTransactionResponse=t.ContractTransactionReceipt=t.ContractEventPayload=t.ContractFactory=t.Contract=t.BaseContract=t.MessagePrefix=t.EtherSymbol=t.ZeroHash=t.N=t.MaxInt256=t.MinInt256=t.MaxUint256=t.WeiPerEther=t.ZeroAddress=t.resolveAddress=t.isAddress=t.isAddressable=t.getCreate2Address=t.getCreateAddress=t.getIcapAddress=t.getAddress=t.Typed=t.TransactionDescription=t.Result=t.LogDescription=t.Interface=t.Indexed=t.ErrorDescription=t.checkResultErrors=t.StructFragment=t.ParamType=t.NamedFragment=t.FunctionFragment=t.FallbackFragment=t.Fragment=t.EventFragment=t.ErrorFragment=t.ConstructorFragment=t.AbiCoder=t.encodeBytes32String=t.decodeBytes32String=t.version=void 0,t.GasCostPlugin=t.FeeDataNetworkPlugin=t.EtherscanPlugin=t.EnsPlugin=t.Network=t.EnsResolver=t.WebSocketProvider=t.SocketProvider=t.IpcSocketProvider=t.QuickNodeProvider=t.PocketProvider=t.InfuraWebSocketProvider=t.InfuraProvider=t.EtherscanProvider=t.CloudflareProvider=t.AnkrProvider=t.AlchemyProvider=t.BrowserProvider=t.JsonRpcSigner=t.JsonRpcProvider=t.JsonRpcApiProvider=t.FallbackProvider=t.AbstractProvider=t.VoidSigner=t.NonceManager=t.AbstractSigner=t.TransactionResponse=t.TransactionReceipt=t.Log=t.FeeData=t.Block=t.getDefaultProvider=t.TypedDataEncoder=t.solidityPackedSha256=t.solidityPackedKeccak256=t.solidityPacked=t.verifyMessage=t.hashMessage=t.dnsEncode=t.namehash=t.isValidName=t.ensNormalize=t.id=t.SigningKey=t.Signature=t.lock=t.scryptSync=t.scrypt=t.pbkdf2=t.sha512=void 0,t.toQuantity=t.toNumber=t.toBeHex=t.toBigInt=t.toBeArray=t.getUint=t.getNumber=t.getBigInt=t.FixedNumber=t.FetchCancelSignal=t.FetchResponse=t.FetchRequest=t.EventPayload=t.isError=t.isCallException=t.makeError=t.assertPrivate=t.assertNormalize=t.assertArgumentCount=t.assertArgument=t.assert=t.resolveProperties=t.defineProperties=t.zeroPadValue=t.zeroPadBytes=t.stripZerosLeft=t.isBytesLike=t.isHexString=t.hexlify=t.getBytesCopy=t.getBytes=t.dataSlice=t.dataLength=t.concat=t.encodeBase64=t.decodeBase64=t.encodeBase58=t.decodeBase58=t.Transaction=t.recoverAddress=t.computeAddress=t.accessListify=t.showThrottleMessage=t.copyRequest=t.UnmanagedSubscriber=t.SocketSubscriber=t.SocketPendingSubscriber=t.SocketEventSubscriber=t.SocketBlockSubscriber=t.NetworkPlugin=void 0,t.wordlists=t.WordlistOwlA=t.WordlistOwl=t.LangEn=t.Wordlist=t.encryptKeystoreJsonSync=t.encryptKeystoreJson=t.decryptKeystoreJson=t.decryptKeystoreJsonSync=t.decryptCrowdsaleJson=t.isKeystoreJson=t.isCrowdsaleJson=t.getAccountPath=t.defaultPath=t.Wallet=t.HDNodeVoidWallet=t.HDNodeWallet=t.BaseWallet=t.Mnemonic=t.uuidV4=t.encodeRlp=t.decodeRlp=t.Utf8ErrorFuncs=t.toUtf8String=t.toUtf8CodePoints=t.toUtf8Bytes=t.parseUnits=t.formatUnits=t.parseEther=t.formatEther=t.mask=t.toTwos=t.fromTwos=void 0;var n=r(79406);Object.defineProperty(t,"version",{enumerable:!0,get:function(){return n.version}});var i=r(93707);Object.defineProperty(t,"decodeBytes32String",{enumerable:!0,get:function(){return i.decodeBytes32String}}),Object.defineProperty(t,"encodeBytes32String",{enumerable:!0,get:function(){return i.encodeBytes32String}}),Object.defineProperty(t,"AbiCoder",{enumerable:!0,get:function(){return i.AbiCoder}}),Object.defineProperty(t,"ConstructorFragment",{enumerable:!0,get:function(){return i.ConstructorFragment}}),Object.defineProperty(t,"ErrorFragment",{enumerable:!0,get:function(){return i.ErrorFragment}}),Object.defineProperty(t,"EventFragment",{enumerable:!0,get:function(){return i.EventFragment}}),Object.defineProperty(t,"Fragment",{enumerable:!0,get:function(){return i.Fragment}}),Object.defineProperty(t,"FallbackFragment",{enumerable:!0,get:function(){return i.FallbackFragment}}),Object.defineProperty(t,"FunctionFragment",{enumerable:!0,get:function(){return i.FunctionFragment}}),Object.defineProperty(t,"NamedFragment",{enumerable:!0,get:function(){return i.NamedFragment}}),Object.defineProperty(t,"ParamType",{enumerable:!0,get:function(){return i.ParamType}}),Object.defineProperty(t,"StructFragment",{enumerable:!0,get:function(){return i.StructFragment}}),Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return i.checkResultErrors}}),Object.defineProperty(t,"ErrorDescription",{enumerable:!0,get:function(){return i.ErrorDescription}}),Object.defineProperty(t,"Indexed",{enumerable:!0,get:function(){return i.Indexed}}),Object.defineProperty(t,"Interface",{enumerable:!0,get:function(){return i.Interface}}),Object.defineProperty(t,"LogDescription",{enumerable:!0,get:function(){return i.LogDescription}}),Object.defineProperty(t,"Result",{enumerable:!0,get:function(){return i.Result}}),Object.defineProperty(t,"TransactionDescription",{enumerable:!0,get:function(){return i.TransactionDescription}}),Object.defineProperty(t,"Typed",{enumerable:!0,get:function(){return i.Typed}});var o=r(45475);Object.defineProperty(t,"getAddress",{enumerable:!0,get:function(){return o.getAddress}}),Object.defineProperty(t,"getIcapAddress",{enumerable:!0,get:function(){return o.getIcapAddress}}),Object.defineProperty(t,"getCreateAddress",{enumerable:!0,get:function(){return o.getCreateAddress}}),Object.defineProperty(t,"getCreate2Address",{enumerable:!0,get:function(){return o.getCreate2Address}}),Object.defineProperty(t,"isAddressable",{enumerable:!0,get:function(){return o.isAddressable}}),Object.defineProperty(t,"isAddress",{enumerable:!0,get:function(){return o.isAddress}}),Object.defineProperty(t,"resolveAddress",{enumerable:!0,get:function(){return o.resolveAddress}});var a=r(30087);Object.defineProperty(t,"ZeroAddress",{enumerable:!0,get:function(){return a.ZeroAddress}}),Object.defineProperty(t,"WeiPerEther",{enumerable:!0,get:function(){return a.WeiPerEther}}),Object.defineProperty(t,"MaxUint256",{enumerable:!0,get:function(){return a.MaxUint256}}),Object.defineProperty(t,"MinInt256",{enumerable:!0,get:function(){return a.MinInt256}}),Object.defineProperty(t,"MaxInt256",{enumerable:!0,get:function(){return a.MaxInt256}}),Object.defineProperty(t,"N",{enumerable:!0,get:function(){return a.N}}),Object.defineProperty(t,"ZeroHash",{enumerable:!0,get:function(){return a.ZeroHash}}),Object.defineProperty(t,"EtherSymbol",{enumerable:!0,get:function(){return a.EtherSymbol}}),Object.defineProperty(t,"MessagePrefix",{enumerable:!0,get:function(){return a.MessagePrefix}});var s=r(37252);Object.defineProperty(t,"BaseContract",{enumerable:!0,get:function(){return s.BaseContract}}),Object.defineProperty(t,"Contract",{enumerable:!0,get:function(){return s.Contract}}),Object.defineProperty(t,"ContractFactory",{enumerable:!0,get:function(){return s.ContractFactory}}),Object.defineProperty(t,"ContractEventPayload",{enumerable:!0,get:function(){return s.ContractEventPayload}}),Object.defineProperty(t,"ContractTransactionReceipt",{enumerable:!0,get:function(){return s.ContractTransactionReceipt}}),Object.defineProperty(t,"ContractTransactionResponse",{enumerable:!0,get:function(){return s.ContractTransactionResponse}}),Object.defineProperty(t,"ContractUnknownEventPayload",{enumerable:!0,get:function(){return s.ContractUnknownEventPayload}}),Object.defineProperty(t,"EventLog",{enumerable:!0,get:function(){return s.EventLog}});var u=r(96965);Object.defineProperty(t,"computeHmac",{enumerable:!0,get:function(){return u.computeHmac}}),Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return u.randomBytes}}),Object.defineProperty(t,"keccak256",{enumerable:!0,get:function(){return u.keccak256}}),Object.defineProperty(t,"ripemd160",{enumerable:!0,get:function(){return u.ripemd160}}),Object.defineProperty(t,"sha256",{enumerable:!0,get:function(){return u.sha256}}),Object.defineProperty(t,"sha512",{enumerable:!0,get:function(){return u.sha512}}),Object.defineProperty(t,"pbkdf2",{enumerable:!0,get:function(){return u.pbkdf2}}),Object.defineProperty(t,"scrypt",{enumerable:!0,get:function(){return u.scrypt}}),Object.defineProperty(t,"scryptSync",{enumerable:!0,get:function(){return u.scryptSync}}),Object.defineProperty(t,"lock",{enumerable:!0,get:function(){return u.lock}}),Object.defineProperty(t,"Signature",{enumerable:!0,get:function(){return u.Signature}}),Object.defineProperty(t,"SigningKey",{enumerable:!0,get:function(){return u.SigningKey}});var c=r(98336);Object.defineProperty(t,"id",{enumerable:!0,get:function(){return c.id}}),Object.defineProperty(t,"ensNormalize",{enumerable:!0,get:function(){return c.ensNormalize}}),Object.defineProperty(t,"isValidName",{enumerable:!0,get:function(){return c.isValidName}}),Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return c.namehash}}),Object.defineProperty(t,"dnsEncode",{enumerable:!0,get:function(){return c.dnsEncode}}),Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return c.hashMessage}}),Object.defineProperty(t,"verifyMessage",{enumerable:!0,get:function(){return c.verifyMessage}}),Object.defineProperty(t,"solidityPacked",{enumerable:!0,get:function(){return c.solidityPacked}}),Object.defineProperty(t,"solidityPackedKeccak256",{enumerable:!0,get:function(){return c.solidityPackedKeccak256}}),Object.defineProperty(t,"solidityPackedSha256",{enumerable:!0,get:function(){return c.solidityPackedSha256}}),Object.defineProperty(t,"TypedDataEncoder",{enumerable:!0,get:function(){return c.TypedDataEncoder}});var l=r(4878);Object.defineProperty(t,"getDefaultProvider",{enumerable:!0,get:function(){return l.getDefaultProvider}}),Object.defineProperty(t,"Block",{enumerable:!0,get:function(){return l.Block}}),Object.defineProperty(t,"FeeData",{enumerable:!0,get:function(){return l.FeeData}}),Object.defineProperty(t,"Log",{enumerable:!0,get:function(){return l.Log}}),Object.defineProperty(t,"TransactionReceipt",{enumerable:!0,get:function(){return l.TransactionReceipt}}),Object.defineProperty(t,"TransactionResponse",{enumerable:!0,get:function(){return l.TransactionResponse}}),Object.defineProperty(t,"AbstractSigner",{enumerable:!0,get:function(){return l.AbstractSigner}}),Object.defineProperty(t,"NonceManager",{enumerable:!0,get:function(){return l.NonceManager}}),Object.defineProperty(t,"VoidSigner",{enumerable:!0,get:function(){return l.VoidSigner}}),Object.defineProperty(t,"AbstractProvider",{enumerable:!0,get:function(){return l.AbstractProvider}}),Object.defineProperty(t,"FallbackProvider",{enumerable:!0,get:function(){return l.FallbackProvider}}),Object.defineProperty(t,"JsonRpcApiProvider",{enumerable:!0,get:function(){return l.JsonRpcApiProvider}}),Object.defineProperty(t,"JsonRpcProvider",{enumerable:!0,get:function(){return l.JsonRpcProvider}}),Object.defineProperty(t,"JsonRpcSigner",{enumerable:!0,get:function(){return l.JsonRpcSigner}}),Object.defineProperty(t,"BrowserProvider",{enumerable:!0,get:function(){return l.BrowserProvider}}),Object.defineProperty(t,"AlchemyProvider",{enumerable:!0,get:function(){return l.AlchemyProvider}}),Object.defineProperty(t,"AnkrProvider",{enumerable:!0,get:function(){return l.AnkrProvider}}),Object.defineProperty(t,"CloudflareProvider",{enumerable:!0,get:function(){return l.CloudflareProvider}}),Object.defineProperty(t,"EtherscanProvider",{enumerable:!0,get:function(){return l.EtherscanProvider}}),Object.defineProperty(t,"InfuraProvider",{enumerable:!0,get:function(){return l.InfuraProvider}}),Object.defineProperty(t,"InfuraWebSocketProvider",{enumerable:!0,get:function(){return l.InfuraWebSocketProvider}}),Object.defineProperty(t,"PocketProvider",{enumerable:!0,get:function(){return l.PocketProvider}}),Object.defineProperty(t,"QuickNodeProvider",{enumerable:!0,get:function(){return l.QuickNodeProvider}}),Object.defineProperty(t,"IpcSocketProvider",{enumerable:!0,get:function(){return l.IpcSocketProvider}}),Object.defineProperty(t,"SocketProvider",{enumerable:!0,get:function(){return l.SocketProvider}}),Object.defineProperty(t,"WebSocketProvider",{enumerable:!0,get:function(){return l.WebSocketProvider}}),Object.defineProperty(t,"EnsResolver",{enumerable:!0,get:function(){return l.EnsResolver}}),Object.defineProperty(t,"Network",{enumerable:!0,get:function(){return l.Network}}),Object.defineProperty(t,"EnsPlugin",{enumerable:!0,get:function(){return l.EnsPlugin}}),Object.defineProperty(t,"EtherscanPlugin",{enumerable:!0,get:function(){return l.EtherscanPlugin}}),Object.defineProperty(t,"FeeDataNetworkPlugin",{enumerable:!0,get:function(){return l.FeeDataNetworkPlugin}}),Object.defineProperty(t,"GasCostPlugin",{enumerable:!0,get:function(){return l.GasCostPlugin}}),Object.defineProperty(t,"NetworkPlugin",{enumerable:!0,get:function(){return l.NetworkPlugin}}),Object.defineProperty(t,"SocketBlockSubscriber",{enumerable:!0,get:function(){return l.SocketBlockSubscriber}}),Object.defineProperty(t,"SocketEventSubscriber",{enumerable:!0,get:function(){return l.SocketEventSubscriber}}),Object.defineProperty(t,"SocketPendingSubscriber",{enumerable:!0,get:function(){return l.SocketPendingSubscriber}}),Object.defineProperty(t,"SocketSubscriber",{enumerable:!0,get:function(){return l.SocketSubscriber}}),Object.defineProperty(t,"UnmanagedSubscriber",{enumerable:!0,get:function(){return l.UnmanagedSubscriber}}),Object.defineProperty(t,"copyRequest",{enumerable:!0,get:function(){return l.copyRequest}}),Object.defineProperty(t,"showThrottleMessage",{enumerable:!0,get:function(){return l.showThrottleMessage}});var f=r(2290);Object.defineProperty(t,"accessListify",{enumerable:!0,get:function(){return f.accessListify}}),Object.defineProperty(t,"computeAddress",{enumerable:!0,get:function(){return f.computeAddress}}),Object.defineProperty(t,"recoverAddress",{enumerable:!0,get:function(){return f.recoverAddress}}),Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return f.Transaction}});var h=r(42120);Object.defineProperty(t,"decodeBase58",{enumerable:!0,get:function(){return h.decodeBase58}}),Object.defineProperty(t,"encodeBase58",{enumerable:!0,get:function(){return h.encodeBase58}}),Object.defineProperty(t,"decodeBase64",{enumerable:!0,get:function(){return h.decodeBase64}}),Object.defineProperty(t,"encodeBase64",{enumerable:!0,get:function(){return h.encodeBase64}}),Object.defineProperty(t,"concat",{enumerable:!0,get:function(){return h.concat}}),Object.defineProperty(t,"dataLength",{enumerable:!0,get:function(){return h.dataLength}}),Object.defineProperty(t,"dataSlice",{enumerable:!0,get:function(){return h.dataSlice}}),Object.defineProperty(t,"getBytes",{enumerable:!0,get:function(){return h.getBytes}}),Object.defineProperty(t,"getBytesCopy",{enumerable:!0,get:function(){return h.getBytesCopy}}),Object.defineProperty(t,"hexlify",{enumerable:!0,get:function(){return h.hexlify}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return h.isHexString}}),Object.defineProperty(t,"isBytesLike",{enumerable:!0,get:function(){return h.isBytesLike}}),Object.defineProperty(t,"stripZerosLeft",{enumerable:!0,get:function(){return h.stripZerosLeft}}),Object.defineProperty(t,"zeroPadBytes",{enumerable:!0,get:function(){return h.zeroPadBytes}}),Object.defineProperty(t,"zeroPadValue",{enumerable:!0,get:function(){return h.zeroPadValue}}),Object.defineProperty(t,"defineProperties",{enumerable:!0,get:function(){return h.defineProperties}}),Object.defineProperty(t,"resolveProperties",{enumerable:!0,get:function(){return h.resolveProperties}}),Object.defineProperty(t,"assert",{enumerable:!0,get:function(){return h.assert}}),Object.defineProperty(t,"assertArgument",{enumerable:!0,get:function(){return h.assertArgument}}),Object.defineProperty(t,"assertArgumentCount",{enumerable:!0,get:function(){return h.assertArgumentCount}}),Object.defineProperty(t,"assertNormalize",{enumerable:!0,get:function(){return h.assertNormalize}}),Object.defineProperty(t,"assertPrivate",{enumerable:!0,get:function(){return h.assertPrivate}}),Object.defineProperty(t,"makeError",{enumerable:!0,get:function(){return h.makeError}}),Object.defineProperty(t,"isCallException",{enumerable:!0,get:function(){return h.isCallException}}),Object.defineProperty(t,"isError",{enumerable:!0,get:function(){return h.isError}}),Object.defineProperty(t,"EventPayload",{enumerable:!0,get:function(){return h.EventPayload}}),Object.defineProperty(t,"FetchRequest",{enumerable:!0,get:function(){return h.FetchRequest}}),Object.defineProperty(t,"FetchResponse",{enumerable:!0,get:function(){return h.FetchResponse}}),Object.defineProperty(t,"FetchCancelSignal",{enumerable:!0,get:function(){return h.FetchCancelSignal}}),Object.defineProperty(t,"FixedNumber",{enumerable:!0,get:function(){return h.FixedNumber}}),Object.defineProperty(t,"getBigInt",{enumerable:!0,get:function(){return h.getBigInt}}),Object.defineProperty(t,"getNumber",{enumerable:!0,get:function(){return h.getNumber}}),Object.defineProperty(t,"getUint",{enumerable:!0,get:function(){return h.getUint}}),Object.defineProperty(t,"toBeArray",{enumerable:!0,get:function(){return h.toBeArray}}),Object.defineProperty(t,"toBigInt",{enumerable:!0,get:function(){return h.toBigInt}}),Object.defineProperty(t,"toBeHex",{enumerable:!0,get:function(){return h.toBeHex}}),Object.defineProperty(t,"toNumber",{enumerable:!0,get:function(){return h.toNumber}}),Object.defineProperty(t,"toQuantity",{enumerable:!0,get:function(){return h.toQuantity}}),Object.defineProperty(t,"fromTwos",{enumerable:!0,get:function(){return h.fromTwos}}),Object.defineProperty(t,"toTwos",{enumerable:!0,get:function(){return h.toTwos}}),Object.defineProperty(t,"mask",{enumerable:!0,get:function(){return h.mask}}),Object.defineProperty(t,"formatEther",{enumerable:!0,get:function(){return h.formatEther}}),Object.defineProperty(t,"parseEther",{enumerable:!0,get:function(){return h.parseEther}}),Object.defineProperty(t,"formatUnits",{enumerable:!0,get:function(){return h.formatUnits}}),Object.defineProperty(t,"parseUnits",{enumerable:!0,get:function(){return h.parseUnits}}),Object.defineProperty(t,"toUtf8Bytes",{enumerable:!0,get:function(){return h.toUtf8Bytes}}),Object.defineProperty(t,"toUtf8CodePoints",{enumerable:!0,get:function(){return h.toUtf8CodePoints}}),Object.defineProperty(t,"toUtf8String",{enumerable:!0,get:function(){return h.toUtf8String}}),Object.defineProperty(t,"Utf8ErrorFuncs",{enumerable:!0,get:function(){return h.Utf8ErrorFuncs}}),Object.defineProperty(t,"decodeRlp",{enumerable:!0,get:function(){return h.decodeRlp}}),Object.defineProperty(t,"encodeRlp",{enumerable:!0,get:function(){return h.encodeRlp}}),Object.defineProperty(t,"uuidV4",{enumerable:!0,get:function(){return h.uuidV4}});var d=r(91602);Object.defineProperty(t,"Mnemonic",{enumerable:!0,get:function(){return d.Mnemonic}}),Object.defineProperty(t,"BaseWallet",{enumerable:!0,get:function(){return d.BaseWallet}}),Object.defineProperty(t,"HDNodeWallet",{enumerable:!0,get:function(){return d.HDNodeWallet}}),Object.defineProperty(t,"HDNodeVoidWallet",{enumerable:!0,get:function(){return d.HDNodeVoidWallet}}),Object.defineProperty(t,"Wallet",{enumerable:!0,get:function(){return d.Wallet}}),Object.defineProperty(t,"defaultPath",{enumerable:!0,get:function(){return d.defaultPath}}),Object.defineProperty(t,"getAccountPath",{enumerable:!0,get:function(){return d.getAccountPath}}),Object.defineProperty(t,"isCrowdsaleJson",{enumerable:!0,get:function(){return d.isCrowdsaleJson}}),Object.defineProperty(t,"isKeystoreJson",{enumerable:!0,get:function(){return d.isKeystoreJson}}),Object.defineProperty(t,"decryptCrowdsaleJson",{enumerable:!0,get:function(){return d.decryptCrowdsaleJson}}),Object.defineProperty(t,"decryptKeystoreJsonSync",{enumerable:!0,get:function(){return d.decryptKeystoreJsonSync}}),Object.defineProperty(t,"decryptKeystoreJson",{enumerable:!0,get:function(){return d.decryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJson",{enumerable:!0,get:function(){return d.encryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJsonSync",{enumerable:!0,get:function(){return d.encryptKeystoreJsonSync}});var p=r(60659);Object.defineProperty(t,"Wordlist",{enumerable:!0,get:function(){return p.Wordlist}}),Object.defineProperty(t,"LangEn",{enumerable:!0,get:function(){return p.LangEn}}),Object.defineProperty(t,"WordlistOwl",{enumerable:!0,get:function(){return p.WordlistOwl}}),Object.defineProperty(t,"WordlistOwlA",{enumerable:!0,get:function(){return p.WordlistOwlA}}),Object.defineProperty(t,"wordlists",{enumerable:!0,get:function(){return p.wordlists}})},52625:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.id=void 0;const n=r(96965),i=r(42120);t.id=function(e){return(0,n.keccak256)((0,i.toUtf8Bytes)(e))}},98336:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypedDataEncoder=t.solidityPackedSha256=t.solidityPackedKeccak256=t.solidityPacked=t.verifyMessage=t.hashMessage=t.dnsEncode=t.namehash=t.isValidName=t.ensNormalize=t.id=void 0;var n=r(52625);Object.defineProperty(t,"id",{enumerable:!0,get:function(){return n.id}});var i=r(85420);Object.defineProperty(t,"ensNormalize",{enumerable:!0,get:function(){return i.ensNormalize}}),Object.defineProperty(t,"isValidName",{enumerable:!0,get:function(){return i.isValidName}}),Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return i.namehash}}),Object.defineProperty(t,"dnsEncode",{enumerable:!0,get:function(){return i.dnsEncode}});var o=r(18043);Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return o.hashMessage}}),Object.defineProperty(t,"verifyMessage",{enumerable:!0,get:function(){return o.verifyMessage}});var a=r(18191);Object.defineProperty(t,"solidityPacked",{enumerable:!0,get:function(){return a.solidityPacked}}),Object.defineProperty(t,"solidityPackedKeccak256",{enumerable:!0,get:function(){return a.solidityPackedKeccak256}}),Object.defineProperty(t,"solidityPackedSha256",{enumerable:!0,get:function(){return a.solidityPackedSha256}});var s=r(58993);Object.defineProperty(t,"TypedDataEncoder",{enumerable:!0,get:function(){return s.TypedDataEncoder}})},18043:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.verifyMessage=t.hashMessage=void 0;const n=r(96965),i=r(30087),o=r(2290),a=r(42120);function s(e){return"string"==typeof e&&(e=(0,a.toUtf8Bytes)(e)),(0,n.keccak256)((0,a.concat)([(0,a.toUtf8Bytes)(i.MessagePrefix),(0,a.toUtf8Bytes)(String(e.length)),e]))}t.hashMessage=s,t.verifyMessage=function(e,t){const r=s(e);return(0,o.recoverAddress)(r,t)}},85420:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dnsEncode=t.namehash=t.isValidName=t.ensNormalize=void 0;const n=r(96965),i=r(42120),o=r(40030),a=new Uint8Array(32);function s(e){return(0,i.assertArgument)(0!==e.length,"invalid ENS name; empty component","comp",e),e}function u(e){const t=(0,i.toUtf8Bytes)(c(e)),r=[];if(0===e.length)return r;let n=0;for(let e=0;e{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"}},18191:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.solidityPackedSha256=t.solidityPackedKeccak256=t.solidityPacked=void 0;const n=r(45475),i=r(96965),o=r(42120),a=new RegExp("^bytes([0-9]+)$"),s=new RegExp("^(u?int)([0-9]*)$"),u=new RegExp("^(.*)\\[([0-9]*)\\]$");function c(e,t,r){switch(e){case"address":return r?(0,o.getBytes)((0,o.zeroPadValue)(t,32)):(0,o.getBytes)((0,n.getAddress)(t));case"string":return(0,o.toUtf8Bytes)(t);case"bytes":return(0,o.getBytes)(t);case"bool":return t=t?"0x01":"0x00",r?(0,o.getBytes)((0,o.zeroPadValue)(t,32)):(0,o.getBytes)(t)}let i=e.match(s);if(i){let n="int"===i[1],a=parseInt(i[2]||"256");return(0,o.assertArgument)((!i[2]||i[2]===String(a))&&a%8==0&&0!==a&&a<=256,"invalid number type","type",e),r&&(a=256),n&&(t=(0,o.toTwos)(t,a)),(0,o.getBytes)((0,o.zeroPadValue)((0,o.toBeArray)(t),a/8))}if(i=e.match(a),i){const n=parseInt(i[1]);return(0,o.assertArgument)(String(n)===i[1]&&0!==n&&n<=32,"invalid bytes type","type",e),(0,o.assertArgument)((0,o.dataLength)(t)===n,`invalid value for ${e}`,"value",t),r?(0,o.getBytes)((0,o.zeroPadBytes)(t,32)):t}if(i=e.match(u),i&&Array.isArray(t)){const r=i[1],n=parseInt(i[2]||String(t.length));(0,o.assertArgument)(n===t.length,`invalid array length for ${e}`,"value",t);const a=[];return t.forEach((function(e){a.push(c(r,e,!0))})),(0,o.getBytes)((0,o.concat)(a))}(0,o.assertArgument)(!1,"invalid type","type",e)}function l(e,t){(0,o.assertArgument)(e.length===t.length,"wrong number of values; expected ${ types.length }","values",t);const r=[];return e.forEach((function(e,n){r.push(c(e,t[n]))})),(0,o.hexlify)((0,o.concat)(r))}t.solidityPacked=l,t.solidityPackedKeccak256=function(e,t){return(0,i.keccak256)(l(e,t))},t.solidityPackedSha256=function(e,t){return(0,i.sha256)(l(e,t))}},58993:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypedDataEncoder=void 0;const n=r(45475),i=r(96965),o=r(42120),a=r(52625),s=new Uint8Array(32);s.fill(0);const u=BigInt(-1),c=BigInt(0),l=BigInt(1),f=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");const h=(0,o.toBeHex)(l,32),d=(0,o.toBeHex)(c,32),p={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},m=["name","version","chainId","verifyingContract","salt"];function y(e){return function(t){return(0,o.assertArgument)("string"==typeof t,`invalid domain value for ${JSON.stringify(e)}`,`domain.${e}`,t),t}}const g={name:y("name"),version:y("version"),chainId:function(e){return(0,o.getBigInt)(e,"domain.chainId")},verifyingContract:function(e){try{return(0,n.getAddress)(e).toLowerCase()}catch(e){}(0,o.assertArgument)(!1,'invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){const t=(0,o.getBytes)(e,"domain.salt");return(0,o.assertArgument)(32===t.length,'invalid domain value "salt"',"domain.salt",e),(0,o.hexlify)(t)}};function b(e){{const t=e.match(/^(u?)int(\d*)$/);if(t){const r=""===t[1],n=parseInt(t[2]||"256");(0,o.assertArgument)(n%8==0&&0!==n&&n<=256&&(null==t[2]||t[2]===String(n)),"invalid numeric width","type",e);const i=(0,o.mask)(f,r?n-1:n),a=r?(i+l)*u:c;return function(t){const r=(0,o.getBigInt)(t,"value");return(0,o.assertArgument)(r>=a&&r<=i,`value out-of-bounds for ${e}`,"value",r),(0,o.toBeHex)((0,o.toTwos)(r,256),32)}}}{const t=e.match(/^bytes(\d+)$/);if(t){const r=parseInt(t[1]);return(0,o.assertArgument)(0!==r&&r<=32&&t[1]===String(r),"invalid bytes width","type",e),function(t){const n=(0,o.getBytes)(t);return(0,o.assertArgument)(n.length===r,`invalid length for ${e}`,"value",t),function(e){const t=(0,o.getBytes)(e),r=t.length%32;return r?(0,o.concat)([t,s.slice(r)]):(0,o.hexlify)(t)}(t)}}}switch(e){case"address":return function(e){return(0,o.zeroPadValue)((0,n.getAddress)(e),32)};case"bool":return function(e){return e?h:d};case"bytes":return function(e){return(0,i.keccak256)(e)};case"string":return function(e){return(0,a.id)(e)}}return null}function v(e,t){return`${e}(${t.map((({name:e,type:t})=>t+" "+e)).join(",")})`}class w{primaryType;#E;get types(){return JSON.parse(this.#E)}#_;#M;constructor(e){this.#E=JSON.stringify(e),this.#_=new Map,this.#M=new Map;const t=new Map,r=new Map,n=new Map;Object.keys(e).forEach((e=>{t.set(e,new Set),r.set(e,[]),n.set(e,new Set)}));for(const n in e){const i=new Set;for(const a of e[n]){(0,o.assertArgument)(!i.has(a.name),`duplicate variable name ${JSON.stringify(a.name)} in ${JSON.stringify(n)}`,"types",e),i.add(a.name);const s=a.type.match(/^([^\x5b]*)(\x5b|$)/)[1]||null;(0,o.assertArgument)(s!==n,`circular type reference to ${JSON.stringify(s)}`,"types",e);b(s)||((0,o.assertArgument)(r.has(s),`unknown type ${JSON.stringify(s)}`,"types",e),r.get(s).push(n),t.get(n).add(s))}}const i=Array.from(r.keys()).filter((e=>0===r.get(e).length));(0,o.assertArgument)(0!==i.length,"missing primary type","types",e),(0,o.assertArgument)(1===i.length,`ambiguous primary types or unused types: ${i.map((e=>JSON.stringify(e))).join(", ")}`,"types",e),(0,o.defineProperties)(this,{primaryType:i[0]}),function i(a,s){(0,o.assertArgument)(!s.has(a),`circular type reference to ${JSON.stringify(a)}`,"types",e),s.add(a);for(const e of t.get(a))if(r.has(e)){i(e,s);for(const t of s)n.get(t).add(e)}s.delete(a)}(this.primaryType,new Set);for(const[t,r]of n){const n=Array.from(r);n.sort(),this.#_.set(t,v(t,e[t])+n.map((t=>v(t,e[t]))).join(""))}}getEncoder(e){let t=this.#M.get(e);return t||(t=this.#T(e),this.#M.set(e,t)),t}#T(e){{const t=b(e);if(t)return t}const t=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(t){const e=t[1],r=this.getEncoder(e);return n=>{(0,o.assertArgument)(!t[3]||parseInt(t[3])===n.length,`array length mismatch; expected length ${parseInt(t[3])}`,"value",n);let a=n.map(r);return this.#_.has(e)&&(a=a.map(i.keccak256)),(0,i.keccak256)((0,o.concat)(a))}}const r=this.types[e];if(r){const t=(0,a.id)(this.#_.get(e));return e=>{const n=r.map((({name:t,type:r})=>{const n=this.getEncoder(r)(e[t]);return this.#_.has(r)?(0,i.keccak256)(n):n}));return n.unshift(t),(0,o.concat)(n)}}(0,o.assertArgument)(!1,`unknown type: ${e}`,"type",e)}encodeType(e){const t=this.#_.get(e);return(0,o.assertArgument)(t,`unknown type: ${JSON.stringify(e)}`,"name",e),t}encodeData(e,t){return this.getEncoder(e)(t)}hashStruct(e,t){return(0,i.keccak256)(this.encodeData(e,t))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,t,r){if(b(e))return r(e,t);const n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n)return(0,o.assertArgument)(!n[3]||parseInt(n[3])===t.length,`array length mismatch; expected length ${parseInt(n[3])}`,"value",t),t.map((e=>this._visit(n[1],e,r)));const i=this.types[e];if(i)return i.reduce(((e,{name:n,type:i})=>(e[n]=this._visit(i,t[n],r),e)),{});(0,o.assertArgument)(!1,`unknown type: ${e}`,"type",e)}visit(e,t){return this._visit(this.primaryType,e,t)}static from(e){return new w(e)}static getPrimaryType(e){return w.from(e).primaryType}static hashStruct(e,t,r){return w.from(t).hashStruct(e,r)}static hashDomain(e){const t=[];for(const r in e){if(null==e[r])continue;const n=p[r];(0,o.assertArgument)(n,`invalid typed-data domain key: ${JSON.stringify(r)}`,"domain",e),t.push({name:r,type:n})}return t.sort(((e,t)=>m.indexOf(e.name)-m.indexOf(t.name))),w.hashStruct("EIP712Domain",{EIP712Domain:t},e)}static encode(e,t,r){return(0,o.concat)(["0x1901",w.hashDomain(e),w.from(t).hash(r)])}static hash(e,t,r){return(0,i.keccak256)(w.encode(e,t,r))}static async resolveNames(e,t,r,n){e=Object.assign({},e);for(const t in e)null==e[t]&&delete e[t];const i={};e.verifyingContract&&!(0,o.isHexString)(e.verifyingContract,20)&&(i[e.verifyingContract]="0x");const a=w.from(t);a.visit(r,((e,t)=>("address"!==e||(0,o.isHexString)(t,20)||(i[t]="0x"),t)));for(const e in i)i[e]=await n(e);return e.verifyingContract&&i[e.verifyingContract]&&(e.verifyingContract=i[e.verifyingContract]),{domain:e,value:r=a.visit(r,((e,t)=>"address"===e&&i[t]?i[t]:t))}}static getPayload(e,t,r){w.hashDomain(e);const n={},i=[];m.forEach((t=>{const r=e[t];null!=r&&(n[t]=g[t](r),i.push({name:t,type:p[t]}))}));const a=w.from(t),s=Object.assign({},t);return(0,o.assertArgument)(null==s.EIP712Domain,"types must not contain EIP712Domain type","types.EIP712Domain",t),s.EIP712Domain=i,a.encode(r),{types:s,domain:n,primaryType:a.primaryType,message:a.visit(r,((e,t)=>{if(e.match(/^bytes(\d*)/))return(0,o.hexlify)((0,o.getBytes)(t));if(e.match(/^u?int/))return(0,o.getBigInt)(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return(0,o.assertArgument)("string"==typeof t,"invalid string","value",t),t}(0,o.assertArgument)(!1,"unsupported type","type",e)}))}}}t.TypedDataEncoder=w},59237:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return i(t,e),t},a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.ethers=void 0;const s=o(r(81097));t.ethers=s,a(r(81097),t)},55142:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractProvider=t.UnmanagedSubscriber=void 0;const n=r(45475),i=r(30087),o=r(37252),a=r(98336),s=r(2290),u=r(42120),c=r(54087),l=r(83080),f=r(54837),h=r(37143),d=r(21097),p=BigInt(2);function m(e){return e&&"function"==typeof e.then}function y(e,t){return e+":"+JSON.stringify(t,((e,t)=>{if(null==t)return"null";if("bigint"==typeof t)return`bigint:${t.toString()}`;if("string"==typeof t)return t.toLowerCase();if("object"==typeof t&&!Array.isArray(t)){const e=Object.keys(t);return e.sort(),e.reduce(((e,r)=>(e[r]=t[r],e)),{})}return t}))}class g{name;constructor(e){(0,u.defineProperties)(this,{name:e})}start(){}stop(){}pause(e){}resume(){}}function b(e){return(e=Array.from(new Set(e).values())).sort(),e}async function v(e,t){if(null==e)throw new Error("invalid event");if(Array.isArray(e)&&(e={topics:e}),"string"==typeof e)switch(e){case"block":case"pending":case"debug":case"network":return{type:e,tag:e}}if((0,u.isHexString)(e,32)){const t=e.toLowerCase();return{type:"transaction",tag:y("tx",{hash:t}),hash:t}}if(e.orphan){const t=e;return{type:"orphan",tag:y("orphan",t),filter:(r=t,JSON.parse(JSON.stringify(r)))}}var r;if(e.address||e.topics){const r=e,i={topics:(r.topics||[]).map((e=>null==e?null:Array.isArray(e)?b(e.map((e=>e.toLowerCase()))):e.toLowerCase()))};if(r.address){const e=[],o=[],a=r=>{(0,u.isHexString)(r)?e.push(r):o.push((async()=>{e.push(await(0,n.resolveAddress)(r,t))})())};Array.isArray(r.address)?r.address.forEach(a):a(r.address),o.length&&await Promise.all(o),i.address=b(e.map((e=>e.toLowerCase())))}return{filter:i,tag:y("event",i),type:"event"}}(0,u.assertArgument)(!1,"unknown ProviderEvent","event",e)}function w(){return(new Date).getTime()}t.UnmanagedSubscriber=g;function A(e,t){try{const r=S(e,t);if(r)return(0,u.toUtf8String)(r)}catch(e){}return null}function S(e,t){if("0x"===e)return null;try{const r=(0,u.getNumber)((0,u.dataSlice)(e,t,t+32)),n=(0,u.getNumber)((0,u.dataSlice)(e,r,r+32));return(0,u.dataSlice)(e,r+32,r+32+n)}catch(e){}return null}function k(e){const t=(0,u.toBeArray)(e);if(t.length>32)throw new Error("internal; should not happen");const r=new Uint8Array(32);return r.set(t,32-t.length),r}function E(e){if(e.length%32==0)return e;const t=new Uint8Array(32*Math.ceil(e.length/32));return t.set(e),t}t.AbstractProvider=class{#x;#P;#I;#O;#R;#C;#B;#N;#L;#U;constructor(e){if("any"===e)this.#R=!0,this.#O=null;else if(e){const t=f.Network.from(e);this.#R=!1,this.#O=Promise.resolve(t),setTimeout((()=>{this.emit("network",t,null)}),0)}else this.#R=!1,this.#O=null;this.#B=-1,this.#C=new Map,this.#x=new Map,this.#P=new Map,this.#I=null,this.#N=1,this.#L=new Map,this.#U=!1}get provider(){return this}get plugins(){return Array.from(this.#P.values())}attachPlugin(e){if(this.#P.get(e.name))throw new Error(`cannot replace existing plugin: ${e.name} `);return this.#P.set(e.name,e.connect(this)),this}getPlugin(e){return this.#P.get(e)||null}get disableCcipRead(){return this.#U}set disableCcipRead(e){this.#U=!!e}async#F(e){const t=y(e.method,e);let r=this.#C.get(t);return r||(r=this._perform(e),this.#C.set(t,r),setTimeout((()=>{this.#C.get(t)===r&&this.#C.delete(t)}),250)),await r}async ccipReadFetch(e,t,r){if(this.disableCcipRead||0===r.length||null==e.to)return null;const n=e.to.toLowerCase(),i=t.toLowerCase(),o=[];for(let t=0;t=500,`response not found during CCIP fetch: ${l}`,"OFFCHAIN_FAULT",{reason:"404_MISSING_RESOURCE",transaction:e,info:{url:a,errorMessage:l}}),o.push(l)}(0,u.assert)(!1,`error encountered during CCIP fetch: ${o.map((e=>JSON.stringify(e))).join(", ")}`,"OFFCHAIN_FAULT",{reason:"500_SERVER_ERROR",transaction:e,info:{urls:r,errorMessages:o}})}_wrapBlock(e,t){return new h.Block((0,l.formatBlock)(e),this)}_wrapLog(e,t){return new h.Log((0,l.formatLog)(e),this)}_wrapTransactionReceipt(e,t){return new h.TransactionReceipt((0,l.formatTransactionReceipt)(e),this)}_wrapTransactionResponse(e,t){return new h.TransactionResponse(e,this)}_detectNetwork(){(0,u.assert)(!1,"sub-classes must implement this","UNSUPPORTED_OPERATION",{operation:"_detectNetwork"})}async _perform(e){(0,u.assert)(!1,`unsupported method: ${e.method}`,"UNSUPPORTED_OPERATION",{operation:e.method,info:e})}async getBlockNumber(){const e=(0,u.getNumber)(await this.#F({method:"getBlockNumber"}),"%response");return this.#B>=0&&(this.#B=e),e}_getAddress(e){return(0,n.resolveAddress)(e,this)}_getBlockTag(e){if(null==e)return"latest";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}return(0,u.isHexString)(e)?(0,u.isHexString)(e,32)?e:(0,u.toQuantity)(e):("bigint"==typeof e&&(e=(0,u.getNumber)(e,"blockTag")),"number"==typeof e?e>=0?(0,u.toQuantity)(e):this.#B>=0?(0,u.toQuantity)(this.#B+e):this.getBlockNumber().then((t=>(0,u.toQuantity)(t+e))):void(0,u.assertArgument)(!1,"invalid blockTag","blockTag",e))}_getFilter(e){const t=(e.topics||[]).map((e=>null==e?null:Array.isArray(e)?b(e.map((e=>e.toLowerCase()))):e.toLowerCase())),r="blockHash"in e?e.blockHash:void 0,n=(e,n,i)=>{let o;switch(e.length){case 0:break;case 1:o=e[0];break;default:e.sort(),o=e}if(r&&(null!=n||null!=i))throw new Error("invalid filter");const a={};return o&&(a.address=o),t.length&&(a.topics=t),n&&(a.fromBlock=n),i&&(a.toBlock=i),r&&(a.blockHash=r),a};let i,o,a=[];if(e.address)if(Array.isArray(e.address))for(const t of e.address)a.push(this._getAddress(t));else a.push(this._getAddress(e.address));return"fromBlock"in e&&(i=this._getBlockTag(e.fromBlock)),"toBlock"in e&&(o=this._getBlockTag(e.toBlock)),a.filter((e=>"string"!=typeof e)).length||null!=i&&"string"!=typeof i||null!=o&&"string"!=typeof o?Promise.all([Promise.all(a),i,o]).then((e=>n(e[0],e[1],e[2]))):n(a,i,o)}_getTransactionRequest(e){const t=(0,h.copyRequest)(e),r=[];if(["to","from"].forEach((e=>{if(null==t[e])return;const i=(0,n.resolveAddress)(t[e]);m(i)?r.push(async function(){t[e]=await i}()):t[e]=i})),null!=t.blockTag){const e=this._getBlockTag(t.blockTag);m(e)?r.push(async function(){t.blockTag=await e}()):t.blockTag=e}return r.length?async function(){return await Promise.all(r),t}():t}async getNetwork(){if(null==this.#O){const e=this._detectNetwork().then((e=>(this.emit("network",e,null),e)),(t=>{throw this.#O===e&&(this.#O=null),t}));return this.#O=e,(await e).clone()}const e=this.#O,[t,r]=await Promise.all([e,this._detectNetwork()]);return t.chainId!==r.chainId&&(this.#R?(this.emit("network",r,t),this.#O===e&&(this.#O=Promise.resolve(r))):(0,u.assert)(!1,`network changed: ${t.chainId} => ${r.chainId} `,"NETWORK_ERROR",{event:"changed"})),t.clone()}async getFeeData(){const{block:e,gasPrice:t}=await(0,u.resolveProperties)({block:this.getBlock("latest"),gasPrice:(async()=>{try{const e=await this.#F({method:"getGasPrice"});return(0,u.getBigInt)(e,"%response")}catch(e){}return null})()});let r=null,n=null;return e&&e.baseFeePerGas&&(n=BigInt("1000000000"),r=e.baseFeePerGas*p+n),new h.FeeData(t,r,n)}async estimateGas(e){let t=this._getTransactionRequest(e);return m(t)&&(t=await t),(0,u.getBigInt)(await this.#F({method:"estimateGas",transaction:t}),"%response")}async#D(e,t,r){(0,u.assert)(r<10,"CCIP read exceeded maximum redirections","OFFCHAIN_FAULT",{reason:"TOO_MANY_REDIRECTS",transaction:Object.assign({},e,{blockTag:t,enableCcipRead:!0})});const i=(0,h.copyRequest)(e);try{return(0,u.hexlify)(await this._perform({method:"call",transaction:i,blockTag:t}))}catch(e){if(!this.disableCcipRead&&(0,u.isCallException)(e)&&e.data&&r>=0&&"latest"===t&&null!=i.to&&"0x556f1830"===(0,u.dataSlice)(e.data,0,4)){const o=e.data,a=await(0,n.resolveAddress)(i.to,this);let s;try{s=function(e){const t={sender:"",urls:[],calldata:"",selector:"",extraData:"",errorArgs:[]};(0,u.assert)((0,u.dataLength)(e)>=160,"insufficient OffchainLookup data","OFFCHAIN_FAULT",{reason:"insufficient OffchainLookup data"});const r=(0,u.dataSlice)(e,0,32);(0,u.assert)((0,u.dataSlice)(r,0,12)===(0,u.dataSlice)(T,0,12),"corrupt OffchainLookup sender","OFFCHAIN_FAULT",{reason:"corrupt OffchainLookup sender"}),t.sender=(0,u.dataSlice)(r,12);try{const r=[],n=(0,u.getNumber)((0,u.dataSlice)(e,32,64)),i=(0,u.getNumber)((0,u.dataSlice)(e,n,n+32)),o=(0,u.dataSlice)(e,n+32);for(let e=0;et[e])),t}((0,u.dataSlice)(e.data,4))}catch(e){(0,u.assert)(!1,e.message,"OFFCHAIN_FAULT",{reason:"BAD_DATA",transaction:i,info:{data:o}})}(0,u.assert)(s.sender.toLowerCase()===a.toLowerCase(),"CCIP Read sender mismatch","CALL_EXCEPTION",{action:"call",data:o,reason:"OffchainLookup",transaction:i,invocation:null,revert:{signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",name:"OffchainLookup",args:s.errorArgs}});const c=await this.ccipReadFetch(i,s.calldata,s.urls);(0,u.assert)(null!=c,"CCIP Read failed to fetch data","OFFCHAIN_FAULT",{reason:"FETCH_FAILED",transaction:i,info:{data:e.data,errorArgs:s.errorArgs}});const l={to:a,data:(0,u.concat)([s.selector,M([c,s.extraData])])};this.emit("debug",{action:"sendCcipReadCall",transaction:l});try{const e=await this.#D(l,t,r+1);return this.emit("debug",{action:"receiveCcipReadCallResult",transaction:Object.assign({},l),result:e}),e}catch(e){throw this.emit("debug",{action:"receiveCcipReadCallError",transaction:Object.assign({},l),error:e}),e}}throw e}}async#j(e){const{value:t}=await(0,u.resolveProperties)({network:this.getNetwork(),value:e});return t}async call(e){const{tx:t,blockTag:r}=await(0,u.resolveProperties)({tx:this._getTransactionRequest(e),blockTag:this._getBlockTag(e.blockTag)});return await this.#j(this.#D(t,r,e.enableCcipRead?0:-1))}async#H(e,t,r){let n=this._getAddress(t),i=this._getBlockTag(r);return"string"==typeof n&&"string"==typeof i||([n,i]=await Promise.all([n,i])),await this.#j(this.#F(Object.assign(e,{address:n,blockTag:i})))}async getBalance(e,t){return(0,u.getBigInt)(await this.#H({method:"getBalance"},e,t),"%response")}async getTransactionCount(e,t){return(0,u.getNumber)(await this.#H({method:"getTransactionCount"},e,t),"%response")}async getCode(e,t){return(0,u.hexlify)(await this.#H({method:"getCode"},e,t))}async getStorage(e,t,r){const n=(0,u.getBigInt)(t,"position");return(0,u.hexlify)(await this.#H({method:"getStorage",position:n},e,r))}async broadcastTransaction(e){const{blockNumber:t,hash:r,network:n}=await(0,u.resolveProperties)({blockNumber:this.getBlockNumber(),hash:this._perform({method:"broadcastTransaction",signedTransaction:e}),network:this.getNetwork()}),i=s.Transaction.from(e);if(i.hash!==r)throw new Error("@TODO: the returned hash did not match");return this._wrapTransactionResponse(i,n).replaceableTransaction(t)}async#J(e,t){if((0,u.isHexString)(e,32))return await this.#F({method:"getBlock",blockHash:e,includeTransactions:t});let r=this._getBlockTag(e);return"string"!=typeof r&&(r=await r),await this.#F({method:"getBlock",blockTag:r,includeTransactions:t})}async getBlock(e,t){const{network:r,params:n}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#J(e,!!t)});return null==n?null:this._wrapBlock((0,l.formatBlock)(n),r)}async getTransaction(e){const{network:t,params:r}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#F({method:"getTransaction",hash:e})});return null==r?null:this._wrapTransactionResponse((0,l.formatTransactionResponse)(r),t)}async getTransactionReceipt(e){const{network:t,params:r}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#F({method:"getTransactionReceipt",hash:e})});if(null==r)return null;if(null==r.gasPrice&&null==r.effectiveGasPrice){const t=await this.#F({method:"getTransaction",hash:e});if(null==t)throw new Error("report this; could not find tx or effectiveGasPrice");r.effectiveGasPrice=t.gasPrice}return this._wrapTransactionReceipt((0,l.formatTransactionReceipt)(r),t)}async getTransactionResult(e){const{result:t}=await(0,u.resolveProperties)({network:this.getNetwork(),result:this.#F({method:"getTransactionResult",hash:e})});return null==t?null:(0,u.hexlify)(t)}async getLogs(e){let t=this._getFilter(e);m(t)&&(t=await t);const{network:r,params:n}=await(0,u.resolveProperties)({network:this.getNetwork(),params:this.#F({method:"getLogs",filter:t})});return n.map((e=>this._wrapLog((0,l.formatLog)(e),r)))}_getProvider(e){(0,u.assert)(!1,"provider cannot connect to target network","UNSUPPORTED_OPERATION",{operation:"_getProvider()"})}async getResolver(e){return await c.EnsResolver.fromName(this,e)}async getAvatar(e){const t=await this.getResolver(e);return t?await t.getAvatar():null}async resolveName(e){const t=await this.getResolver(e);return t?await t.getAddress():null}async lookupAddress(e){e=(0,n.getAddress)(e);const t=(0,a.namehash)(e.substring(2).toLowerCase()+".addr.reverse");try{const r=await c.EnsResolver.getEnsAddress(this),n=new o.Contract(r,["function resolver(bytes32) view returns (address)"],this),a=await n.resolver(t);if(null==a||a===i.ZeroHash)return null;const s=new o.Contract(a,["function name(bytes32) view returns (string)"],this),u=await s.name(t);return await this.resolveName(u)!==e?null:u}catch(e){if((0,u.isError)(e,"BAD_DATA")&&"0x"===e.value)return null;if((0,u.isError)(e,"CALL_EXCEPTION"))return null;throw e}return null}async waitForTransaction(e,t,r){const n=null!=t?t:1;return 0===n?this.getTransactionReceipt(e):new Promise((async(t,i)=>{let o=null;const a=async r=>{try{const i=await this.getTransactionReceipt(e);if(null!=i&&r-i.blockNumber+1>=n)return t(i),void(o&&(clearTimeout(o),o=null))}catch(e){console.log("EEE",e)}this.once("block",a)};null!=r&&(o=setTimeout((()=>{null!=o&&(o=null,this.off("block",a),i((0,u.makeError)("timeout","TIMEOUT",{reason:"timeout"})))}),r)),a(await this.getBlockNumber())}))}async waitForBlock(e){(0,u.assert)(!1,"not implemented yet","NOT_IMPLEMENTED",{operation:"waitForBlock"})}_clearTimeout(e){const t=this.#L.get(e);t&&(t.timer&&clearTimeout(t.timer),this.#L.delete(e))}_setTimeout(e,t){null==t&&(t=0);const r=this.#N++,n=()=>{this.#L.delete(r),e()};if(this.paused)this.#L.set(r,{timer:null,func:n,time:t});else{const e=setTimeout(n,t);this.#L.set(r,{timer:e,func:n,time:w()})}return r}_forEachSubscriber(e){for(const t of this.#x.values())e(t.subscriber)}_getSubscriber(e){switch(e.type){case"debug":case"network":return new g(e.type);case"block":return new d.PollingBlockSubscriber(this);case"event":return new d.PollingEventSubscriber(this,e.filter);case"transaction":return new d.PollingTransactionSubscriber(this,e.hash);case"orphan":return new d.PollingOrphanSubscriber(this,e.filter)}throw new Error(`unsupported event: ${e.type}`)}_recoverSubscriber(e,t){for(const r of this.#x.values())if(r.subscriber===e){r.started&&r.subscriber.stop(),r.subscriber=t,r.started&&t.start(),null!=this.#I&&t.pause(this.#I);break}}async#z(e,t){let r=await v(e,this);return"event"===r.type&&t&&t.length>0&&!0===t[0].removed&&(r=await v({orphan:"drop-log",log:t[0]},this)),this.#x.get(r.tag)||null}async#G(e){const t=await v(e,this),r=t.tag;let n=this.#x.get(r);if(!n){n={subscriber:this._getSubscriber(t),tag:r,addressableMap:new WeakMap,nameMap:new Map,started:!1,listeners:[]},this.#x.set(r,n)}return n}async on(e,t){const r=await this.#G(e);return r.listeners.push({listener:t,once:!1}),r.started||(r.subscriber.start(),r.started=!0,null!=this.#I&&r.subscriber.pause(this.#I)),this}async once(e,t){const r=await this.#G(e);return r.listeners.push({listener:t,once:!0}),r.started||(r.subscriber.start(),r.started=!0,null!=this.#I&&r.subscriber.pause(this.#I)),this}async emit(e,...t){const r=await this.#z(e,t);if(!r||0===r.listeners.length)return!1;const n=r.listeners.length;return r.listeners=r.listeners.filter((({listener:r,once:n})=>{const i=new u.EventPayload(this,n?null:r,e);try{r.call(this,...t,i)}catch(e){}return!n})),0===r.listeners.length&&(r.started&&r.subscriber.stop(),this.#x.delete(r.tag)),n>0}async listenerCount(e){if(e){const t=await this.#z(e);return t?t.listeners.length:0}let t=0;for(const{listeners:e}of this.#x.values())t+=e.length;return t}async listeners(e){if(e){const t=await this.#z(e);return t?t.listeners.map((({listener:e})=>e)):[]}let t=[];for(const{listeners:e}of this.#x.values())t=t.concat(e.map((({listener:e})=>e)));return t}async off(e,t){const r=await this.#z(e);if(!r)return this;if(t){const e=r.listeners.map((({listener:e})=>e)).indexOf(t);e>=0&&r.listeners.splice(e,1)}return t&&0!==r.listeners.length||(r.started&&r.subscriber.stop(),this.#x.delete(r.tag)),this}async removeAllListeners(e){if(e){const{tag:t,started:r,subscriber:n}=await this.#G(e);r&&n.stop(),this.#x.delete(t)}else for(const[e,{started:t,subscriber:r}]of this.#x)t&&r.stop(),this.#x.delete(e);return this}async addListener(e,t){return await this.on(e,t)}async removeListener(e,t){return this.off(e,t)}destroy(){this.removeAllListeners();for(const e of this.#L.keys())this._clearTimeout(e)}get paused(){return null!=this.#I}set paused(e){!!e!==this.paused&&(this.paused?this.resume():this.pause(!1))}pause(e){if(this.#B=-1,null!=this.#I){if(this.#I==!!e)return;(0,u.assert)(!1,"cannot change pause type; resume first","UNSUPPORTED_OPERATION",{operation:"pause"})}this._forEachSubscriber((t=>t.pause(e))),this.#I=!!e;for(const e of this.#L.values())e.timer&&clearTimeout(e.timer),e.time=w()-e.time}resume(){if(null!=this.#I){this._forEachSubscriber((e=>e.resume())),this.#I=null;for(const e of this.#L.values()){let t=e.time;t<0&&(t=0),e.time=w(),setTimeout(e.func,t)}}}};const _=new Uint8Array([]);function M(e){const t=[];let r=0;for(let n=0;n{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VoidSigner=t.AbstractSigner=void 0;const n=r(45475),i=r(2290),o=r(42120),a=r(37143);function s(e,t){if(e.provider)return e.provider;(0,o.assert)(!1,"missing provider","UNSUPPORTED_OPERATION",{operation:t})}async function u(e,t){let r=(0,a.copyRequest)(t);if(null!=r.to&&(r.to=(0,n.resolveAddress)(r.to,e)),null!=r.from){const t=r.from;r.from=Promise.all([e.getAddress(),(0,n.resolveAddress)(t,e)]).then((([e,t])=>((0,o.assertArgument)(e.toLowerCase()===t.toLowerCase(),"transaction from mismatch","tx.from",t),e)))}else r.from=e.getAddress();return await(0,o.resolveProperties)(r)}class c{provider;constructor(e){(0,o.defineProperties)(this,{provider:e||null})}async getNonce(e){return s(this,"getTransactionCount").getTransactionCount(await this.getAddress(),e)}async populateCall(e){return await u(this,e)}async populateTransaction(e){const t=s(this,"populateTransaction"),r=await u(this,e);null==r.nonce&&(r.nonce=await this.getNonce("pending")),null==r.gasLimit&&(r.gasLimit=await this.estimateGas(r));const n=await this.provider.getNetwork();if(null!=r.chainId){const t=(0,o.getBigInt)(r.chainId);(0,o.assertArgument)(t===n.chainId,"transaction chainId mismatch","tx.chainId",e.chainId)}else r.chainId=n.chainId;const i=null!=r.maxFeePerGas||null!=r.maxPriorityFeePerGas;if(null==r.gasPrice||2!==r.type&&!i?0!==r.type&&1!==r.type||!i||(0,o.assertArgument)(!1,"pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","tx",e):(0,o.assertArgument)(!1,"eip-1559 transaction do not support gasPrice","tx",e),2!==r.type&&null!=r.type||null==r.maxFeePerGas||null==r.maxPriorityFeePerGas)if(0===r.type||1===r.type){const e=await t.getFeeData();(0,o.assert)(null!=e.gasPrice,"network does not support gasPrice","UNSUPPORTED_OPERATION",{operation:"getGasPrice"}),null==r.gasPrice&&(r.gasPrice=e.gasPrice)}else{const e=await t.getFeeData();if(null==r.type)if(null!=e.maxFeePerGas&&null!=e.maxPriorityFeePerGas)if(r.type=2,null!=r.gasPrice){const e=r.gasPrice;delete r.gasPrice,r.maxFeePerGas=e,r.maxPriorityFeePerGas=e}else null==r.maxFeePerGas&&(r.maxFeePerGas=e.maxFeePerGas),null==r.maxPriorityFeePerGas&&(r.maxPriorityFeePerGas=e.maxPriorityFeePerGas);else null!=e.gasPrice?((0,o.assert)(!i,"network does not support EIP-1559","UNSUPPORTED_OPERATION",{operation:"populateTransaction"}),null==r.gasPrice&&(r.gasPrice=e.gasPrice),r.type=0):(0,o.assert)(!1,"failed to get consistent fee data","UNSUPPORTED_OPERATION",{operation:"signer.getFeeData"});else 2===r.type&&(null==r.maxFeePerGas&&(r.maxFeePerGas=e.maxFeePerGas),null==r.maxPriorityFeePerGas&&(r.maxPriorityFeePerGas=e.maxPriorityFeePerGas))}else r.type=2;return await(0,o.resolveProperties)(r)}async estimateGas(e){return s(this,"estimateGas").estimateGas(await this.populateCall(e))}async call(e){return s(this,"call").call(await this.populateCall(e))}async resolveName(e){const t=s(this,"resolveName");return await t.resolveName(e)}async sendTransaction(e){const t=s(this,"sendTransaction"),r=await this.populateTransaction(e);delete r.from;const n=i.Transaction.from(r);return await t.broadcastTransaction(await this.signTransaction(n))}}t.AbstractSigner=c;class l extends c{address;constructor(e,t){super(t),(0,o.defineProperties)(this,{address:e})}async getAddress(){return this.address}connect(e){return new l(this.address,e)}#q(e,t){(0,o.assert)(!1,`VoidSigner cannot sign ${e}`,"UNSUPPORTED_OPERATION",{operation:t})}async signTransaction(e){this.#q("transactions","signTransaction")}async signMessage(e){this.#q("messages","signMessage")}async signTypedData(e,t,r){this.#q("typed-data","signTypedData")}}t.VoidSigner=l},32813:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.showThrottleMessage=void 0;const r=new Set;t.showThrottleMessage=function(e){r.has(e)||(r.add(e),console.log("========= NOTICE ========="),console.log(`Request-Rate Exceeded for ${e} (this message will not be repeated)`),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.org/api-keys/"),console.log("=========================="))}},7994:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getDefaultProvider=void 0;const n=r(42120),i=r(16791),o=r(23815),a=r(3377),s=r(22880),u=r(35012),c=r(81333),l=r(24129),f=r(32013),h=r(62196);t.getDefaultProvider=function(e,t){if(null==t&&(t={}),"string"==typeof e&&e.match(/^https?:/))return new f.JsonRpcProvider(e);if("string"==typeof e&&e.match(/^wss?:/)||(r=e)&&"function"==typeof r.send&&"function"==typeof r.close)return new h.WebSocketProvider(e);var r;const d=[];if("-"!==t.alchemy)try{d.push(new o.AlchemyProvider(e,t.alchemy))}catch(e){console.log(e)}if("-"!==t.ankr)try{d.push(new i.AnkrProvider(e,t.ankr))}catch(e){console.log(e)}if("-"!==t.cloudflare)try{d.push(new a.CloudflareProvider(e))}catch(e){console.log(e)}if("-"!==t.etherscan)try{d.push(new s.EtherscanProvider(e,t.etherscan))}catch(e){console.log(e)}if("-"!==t.infura)try{let r,n=t.infura;"object"==typeof n&&(r=n.projectSecret,n=n.projectId),d.push(new u.InfuraProvider(e,n,r))}catch(e){console.log(e)}if("-"!==t.quicknode)try{let r=t.quicknode;d.push(new c.QuickNodeProvider(e,r))}catch(e){console.log(e)}return(0,n.assert)(d.length,"unsupported default network","UNSUPPORTED_OPERATION",{operation:"getDefaultProvider"}),1===d.length?d[0]:new l.FallbackProvider(d)}},54087:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EnsResolver=t.BasicMulticoinProviderPlugin=t.MulticoinProviderPlugin=void 0;const n=r(30087),i=r(37252),o=r(98336),a=r(42120);function s(e){return e.match(/^ipfs:\/\/ipfs\//i)?e=e.substring(12):e.match(/^ipfs:\/\//i)?e=e.substring(7):(0,a.assertArgument)(!1,"unsupported IPFS format","link",e),`https://gateway.ipfs.io/ipfs/${e}`}class u{name;constructor(e){(0,a.defineProperties)(this,{name:e})}connect(e){return this}supportsCoinType(e){return!1}async encodeAddress(e,t){throw new Error("unsupported coin")}async decodeAddress(e,t){throw new Error("unsupported coin")}}t.MulticoinProviderPlugin=u;t.BasicMulticoinProviderPlugin=class extends u{constructor(){super("org.ethers.plugins.provider.BasicMulticoin")}};const c=new RegExp("^(ipfs)://(.*)$","i"),l=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),c,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];class f{provider;address;name;#K;#V;constructor(e,t,r){(0,a.defineProperties)(this,{provider:e,address:t,name:r}),this.#K=null,this.#V=new i.Contract(t,["function supportsInterface(bytes4) view returns (bool)","function resolve(bytes, bytes) view returns (bytes)","function addr(bytes32) view returns (address)","function addr(bytes32, uint) view returns (address)","function text(bytes32, string) view returns (string)","function contenthash(bytes32) view returns (bytes)"],e)}async supportsWildcard(){return null==this.#K&&(this.#K=(async()=>{try{return await this.#V.supportsInterface("0x9061b923")}catch(e){if((0,a.isError)(e,"CALL_EXCEPTION"))return!1;throw this.#K=null,e}})()),await this.#K}async#X(e,t){t=(t||[]).slice();const r=this.#V.interface;t.unshift((0,o.namehash)(this.name));let n=null;await this.supportsWildcard()&&(n=r.getFunction(e),(0,a.assert)(n,"missing fragment","UNKNOWN_ERROR",{info:{funcName:e}}),t=[(0,o.dnsEncode)(this.name),r.encodeFunctionData(n,t)],e="resolve(bytes,bytes)"),t.push({ccipReadEnable:!0});try{const i=await this.#V[e](...t);return n?r.decodeFunctionResult(n,i)[0]:i}catch(e){if(!(0,a.isError)(e,"CALL_EXCEPTION"))throw e}return null}async getAddress(e){if(null==e&&(e=60),60===e)try{const e=await this.#X("addr(bytes32)");return null==e||e===n.ZeroAddress?null:e}catch(e){if((0,a.isError)(e,"CALL_EXCEPTION"))return null;throw e}let t=null;for(const r of this.provider.plugins)if(r instanceof u&&r.supportsCoinType(e)){t=r;break}if(null==t)return null;const r=await this.#X("addr(bytes32,uint)",[e]);if(null==r||"0x"===r)return null;const i=await t.encodeAddress(e,r);if(null!=i)return i;(0,a.assert)(!1,"invalid coin data","UNSUPPORTED_OPERATION",{operation:`getAddress(${e})`,info:{coinType:e,data:r}})}async getText(e){const t=await this.#X("text(bytes32,string)",[e]);return null==t||"0x"===t?null:t}async getContentHash(){const e=await this.#X("contenthash(bytes32)");if(null==e||"0x"===e)return null;const t=e.match(/^0x(e3010170|e5010172)(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(t){const e="e3010170"===t[1]?"ipfs":"ipns",r=parseInt(t[4],16);if(t[5].length===2*r)return`${e}://${(0,a.encodeBase58)("0x"+t[2])}`}const r=e.match(/^0xe40101fa011b20([0-9a-f]*)$/);if(r&&64===r[1].length)return`bzz://${r[1]}`;(0,a.assert)(!1,"invalid or unsupported content hash data","UNSUPPORTED_OPERATION",{operation:"getContentHash()",info:{data:e}})}async getAvatar(){return(await this._getAvatar()).url}async _getAvatar(){const e=[{type:"name",value:this.name}];try{const t=await this.getText("avatar");if(null==t)return e.push({type:"!avatar",value:""}),{url:null,linkage:e};e.push({type:"avatar",value:t});for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatTransactionResponse=t.formatTransactionReceipt=t.formatReceiptLog=t.formatBlock=t.formatLog=t.formatUint256=t.formatHash=t.formatData=t.formatBoolean=t.object=t.arrayOf=t.allowNull=void 0;const n=r(45475),i=r(96965),o=r(2290),a=r(42120),s=BigInt(0);function u(e,t){return function(r){return null==r?t:e(r)}}function c(e){return t=>{if(!Array.isArray(t))throw new Error("not an array");return t.map((t=>e(t)))}}function l(e,t){return r=>{const n={};for(const i in e){let o=i;if(t&&i in t&&!(o in r))for(const e of t[i])if(e in r){o=e;break}try{const t=e[i](r[o]);void 0!==t&&(n[i]=t)}catch(e){const t=e instanceof Error?e.message:"not-an-error";(0,a.assert)(!1,`invalid value for value.${i} (${t})`,"BAD_DATA",{value:r})}}return n}}function f(e){switch(e){case!0:case"true":return!0;case!1:case"false":return!1}(0,a.assertArgument)(!1,`invalid boolean; ${JSON.stringify(e)}`,"value",e)}function h(e){return(0,a.assertArgument)((0,a.isHexString)(e,!0),"invalid data","value",e),e}function d(e){return(0,a.assertArgument)((0,a.isHexString)(e,32),"invalid hash","value",e),e}t.allowNull=u,t.arrayOf=c,t.object=l,t.formatBoolean=f,t.formatData=h,t.formatHash=d,t.formatUint256=function(e){if(!(0,a.isHexString)(e))throw new Error("invalid uint256");return(0,a.zeroPadValue)(e,32)};const p=l({address:n.getAddress,blockHash:d,blockNumber:a.getNumber,data:h,index:a.getNumber,removed:f,topics:c(d),transactionHash:d,transactionIndex:a.getNumber},{index:["logIndex"]});t.formatLog=function(e){return p(e)};const m=l({hash:u(d),parentHash:d,number:a.getNumber,timestamp:a.getNumber,nonce:u(h),difficulty:a.getBigInt,gasLimit:a.getBigInt,gasUsed:a.getBigInt,miner:u(n.getAddress),extraData:h,baseFeePerGas:u(a.getBigInt)});t.formatBlock=function(e){const t=m(e);return t.transactions=e.transactions.map((e=>"string"==typeof e?e:v(e))),t};const y=l({transactionIndex:a.getNumber,blockNumber:a.getNumber,transactionHash:d,address:n.getAddress,topics:c(d),data:h,index:a.getNumber,blockHash:d},{index:["logIndex"]});function g(e){return y(e)}t.formatReceiptLog=g;const b=l({to:u(n.getAddress,null),from:u(n.getAddress,null),contractAddress:u(n.getAddress,null),index:a.getNumber,root:u(a.hexlify),gasUsed:a.getBigInt,logsBloom:u(h),blockHash:d,hash:d,logs:c(g),blockNumber:a.getNumber,cumulativeGasUsed:a.getBigInt,effectiveGasPrice:u(a.getBigInt),status:u(a.getNumber),type:u(a.getNumber,0)},{effectiveGasPrice:["gasPrice"],hash:["transactionHash"],index:["transactionIndex"]});function v(e){e.to&&(0,a.getBigInt)(e.to)===s&&(e.to="0x0000000000000000000000000000000000000000");const t=l({hash:d,type:e=>"0x"===e||null==e?0:(0,a.getNumber)(e),accessList:u(o.accessListify,null),blockHash:u(d,null),blockNumber:u(a.getNumber,null),transactionIndex:u(a.getNumber,null),from:n.getAddress,gasPrice:u(a.getBigInt),maxPriorityFeePerGas:u(a.getBigInt),maxFeePerGas:u(a.getBigInt),gasLimit:a.getBigInt,to:u(n.getAddress,null),value:a.getBigInt,nonce:a.getNumber,data:h,creates:u(n.getAddress,null),chainId:u(a.getBigInt,null)},{data:["input"],gasLimit:["gas"]})(e);if(null==t.to&&null==t.creates&&(t.creates=(0,n.getCreateAddress)(t)),1!==e.type&&2!==e.type||null!=e.accessList||(t.accessList=[]),e.signature?t.signature=i.Signature.from(e.signature):t.signature=i.Signature.from(e),null==t.chainId){const e=t.signature.legacyChainId;null!=e&&(t.chainId=e)}return t.blockHash&&(0,a.getBigInt)(t.blockHash)===s&&(t.blockHash=null),t}t.formatTransactionReceipt=function(e){return b(e)},t.formatTransactionResponse=v},4878:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SocketEventSubscriber=t.SocketPendingSubscriber=t.SocketBlockSubscriber=t.SocketSubscriber=t.WebSocketProvider=t.SocketProvider=t.IpcSocketProvider=t.QuickNodeProvider=t.PocketProvider=t.InfuraWebSocketProvider=t.InfuraProvider=t.EtherscanPlugin=t.EtherscanProvider=t.CloudflareProvider=t.AnkrProvider=t.AlchemyProvider=t.BrowserProvider=t.JsonRpcSigner=t.JsonRpcProvider=t.JsonRpcApiProvider=t.FallbackProvider=t.copyRequest=t.TransactionResponse=t.TransactionReceipt=t.Log=t.FeeData=t.Block=t.FeeDataNetworkPlugin=t.EnsPlugin=t.GasCostPlugin=t.NetworkPlugin=t.NonceManager=t.Network=t.EnsResolver=t.getDefaultProvider=t.showThrottleMessage=t.VoidSigner=t.AbstractSigner=t.UnmanagedSubscriber=t.AbstractProvider=void 0;var n=r(55142);Object.defineProperty(t,"AbstractProvider",{enumerable:!0,get:function(){return n.AbstractProvider}}),Object.defineProperty(t,"UnmanagedSubscriber",{enumerable:!0,get:function(){return n.UnmanagedSubscriber}});var i=r(35649);Object.defineProperty(t,"AbstractSigner",{enumerable:!0,get:function(){return i.AbstractSigner}}),Object.defineProperty(t,"VoidSigner",{enumerable:!0,get:function(){return i.VoidSigner}});var o=r(32813);Object.defineProperty(t,"showThrottleMessage",{enumerable:!0,get:function(){return o.showThrottleMessage}});var a=r(7994);Object.defineProperty(t,"getDefaultProvider",{enumerable:!0,get:function(){return a.getDefaultProvider}});var s=r(54087);Object.defineProperty(t,"EnsResolver",{enumerable:!0,get:function(){return s.EnsResolver}});var u=r(54837);Object.defineProperty(t,"Network",{enumerable:!0,get:function(){return u.Network}});var c=r(22992);Object.defineProperty(t,"NonceManager",{enumerable:!0,get:function(){return c.NonceManager}});var l=r(67004);Object.defineProperty(t,"NetworkPlugin",{enumerable:!0,get:function(){return l.NetworkPlugin}}),Object.defineProperty(t,"GasCostPlugin",{enumerable:!0,get:function(){return l.GasCostPlugin}}),Object.defineProperty(t,"EnsPlugin",{enumerable:!0,get:function(){return l.EnsPlugin}}),Object.defineProperty(t,"FeeDataNetworkPlugin",{enumerable:!0,get:function(){return l.FeeDataNetworkPlugin}});var f=r(37143);Object.defineProperty(t,"Block",{enumerable:!0,get:function(){return f.Block}}),Object.defineProperty(t,"FeeData",{enumerable:!0,get:function(){return f.FeeData}}),Object.defineProperty(t,"Log",{enumerable:!0,get:function(){return f.Log}}),Object.defineProperty(t,"TransactionReceipt",{enumerable:!0,get:function(){return f.TransactionReceipt}}),Object.defineProperty(t,"TransactionResponse",{enumerable:!0,get:function(){return f.TransactionResponse}}),Object.defineProperty(t,"copyRequest",{enumerable:!0,get:function(){return f.copyRequest}});var h=r(24129);Object.defineProperty(t,"FallbackProvider",{enumerable:!0,get:function(){return h.FallbackProvider}});var d=r(32013);Object.defineProperty(t,"JsonRpcApiProvider",{enumerable:!0,get:function(){return d.JsonRpcApiProvider}}),Object.defineProperty(t,"JsonRpcProvider",{enumerable:!0,get:function(){return d.JsonRpcProvider}}),Object.defineProperty(t,"JsonRpcSigner",{enumerable:!0,get:function(){return d.JsonRpcSigner}});var p=r(30292);Object.defineProperty(t,"BrowserProvider",{enumerable:!0,get:function(){return p.BrowserProvider}});var m=r(23815);Object.defineProperty(t,"AlchemyProvider",{enumerable:!0,get:function(){return m.AlchemyProvider}});var y=r(16791);Object.defineProperty(t,"AnkrProvider",{enumerable:!0,get:function(){return y.AnkrProvider}});var g=r(3377);Object.defineProperty(t,"CloudflareProvider",{enumerable:!0,get:function(){return g.CloudflareProvider}});var b=r(22880);Object.defineProperty(t,"EtherscanProvider",{enumerable:!0,get:function(){return b.EtherscanProvider}}),Object.defineProperty(t,"EtherscanPlugin",{enumerable:!0,get:function(){return b.EtherscanPlugin}});var v=r(35012);Object.defineProperty(t,"InfuraProvider",{enumerable:!0,get:function(){return v.InfuraProvider}}),Object.defineProperty(t,"InfuraWebSocketProvider",{enumerable:!0,get:function(){return v.InfuraWebSocketProvider}});var w=r(52751);Object.defineProperty(t,"PocketProvider",{enumerable:!0,get:function(){return w.PocketProvider}});var A=r(81333);Object.defineProperty(t,"QuickNodeProvider",{enumerable:!0,get:function(){return A.QuickNodeProvider}});const S=r(74019);Object.defineProperty(t,"IpcSocketProvider",{enumerable:!0,get:function(){return S.IpcSocketProvider}});var k=r(12394);Object.defineProperty(t,"SocketProvider",{enumerable:!0,get:function(){return k.SocketProvider}});var E=r(62196);Object.defineProperty(t,"WebSocketProvider",{enumerable:!0,get:function(){return E.WebSocketProvider}});var _=r(12394);Object.defineProperty(t,"SocketSubscriber",{enumerable:!0,get:function(){return _.SocketSubscriber}}),Object.defineProperty(t,"SocketBlockSubscriber",{enumerable:!0,get:function(){return _.SocketBlockSubscriber}}),Object.defineProperty(t,"SocketPendingSubscriber",{enumerable:!0,get:function(){return _.SocketPendingSubscriber}}),Object.defineProperty(t,"SocketEventSubscriber",{enumerable:!0,get:function(){return _.SocketEventSubscriber}})},54837:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Network=void 0;const n=r(2290),i=r(42120),o=r(67004),a=new Map;class s{#W;#Z;#P;constructor(e,t){this.#W=e,this.#Z=(0,i.getBigInt)(t),this.#P=new Map}toJSON(){return{name:this.name,chainId:this.chainId}}get name(){return this.#W}set name(e){this.#W=e}get chainId(){return this.#Z}set chainId(e){this.#Z=(0,i.getBigInt)(e,"chainId")}get plugins(){return Array.from(this.#P.values())}attachPlugin(e){if(this.#P.get(e.name))throw new Error(`cannot replace existing plugin: ${e.name} `);return this.#P.set(e.name,e.clone()),this}getPlugin(e){return this.#P.get(e)||null}getPlugins(e){return this.plugins.filter((t=>t.name.split("#")[0]===e))}clone(){const e=new s(this.name,this.chainId);return this.plugins.forEach((t=>{e.attachPlugin(t.clone())})),e}computeIntrinsicGas(e){const t=this.getPlugin("org.ethers.plugins.network.GasCost")||new o.GasCostPlugin;let r=t.txBase;if(null==e.to&&(r+=t.txCreate),e.data)for(let n=2;n{s.register(e,n)}))}u=!0,e("mainnet",1,{ensNetwork:1,altNames:["homestead"]}),e("ropsten",3,{ensNetwork:3}),e("rinkeby",4,{ensNetwork:4}),e("goerli",5,{ensNetwork:5}),e("kovan",42,{ensNetwork:42}),e("sepolia",11155111,{}),e("classic",61,{}),e("classicKotti",6,{}),e("xdai",100,{ensNetwork:1}),e("optimism",10,{ensNetwork:1,etherscan:{url:"https://api-optimistic.etherscan.io/"}}),e("optimism-goerli",420,{etherscan:{url:"https://api-goerli-optimistic.etherscan.io/"}}),e("arbitrum",42161,{ensNetwork:1,etherscan:{url:"https://api.arbiscan.io/"}}),e("arbitrum-goerli",421613,{etherscan:{url:"https://api-goerli.arbiscan.io/"}}),e("matic",137,{ensNetwork:1,etherscan:{url:"https://api.polygonscan.com/"}}),e("matic-mumbai",80001,{altNames:["maticMumbai","maticmum"],etherscan:{url:"https://api-testnet.polygonscan.com/"}}),e("bnb",56,{ensNetwork:1,etherscan:{url:"http://api.bscscan.com"}}),e("bnbt",97,{etherscan:{url:"http://api-testnet.bscscan.com"}})}(),null==e)return s.from("mainnet");if("number"==typeof e&&(e=BigInt(e)),"string"==typeof e||"bigint"==typeof e){const t=a.get(e);if(t)return t();if("bigint"==typeof e)return new s("unknown",e);(0,i.assertArgument)(!1,"unknown network","network",e)}if("function"==typeof e.clone){return e.clone()}if("object"==typeof e){(0,i.assertArgument)("string"==typeof e.name&&"number"==typeof e.chainId,"invalid network object name or chainId","network",e);const t=new s(e.name,e.chainId);return(e.ensAddress||null!=e.ensNetwork)&&t.attachPlugin(new o.EnsPlugin(e.ensAddress,e.ensNetwork)),t}(0,i.assertArgument)(!1,"invalid network","network",e)}static register(e,t){"number"==typeof e&&(e=BigInt(e));const r=a.get(e);r&&(0,i.assertArgument)(!1,`conflicting network for ${JSON.stringify(r.name)}`,"nameOrChainId",e),a.set(e,t)}}t.Network=s;let u=!1},67004:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FeeDataNetworkPlugin=t.EnsPlugin=t.GasCostPlugin=t.NetworkPlugin=void 0;const n=r(39290),i=r(42120);class o{name;constructor(e){(0,n.defineProperties)(this,{name:e})}clone(){return new o(this.name)}}t.NetworkPlugin=o;class a extends o{effectiveBlock;txBase;txCreate;txDataZero;txDataNonzero;txAccessListStorageKey;txAccessListAddress;constructor(e,t){null==e&&(e=0),super(`org.ethers.network.plugins.GasCost#${e||0}`);const r={effectiveBlock:e};function o(e,n){let o=(t||{})[e];null==o&&(o=n),(0,i.assertArgument)("number"==typeof o,`invalud value for ${e}`,"costs",t),r[e]=o}o("txBase",21e3),o("txCreate",32e3),o("txDataZero",4),o("txDataNonzero",16),o("txAccessListStorageKey",1900),o("txAccessListAddress",2400),(0,n.defineProperties)(this,r)}clone(){return new a(this.effectiveBlock,this)}}t.GasCostPlugin=a;class s extends o{address;targetNetwork;constructor(e,t){super("org.ethers.plugins.network.Ens"),(0,n.defineProperties)(this,{address:e||"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",targetNetwork:null==t?1:t})}clone(){return new s(this.address,this.targetNetwork)}}t.EnsPlugin=s;class u extends o{#Y;get feeDataFunc(){return this.#Y}constructor(e){super("org.ethers.plugins.network.FeeData"),this.#Y=e}async getFeeData(e){return await this.#Y(e)}clone(){return new u(this.#Y)}}t.FeeDataNetworkPlugin=u},23815:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AlchemyProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC";class u extends a.JsonRpcProvider{apiKey;constructor(e,t){null==e&&(e="mainnet");const r=o.Network.from(e);null==t&&(t=s);super(u.getRequest(r,t),r,{staticNetwork:r}),(0,n.defineProperties)(this,{apiKey:t})}_getProvider(e){try{return new u(e,this.apiKey)}catch(e){}return super._getProvider(e)}async _perform(e){if("getTransactionResult"===e.method){const{trace:t,tx:r}=await(0,n.resolveProperties)({trace:this.send("trace_transaction",[e.hash]),tx:this.getTransaction(e.hash)});if(null==t||null==r)return null;let i,o=!1;try{i=t[0].result.output,o="Reverted"===t[0].error}catch(e){}if(i)return(0,n.assert)(!o,"an error occurred during transaction executions","CALL_EXCEPTION",{action:"getTransactionResult",data:i,reason:null,transaction:r,invocation:null,revert:null}),i;(0,n.assert)(!1,"could not parse trace result","BAD_DATA",{value:t})}return await super._perform(e)}isCommunityResource(){return this.apiKey===s}static getRequest(e,t){null==t&&(t=s);const r=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"eth-mainnet.alchemyapi.io";case"goerli":return"eth-goerli.g.alchemy.com";case"sepolia":return"eth-sepolia.g.alchemy.com";case"arbitrum":return"arb-mainnet.g.alchemy.com";case"arbitrum-goerli":return"arb-goerli.g.alchemy.com";case"matic":return"polygon-mainnet.g.alchemy.com";case"matic-mumbai":return"polygon-mumbai.g.alchemy.com";case"optimism":return"opt-mainnet.g.alchemy.com";case"optimism-goerli":return"opt-goerli.g.alchemy.com"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/v2/${t}`);return r.allowGzip=!0,t===s&&(r.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("alchemy"),!0)),r}}t.AlchemyProvider=u},16791:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AnkrProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";class u extends a.JsonRpcProvider{apiKey;constructor(e,t){null==e&&(e="mainnet");const r=o.Network.from(e);null==t&&(t=s);const i={polling:!0,staticNetwork:r};super(u.getRequest(r,t),r,i),(0,n.defineProperties)(this,{apiKey:t})}_getProvider(e){try{return new u(e,this.apiKey)}catch(e){}return super._getProvider(e)}static getRequest(e,t){null==t&&(t=s);const r=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"rpc.ankr.com/eth";case"goerli":return"rpc.ankr.com/eth_goerli";case"matic":return"rpc.ankr.com/polygon";case"arbitrum":return"rpc.ankr.com/arbitrum"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/${t}`);return r.allowGzip=!0,t===s&&(r.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("AnkrProvider"),!0)),r}getRpcError(e,t){return"eth_sendRawTransaction"===e.method&&t&&t.error&&"INTERNAL_ERROR: could not replace existing tx"===t.error.message&&(t.error.message="replacement transaction underpriced"),super.getRpcError(e,t)}isCommunityResource(){return this.apiKey===s}}t.AnkrProvider=u},30292:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BrowserProvider=void 0;const n=r(42120),i=r(32013);class o extends i.JsonRpcApiPollingProvider{#$;constructor(e,t){super(t,{batchMaxCount:1}),this.#$=async(t,r)=>{const n={method:t,params:r};this.emit("debug",{action:"sendEip1193Request",payload:n});try{const t=await e.request(n);return this.emit("debug",{action:"receiveEip1193Result",result:t}),t}catch(e){const t=new Error(e.message);throw t.code=e.code,t.data=e.data,t.payload=n,this.emit("debug",{action:"receiveEip1193Error",error:t}),t}}}async send(e,t){return await this._start(),await super.send(e,t)}async _send(e){(0,n.assertArgument)(!Array.isArray(e),"EIP-1193 does not support batch request","payload",e);try{const t=await this.#$(e.method,e.params||[]);return[{id:e.id,result:t}]}catch(t){return[{id:e.id,error:{code:t.code,data:t.data,message:t.message}}]}}getRpcError(e,t){switch((t=JSON.parse(JSON.stringify(t))).error.code||-1){case 4001:t.error.message=`ethers-user-denied: ${t.error.message}`;break;case 4200:t.error.message=`ethers-unsupported: ${t.error.message}`}return super.getRpcError(e,t)}async hasSigner(e){null==e&&(e=0);const t=await this.send("eth_accounts",[]);return"number"==typeof e?t.length>e:(e=e.toLowerCase(),0!==t.filter((t=>t.toLowerCase()===e)).length)}async getSigner(e){if(null==e&&(e=0),!await this.hasSigner(e))try{await this.#$("eth_requestAccounts",[])}catch(e){const t=e.payload;throw this.getRpcError(t,{id:t.id,error:e})}return await super.getSigner(e)}}t.BrowserProvider=o},3377:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CloudflareProvider=void 0;const n=r(42120),i=r(54837),o=r(32013);class a extends o.JsonRpcProvider{constructor(e){null==e&&(e="mainnet");const t=i.Network.from(e);(0,n.assertArgument)("mainnet"===t.name,"unsupported network","network",e),super("https://cloudflare-eth.com/",t,{staticNetwork:t})}}t.CloudflareProvider=a},22880:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EtherscanProvider=t.EtherscanPlugin=void 0;const n=r(93707),i=r(37252),o=r(2290),a=r(42120),s=r(55142),u=r(54837),c=r(67004),l=r(32813);const f="org.ethers.plugins.provider.Etherscan";class h extends c.NetworkPlugin{baseUrl;constructor(e){super(f),(0,a.defineProperties)(this,{baseUrl:e})}clone(){return new h(this.baseUrl)}}t.EtherscanPlugin=h;let d=1;class p extends s.AbstractProvider{network;apiKey;#ee;constructor(e,t){const r=null!=t?t:null;super();const n=u.Network.from(e);this.#ee=n.getPlugin(f),(0,a.defineProperties)(this,{apiKey:r,network:n}),this.getBaseUrl()}getBaseUrl(){if(this.#ee)return this.#ee.baseUrl;switch(this.network.name){case"mainnet":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"matic":return"https://api.polygonscan.com";case"matic-mumbai":return"https://api-testnet.polygonscan.com";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io"}(0,a.assertArgument)(!1,"unsupported network","network",this.network)}getUrl(e,t){const r=Object.keys(t).reduce(((e,r)=>{const n=t[r];return null!=n&&(e+=`&${r}=${n}`),e}),""),n=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.getBaseUrl()}/api?module=${e}${r}${n}`}getPostUrl(){return`${this.getBaseUrl()}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}async detectNetwork(){return this.network}async fetch(e,t,r){const n=d++,i=r?this.getPostUrl():this.getUrl(e,t),o=r?this.getPostData(e,t):null;this.emit("debug",{action:"sendRequest",id:n,url:i,payload:o});const s=new a.FetchRequest(i);s.setThrottleParams({slotInterval:1e3}),s.retryFunc=(e,t,r)=>(this.isCommunityResource()&&(0,l.showThrottleMessage)("Etherscan"),Promise.resolve(!0)),s.processFunc=async(t,r)=>{const i=r.hasBody()?JSON.parse((0,a.toUtf8String)(r.body)):{},o=("string"==typeof i.result?i.result:"").toLowerCase().indexOf("rate limit")>=0;return"proxy"===e?i&&0==i.status&&"NOTOK"==i.message&&o&&(this.emit("debug",{action:"receiveError",id:n,reason:"proxy-NOTOK",error:i}),r.throwThrottleError(i.result,2e3)):o&&(this.emit("debug",{action:"receiveError",id:n,reason:"null result",error:i.result}),r.throwThrottleError(i.result,2e3)),r},o&&(s.setHeader("content-type","application/x-www-form-urlencoded; charset=UTF-8"),s.body=Object.keys(o).map((e=>`${e}=${o[e]}`)).join("&"));const u=await s.send();try{u.assertOk()}catch(e){this.emit("debug",{action:"receiveError",id:n,error:e,reason:"assertOk"}),(0,a.assert)(!1,"response error","SERVER_ERROR",{request:s,response:u})}u.hasBody()||(this.emit("debug",{action:"receiveError",id:n,error:"missing body",reason:"null body"}),(0,a.assert)(!1,"missing response","SERVER_ERROR",{request:s,response:u}));const c=JSON.parse((0,a.toUtf8String)(u.body));return"proxy"===e?("2.0"!=c.jsonrpc&&(this.emit("debug",{action:"receiveError",id:n,result:c,reason:"invalid JSON-RPC"}),(0,a.assert)(!1,"invalid JSON-RPC response (missing jsonrpc='2.0')","SERVER_ERROR",{request:s,response:u,info:{result:c}})),c.error&&(this.emit("debug",{action:"receiveError",id:n,result:c,reason:"JSON-RPC error"}),(0,a.assert)(!1,"error response","SERVER_ERROR",{request:s,response:u,info:{result:c}})),this.emit("debug",{action:"receiveRequest",id:n,result:c}),c.result):0!=c.status||"No records found"!==c.message&&"No transactions found"!==c.message?((1!=c.status||"string"==typeof c.message&&!c.message.match(/^OK/))&&(this.emit("debug",{action:"receiveError",id:n,result:c}),(0,a.assert)(!1,"error response","SERVER_ERROR",{request:s,response:u,info:{result:c}})),this.emit("debug",{action:"receiveRequest",id:n,result:c}),c.result):(this.emit("debug",{action:"receiveRequest",id:n,result:c}),c.result)}_getTransactionPostData(e){const t={};for(let r in e){if(null==e[r])continue;let n=e[r];"type"===r&&0===n||(n={type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[r]?(0,a.toQuantity)(n):"accessList"===r?"["+(0,o.accessListify)(n).map((e=>`{address:"${e.address}",storageKeys:["${e.storageKeys.join('","')}"]}`)).join(",")+"]":(0,a.hexlify)(n),t[r]=n)}return t}_checkError(e,t,r){let i="";if((0,a.isError)(t,"SERVER_ERROR")){try{i=t.info.result.error.message}catch(e){}if(!i)try{i=t.info.message}catch(e){}}if("estimateGas"===e.method&&!i.match(/revert/i)&&i.match(/insufficient funds/i)&&(0,a.assert)(!1,"insufficient funds","INSUFFICIENT_FUNDS",{transaction:e.transaction}),("call"===e.method||"estimateGas"===e.method)&&i.match(/execution reverted/i)){let r="";try{r=t.info.result.error.data}catch(t){}const i=n.AbiCoder.getBuiltinCallException(e.method,e.transaction,r);throw i.info={request:e,error:t},i}if(i&&"broadcastTransaction"===e.method){const t=o.Transaction.from(e.signedTransaction);i.match(/replacement/i)&&i.match(/underpriced/i)&&(0,a.assert)(!1,"replacement fee too low","REPLACEMENT_UNDERPRICED",{transaction:t}),i.match(/insufficient funds/)&&(0,a.assert)(!1,"insufficient funds for intrinsic transaction cost","INSUFFICIENT_FUNDS",{transaction:t}),i.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&(0,a.assert)(!1,"nonce has already been used","NONCE_EXPIRED",{transaction:t})}throw t}async _detectNetwork(){return this.network}async _perform(e){switch(e.method){case"chainId":return this.network.chainId;case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:e.address,tag:e.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:e.address,tag:e.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:e.address,tag:e.blockTag});case"getStorage":return this.fetch("proxy",{action:"eth_getStorageAt",address:e.address,position:e.position,tag:e.blockTag});case"broadcastTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:e.signedTransaction},!0).catch((t=>this._checkError(e,t,e.signedTransaction)));case"getBlock":if("blockTag"in e)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:e.blockTag,boolean:e.includeTransactions?"true":"false"});(0,a.assert)(!1,"getBlock by blockHash not supported by Etherscan","UNSUPPORTED_OPERATION",{operation:"getBlock(blockHash)"});case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:e.hash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:e.hash});case"call":{if("latest"!==e.blockTag)throw new Error("EtherscanProvider does not support blockTag for call");const t=this._getTransactionPostData(e.transaction);t.module="proxy",t.action="eth_call";try{return await this.fetch("proxy",t,!0)}catch(t){return this._checkError(e,t,e.transaction)}}case"estimateGas":{const t=this._getTransactionPostData(e.transaction);t.module="proxy",t.action="eth_estimateGas";try{return await this.fetch("proxy",t,!0)}catch(t){return this._checkError(e,t,e.transaction)}}}return super._perform(e)}async getNetwork(){return this.network}async getEtherPrice(){return"mainnet"!==this.network.name?0:parseFloat((await this.fetch("stats",{action:"ethprice"})).ethusd)}async getContract(e){let t=this._getAddress(e);var r;(r=t)&&"function"==typeof r.then&&(t=await t);try{const e=await this.fetch("contract",{action:"getabi",address:t}),r=JSON.parse(e);return new i.Contract(t,r,this)}catch(e){return null}}isCommunityResource(){return null==this.apiKey}}t.EtherscanProvider=p},24129:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FallbackProvider=void 0;const n=r(42120),i=r(55142),o=r(54837),a=BigInt("1"),s=BigInt("2");function u(){return(new Date).getTime()}function c(e){return JSON.stringify(e,((e,t)=>"bigint"==typeof t?{type:"bigint",value:t.toString()}:t))}const l={stallTimeout:400,priority:1,weight:1},f={blockNumber:-2,requests:0,lateResponses:0,errorResponses:0,outOfSync:-1,unsupportedEvents:0,rollingDuration:0,score:0,_network:null,_updateNumber:null,_totalTime:0};function h(e){if(null==e)return"null";if(Array.isArray(e))return"["+e.map(h).join(",")+"]";if("object"==typeof e&&"function"==typeof e.toJSON)return h(e.toJSON());switch(typeof e){case"boolean":case"symbol":return e.toString();case"bigint":case"number":return BigInt(e).toString();case"string":return JSON.stringify(e);case"object":{const t=Object.keys(e);return t.sort(),"{"+t.map((t=>`${JSON.stringify(t)}:${h(e[t])}`)).join(",")+"}"}}throw console.log("Could not serialize",e),new Error("Hmm...")}function d(e){if("error"in e){const t=e.error;return{tag:h(t),value:t}}const t=e.result;return{tag:h(t),value:t}}function p(e,t){const r=new Map;for(const{value:e,tag:n,weight:i}of t){const t=r.get(n)||{value:e,weight:0};t.weight+=i,r.set(n,t)}let n=null;for(const t of r.values())t.weight>=e&&(!n||t.weight>n.weight)&&(n=t);if(n)return n.value}function m(e,t){let r=0;const n=new Map;let i=null;const o=[];for(const{value:e,tag:a,weight:s}of t)if(e instanceof Error){const t=n.get(a)||{value:e,weight:0};t.weight+=s,n.set(a,t),(null==i||t.weight>i.weight)&&(i=t)}else o.push(BigInt(e)),r+=s;if(r=e?i.value:void 0;o.sort(((e,t)=>ee?1:0));const u=Math.floor(o.length/2);return o.length%2?o[u]:(o[u-1]+o[u]+a)/s}function y(e,t){const r=p(e,t);if(void 0!==r)return r;for(const e of t)if(e.value)return e.value}class g extends i.AbstractProvider{quorum;eventQuorum;eventWorkers;#te;#re;#ne;constructor(e,t){super(t),this.#te=e.map((e=>e instanceof i.AbstractProvider?Object.assign({provider:e},l,f):Object.assign({},l,e,f))),this.#re=-2,this.#ne=null,this.quorum=2,this.eventQuorum=1,this.eventWorkers=1,(0,n.assertArgument)(this.quorum<=this.#te.reduce(((e,t)=>e+t.weight),0),"quorum exceed provider wieght","quorum",this.quorum)}get providerConfigs(){return this.#te.map((e=>{const t=Object.assign({},e);for(const e in t)"_"===e[0]&&delete t[e];return t}))}async _detectNetwork(){return o.Network.from((0,n.getBigInt)(await this._perform({method:"chainId"})))}async _translatePerform(e,t){switch(t.method){case"broadcastTransaction":return await e.broadcastTransaction(t.signedTransaction);case"call":return await e.call(Object.assign({},t.transaction,{blockTag:t.blockTag}));case"chainId":return(await e.getNetwork()).chainId;case"estimateGas":return await e.estimateGas(t.transaction);case"getBalance":return await e.getBalance(t.address,t.blockTag);case"getBlock":{const r="blockHash"in t?t.blockHash:t.blockTag;return await e.getBlock(r,t.includeTransactions)}case"getBlockNumber":return await e.getBlockNumber();case"getCode":return await e.getCode(t.address,t.blockTag);case"getGasPrice":return(await e.getFeeData()).gasPrice;case"getLogs":return await e.getLogs(t.filter);case"getStorage":return await e.getStorage(t.address,t.position,t.blockTag);case"getTransaction":return await e.getTransaction(t.hash);case"getTransactionCount":return await e.getTransactionCount(t.address,t.blockTag);case"getTransactionReceipt":return await e.getTransactionReceipt(t.hash);case"getTransactionResult":return await e.getTransactionResult(t.hash)}}#ie(e){const t=Array.from(e).map((e=>e.config)),r=this.#te.slice();!function(e){for(let t=e.length-1;t>0;t--){const r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}}(r),r.sort(((e,t)=>t.priority-e.priority));for(const e of r)if(-1===t.indexOf(e))return e;return null}#oe(e,t){const r=this.#ie(e);if(null==r)return null;const n={config:r,result:null,didBump:!1,perform:null,staller:null},i=u();return n.perform=(async()=>{try{r.requests++;const e=await this._translatePerform(r.provider,t);n.result={result:e}}catch(e){r.errorResponses++,n.result={error:e}}const e=u()-i;r._totalTime+=e,r.rollingDuration=.95*r.rollingDuration+.05*e,n.perform=null})(),n.staller=(async()=>{var e;await(e=r.stallTimeout,new Promise((t=>{setTimeout(t,e)}))),n.staller=null})(),e.add(n),n}async#ae(){let e=this.#ne;if(!e){const t=[];this.#te.forEach((e=>{t.push(async function(e,t){for(;e.blockNumber<0||e.blockNumber{const t=await e.provider.getBlockNumber();t>e.blockNumber&&(e.blockNumber=t),e._updateNumber=null})()),await e._updateNumber,e.outOfSync++}(e,0)),t.push((async()=>{e._network=await e.provider.getNetwork()})())})),this.#ne=e=(async()=>{await Promise.all(t);let e=null;for(const t of this.#te){const r=t._network;null==e?e=r.chainId:r.chainId!==e&&(0,n.assert)(!1,"cannot mix providers on different networks","UNSUPPORTED_OPERATION",{operation:"new FallbackProvider"})}})()}await e}async#se(e,t){const r=[];for(const t of e)if(null!=t.result){const{tag:e,value:n}=d(t.result);r.push({tag:e,value:n,weight:t.config.weight})}if(!(r.reduce(((e,t)=>e+t.weight),0)({value:e.blockNumber,tag:(0,n.getNumber)(e.blockNumber).toString(),weight:e.weight})))))));const e=function(e,t){if(1===e)return(0,n.getNumber)(m(e,t),"%internal");const r=new Map,i=(e,t)=>{const n=r.get(e)||{result:e,weight:0};n.weight+=t,r.set(e,n)};for(const{weight:e,value:r}of t){const t=(0,n.getNumber)(r);i(t-1,e),i(t,e),i(t+1,e)}let o,a=0;for(const{weight:t,result:n}of r.values())t>=e&&(t>a||null!=o&&t===a&&n>o)&&(a=t,o=n);return o}(this.quorum,r);if(void 0===e)return;return e>this.#re&&(this.#re=e),this.#re}case"getGasPrice":case"estimateGas":return m(this.quorum,r);case"getBlock":return"blockTag"in t&&"pending"===t.blockTag?y(this.quorum,r):p(this.quorum,r);case"call":case"chainId":case"getBalance":case"getTransactionCount":case"getCode":case"getStorage":case"getTransaction":case"getTransactionReceipt":case"getLogs":return p(this.quorum,r);case"broadcastTransaction":return y(this.quorum,r)}(0,n.assert)(!1,"unsupported method","UNSUPPORTED_OPERATION",{operation:`_perform(${c(t.method)})`})}}async#ue(e,t){if(0===e.size)throw new Error("no runners?!");const r=[];let i=0;for(const t of e)t.perform&&r.push(t.perform),t.staller?r.push(t.staller):t.didBump||(t.didBump=!0,i++);const o=await this.#se(e,t);if(void 0!==o){if(o instanceof Error)throw o;return o}for(let r=0;r0,"quorum not met","SERVER_ERROR",{request:"%sub-requests",info:{request:t,results:Array.from(e).map((e=>c(e.result)))}}),await Promise.race(r),await this.#ue(e,t)}async _perform(e){if("broadcastTransaction"===e.method){const t=await Promise.all(this.#te.map((async({provider:t,weight:r})=>{try{const n=await t._perform(e);return Object.assign(d({result:n}),{weight:r})}catch(e){return Object.assign(d({error:e}),{weight:r})}}))),r=y(this.quorum,t);if((0,n.assert)(void 0!==r,"problem multi-broadcasting","SERVER_ERROR",{request:"%sub-requests",info:{request:e,results:t.map(c)}}),r instanceof Error)throw r;return r}await this.#ae();const t=new Set;for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InfuraProvider=t.InfuraWebSocketProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s=r(62196),u="84842078b09946638c03157f83405213";class c extends s.WebSocketProvider{projectId;projectSecret;constructor(e,t){const r=new l(e,t),i=r._getConnection();(0,n.assert)(!i.credentials,"INFURA WebSocket project secrets unsupported","UNSUPPORTED_OPERATION",{operation:"InfuraProvider.getWebSocketProvider()"});super(i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/"),e),(0,n.defineProperties)(this,{projectId:r.projectId,projectSecret:r.projectSecret})}isCommunityResource(){return this.projectId===u}}t.InfuraWebSocketProvider=c;class l extends a.JsonRpcProvider{projectId;projectSecret;constructor(e,t,r){null==e&&(e="mainnet");const i=o.Network.from(e);null==t&&(t=u),null==r&&(r=null);super(l.getRequest(i,t,r),i,{staticNetwork:i}),(0,n.defineProperties)(this,{projectId:t,projectSecret:r})}_getProvider(e){try{return new l(e,this.projectId,this.projectSecret)}catch(e){}return super._getProvider(e)}isCommunityResource(){return this.projectId===u}static getWebSocketProvider(e,t){return new c(e,t)}static getRequest(e,t,r){null==t&&(t=u),null==r&&(r=null);const o=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"mainnet.infura.io";case"goerli":return"goerli.infura.io";case"sepolia":return"sepolia.infura.io";case"arbitrum":return"arbitrum-mainnet.infura.io";case"arbitrum-goerli":return"arbitrum-goerli.infura.io";case"matic":return"polygon-mainnet.infura.io";case"matic-mumbai":return"polygon-mumbai.infura.io";case"optimism":return"optimism-mainnet.infura.io";case"optimism-goerli":return"optimism-goerli.infura.io"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/v3/${t}`);return o.allowGzip=!0,r&&o.setCredentials("",r),t===u&&(o.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("InfuraProvider"),!0)),o}}t.InfuraProvider=l},74019:(e,t,r)=>{"use strict";var n=r(48764).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.IpcSocketProvider=void 0;const i=r(47444),o=r(12394);class a extends o.SocketProvider{#ce;get socket(){return this.#ce}constructor(e,t){super(t),this.#ce=(0,i.connect)(e),this.socket.on("ready",(async()=>{try{await this._start()}catch(e){console.log("failed to start IpcSocketProvider",e)}}));let r=n.alloc(0);this.socket.on("data",(e=>{r=n.concat([r,e]);const{messages:t,remaining:i}=function(e){const t=[];let r=0;for(;;){const n=e.indexOf(10,r);if(-1===n)break;t.push(e.subarray(r,n).toString().trim()),r=n+1}return{messages:t,remaining:e.subarray(r)}}(r);t.forEach((e=>{this._processMessage(e)})),r=i})),this.socket.on("end",(()=>{this.emit("close"),this.socket.destroy(),this.socket.end()}))}destroy(){this.socket.destroy(),this.socket.end(),super.destroy()}async _write(e){console.log(">>>",e),this.socket.write(e)}}t.IpcSocketProvider=a},32013:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.JsonRpcProvider=t.JsonRpcApiPollingProvider=t.JsonRpcApiProvider=t.JsonRpcSigner=void 0;const n=r(93707),i=r(45475),o=r(98336),a=r(2290),s=r(42120),u=r(55142),c=r(35649),l=r(54837),f=r(21570),h=r(21097),d="bigint,boolean,function,number,string,symbol".split(/,/g);function p(e){if(null==e||d.indexOf(typeof e)>=0)return e;if("function"==typeof e.getAddress)return e;if(Array.isArray(e))return e.map(p);if("object"==typeof e)return Object.keys(e).reduce(((t,r)=>(t[r]=e[r],t)),{});throw new Error(`should not happen: ${e} (${typeof e})`)}function m(e){return new Promise((t=>{setTimeout(t,e)}))}function y(e){return e?e.toLowerCase():e}function g(e){return e&&"number"==typeof e.pollingInterval}const b={polling:!1,staticNetwork:null,batchStallTime:10,batchMaxSize:1<<20,batchMaxCount:100};class v extends c.AbstractSigner{address;constructor(e,t){super(e),t=(0,i.getAddress)(t),(0,s.defineProperties)(this,{address:t})}connect(e){(0,s.assert)(!1,"cannot reconnect JsonRpcSigner","UNSUPPORTED_OPERATION",{operation:"signer.connect"})}async getAddress(){return this.address}async populateTransaction(e){return await this.populateCall(e)}async sendUncheckedTransaction(e){const t=p(e),r=[];if(t.from){const n=t.from;r.push((async()=>{const r=await(0,i.resolveAddress)(n,this.provider);(0,s.assertArgument)(null!=r&&r.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",e),t.from=r})())}else t.from=this.address;if(null==t.gasLimit&&r.push((async()=>{t.gasLimit=await this.provider.estimateGas({...t,from:this.address})})()),null!=t.to){const e=t.to;r.push((async()=>{t.to=await(0,i.resolveAddress)(e,this.provider)})())}r.length&&await Promise.all(r);const n=this.provider.getRpcTransaction(t);return this.provider.send("eth_sendTransaction",[n])}async sendTransaction(e){const t=await this.provider.getBlockNumber(),r=await this.sendUncheckedTransaction(e);return await new Promise(((e,n)=>{const i=[1e3,100],o=async()=>{const n=await this.provider.getTransaction(r);null==n?this.provider._setTimeout((()=>{o()}),i.pop()||4e3):e(n.replaceableTransaction(t))};o()}))}async signTransaction(e){const t=p(e);if(t.from){const r=await(0,i.resolveAddress)(t.from,this.provider);(0,s.assertArgument)(null!=r&&r.toLowerCase()===this.address.toLowerCase(),"from address mismatch","transaction",e),t.from=r}else t.from=this.address;const r=this.provider.getRpcTransaction(t);return await this.provider.send("eth_signTransaction",[r])}async signMessage(e){const t="string"==typeof e?(0,s.toUtf8Bytes)(e):e;return await this.provider.send("personal_sign",[(0,s.hexlify)(t),this.address.toLowerCase()])}async signTypedData(e,t,r){const n=p(r),a=await o.TypedDataEncoder.resolveNames(e,t,n,(async e=>{const t=await(0,i.resolveAddress)(e);return(0,s.assertArgument)(null!=t,"TypedData does not support null address","value",e),t}));return await this.provider.send("eth_signTypedData_v4",[this.address.toLowerCase(),JSON.stringify(o.TypedDataEncoder.getPayload(a.domain,t,a.value))])}async unlock(e){return this.provider.send("personal_unlockAccount",[this.address.toLowerCase(),e,null])}async _legacySignMessage(e){const t="string"==typeof e?(0,s.toUtf8Bytes)(e):e;return await this.provider.send("eth_sign",[this.address.toLowerCase(),(0,s.hexlify)(t)])}}t.JsonRpcSigner=v;class w extends u.AbstractProvider{#y;#le;#fe;#he;#de;#pe;#me(){if(this.#he)return;const e=1===this._getOption("batchMaxCount")?0:this._getOption("batchStallTime");this.#he=setTimeout((()=>{this.#he=null;const e=this.#fe;for(this.#fe=[];e.length;){const t=[e.shift()];for(;e.length&&t.length!==this.#y.batchMaxCount;){t.push(e.shift());if(JSON.stringify(t.map((e=>e.payload))).length>this.#y.batchMaxSize){e.unshift(t.pop());break}}(async()=>{const e=1===t.length?t[0].payload:t.map((e=>e.payload));this.emit("debug",{action:"sendRpcPayload",payload:e});try{const r=await this._send(e);this.emit("debug",{action:"receiveRpcResult",result:r});for(const{resolve:e,reject:n,payload:i}of t){const t=r.filter((e=>e.id===i.id))[0];if(null==t)return n(new Error("@TODO: no result"));if("error"in t)return n(this.getRpcError(i,t));e(t.result)}}catch(e){this.emit("debug",{action:"receiveRpcError",error:e});for(const{reject:r}of t)r(e)}})()}}),e)}constructor(e,t){super(e),this.#le=1,this.#y=Object.assign({},b,t||{}),this.#fe=[],this.#he=null,this.#pe=null;{let e=null;const t=new Promise((t=>{e=t}));this.#de={promise:t,resolve:e}}const r=this._getOption("staticNetwork");r&&((0,s.assertArgument)(r===e,"staticNetwork MUST match network object","options",t),this.#pe=r)}_getOption(e){return this.#y[e]}get _network(){return(0,s.assert)(this.#pe,"network is not available yet","NETWORK_ERROR"),this.#pe}async _perform(e){if("call"===e.method||"estimateGas"===e.method){let t=e.transaction;if(t&&null!=t.type&&(0,s.getBigInt)(t.type)&&null==t.maxFeePerGas&&null==t.maxPriorityFeePerGas){const r=await this.getFeeData();null==r.maxFeePerGas&&null==r.maxPriorityFeePerGas&&(e=Object.assign({},e,{transaction:Object.assign({},t,{type:void 0})}))}}const t=this.getRpcRequest(e);return null!=t?await this.send(t.method,t.args):super._perform(e)}async _detectNetwork(){const e=this._getOption("staticNetwork");if(e)return e;if(this.ready)return l.Network.from((0,s.getBigInt)(await this.send("eth_chainId",[])));const t={id:this.#le++,method:"eth_chainId",params:[],jsonrpc:"2.0"};let r;this.emit("debug",{action:"sendRpcPayload",payload:t});try{r=(await this._send(t))[0]}catch(e){throw this.emit("debug",{action:"receiveRpcError",error:e}),e}if(this.emit("debug",{action:"receiveRpcResult",result:r}),"result"in r)return l.Network.from((0,s.getBigInt)(r.result));throw this.getRpcError(t,r)}_start(){null!=this.#de&&null!=this.#de.resolve&&(this.#de.resolve(),this.#de=null,(async()=>{for(;null==this.#pe;)try{this.#pe=await this._detectNetwork()}catch(e){console.log("JsonRpcProvider failed to startup; retry in 1s"),await m(1e3)}this.#me()})())}async _waitUntilReady(){if(null!=this.#de)return await this.#de.promise}_getSubscriber(e){return"pending"===e.type?new f.FilterIdPendingSubscriber(this):"event"===e.type?this._getOption("polling")?new h.PollingEventSubscriber(this,e.filter):new f.FilterIdEventSubscriber(this,e.filter):"orphan"===e.type&&"drop-log"===e.filter.orphan?new u.UnmanagedSubscriber("orphan"):super._getSubscriber(e)}get ready(){return null==this.#de}getRpcTransaction(e){const t={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach((r=>{if(null==e[r])return;let n=r;"gasLimit"===r&&(n="gas"),t[n]=(0,s.toQuantity)((0,s.getBigInt)(e[r],`tx.${r}`))})),["from","to","data"].forEach((r=>{null!=e[r]&&(t[r]=(0,s.hexlify)(e[r]))})),e.accessList&&(t.accessList=(0,a.accessListify)(e.accessList)),t}getRpcRequest(e){switch(e.method){case"chainId":return{method:"eth_chainId",args:[]};case"getBlockNumber":return{method:"eth_blockNumber",args:[]};case"getGasPrice":return{method:"eth_gasPrice",args:[]};case"getBalance":return{method:"eth_getBalance",args:[y(e.address),e.blockTag]};case"getTransactionCount":return{method:"eth_getTransactionCount",args:[y(e.address),e.blockTag]};case"getCode":return{method:"eth_getCode",args:[y(e.address),e.blockTag]};case"getStorage":return{method:"eth_getStorageAt",args:[y(e.address),"0x"+e.position.toString(16),e.blockTag]};case"broadcastTransaction":return{method:"eth_sendRawTransaction",args:[e.signedTransaction]};case"getBlock":if("blockTag"in e)return{method:"eth_getBlockByNumber",args:[e.blockTag,!!e.includeTransactions]};if("blockHash"in e)return{method:"eth_getBlockByHash",args:[e.blockHash,!!e.includeTransactions]};break;case"getTransaction":return{method:"eth_getTransactionByHash",args:[e.hash]};case"getTransactionReceipt":return{method:"eth_getTransactionReceipt",args:[e.hash]};case"call":return{method:"eth_call",args:[this.getRpcTransaction(e.transaction),e.blockTag]};case"estimateGas":return{method:"eth_estimateGas",args:[this.getRpcTransaction(e.transaction)]};case"getLogs":return e.filter&&null!=e.filter.address&&(Array.isArray(e.filter.address)?e.filter.address=e.filter.address.map(y):e.filter.address=y(e.filter.address)),{method:"eth_getLogs",args:[e.filter]}}return null}getRpcError(e,t){const{method:r}=e,{error:i}=t;if("eth_estimateGas"===r&&i.message){const t=i.message;if(!t.match(/revert/i)&&t.match(/insufficient funds/i))return(0,s.makeError)("insufficient funds","INSUFFICIENT_FUNDS",{transaction:e.params[0]})}if("eth_call"===r||"eth_estimateGas"===r){const t=S(i),o=n.AbiCoder.getBuiltinCallException("eth_call"===r?"call":"estimateGas",e.params[0],t?t.data:null);return o.info={error:i,payload:e},o}const o=JSON.stringify(function(e){const t=[];return k(e,t),t}(i));if("string"==typeof i.message&&i.message.match(/user denied|ethers-user-denied/i)){const t={eth_sign:"signMessage",personal_sign:"signMessage",eth_signTypedData_v4:"signTypedData",eth_signTransaction:"signTransaction",eth_sendTransaction:"sendTransaction",eth_requestAccounts:"requestAccess",wallet_requestAccounts:"requestAccess"};return(0,s.makeError)("user rejected action","ACTION_REJECTED",{action:t[r]||"unknown",reason:"rejected",info:{payload:e,error:i}})}if("eth_sendRawTransaction"===r||"eth_sendTransaction"===r){const t=e.params[0];if(o.match(/insufficient funds|base fee exceeds gas limit/i))return(0,s.makeError)("insufficient funds for intrinsic transaction cost","INSUFFICIENT_FUNDS",{transaction:t,info:{error:i}});if(o.match(/nonce/i)&&o.match(/too low/i))return(0,s.makeError)("nonce has already been used","NONCE_EXPIRED",{transaction:t});if(o.match(/replacement transaction/i)&&o.match(/underpriced/i))return(0,s.makeError)("replacement fee too low","REPLACEMENT_UNDERPRICED",{transaction:t});if(o.match(/only replay-protected/i))return(0,s.makeError)("legacy pre-eip-155 transactions not supported","UNSUPPORTED_OPERATION",{operation:r,info:{transaction:t}})}return o.match(/the method .* does not exist/i)?(0,s.makeError)("unsupported operation","UNSUPPORTED_OPERATION",{operation:e.method,info:{error:i}}):(0,s.makeError)("could not coalesce error","UNKNOWN_ERROR",{error:i})}send(e,t){const r=this.#le++,n=new Promise(((n,i)=>{this.#fe.push({resolve:n,reject:i,payload:{method:e,params:t,id:r,jsonrpc:"2.0"}})}));return this.#me(),n}async getSigner(e){null==e&&(e=0);const t=this.send("eth_accounts",[]);if("number"==typeof e){const r=await t;if(e>=r.length)throw new Error("no such account");return new v(this,r[e])}const{accounts:r}=await(0,s.resolveProperties)({network:this.getNetwork(),accounts:t});e=(0,i.getAddress)(e);for(const t of r)if((0,i.getAddress)(t)===e)return new v(this,e);throw new Error("invalid account")}async listAccounts(){return(await this.send("eth_accounts",[])).map((e=>new v(this,e)))}}t.JsonRpcApiProvider=w;class A extends w{#ye;constructor(e,t){super(e,t),this.#ye=4e3}_getSubscriber(e){const t=super._getSubscriber(e);return g(t)&&(t.pollingInterval=this.#ye),t}get pollingInterval(){return this.#ye}set pollingInterval(e){if(!Number.isInteger(e)||e<0)throw new Error("invalid interval");this.#ye=e,this._forEachSubscriber((e=>{g(e)&&(e.pollingInterval=this.#ye)}))}}t.JsonRpcApiPollingProvider=A;function S(e){if(null==e)return null;if("string"==typeof e.message&&e.message.match("reverted")&&(0,s.isHexString)(e.data))return{message:e.message,data:e.data};if("object"==typeof e){for(const t in e){const r=S(e[t]);if(r)return r}return null}if("string"==typeof e)try{return S(JSON.parse(e))}catch(e){}return null}function k(e,t){if(null!=e){if("string"==typeof e.message&&t.push(e.message),"object"==typeof e)for(const r in e)k(e[r],t);if("string"==typeof e)try{return k(JSON.parse(e),t)}catch(e){}}}t.JsonRpcProvider=class extends A{#ge;constructor(e,t,r){null==e&&(e="http://localhost:8545"),super(t,r),this.#ge="string"==typeof e?new s.FetchRequest(e):e.clone()}_getConnection(){return this.#ge.clone()}async send(e,t){return await this._start(),await super.send(e,t)}async _send(e){const t=this._getConnection();t.body=JSON.stringify(e),t.setHeader("content-type","application/json");const r=await t.send();r.assertOk();let n=r.bodyJson;return Array.isArray(n)||(n=[n]),n}}},52751:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PocketProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="62e1ad51b37b8e00394bda3b";class u extends a.JsonRpcProvider{applicationId;applicationSecret;constructor(e,t,r){null==e&&(e="mainnet");const i=o.Network.from(e);null==t&&(t=s),null==r&&(r=null);const a={staticNetwork:i};super(u.getRequest(i,t,r),i,a),(0,n.defineProperties)(this,{applicationId:t,applicationSecret:r})}_getProvider(e){try{return new u(e,this.applicationId,this.applicationSecret)}catch(e){}return super._getProvider(e)}static getRequest(e,t,r){null==t&&(t=s);const o=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"eth-mainnet.gateway.pokt.network";case"goerli":return"eth-goerli.gateway.pokt.network";case"matic":return"poly-mainnet.gateway.pokt.network";case"matic-mumbai":return"polygon-mumbai-rpc.gateway.pokt.network"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/v1/lb/${t}`);return o.allowGzip=!0,r&&o.setCredentials("",r),t===s&&(o.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("PocketProvider"),!0)),o}isCommunityResource(){return this.applicationId===s}}t.PocketProvider=u},81333:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.QuickNodeProvider=void 0;const n=r(42120),i=r(32813),o=r(54837),a=r(32013),s="919b412a057b5e9c9b6dce193c5a60242d6efadb";class u extends a.JsonRpcProvider{token;constructor(e,t){null==e&&(e="mainnet");const r=o.Network.from(e);null==t&&(t=s);super(u.getRequest(r,t),r,{staticNetwork:r}),(0,n.defineProperties)(this,{token:t})}_getProvider(e){try{return new u(e,this.token)}catch(e){}return super._getProvider(e)}isCommunityResource(){return this.token===s}static getRequest(e,t){null==t&&(t=s);const r=new n.FetchRequest(`https://${function(e){switch(e){case"mainnet":return"ethers.quiknode.pro";case"goerli":return"ethers.ethereum-goerli.quiknode.pro";case"arbitrum":return"ethers.arbitrum-mainnet.quiknode.pro";case"arbitrum-goerli":return"ethers.arbitrum-goerli.quiknode.pro";case"matic":return"ethers.matic.quiknode.pro";case"matic-mumbai":return"ethers.matic-testnet.quiknode.pro";case"optimism":return"ethers.optimism.quiknode.pro";case"optimism-goerli":return"ethers.optimism-goerli.quiknode.pro"}(0,n.assertArgument)(!1,"unsupported network","network",e)}(e.name)}/${t}`);return r.allowGzip=!0,t===s&&(r.retryFunc=async(e,t,r)=>((0,i.showThrottleMessage)("QuickNodeProvider"),!0)),r}}t.QuickNodeProvider=u},12394:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SocketProvider=t.SocketEventSubscriber=t.SocketPendingSubscriber=t.SocketBlockSubscriber=t.SocketSubscriber=void 0;const n=r(55142),i=r(42120),o=r(32013);class a{#be;#g;get filter(){return JSON.parse(this.#g)}#ve;#we;#Ae;constructor(e,t){this.#be=e,this.#g=JSON.stringify(t),this.#ve=null,this.#we=null,this.#Ae=null}start(){this.#ve=this.#be.send("eth_subscribe",this.filter).then((e=>(this.#be._register(e,this),e)))}stop(){this.#ve.then((e=>{this.#be.send("eth_unsubscribe",[e])})),this.#ve=null}pause(e){(0,i.assert)(e,"preserve logs while paused not supported by SocketSubscriber yet","UNSUPPORTED_OPERATION",{operation:"pause(false)"}),this.#we=!!e}resume(){this.#we=null}_handleMessage(e){if(null!=this.#ve&&null===this.#we){let t=this.#Ae;t=null==t?this._emit(this.#be,e):t.then((async()=>{await this._emit(this.#be,e)})),this.#Ae=t.then((()=>{this.#Ae===t&&(this.#Ae=null)}))}}async _emit(e,t){throw new Error("sub-classes must implemente this; _emit")}}t.SocketSubscriber=a;class s extends a{constructor(e){super(e,["newHeads"])}async _emit(e,t){e.emit("block",parseInt(t.number))}}t.SocketBlockSubscriber=s;class u extends a{constructor(e){super(e,["newPendingTransactions"])}async _emit(e,t){e.emit("pending",t)}}t.SocketPendingSubscriber=u;class c extends a{#Se;get logFilter(){return JSON.parse(this.#Se)}constructor(e,t){super(e,["logs",t]),this.#Se=JSON.stringify(t)}async _emit(e,t){e.emit(this.#Se,e._wrapLog(t,e._network))}}t.SocketEventSubscriber=c;class l extends o.JsonRpcApiProvider{#ke;#x;#Ee;constructor(e){super(e,{batchMaxCount:1}),this.#ke=new Map,this.#x=new Map,this.#Ee=new Map}_getSubscriber(e){switch(e.type){case"close":return new n.UnmanagedSubscriber("close");case"block":return new s(this);case"pending":return new u(this);case"event":return new c(this,e.filter);case"orphan":if("drop-log"===e.filter.orphan)return new n.UnmanagedSubscriber("drop-log")}return super._getSubscriber(e)}_register(e,t){this.#x.set(e,t);const r=this.#Ee.get(e);if(r){for(const e of r)t._handleMessage(e);this.#Ee.delete(e)}}async _send(e){(0,i.assertArgument)(!Array.isArray(e),"WebSocket does not support batch send","payload",e);const t=new Promise(((t,r)=>{this.#ke.set(e.id,{payload:e,resolve:t,reject:r})}));return await this._waitUntilReady(),await this._write(JSON.stringify(e)),[await t]}async _processMessage(e){const t=JSON.parse(e);if("id"in t){const e=this.#ke.get(t.id);if(null==e)return void console.log("Weird... Response for not a thing we sent");this.#ke.delete(t.id),e.resolve(t)}else if("eth_subscription"===t.method){const e=t.params.subscription,r=this.#x.get(e);if(r)r._handleMessage(t.params.result);else{let r=this.#Ee.get(e);null==r&&(r=[],this.#Ee.set(e,r)),r.push(t.params.result)}}}async _write(e){throw new Error("sub-classes must override this")}}t.SocketProvider=l},62196:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebSocketProvider=void 0;const n=r(39896),i=r(12394);class o extends i.SocketProvider{#ge;#_e;get websocket(){if(null==this.#_e)throw new Error("websocket closed");return this.#_e}constructor(e,t){super(t),"string"==typeof e?(this.#ge=()=>new n.WebSocket(e),this.#_e=this.#ge()):"function"==typeof e?(this.#ge=e,this.#_e=e()):(this.#ge=null,this.#_e=e),this.websocket.onopen=async()=>{try{await this._start(),this.resume()}catch(e){console.log("failed to start WebsocketProvider",e)}},this.websocket.onmessage=e=>{this._processMessage(e.data)}}async _write(e){this.websocket.send(e)}async destroy(){null!=this.#_e&&(this.#_e.close(),this.#_e=null),super.destroy()}}t.WebSocketProvider=o},37143:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionResponse=t.TransactionReceipt=t.Log=t.Block=t.copyRequest=t.FeeData=void 0;const n=r(42120),i=r(2290),o=BigInt(0);function a(e){return null==e?null:e}function s(e){return null==e?null:e.toString()}t.FeeData=class{gasPrice;maxFeePerGas;maxPriorityFeePerGas;constructor(e,t,r){(0,n.defineProperties)(this,{gasPrice:a(e),maxFeePerGas:a(t),maxPriorityFeePerGas:a(r)})}toJSON(){const{gasPrice:e,maxFeePerGas:t,maxPriorityFeePerGas:r}=this;return{_type:"FeeData",gasPrice:s(e),maxFeePerGas:s(t),maxPriorityFeePerGas:s(r)}}},t.copyRequest=function(e){const t={};e.to&&(t.to=e.to),e.from&&(t.from=e.from),e.data&&(t.data=(0,n.hexlify)(e.data));const r="chainId,gasLimit,gasPrice,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);for(const i of r)i in e&&null!=e[i]&&(t[i]=(0,n.getBigInt)(e[i],`request.${i}`));const o="type,nonce".split(/,/);for(const r of o)r in e&&null!=e[r]&&(t[r]=(0,n.getNumber)(e[r],`request.${r}`));return e.accessList&&(t.accessList=(0,i.accessListify)(e.accessList)),"blockTag"in e&&(t.blockTag=e.blockTag),"enableCcipRead"in e&&(t.enableCcipReadEnabled=!!e.enableCcipRead),"customData"in e&&(t.customData=e.customData),t};class u{provider;number;hash;timestamp;parentHash;nonce;difficulty;gasLimit;gasUsed;miner;extraData;baseFeePerGas;#Me;constructor(e,t){this.#Me=e.transactions.map((e=>"string"!=typeof e?new f(e,t):e)),(0,n.defineProperties)(this,{provider:t,hash:a(e.hash),number:e.number,timestamp:e.timestamp,parentHash:e.parentHash,nonce:e.nonce,difficulty:e.difficulty,gasLimit:e.gasLimit,gasUsed:e.gasUsed,miner:e.miner,extraData:e.extraData,baseFeePerGas:a(e.baseFeePerGas)})}get transactions(){return this.#Me.map((e=>"string"==typeof e?e:e.hash))}get prefetchedTransactions(){const e=this.#Me.slice();return 0===e.length?[]:((0,n.assert)("object"==typeof e[0],"transactions were not prefetched with block request","UNSUPPORTED_OPERATION",{operation:"transactionResponses()"}),e)}toJSON(){const{baseFeePerGas:e,difficulty:t,extraData:r,gasLimit:n,gasUsed:i,hash:o,miner:a,nonce:u,number:c,parentHash:l,timestamp:f,transactions:h}=this;return{_type:"Block",baseFeePerGas:s(e),difficulty:s(t),extraData:r,gasLimit:s(n),gasUsed:s(i),hash:o,miner:a,nonce:u,number:c,parentHash:l,timestamp:f,transactions:h}}[Symbol.iterator](){let e=0;const t=this.transactions;return{next:()=>enew c(e,t)))),(0,n.defineProperties)(this,{provider:t,to:e.to,from:e.from,contractAddress:e.contractAddress,hash:e.hash,index:e.index,blockHash:e.blockHash,blockNumber:e.blockNumber,logsBloom:e.logsBloom,gasUsed:e.gasUsed,cumulativeGasUsed:e.cumulativeGasUsed,gasPrice:e.effectiveGasPrice||e.gasPrice,type:e.type,status:e.status,root:e.root})}get logs(){return this.#Te}toJSON(){const{to:e,from:t,contractAddress:r,hash:n,index:i,blockHash:o,blockNumber:a,logsBloom:u,logs:c,status:l,root:f}=this;return{_type:"TransactionReceipt",blockHash:o,blockNumber:a,contractAddress:r,cumulativeGasUsed:s(this.cumulativeGasUsed),from:t,gasPrice:s(this.gasPrice),gasUsed:s(this.gasUsed),hash:n,index:i,logs:c,logsBloom:u,root:f,status:l,to:e}}get length(){return this.logs.length}[Symbol.iterator](){let e=0;return{next:()=>e{if(u)return null;const{blockNumber:e,nonce:t}=await(0,n.resolveProperties)({blockNumber:this.provider.getBlockNumber(),nonce:this.provider.getTransactionCount(this.from)});if(t=r)return l}else if(await c(),0===r)return null;const f=new Promise(((e,t)=>{const o=[],s=()=>{o.forEach((e=>e()))};if(o.push((()=>{u=!0})),i>0){const e=setTimeout((()=>{s(),t((0,n.makeError)("wait for transaction timeout","TIMEOUT"))}),i);o.push((()=>{clearTimeout(e)}))}const l=async t=>{await t.confirmations()>=r&&(s(),e(t))};if(o.push((()=>{this.provider.off(this.hash,l)})),this.provider.on(this.hash,l),a>=0){const e=async()=>{try{await c()}catch(e){if((0,n.isError)(e,"TRANSACTION_REPLACED"))return s(),void t(e)}u||this.provider.once("block",e)};o.push((()=>{this.provider.off("block",e)})),this.provider.once("block",e)}}));return await f}isMined(){return null!=this.blockHash}isLegacy(){return 0===this.type}isBerlin(){return 1===this.type}isLondon(){return 2===this.type}removedEvent(){return(0,n.assert)(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),d(this)}reorderedEvent(e){return(0,n.assert)(this.isMined(),"unmined transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),(0,n.assert)(!e||e.isMined(),"unmined 'other' transaction canot be orphaned","UNSUPPORTED_OPERATION",{operation:"removeEvent()"}),h(this,e)}replaceableTransaction(e){(0,n.assertArgument)(Number.isInteger(e)&&e>=0,"invalid startBlock","startBlock",e);const t=new f(this,this.provider);return t.#xe=e,t}}function h(e,t){return{orphan:"reorder-transaction",tx:e,other:t}}function d(e){return{orphan:"drop-transaction",tx:e}}t.TransactionResponse=f},22992:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NonceManager=void 0;const n=r(42120),i=r(35649);class o extends i.AbstractSigner{signer;#Pe;#Ie;constructor(e){super(e.provider),(0,n.defineProperties)(this,{signer:e}),this.#Pe=null,this.#Ie=0}async getAddress(){return this.signer.getAddress()}connect(e){return new o(this.signer.connect(e))}async getNonce(e){if("pending"===e){null==this.#Pe&&(this.#Pe=super.getNonce("pending"));const e=this.#Ie;return await this.#Pe+e}return super.getNonce(e)}increment(){this.#Ie++}reset(){this.#Ie=0,this.#Pe=null}async sendTransaction(e){const t=this.getNonce("pending");return this.increment(),(e=await this.signer.populateTransaction(e)).nonce=await t,await this.signer.sendTransaction(e)}signTransaction(e){return this.signer.signTransaction(e)}signMessage(e){return this.signer.signMessage(e)}signTypedData(e,t,r){return this.signer.signTypedData(e,t,r)}}t.NonceManager=o},21570:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FilterIdPendingSubscriber=t.FilterIdEventSubscriber=t.FilterIdSubscriber=void 0;const n=r(42120),i=r(21097);class o{#be;#Oe;#Re;#Ce;#pe;#Be;constructor(e){this.#be=e,this.#Oe=null,this.#Re=this.#Ne.bind(this),this.#Ce=!1,this.#pe=null,this.#Be=!1}_subscribe(e){throw new Error("subclasses must override this")}_emitResults(e,t){throw new Error("subclasses must override this")}_recover(e){throw new Error("subclasses must override this")}async#Ne(e){try{null==this.#Oe&&(this.#Oe=this._subscribe(this.#be));let e=null;try{e=await this.#Oe}catch(e){if(!(0,n.isError)(e,"UNSUPPORTED_OPERATION")||"eth_newFilter"!==e.operation)throw e}if(null==e)return this.#Oe=null,void this.#be._recoverSubscriber(this,this._recover(this.#be));const t=await this.#be.getNetwork();if(this.#pe||(this.#pe=t),this.#pe.chainId!==t.chainId)throw new Error("chaid changed");if(this.#Be)return;const r=await this.#be.send("eth_getFilterChanges",[e]);await this._emitResults(this.#be,r)}catch(e){console.log("@TODO",e)}this.#be.once("block",this.#Re)}#Le(){const e=this.#Oe;e&&(this.#Oe=null,e.then((e=>{this.#be.send("eth_uninstallFilter",[e])})))}start(){this.#Ce||(this.#Ce=!0,this.#Ne(-2))}stop(){this.#Ce&&(this.#Ce=!1,this.#Be=!0,this.#Le(),this.#be.off("block",this.#Re))}pause(e){e&&this.#Le(),this.#be.off("block",this.#Re)}resume(){this.start()}}t.FilterIdSubscriber=o;t.FilterIdEventSubscriber=class extends o{#Ue;constructor(e,t){var r;super(e),this.#Ue=(r=t,JSON.parse(JSON.stringify(r)))}_recover(e){return new i.PollingEventSubscriber(e,this.#Ue)}async _subscribe(e){return await e.send("eth_newFilter",[this.#Ue])}async _emitResults(e,t){for(const r of t)e.emit(this.#Ue,e._wrapLog(r,e._network))}};t.FilterIdPendingSubscriber=class extends o{async _subscribe(e){return await e.send("eth_newPendingTransactionFilter",[])}async _emitResults(e,t){for(const r of t)e.emit("pending",r)}}},21097:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PollingEventSubscriber=t.PollingTransactionSubscriber=t.PollingOrphanSubscriber=t.OnBlockSubscriber=t.PollingBlockSubscriber=t.getPollingSubscriber=void 0;const n=r(42120);function i(e){return JSON.parse(JSON.stringify(e))}t.getPollingSubscriber=function(e,t){return"block"===t?new o(e):(0,n.isHexString)(t,32)?new s(e,t):void(0,n.assert)(!1,"unsupported polling event","UNSUPPORTED_OPERATION",{operation:"getPollingSubscriber",info:{event:t}})};class o{#be;#Re;#Fe;#De;constructor(e){this.#be=e,this.#Re=null,this.#Fe=4e3,this.#De=-2}get pollingInterval(){return this.#Fe}set pollingInterval(e){this.#Fe=e}async#Ne(){const e=await this.#be.getBlockNumber();if(-2!==this.#De){if(e!==this.#De){for(let t=this.#De+1;t<=e;t++){if(null==this.#Re)return;await this.#be.emit("block",t)}this.#De=e}null!=this.#Re&&(this.#Re=this.#be._setTimeout(this.#Ne.bind(this),this.#Fe))}else this.#De=e}start(){this.#Re||(this.#Re=this.#be._setTimeout(this.#Ne.bind(this),this.#Fe),this.#Ne())}stop(){this.#Re&&(this.#be._clearTimeout(this.#Re),this.#Re=null)}pause(e){this.stop(),e&&(this.#De=-2)}resume(){this.start()}}t.PollingBlockSubscriber=o;class a{#be;#Ne;#Ce;constructor(e){this.#be=e,this.#Ce=!1,this.#Ne=e=>{this._poll(e,this.#be)}}async _poll(e,t){throw new Error("sub-classes must override this")}start(){this.#Ce||(this.#Ce=!0,this.#Ne(-2),this.#be.on("block",this.#Ne))}stop(){this.#Ce&&(this.#Ce=!1,this.#be.off("block",this.#Ne))}pause(e){this.stop()}resume(){this.start()}}t.OnBlockSubscriber=a;t.PollingOrphanSubscriber=class extends a{#g;constructor(e,t){super(e),this.#g=i(t)}async _poll(e,t){throw new Error("@TODO")}};class s extends a{#je;constructor(e,t){super(e),this.#je=t}async _poll(e,t){const r=await t.getTransactionReceipt(this.#je);r&&t.emit(this.#je,r)}}t.PollingTransactionSubscriber=s;t.PollingEventSubscriber=class{#be;#g;#Re;#Ce;#De;constructor(e,t){this.#be=e,this.#g=i(t),this.#Re=this.#Ne.bind(this),this.#Ce=!1,this.#De=-2}async#Ne(e){if(-2===this.#De)return;const t=i(this.#g);t.fromBlock=this.#De+1,t.toBlock=e;const r=await this.#be.getLogs(t);if(0!==r.length){this.#De=e;for(const e of r)this.#be.emit(this.#g,e)}else this.#De{this.#De=e})),this.#be.on("block",this.#Re))}stop(){this.#Ce&&(this.#Ce=!1,this.#be.off("block",this.#Re))}pause(e){this.stop(),e&&(this.#De=-2)}resume(){this.start()}}},39896:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebSocket=void 0;var n=r(10639);Object.defineProperty(t,"WebSocket",{enumerable:!0,get:function(){return n.WebSocket}})},484:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.accessListify=void 0;const n=r(45475),i=r(42120);function o(e,t){return{address:(0,n.getAddress)(e),storageKeys:t.map(((e,t)=>((0,i.assertArgument)((0,i.isHexString)(e,32),"invalid slot",`storageKeys[${t}]`,e),e.toLowerCase())))}}t.accessListify=function(e){if(Array.isArray(e))return e.map(((t,r)=>Array.isArray(t)?((0,i.assertArgument)(2===t.length,"invalid slot set",`value[${r}]`,t),o(t[0],t[1])):((0,i.assertArgument)(null!=t&&"object"==typeof t,"invalid address-slot set","value",e),o(t.address,t.storageKeys))));(0,i.assertArgument)(null!=e&&"object"==typeof e,"invalid access list","value",e);const t=Object.keys(e).map((t=>{const r=e[t].reduce(((e,t)=>(e[t]=!0,e)),{});return o(t,Object.keys(r).sort())}));return t.sort(((e,t)=>e.address.localeCompare(t.address))),t}},17782:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.recoverAddress=t.computeAddress=void 0;const n=r(45475),i=r(96965);function o(e){let t;return t="string"==typeof e?i.SigningKey.computePublicKey(e,!1):e.publicKey,(0,n.getAddress)((0,i.keccak256)("0x"+t.substring(4)).substring(26))}t.computeAddress=o,t.recoverAddress=function(e,t){return o(i.SigningKey.recoverPublicKey(e,t))}},2290:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Transaction=t.recoverAddress=t.computeAddress=t.accessListify=void 0;var n=r(484);Object.defineProperty(t,"accessListify",{enumerable:!0,get:function(){return n.accessListify}});var i=r(17782);Object.defineProperty(t,"computeAddress",{enumerable:!0,get:function(){return i.computeAddress}}),Object.defineProperty(t,"recoverAddress",{enumerable:!0,get:function(){return i.recoverAddress}});var o=r(31541);Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return o.Transaction}})},31541:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Transaction=void 0;const n=r(45475),i=r(96965),o=r(42120),a=r(484),s=r(17782),u=BigInt(0),c=BigInt(2),l=BigInt(27),f=BigInt(28),h=BigInt(35),d=BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function p(e){return"0x"===e?null:(0,n.getAddress)(e)}function m(e,t){try{return(0,a.accessListify)(e)}catch(r){(0,o.assertArgument)(!1,r.message,t,e)}}function y(e,t){return"0x"===e?0:(0,o.getNumber)(e,t)}function g(e,t){if("0x"===e)return u;const r=(0,o.getBigInt)(e,t);return(0,o.assertArgument)(r<=d,"value exceeds uint size",t,r),r}function b(e,t){const r=(0,o.getBigInt)(e,"value"),n=(0,o.toBeArray)(r);return(0,o.assertArgument)(n.length<=32,"value too large",`tx.${t}`,r),n}function v(e){return(0,a.accessListify)(e).map((e=>[e.address,e.storageKeys]))}function w(e,t){const r=[b(e.nonce||0,"nonce"),b(e.gasPrice||0,"gasPrice"),b(e.gasLimit||0,"gasLimit"),null!=e.to?(0,n.getAddress)(e.to):"0x",b(e.value||0,"value"),e.data||"0x"];let a=u;if(null!=e.chainId)a=(0,o.getBigInt)(e.chainId,"tx.chainId"),(0,o.assertArgument)(!t||null==t.networkV||t.legacyChainId===a,"tx.chainId/sig.v mismatch","sig",t);else if(t){const e=t.legacyChainId;null!=e&&(a=e)}if(!t)return a!==u&&(r.push((0,o.toBeArray)(a)),r.push("0x"),r.push("0x")),(0,o.encodeRlp)(r);let s=BigInt(27+t.yParity);return a!==u?s=i.Signature.getChainIdV(a,t.v):BigInt(t.v)!==s&&(0,o.assertArgument)(!1,"tx.chainId/sig.v mismatch","sig",t),r.push((0,o.toBeArray)(s)),r.push((0,o.toBeArray)(t.r)),r.push((0,o.toBeArray)(t.s)),(0,o.encodeRlp)(r)}function A(e,t,r){let n;try{if(n=y(t[0],"yParity"),0!==n&&1!==n)throw new Error("bad yParity")}catch(e){(0,o.assertArgument)(!1,"invalid yParity","yParity",t[0])}const a=(0,o.zeroPadValue)(t[1],32),s=(0,o.zeroPadValue)(t[2],32),u=i.Signature.from({r:a,s,yParity:n});e.signature=u}function S(e,t){const r=[b(e.chainId||0,"chainId"),b(e.nonce||0,"nonce"),b(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),b(e.maxFeePerGas||0,"maxFeePerGas"),b(e.gasLimit||0,"gasLimit"),null!=e.to?(0,n.getAddress)(e.to):"0x",b(e.value||0,"value"),e.data||"0x",v(e.accessList||[])];return t&&(r.push(b(t.yParity,"yParity")),r.push((0,o.toBeArray)(t.r)),r.push((0,o.toBeArray)(t.s))),(0,o.concat)(["0x02",(0,o.encodeRlp)(r)])}function k(e,t){const r=[b(e.chainId||0,"chainId"),b(e.nonce||0,"nonce"),b(e.gasPrice||0,"gasPrice"),b(e.gasLimit||0,"gasLimit"),null!=e.to?(0,n.getAddress)(e.to):"0x",b(e.value||0,"value"),e.data||"0x",v(e.accessList||[])];return t&&(r.push(b(t.yParity,"recoveryParam")),r.push((0,o.toBeArray)(t.r)),r.push((0,o.toBeArray)(t.s))),(0,o.concat)(["0x01",(0,o.encodeRlp)(r)])}class E{#He;#Je;#r;#ze;#Ge;#qe;#Ke;#Ve;#Xe;#Z;#Qe;#We;get type(){return this.#He}set type(e){switch(e){case null:this.#He=null;break;case 0:case"legacy":this.#He=0;break;case 1:case"berlin":case"eip-2930":this.#He=1;break;case 2:case"london":case"eip-1559":this.#He=2;break;default:(0,o.assertArgument)(!1,"unsupported transaction type","type",e)}}get typeName(){switch(this.type){case 0:return"legacy";case 1:return"eip-2930";case 2:return"eip-1559"}return null}get to(){return this.#Je}set to(e){this.#Je=null==e?null:(0,n.getAddress)(e)}get nonce(){return this.#ze}set nonce(e){this.#ze=(0,o.getNumber)(e,"value")}get gasLimit(){return this.#Ge}set gasLimit(e){this.#Ge=(0,o.getBigInt)(e)}get gasPrice(){const e=this.#qe;return null!=e||0!==this.type&&1!==this.type?e:u}set gasPrice(e){this.#qe=null==e?null:(0,o.getBigInt)(e,"gasPrice")}get maxPriorityFeePerGas(){const e=this.#Ke;return null==e?2===this.type?u:null:e}set maxPriorityFeePerGas(e){this.#Ke=null==e?null:(0,o.getBigInt)(e,"maxPriorityFeePerGas")}get maxFeePerGas(){const e=this.#Ve;return null==e?2===this.type?u:null:e}set maxFeePerGas(e){this.#Ve=null==e?null:(0,o.getBigInt)(e,"maxFeePerGas")}get data(){return this.#r}set data(e){this.#r=(0,o.hexlify)(e)}get value(){return this.#Xe}set value(e){this.#Xe=(0,o.getBigInt)(e,"value")}get chainId(){return this.#Z}set chainId(e){this.#Z=(0,o.getBigInt)(e)}get signature(){return this.#Qe||null}set signature(e){this.#Qe=null==e?null:i.Signature.from(e)}get accessList(){const e=this.#We||null;return null==e?1===this.type||2===this.type?[]:null:e}set accessList(e){this.#We=null==e?null:(0,a.accessListify)(e)}constructor(){this.#He=null,this.#Je=null,this.#ze=0,this.#Ge=BigInt(0),this.#qe=null,this.#Ke=null,this.#Ve=null,this.#r="0x",this.#Xe=BigInt(0),this.#Z=BigInt(0),this.#Qe=null,this.#We=null}get hash(){return null==this.signature?null:(0,i.keccak256)(this.serialized)}get unsignedHash(){return(0,i.keccak256)(this.unsignedSerialized)}get from(){return null==this.signature?null:(0,s.recoverAddress)(this.unsignedHash,this.signature)}get fromPublicKey(){return null==this.signature?null:i.SigningKey.recoverPublicKey(this.unsignedHash,this.signature)}isSigned(){return null!=this.signature}get serialized(){switch((0,o.assert)(null!=this.signature,"cannot serialize unsigned transaction; maybe you meant .unsignedSerialized","UNSUPPORTED_OPERATION",{operation:".serialized"}),this.inferType()){case 0:return w(this,this.signature);case 1:return k(this,this.signature);case 2:return S(this,this.signature)}(0,o.assert)(!1,"unsupported transaction type","UNSUPPORTED_OPERATION",{operation:".serialized"})}get unsignedSerialized(){switch(this.inferType()){case 0:return w(this);case 1:return k(this);case 2:return S(this)}(0,o.assert)(!1,"unsupported transaction type","UNSUPPORTED_OPERATION",{operation:".unsignedSerialized"})}inferType(){return this.inferTypes().pop()}inferTypes(){const e=null!=this.gasPrice,t=null!=this.maxFeePerGas||null!=this.maxPriorityFeePerGas,r=null!=this.accessList;null!=this.maxFeePerGas&&null!=this.maxPriorityFeePerGas&&(0,o.assert)(this.maxFeePerGas>=this.maxPriorityFeePerGas,"priorityFee cannot be more than maxFee","BAD_DATA",{value:this}),(0,o.assert)(!t||0!==this.type&&1!==this.type,"transaction type cannot have maxFeePerGas or maxPriorityFeePerGas","BAD_DATA",{value:this}),(0,o.assert)(0!==this.type||!r,"legacy transaction cannot have accessList","BAD_DATA",{value:this});const n=[];return null!=this.type?n.push(this.type):t?n.push(2):e?(n.push(1),r||n.push(0)):r?(n.push(1),n.push(2)):(n.push(0),n.push(1),n.push(2)),n.sort(),n}isLegacy(){return 0===this.type}isBerlin(){return 1===this.type}isLondon(){return 2===this.type}clone(){return E.from(this)}toJSON(){const e=e=>null==e?null:e.toString();return{type:this.type,to:this.to,data:this.data,nonce:this.nonce,gasLimit:e(this.gasLimit),gasPrice:e(this.gasPrice),maxPriorityFeePerGas:e(this.maxPriorityFeePerGas),maxFeePerGas:e(this.maxFeePerGas),value:e(this.value),chainId:e(this.chainId),sig:this.signature?this.signature.toJSON():null,accessList:this.accessList}}static from(e){if(null==e)return new E;if("string"==typeof e){const t=(0,o.getBytes)(e);if(t[0]>=127)return E.from(function(e){const t=(0,o.decodeRlp)(e);(0,o.assertArgument)(Array.isArray(t)&&(9===t.length||6===t.length),"invalid field count for legacy transaction","data",e);const r={type:0,nonce:y(t[0],"nonce"),gasPrice:g(t[1],"gasPrice"),gasLimit:g(t[2],"gasLimit"),to:p(t[3]),value:g(t[4],"value"),data:(0,o.hexlify)(t[5]),chainId:u};if(6===t.length)return r;const n=g(t[6],"v"),a=g(t[7],"r"),s=g(t[8],"s");if(a===u&&s===u)r.chainId=n;else{let a=(n-h)/c;a{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBase58=t.encodeBase58=void 0;const n=r(86239),i=r(21766),o=r(90358),a="123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz";let s=null;function u(e){if(null==s){s={};for(let e=0;e{"use strict";var n=r(48764).Buffer;Object.defineProperty(t,"__esModule",{value:!0}),t.encodeBase64=t.decodeBase64=void 0;const i=r(86239);t.decodeBase64=function(e){return(0,i.getBytesCopy)(n.from(e,"base64"))},t.encodeBase64=function(e){return n.from((0,i.getBytes)(e)).toString("base64")}},86239:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.zeroPadBytes=t.zeroPadValue=t.stripZerosLeft=t.dataSlice=t.dataLength=t.concat=t.hexlify=t.isBytesLike=t.isHexString=t.getBytesCopy=t.getBytes=void 0;const n=r(21766);function i(e,t,r){if(e instanceof Uint8Array)return r?new Uint8Array(e):e;if("string"==typeof e&&e.match(/^0x([0-9a-f][0-9a-f])*$/i)){const t=new Uint8Array((e.length-2)/2);let r=2;for(let n=0;n>4]+s[15&n]}return r}function c(e,t,r){const i=o(e);(0,n.assert)(t>=i.length,"padding exceeds data length","BUFFER_OVERRUN",{buffer:new Uint8Array(i),length:t,offset:t+1});const a=new Uint8Array(t);return a.fill(0),r?a.set(i,t-i.length):a.set(i,0),u(a)}t.hexlify=u,t.concat=function(e){return"0x"+e.map((e=>u(e).substring(2))).join("")},t.dataLength=function(e){return a(e,!0)?(e.length-2)/2:o(e).length},t.dataSlice=function(e,t,r){const i=o(e);return null!=r&&r>i.length&&(0,n.assert)(!1,"cannot slice beyond data bounds","BUFFER_OVERRUN",{buffer:i,length:i.length,offset:r}),u(i.slice(null==t?0:t,null==r?i.length:r))},t.stripZerosLeft=function(e){let t=u(e).substring(2);for(;t.startsWith("00");)t=t.substring(2);return"0x"+t},t.zeroPadValue=function(e,t){return c(e,t,!0)},t.zeroPadBytes=function(e,t){return c(e,t,!1)}},21766:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assertPrivate=t.assertNormalize=t.assertArgumentCount=t.assertArgument=t.assert=t.makeError=t.isCallException=t.isError=void 0;const n=r(79406),i=r(39290);function o(e){if(null==e)return"null";if(Array.isArray(e))return"[ "+e.map(o).join(", ")+" ]";if(e instanceof Uint8Array){const t="0123456789abcdef";let r="0x";for(let n=0;n>4],r+=t[15&e[n]];return r}if("object"==typeof e&&"function"==typeof e.toJSON)return o(e.toJSON());switch(typeof e){case"boolean":case"symbol":case"number":return e.toString();case"bigint":return BigInt(e).toString();case"string":return JSON.stringify(e);case"object":{const t=Object.keys(e);return t.sort(),"{ "+t.map((t=>`${o(t)}: ${o(e[t])}`)).join(", ")+" }"}}return"[ COULD NOT SERIALIZE ]"}function a(e,t){return e&&e.code===t}function s(e,t,r){{const i=[];if(r){if("message"in r||"code"in r||"name"in r)throw new Error(`value will overwrite populated values: ${o(r)}`);for(const e in r){const t=r[e];i.push(e+"="+o(t))}}i.push(`code=${t}`),i.push(`version=${n.version}`),i.length&&(e+=" ("+i.join(", ")+")")}let a;switch(t){case"INVALID_ARGUMENT":a=new TypeError(e);break;case"NUMERIC_FAULT":case"BUFFER_OVERRUN":a=new RangeError(e);break;default:a=new Error(e)}return(0,i.defineProperties)(a,{code:t}),r&&Object.assign(a,r),a}function u(e,t,r,n){if(!e)throw s(t,r,n)}t.isError=a,t.isCallException=function(e){return a(e,"CALL_EXCEPTION")},t.makeError=s,t.assert=u,t.assertArgument=function(e,t,r,n){u(e,t,"INVALID_ARGUMENT",{argument:r,value:n})},t.assertArgumentCount=function(e,t,r){null==r&&(r=""),r&&(r=": "+r),u(e>=t,"missing arguemnt"+r,"MISSING_ARGUMENT",{count:e,expectedCount:t}),u(e<=t,"too many arguemnts"+r,"UNEXPECTED_ARGUMENT",{count:e,expectedCount:t})};const c=["NFD","NFC","NFKD","NFKC"].reduce(((e,t)=>{try{if("test"!=="test".normalize(t))throw new Error("bad");if("NFD"===t){const e=String.fromCharCode(233).normalize("NFD");if(e!==String.fromCharCode(101,769))throw new Error("broken")}e.push(t)}catch(e){}return e}),[]);t.assertNormalize=function(e){u(c.indexOf(e)>=0,"platform missing String.prototype.normalize","UNSUPPORTED_OPERATION",{operation:"String.prototype.normalize",info:{form:e}})},t.assertPrivate=function(e,t,r){if(null==r&&(r=""),e!==t){let e=r,t="new";r&&(e+=".",t+=" "+r),u(!1,`private constructor; use ${e}from* methods`,"UNSUPPORTED_OPERATION",{operation:t})}}},52203:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EventPayload=void 0;const n=r(39290);t.EventPayload=class{filter;emitter;#Ze;constructor(e,t,r){this.#Ze=t,(0,n.defineProperties)(this,{emitter:e,filter:r})}async removeListener(){null!=this.#Ze&&await this.emitter.off(this.filter,this.#Ze)}}},93654:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FetchResponse=t.FetchRequest=t.FetchCancelSignal=void 0;const n=r(42946),i=r(86239),o=r(21766),a=r(39290),s=r(82119),u=r(30997);let c=u.getUrl;const l=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),f=new RegExp("^ipfs://(ipfs/)?(.*)$","i");let h=!1;async function d(e,t){try{const t=e.match(l);if(!t)throw new Error("invalid data");return new w(200,"OK",{"content-type":t[1]||"text/plain"},t[2]?(0,n.decodeBase64)(t[3]):(r=t[3],(0,s.toUtf8Bytes)(r.replace(/%([0-9a-f][0-9a-f])/gi,((e,t)=>String.fromCharCode(parseInt(t,16)))))))}catch(t){return new w(599,"BAD REQUEST (invalid data: URI)",{},null,new v(e))}var r}function p(e){return async function(t,r){try{const r=t.match(f);if(!r)throw new Error("invalid link");return new v(`${e}${r[2]}`)}catch(e){return new w(599,"BAD REQUEST (invalid IPFS URI)",{},null,new v(t))}}}const m={data:d,ipfs:p("https://gateway.ipfs.io/ipfs/")},y=new WeakMap;class g{#Ye;#$e;constructor(e){this.#Ye=[],this.#$e=!1,y.set(e,(()=>{if(!this.#$e){this.#$e=!0;for(const e of this.#Ye)setTimeout((()=>{e()}),0);this.#Ye=[]}}))}addListener(e){(0,o.assert)(!this.#$e,"singal already cancelled","UNSUPPORTED_OPERATION",{operation:"fetchCancelSignal.addCancelListener"}),this.#Ye.push(e)}get cancelled(){return this.#$e}checkSignal(){(0,o.assert)(!this.cancelled,"cancelled","CANCELLED",{})}}function b(e){if(null==e)throw new Error("missing signal; should not happen");return e.checkSignal(),e}t.FetchCancelSignal=g;class v{#et;#tt;#rt;#nt;#it;#ot;#at;#st;#ut;#ct;#lt;#ft;#ht;#dt;get url(){return this.#ot}set url(e){this.#ot=String(e)}get body(){return null==this.#at?null:new Uint8Array(this.#at)}set body(e){if(null==e)this.#at=void 0,this.#st=void 0;else if("string"==typeof e)this.#at=(0,s.toUtf8Bytes)(e),this.#st="text/plain";else if(e instanceof Uint8Array)this.#at=e,this.#st="application/octet-stream";else{if("object"!=typeof e)throw new Error("invalid body");this.#at=(0,s.toUtf8Bytes)(JSON.stringify(e)),this.#st="application/json"}}hasBody(){return null!=this.#at}get method(){return this.#nt?this.#nt:this.hasBody()?"POST":"GET"}set method(e){null==e&&(e=""),this.#nt=String(e).toUpperCase()}get headers(){const e=Object.assign({},this.#rt);return this.#ut&&(e.authorization=`Basic ${(0,n.encodeBase64)((0,s.toUtf8Bytes)(this.#ut))}`),this.allowGzip&&(e["accept-encoding"]="gzip"),null==e["content-type"]&&this.#st&&(e["content-type"]=this.#st),this.body&&(e["content-length"]=String(this.body.length)),e}getHeader(e){return this.headers[e.toLowerCase()]}setHeader(e,t){this.#rt[String(e).toLowerCase()]=String(t)}clearHeaders(){this.#rt={}}[Symbol.iterator](){const e=this.headers,t=Object.keys(e);let r=0;return{next:()=>{if(r=0,"timeout must be non-zero","timeout",e),this.#it=e}get preflightFunc(){return this.#ct||null}set preflightFunc(e){this.#ct=e}get processFunc(){return this.#lt||null}set processFunc(e){this.#lt=e}get retryFunc(){return this.#ft||null}set retryFunc(e){this.#ft=e}constructor(e){this.#ot=String(e),this.#et=!1,this.#tt=!0,this.#rt={},this.#nt="",this.#it=3e5,this.#dt={slotInterval:250,maxAttempts:12}}toString(){return``}setThrottleParams(e){null!=e.slotInterval&&(this.#dt.slotInterval=e.slotInterval),null!=e.maxAttempts&&(this.#dt.maxAttempts=e.maxAttempts)}async#pt(e,t,r,n,i){if(e>=this.#dt.maxAttempts)return i.makeServerError("exceeded maximum retry limit");(0,o.assert)(A()<=t,"timeout","TIMEOUT",{operation:"request.send",reason:"timeout",request:n}),r>0&&await function(e){return new Promise((t=>setTimeout(t,e)))}(r);let a=this.clone();const s=(a.url.split(":")[0]||"").toLowerCase();if(s in m){const e=await m[s](a.url,b(n.#ht));if(e instanceof w){let t=e;if(this.processFunc){b(n.#ht);try{t=await this.processFunc(a,t)}catch(e){null!=e.throttle&&"number"==typeof e.stall||t.makeServerError("error in post-processing function",e).assertOk()}}return t}a=e}this.preflightFunc&&(a=await this.preflightFunc(a));const u=await c(a,b(n.#ht));let l=new w(u.statusCode,u.statusMessage,u.headers,u.body,n);if(301===l.statusCode||302===l.statusCode){try{const r=l.headers.location||"";return a.redirect(r).#pt(e+1,t,0,n,l)}catch(e){}return l}if(429===l.statusCode&&(null==this.retryFunc||await this.retryFunc(a,l,e))){const r=l.headers["retry-after"];let i=this.#dt.slotInterval*Math.trunc(Math.random()*Math.pow(2,e));return"string"==typeof r&&r.match(/^[1-9][0-9]*$/)&&(i=parseInt(r)),a.clone().#pt(e+1,t,i,n,l)}if(this.processFunc){b(n.#ht);try{l=await this.processFunc(a,l)}catch(r){null!=r.throttle&&"number"==typeof r.stall||l.makeServerError("error in post-processing function",r).assertOk();let i=this.#dt.slotInterval*Math.trunc(Math.random()*Math.pow(2,e));return r.stall>=0&&(i=r.stall),a.clone().#pt(e+1,t,i,n,l)}}return l}send(){return(0,o.assert)(null==this.#ht,"request already sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.send"}),this.#ht=new g(this),this.#pt(0,A()+this.timeout,0,this,new w(0,"",{},null,this))}cancel(){(0,o.assert)(null!=this.#ht,"request has not been sent","UNSUPPORTED_OPERATION",{operation:"fetchRequest.cancel"});const e=y.get(this);if(!e)throw new Error("missing signal; should not happen");e()}redirect(e){const t=this.url.split(":")[0].toLowerCase(),r=e.split(":")[0].toLowerCase();(0,o.assert)("GET"===this.method&&("https"!==t||"http"!==r)&&e.match(/^https?:/),"unsupported redirect","UNSUPPORTED_OPERATION",{operation:`redirect(${this.method} ${JSON.stringify(this.url)} => ${JSON.stringify(e)})`});const n=new v(e);return n.method="GET",n.allowGzip=this.allowGzip,n.timeout=this.timeout,n.#rt=Object.assign({},this.#rt),this.#at&&(n.#at=new Uint8Array(this.#at)),n.#st=this.#st,n}clone(){const e=new v(this.url);return e.#nt=this.#nt,this.#at&&(e.#at=this.#at),e.#st=this.#st,e.#rt=Object.assign({},this.#rt),e.#ut=this.#ut,this.allowGzip&&(e.allowGzip=!0),e.timeout=this.timeout,this.allowInsecureAuthentication&&(e.allowInsecureAuthentication=!0),e.#ct=this.#ct,e.#lt=this.#lt,e.#ft=this.#ft,e}static lockConfig(){h=!0}static getGateway(e){return m[e.toLowerCase()]||null}static registerGateway(e,t){if("http"===(e=e.toLowerCase())||"https"===e)throw new Error(`cannot intercept ${e}; use registerGetUrl`);if(h)throw new Error("gateways locked");m[e]=t}static registerGetUrl(e){if(h)throw new Error("gateways locked");c=e}static createDataGateway(){return d}static createIpfsGatewayFunc(e){return p(e)}}t.FetchRequest=v;class w{#mt;#yt;#rt;#at;#$;#gt;toString(){return``}get statusCode(){return this.#mt}get statusMessage(){return this.#yt}get headers(){return Object.assign({},this.#rt)}get body(){return null==this.#at?null:new Uint8Array(this.#at)}get bodyText(){try{return null==this.#at?"":(0,s.toUtf8String)(this.#at)}catch(e){(0,o.assert)(!1,"response body is not valid UTF-8 data","UNSUPPORTED_OPERATION",{operation:"bodyText",info:{response:this}})}}get bodyJson(){try{return JSON.parse(this.bodyText)}catch(e){(0,o.assert)(!1,"response body is not valid JSON","UNSUPPORTED_OPERATION",{operation:"bodyJson",info:{response:this}})}}[Symbol.iterator](){const e=this.headers,t=Object.keys(e);let r=0;return{next:()=>{if(r(e[t.toLowerCase()]=String(r[t]),e)),{}),this.#at=null==n?null:new Uint8Array(n),this.#$=i||null,this.#gt={message:""}}makeServerError(e,t){let r;r=e?`CLIENT ESCALATED SERVER ERROR (${this.statusCode} ${this.statusMessage}; ${e})`:`CLIENT ESCALATED SERVER ERROR (${e=`${this.statusCode} ${this.statusMessage}`})`;const n=new w(599,r,this.headers,this.body,this.#$||void 0);return n.#gt={message:e,error:t},n}throwThrottleError(e,t){null==t?t=-1:(0,o.assertArgument)(Number.isInteger(t)&&t>=0,"invalid stall timeout","stall",t);const r=new Error(e||"throttling requests");throw(0,a.defineProperties)(r,{stall:t,throttle:!0}),r}getHeader(e){return this.headers[e.toLowerCase()]}hasBody(){return null!=this.#at}get request(){return this.#$}ok(){return""===this.#gt.message&&this.statusCode>=200&&this.statusCode<300}assertOk(){if(this.ok())return;let{message:e,error:t}=this.#gt;""===e&&(e=`server response ${this.statusCode} ${this.statusMessage}`),(0,o.assert)(!1,e,"SERVER_ERROR",{request:this.request||"unknown request",response:this,error:t})}}function A(){return(new Date).getTime()}t.FetchResponse=w},76539:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FixedNumber=void 0;const n=r(86239),i=r(21766),o=r(90358),a=r(39290),s=BigInt(-1),u=BigInt(0),c=BigInt(1),l=BigInt(5),f={};let h="0000";for(;h.length<80;)h+=h;function d(e){let t=h;for(;t.length=-t&&eu?(0,o.fromTwos)((0,o.mask)(e,n),n):-(0,o.fromTwos)((0,o.mask)(-e,n),n)}else{const t=c<=0&&enull==o[e]?r:((0,i.assertArgument)(typeof o[e]===t,"invalid fixed format ("+e+" not "+t+")","format."+e,o[e]),o[e]);t=a("signed","boolean",t),r=a("width","number",r),n=a("decimals","number",n)}(0,i.assertArgument)(r%8==0,"invalid FixedNumber width (not byte aligned)","format.width",r),(0,i.assertArgument)(n<=80,"invalid FixedNumber decimals (too large)","format.decimals",n);return{signed:t,width:r,decimals:n,name:(t?"":"u")+"fixed"+String(r)+"x"+String(n)}}class y{format;#bt;#vt;#wt;_value;constructor(e,t,r){(0,i.assertPrivate)(e,f,"FixedNumber"),this.#vt=t,this.#bt=r;const n=function(e,t){let r="";e0?r*=d(n):n<0&&(t*=d(-n)),tr?-1:0}eq(e){return 0===this.cmp(e)}lt(e){return this.cmp(e)<0}lte(e){return this.cmp(e)<=0}gt(e){return this.cmp(e)>0}gte(e){return this.cmp(e)>=0}floor(){let e=this.#vt;return this.#vtu&&(e+=this.#wt-c),e=this.#vt/this.#wt*this.#wt,this.#St(e,"ceiling")}round(e){if(null==e&&(e=0),e>=this.decimals)return this;const t=this.decimals-e,r=l*d(t-1);let n=this.value+r;const i=d(t);return n=n/i*i,p(n,this.#bt,"round"),new y(f,n,this.#bt)}isZero(){return this.#vt===u}isNegative(){return this.#vt0){const t=d(s);(0,i.assert)(a%t===u,"value loses precision for format","NUMERIC_FAULT",{operation:"fromValue",fault:"underflow",value:e}),a/=t}else s<0&&(a*=d(-s));return p(a,n,"fromValue"),new y(f,a,n)}static fromString(e,t){const r=e.match(/^(-?)([0-9]*)\.?([0-9]*)$/);(0,i.assertArgument)(r&&r[2].length+r[3].length>0,"invalid FixedNumber string value","value",e);const n=m(t);let o=r[2]||"0",a=r[3]||"";for(;a.length{l.once("response",(n=>{const i=n.statusCode||0,o=n.statusMessage||"",a=Object.keys(n.headers||{}).reduce(((e,t)=>{let r=n.headers[t]||"";return Array.isArray(r)&&(r=r.join(", ")),e[t]=r,e}),{});let u=null;n.on("data",(e=>{if(t)try{t.checkSignal()}catch(e){return r(e)}if(null==u)u=e;else{const t=new Uint8Array(u.length+e.length);t.set(u,0),t.set(e,u.length),u=t}})),n.on("end",(()=>{"gzip"===a["content-encoding"]&&u&&(u=(0,c.getBytes)((0,s.gunzipSync)(u))),e({statusCode:i,statusMessage:o,headers:a,body:u})})),n.on("error",(e=>{e.response={statusCode:i,statusMessage:o,headers:a,body:u},r(e)}))})),l.on("error",(e=>{r(e)}))}))}},42120:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toUtf8String=t.toUtf8CodePoints=t.toUtf8Bytes=t.parseUnits=t.formatUnits=t.parseEther=t.formatEther=t.encodeRlp=t.decodeRlp=t.defineProperties=t.resolveProperties=t.toQuantity=t.toBeArray=t.toBeHex=t.toNumber=t.toBigInt=t.getUint=t.getNumber=t.getBigInt=t.mask=t.toTwos=t.fromTwos=t.FixedNumber=t.FetchCancelSignal=t.FetchResponse=t.FetchRequest=t.EventPayload=t.makeError=t.assertNormalize=t.assertPrivate=t.assertArgumentCount=t.assertArgument=t.assert=t.isError=t.isCallException=t.zeroPadBytes=t.zeroPadValue=t.stripZerosLeft=t.dataSlice=t.dataLength=t.concat=t.hexlify=t.isBytesLike=t.isHexString=t.getBytesCopy=t.getBytes=t.encodeBase64=t.decodeBase64=t.encodeBase58=t.decodeBase58=void 0,t.uuidV4=t.Utf8ErrorFuncs=void 0;var n=r(20349);Object.defineProperty(t,"decodeBase58",{enumerable:!0,get:function(){return n.decodeBase58}}),Object.defineProperty(t,"encodeBase58",{enumerable:!0,get:function(){return n.encodeBase58}});var i=r(42946);Object.defineProperty(t,"decodeBase64",{enumerable:!0,get:function(){return i.decodeBase64}}),Object.defineProperty(t,"encodeBase64",{enumerable:!0,get:function(){return i.encodeBase64}});var o=r(86239);Object.defineProperty(t,"getBytes",{enumerable:!0,get:function(){return o.getBytes}}),Object.defineProperty(t,"getBytesCopy",{enumerable:!0,get:function(){return o.getBytesCopy}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return o.isHexString}}),Object.defineProperty(t,"isBytesLike",{enumerable:!0,get:function(){return o.isBytesLike}}),Object.defineProperty(t,"hexlify",{enumerable:!0,get:function(){return o.hexlify}}),Object.defineProperty(t,"concat",{enumerable:!0,get:function(){return o.concat}}),Object.defineProperty(t,"dataLength",{enumerable:!0,get:function(){return o.dataLength}}),Object.defineProperty(t,"dataSlice",{enumerable:!0,get:function(){return o.dataSlice}}),Object.defineProperty(t,"stripZerosLeft",{enumerable:!0,get:function(){return o.stripZerosLeft}}),Object.defineProperty(t,"zeroPadValue",{enumerable:!0,get:function(){return o.zeroPadValue}}),Object.defineProperty(t,"zeroPadBytes",{enumerable:!0,get:function(){return o.zeroPadBytes}});var a=r(21766);Object.defineProperty(t,"isCallException",{enumerable:!0,get:function(){return a.isCallException}}),Object.defineProperty(t,"isError",{enumerable:!0,get:function(){return a.isError}}),Object.defineProperty(t,"assert",{enumerable:!0,get:function(){return a.assert}}),Object.defineProperty(t,"assertArgument",{enumerable:!0,get:function(){return a.assertArgument}}),Object.defineProperty(t,"assertArgumentCount",{enumerable:!0,get:function(){return a.assertArgumentCount}}),Object.defineProperty(t,"assertPrivate",{enumerable:!0,get:function(){return a.assertPrivate}}),Object.defineProperty(t,"assertNormalize",{enumerable:!0,get:function(){return a.assertNormalize}}),Object.defineProperty(t,"makeError",{enumerable:!0,get:function(){return a.makeError}});var s=r(52203);Object.defineProperty(t,"EventPayload",{enumerable:!0,get:function(){return s.EventPayload}});var u=r(93654);Object.defineProperty(t,"FetchRequest",{enumerable:!0,get:function(){return u.FetchRequest}}),Object.defineProperty(t,"FetchResponse",{enumerable:!0,get:function(){return u.FetchResponse}}),Object.defineProperty(t,"FetchCancelSignal",{enumerable:!0,get:function(){return u.FetchCancelSignal}});var c=r(76539);Object.defineProperty(t,"FixedNumber",{enumerable:!0,get:function(){return c.FixedNumber}});var l=r(90358);Object.defineProperty(t,"fromTwos",{enumerable:!0,get:function(){return l.fromTwos}}),Object.defineProperty(t,"toTwos",{enumerable:!0,get:function(){return l.toTwos}}),Object.defineProperty(t,"mask",{enumerable:!0,get:function(){return l.mask}}),Object.defineProperty(t,"getBigInt",{enumerable:!0,get:function(){return l.getBigInt}}),Object.defineProperty(t,"getNumber",{enumerable:!0,get:function(){return l.getNumber}}),Object.defineProperty(t,"getUint",{enumerable:!0,get:function(){return l.getUint}}),Object.defineProperty(t,"toBigInt",{enumerable:!0,get:function(){return l.toBigInt}}),Object.defineProperty(t,"toNumber",{enumerable:!0,get:function(){return l.toNumber}}),Object.defineProperty(t,"toBeHex",{enumerable:!0,get:function(){return l.toBeHex}}),Object.defineProperty(t,"toBeArray",{enumerable:!0,get:function(){return l.toBeArray}}),Object.defineProperty(t,"toQuantity",{enumerable:!0,get:function(){return l.toQuantity}});var f=r(39290);Object.defineProperty(t,"resolveProperties",{enumerable:!0,get:function(){return f.resolveProperties}}),Object.defineProperty(t,"defineProperties",{enumerable:!0,get:function(){return f.defineProperties}});var h=r(14978);Object.defineProperty(t,"decodeRlp",{enumerable:!0,get:function(){return h.decodeRlp}});var d=r(49122);Object.defineProperty(t,"encodeRlp",{enumerable:!0,get:function(){return d.encodeRlp}});var p=r(88680);Object.defineProperty(t,"formatEther",{enumerable:!0,get:function(){return p.formatEther}}),Object.defineProperty(t,"parseEther",{enumerable:!0,get:function(){return p.parseEther}}),Object.defineProperty(t,"formatUnits",{enumerable:!0,get:function(){return p.formatUnits}}),Object.defineProperty(t,"parseUnits",{enumerable:!0,get:function(){return p.parseUnits}});var m=r(82119);Object.defineProperty(t,"toUtf8Bytes",{enumerable:!0,get:function(){return m.toUtf8Bytes}}),Object.defineProperty(t,"toUtf8CodePoints",{enumerable:!0,get:function(){return m.toUtf8CodePoints}}),Object.defineProperty(t,"toUtf8String",{enumerable:!0,get:function(){return m.toUtf8String}}),Object.defineProperty(t,"Utf8ErrorFuncs",{enumerable:!0,get:function(){return m.Utf8ErrorFuncs}});var y=r(4824);Object.defineProperty(t,"uuidV4",{enumerable:!0,get:function(){return y.uuidV4}})},90358:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toQuantity=t.toBeArray=t.toBeHex=t.toNumber=t.getNumber=t.toBigInt=t.getUint=t.getBigInt=t.mask=t.toTwos=t.fromTwos=void 0;const n=r(86239),i=r(21766),o=BigInt(0),a=BigInt(1),s=9007199254740991;function u(e,t){switch(typeof e){case"bigint":return e;case"number":return(0,i.assertArgument)(Number.isInteger(e),"underflow",t||"value",e),(0,i.assertArgument)(e>=-s&&e<=s,"overflow",t||"value",e),BigInt(e);case"string":try{if(""===e)throw new Error("empty string");return"-"===e[0]&&"-"!==e[1]?-BigInt(e.substring(1)):BigInt(e)}catch(r){(0,i.assertArgument)(!1,`invalid BigNumberish string: ${r.message}`,t||"value",e)}}(0,i.assertArgument)(!1,"invalid BigNumberish value",t||"value",e)}function c(e,t){const r=u(e,t);return(0,i.assert)(r>=o,"unsigned value cannot be negative","NUMERIC_FAULT",{fault:"overflow",operation:"getUint",value:e}),r}t.fromTwos=function(e,t){const r=c(e,"value"),n=BigInt(h(t,"width"));if((0,i.assert)(r>>n===o,"overflow","NUMERIC_FAULT",{operation:"fromTwos",fault:"overflow",value:e}),r>>n-a){return-((~r&(a<>4],t+=l[15&r];return BigInt(t)}return u(e)}function h(e,t){switch(typeof e){case"bigint":return(0,i.assertArgument)(e>=-s&&e<=s,"overflow",t||"value",e),Number(e);case"number":return(0,i.assertArgument)(Number.isInteger(e),"underflow",t||"value",e),(0,i.assertArgument)(e>=-s&&e<=s,"overflow",t||"value",e),e;case"string":try{if(""===e)throw new Error("empty string");return h(BigInt(e),t)}catch(r){(0,i.assertArgument)(!1,`invalid numeric string: ${r.message}`,t||"value",e)}}(0,i.assertArgument)(!1,"invalid numeric value",t||"value",e)}function d(e){const t=c(e,"value");if(t===o)return new Uint8Array([]);let r=t.toString(16);r.length%2&&(r="0"+r);const n=new Uint8Array(r.length/2);for(let e=0;e=r.length,`value exceeds width (${n} bits)`,"NUMERIC_FAULT",{operation:"toBeHex",fault:"overflow",value:e});r.length<2*n;)r="0"+r}return"0x"+r},t.toBeArray=d,t.toQuantity=function(e){let t=(0,n.hexlify)((0,n.isBytesLike)(e)?e:d(e)).substring(2);for(;t.startsWith("0");)t=t.substring(1);return""===t&&(t="0"),"0x"+t}},39290:(e,t)=>{"use strict";function r(e,t,r){const n=t.split("|").map((e=>e.trim()));for(let r=0;rPromise.resolve(e[t]))))).reduce(((e,r,n)=>(e[t[n]]=r,e)),{})},t.defineProperties=function(e,t,n){for(let i in t){let o=t[i];const a=n?n[i]:null;a&&r(o,a,i),Object.defineProperty(e,i,{enumerable:!0,value:o,writable:!1})}}},14978:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeRlp=void 0;const n=r(86239),i=r(21766),o=r(86239);function a(e){let t=e.toString(16);for(;t.length<2;)t="0"+t;return"0x"+t}function s(e,t,r){let n=0;for(let i=0;i{(0,i.assert)(t<=e.length,"data short segment too short","BUFFER_OVERRUN",{buffer:e,length:e.length,offset:t})};if(e[t]>=248){const n=e[t]-247;r(t+1+n);const i=s(e,t+1,n);return r(t+1+n+i),u(e,t,t+1+n,n+i)}if(e[t]>=192){const n=e[t]-192;return r(t+1+n),u(e,t,t+1,n)}if(e[t]>=184){const i=e[t]-183;r(t+1+i);const o=s(e,t+1,i);r(t+1+i+o);return{consumed:1+i+o,result:(0,n.hexlify)(e.slice(t+1+i,t+1+i+o))}}if(e[t]>=128){const i=e[t]-128;r(t+1+i);return{consumed:1+i,result:(0,n.hexlify)(e.slice(t+1,t+1+i))}}return{consumed:1,result:a(e[t])}}t.decodeRlp=function(e){const t=(0,o.getBytes)(e,"data"),r=c(t,0);return(0,i.assertArgument)(r.consumed===t.length,"unexpected junk after rlp payload","data",e),r.result}},49122:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encodeRlp=void 0;const n=r(86239);function i(e){const t=[];for(;e;)t.unshift(255&e),e>>=8;return t}function o(e){if(Array.isArray(e)){let t=[];if(e.forEach((function(e){t=t.concat(o(e))})),t.length<=55)return t.unshift(192+t.length),t;const r=i(t.length);return r.unshift(247+r.length),r.concat(t)}const t=Array.prototype.slice.call((0,n.getBytes)(e,"object"));if(1===t.length&&t[0]<=127)return t;if(t.length<=55)return t.unshift(128+t.length),t;const r=i(t.length);return r.unshift(183+r.length),r.concat(t)}const a="0123456789abcdef";t.encodeRlp=function(e){let t="0x";for(const r of o(e))t+=a[r>>4],t+=a[15&r];return t}},88680:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseEther=t.formatEther=t.parseUnits=t.formatUnits=void 0;const n=r(21766),i=r(76539),o=r(90358),a=["wei","kwei","mwei","gwei","szabo","finney","ether"];function s(e,t){let r=18;if("string"==typeof t){const e=a.indexOf(t);(0,n.assertArgument)(e>=0,"invalid unit","unit",t),r=3*e}else null!=t&&(r=(0,o.getNumber)(t,"unit"));return i.FixedNumber.fromValue(e,r,{decimals:r}).toString()}function u(e,t){(0,n.assertArgument)("string"==typeof e,"value must be a string","value",e);let r=18;if("string"==typeof t){const e=a.indexOf(t);(0,n.assertArgument)(e>=0,"invalid unit","unit",t),r=3*e}else null!=t&&(r=(0,o.getNumber)(t,"unit"));return i.FixedNumber.fromString(e,{decimals:r}).value}t.formatUnits=s,t.parseUnits=u,t.formatEther=function(e){return s(e,18)},t.parseEther=function(e){return u(e,18)}},82119:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toUtf8CodePoints=t.toUtf8String=t.toUtf8Bytes=t.Utf8ErrorFuncs=void 0;const n=r(86239),i=r(21766);function o(e,t,r,n,i){if("BAD_PREFIX"===e||"UNEXPECTED_CONTINUE"===e){let e=0;for(let n=t+1;n>6==2;n++)e++;return e}return"OVERRUN"===e?r.length-t-1:0}function a(e,r){null==r&&(r=t.Utf8ErrorFuncs.error);const i=(0,n.getBytes)(e,"bytes"),o=[];let a=0;for(;a>7==0){o.push(e);continue}let t=null,n=null;if(192==(224&e))t=1,n=127;else if(224==(240&e))t=2,n=2047;else{if(240!=(248&e)){a+=r(128==(192&e)?"UNEXPECTED_CONTINUE":"BAD_PREFIX",a-1,i,o);continue}t=3,n=65535}if(a-1+t>=i.length){a+=r("OVERRUN",a-1,i,o);continue}let s=e&(1<<8-t-1)-1;for(let e=0;e1114111?a+=r("OUT_OF_RANGE",a-1-t,i,o,s):s>=55296&&s<=57343?a+=r("UTF16_SURROGATE",a-1-t,i,o,s):s<=n?a+=r("OVERLONG",a-1-t,i,o,s):o.push(s))}return o}function s(e,t){null!=t&&((0,i.assertNormalize)(t),e=e.normalize(t));let r=[];for(let t=0;t>6|192),r.push(63&n|128);else if(55296==(64512&n)){t++;const o=e.charCodeAt(t);(0,i.assertArgument)(t>18|240),r.push(a>>12&63|128),r.push(a>>6&63|128),r.push(63&a|128)}else r.push(n>>12|224),r.push(n>>6&63|128),r.push(63&n|128)}return new Uint8Array(r)}t.Utf8ErrorFuncs=Object.freeze({error:function(e,t,r,n,o){(0,i.assertArgument)(!1,`invalid codepoint at offset ${t}; ${e}`,"bytes",r)},ignore:o,replace:function(e,t,r,n,a){return"OVERLONG"===e?((0,i.assertArgument)("number"==typeof a,"invalid bad code point for replacement","badCodepoint",a),n.push(a),0):(n.push(65533),o(e,t,r))}}),t.toUtf8Bytes=s,t.toUtf8String=function(e,t){return a(e,t).map((e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e))))).join("")},t.toUtf8CodePoints=function(e,t){return a(s(e,t))}},4824:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.uuidV4=void 0;const n=r(86239);t.uuidV4=function(e){const t=(0,n.getBytes)(e,"randomBytes");t[6]=15&t[6]|64,t[8]=63&t[8]|128;const r=(0,n.hexlify)(t);return[r.substring(2,10),r.substring(10,14),r.substring(14,18),r.substring(18,22),r.substring(22,34)].join("-")}},85662:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseWallet=void 0;const n=r(45475),i=r(98336),o=r(4878),a=r(2290),s=r(42120);class u extends o.AbstractSigner{address;#Tt;constructor(e,t){super(t),(0,s.assertArgument)(e&&"function"==typeof e.sign,"invalid private key","privateKey","[ REDACTED ]"),this.#Tt=e;const r=(0,a.computeAddress)(this.signingKey.publicKey);(0,s.defineProperties)(this,{address:r})}get signingKey(){return this.#Tt}get privateKey(){return this.signingKey.privateKey}async getAddress(){return this.address}connect(e){return new u(this.#Tt,e)}async signTransaction(e){const{to:t,from:r}=await(0,s.resolveProperties)({to:e.to?(0,n.resolveAddress)(e.to,this.provider):void 0,from:e.from?(0,n.resolveAddress)(e.from,this.provider):void 0});null!=t&&(e.to=t),null!=r&&(e.from=r),null!=e.from&&((0,s.assertArgument)((0,n.getAddress)(e.from)===this.address,"transaction from address mismatch","tx.from",e.from),delete e.from);const i=a.Transaction.from(e);return i.signature=this.signingKey.sign(i.unsignedHash),i.serialized}async signMessage(e){return this.signMessageSync(e)}signMessageSync(e){return this.signingKey.sign((0,i.hashMessage)(e)).serialized}async signTypedData(e,t,r){const n=await i.TypedDataEncoder.resolveNames(e,t,r,(async e=>{(0,s.assert)(null!=this.provider,"cannot resolve ENS names without a provider","UNSUPPORTED_OPERATION",{operation:"resolveName",info:{name:e}});const t=await this.provider.resolveName(e);return(0,s.assert)(null!=t,"unconfigured ENS name","UNCONFIGURED_NAME",{value:e}),t}));return this.signingKey.sign(i.TypedDataEncoder.hash(n.domain,t,n.value)).serialized}}t.BaseWallet=u},90483:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getIndexedAccountPath=t.getAccountPath=t.HDNodeVoidWallet=t.HDNodeWallet=t.defaultPath=void 0;const n=r(96965),i=r(4878),o=r(2290),a=r(42120),s=r(10847),u=r(85662),c=r(40075),l=r(10630);t.defaultPath="m/44'/60'/0'/0/0";const f=new Uint8Array([66,105,116,99,111,105,110,32,115,101,101,100]),h=2147483648,d=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141");function p(e,t){let r="";for(;e;)r="0123456789abcdef"[e%16]+r,e=Math.trunc(e/16);for(;r.length<2*t;)r="0"+r;return"0x"+r}function m(e){const t=(0,a.getBytes)(e),r=(0,a.dataSlice)((0,n.sha256)((0,n.sha256)(t)),0,4),i=(0,a.concat)([t,r]);return(0,a.encodeBase58)(i)}const y={};function g(e,t,r,i){const o=new Uint8Array(37);e&h?((0,a.assert)(null!=i,"cannot derive child of neutered node","UNSUPPORTED_OPERATION",{operation:"deriveChild"}),o.set((0,a.getBytes)(i),1)):o.set((0,a.getBytes)(r));for(let t=24;t>=0;t-=8)o[33+(t>>3)]=e>>24-t&255;const s=(0,a.getBytes)((0,n.computeHmac)("sha512",t,o));return{IL:s.slice(0,32),IR:s.slice(32)}}function b(e,t){const r=t.split("/");(0,a.assertArgument)(r.length>0&&("m"===r[0]||e.depth>0),"invalid path","path",t),"m"===r[0]&&r.shift();let n=e;for(let e=0;e=16&&r.length<=64,"invalid seed","seed","[REDACTED]");const i=(0,a.getBytes)((0,n.computeHmac)("sha512",f,r)),o=new n.SigningKey((0,a.hexlify)(i.slice(0,32)));return new v(y,o,"0x00000000",(0,a.hexlify)(i.slice(32)),"m",0,0,t,null)}static fromExtendedKey(e){const t=(0,a.toBeArray)((0,a.decodeBase58)(e));(0,a.assertArgument)(82===t.length||m(t.slice(0,78))===e,"invalid extended key","extendedKey","[ REDACTED ]");const r=t[4],i=(0,a.hexlify)(t.slice(5,9)),s=parseInt((0,a.hexlify)(t.slice(9,13)).substring(2),16),u=(0,a.hexlify)(t.slice(13,45)),c=t.slice(45,78);switch((0,a.hexlify)(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":{const e=(0,a.hexlify)(c);return new w(y,(0,o.computeAddress)(e),e,i,u,null,s,r,null)}case"0x0488ade4":case"0x04358394 ":if(0!==c[0])break;return new v(y,new n.SigningKey(c.slice(1)),i,u,null,s,r,null,null)}(0,a.assertArgument)(!1,"invalid extended key prefix","extendedKey","[ REDACTED ]")}static createRandom(e,r,i){null==e&&(e=""),null==r&&(r=t.defaultPath),null==i&&(i=s.LangEn.wordlist());const o=c.Mnemonic.fromEntropy((0,n.randomBytes)(16),e,i);return v.#Pt(o.computeSeed(),o).derivePath(r)}static fromMnemonic(e,r){return r||(r=t.defaultPath),v.#Pt(e.computeSeed(),e).derivePath(r)}static fromPhrase(e,r,n,i){null==r&&(r=""),null==n&&(n=t.defaultPath),null==i&&(i=s.LangEn.wordlist());const o=c.Mnemonic.fromPhrase(e,r,i);return v.#Pt(o.computeSeed(),o).derivePath(n)}static fromSeed(e){return v.#Pt(e,null)}}t.HDNodeWallet=v;class w extends i.VoidSigner{publicKey;fingerprint;parentFingerprint;chainCode;path;index;depth;constructor(e,t,r,i,o,s,u,c,l){super(t,l),(0,a.assertPrivate)(e,y,"HDNodeVoidWallet"),(0,a.defineProperties)(this,{publicKey:r});const f=(0,a.dataSlice)((0,n.ripemd160)((0,n.sha256)(r)),0,4);(0,a.defineProperties)(this,{publicKey:r,fingerprint:f,parentFingerprint:i,chainCode:o,path:s,index:u,depth:c})}connect(e){return new w(y,this.address,this.publicKey,this.parentFingerprint,this.chainCode,this.path,this.index,this.depth,e)}get extendedKey(){return(0,a.assert)(this.depth<256,"Depth too deep","UNSUPPORTED_OPERATION",{operation:"extendedKey"}),m((0,a.concat)(["0x0488B21E",p(this.depth,1),this.parentFingerprint,p(this.index,4),this.chainCode,this.publicKey]))}hasPath(){return null!=this.path}deriveChild(e){const t=(0,a.getNumber)(e,"index");(0,a.assertArgument)(t<=4294967295,"invalid index","index",t);let r=this.path;r&&(r+="/"+(2147483647&t),t&h&&(r+="'"));const{IR:i,IL:s}=g(t,this.chainCode,this.publicKey,null),u=n.SigningKey.addPoints(s,this.publicKey,!0),c=(0,o.computeAddress)(u);return new w(y,c,u,this.fingerprint,(0,a.hexlify)(i),r,t,this.depth+1,this.provider)}derivePath(e){return b(this,e)}}t.HDNodeVoidWallet=w,t.getAccountPath=function(e){const t=(0,a.getNumber)(e,"index");return(0,a.assertArgument)(t>=0&&t=0&&t{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Wallet=t.Mnemonic=t.encryptKeystoreJsonSync=t.encryptKeystoreJson=t.decryptKeystoreJson=t.decryptKeystoreJsonSync=t.isKeystoreJson=t.decryptCrowdsaleJson=t.isCrowdsaleJson=t.HDNodeVoidWallet=t.HDNodeWallet=t.getAccountPath=t.defaultPath=t.BaseWallet=void 0;var n=r(85662);Object.defineProperty(t,"BaseWallet",{enumerable:!0,get:function(){return n.BaseWallet}});var i=r(90483);Object.defineProperty(t,"defaultPath",{enumerable:!0,get:function(){return i.defaultPath}}),Object.defineProperty(t,"getAccountPath",{enumerable:!0,get:function(){return i.getAccountPath}}),Object.defineProperty(t,"HDNodeWallet",{enumerable:!0,get:function(){return i.HDNodeWallet}}),Object.defineProperty(t,"HDNodeVoidWallet",{enumerable:!0,get:function(){return i.HDNodeVoidWallet}});var o=r(78668);Object.defineProperty(t,"isCrowdsaleJson",{enumerable:!0,get:function(){return o.isCrowdsaleJson}}),Object.defineProperty(t,"decryptCrowdsaleJson",{enumerable:!0,get:function(){return o.decryptCrowdsaleJson}});var a=r(10630);Object.defineProperty(t,"isKeystoreJson",{enumerable:!0,get:function(){return a.isKeystoreJson}}),Object.defineProperty(t,"decryptKeystoreJsonSync",{enumerable:!0,get:function(){return a.decryptKeystoreJsonSync}}),Object.defineProperty(t,"decryptKeystoreJson",{enumerable:!0,get:function(){return a.decryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJson",{enumerable:!0,get:function(){return a.encryptKeystoreJson}}),Object.defineProperty(t,"encryptKeystoreJsonSync",{enumerable:!0,get:function(){return a.encryptKeystoreJsonSync}});var s=r(40075);Object.defineProperty(t,"Mnemonic",{enumerable:!0,get:function(){return s.Mnemonic}});var u=r(6389);Object.defineProperty(t,"Wallet",{enumerable:!0,get:function(){return u.Wallet}})},78668:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decryptCrowdsaleJson=t.isCrowdsaleJson=void 0;const n=r(93260),i=r(45475),o=r(96965),a=r(98336),s=r(42120),u=r(57668);t.isCrowdsaleJson=function(e){try{if(JSON.parse(e).encseed)return!0}catch(e){}return!1},t.decryptCrowdsaleJson=function(e,t){const r=JSON.parse(e),c=(0,u.getPassword)(t),l=(0,i.getAddress)((0,u.spelunk)(r,"ethaddr:string!")),f=(0,u.looseArrayify)((0,u.spelunk)(r,"encseed:string!"));(0,s.assertArgument)(f&&f.length%16==0,"invalid encseed","json",e);const h=(0,s.getBytes)((0,o.pbkdf2)(c,c,2e3,32,"sha256")).slice(0,16),d=f.slice(0,16),p=f.slice(16),m=new n.CBC(h,d),y=(0,n.pkcs7Strip)((0,s.getBytes)(m.decrypt(p)));let g="";for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.encryptKeystoreJson=t.encryptKeystoreJsonSync=t.decryptKeystoreJson=t.decryptKeystoreJsonSync=t.isKeystoreJson=void 0;const n=r(93260),i=r(45475),o=r(96965),a=r(2290),s=r(42120),u=r(57668),c=r(79406),l="m/44'/60'/0'/0/0";function f(e,t){const r=(0,s.getBytes)(t),c=(0,u.spelunk)(e,"crypto.ciphertext:data!"),f=(0,s.hexlify)((0,o.keccak256)((0,s.concat)([r.slice(16,32),c]))).substring(2);(0,s.assertArgument)(f===(0,u.spelunk)(e,"crypto.mac:string!").toLowerCase(),"incorrect password","password","[ REDACTED ]");const h=function(e,t,r){if("aes-128-ctr"===(0,u.spelunk)(e,"crypto.cipher:string")){const i=(0,u.spelunk)(e,"crypto.cipherparams.iv:data!"),o=new n.CTR(t,i);return(0,s.hexlify)(o.decrypt(r))}(0,s.assert)(!1,"unsupported cipher","UNSUPPORTED_OPERATION",{operation:"decrypt"})}(e,r.slice(0,16),c),d=(0,a.computeAddress)(h);if(e.address){let t=e.address.toLowerCase();t.startsWith("0x")||(t="0x"+t),(0,s.assertArgument)((0,i.getAddress)(t)===d,"keystore address/privateKey mismatch","address",e.address)}const p={address:d,privateKey:h};if("0.1"===(0,u.spelunk)(e,"x-ethers.version:string")){const t=r.slice(32,64),i=(0,u.spelunk)(e,"x-ethers.mnemonicCiphertext:data!"),o=(0,u.spelunk)(e,"x-ethers.mnemonicCounter:data!"),a=new n.CTR(t,o);p.mnemonic={path:(0,u.spelunk)(e,"x-ethers.path:string")||l,locale:(0,u.spelunk)(e,"x-ethers.locale:string")||"en",entropy:(0,s.hexlify)((0,s.getBytes)(a.decrypt(i)))}}return p}function h(e){const t=(0,u.spelunk)(e,"crypto.kdf:string");if(t&&"string"==typeof t){if("scrypt"===t.toLowerCase()){const r=(0,u.spelunk)(e,"crypto.kdfparams.salt:data!"),n=(0,u.spelunk)(e,"crypto.kdfparams.n:int!"),i=(0,u.spelunk)(e,"crypto.kdfparams.r:int!"),o=(0,u.spelunk)(e,"crypto.kdfparams.p:int!");(0,s.assertArgument)(n>0&&0==(n&n-1),"invalid kdf.N","kdf.N",n),(0,s.assertArgument)(i>0&&o>0,"invalid kdf","kdf",t);const a=(0,u.spelunk)(e,"crypto.kdfparams.dklen:int!");return(0,s.assertArgument)(32===a,"invalid kdf.dklen","kdf.dflen",a),{name:"scrypt",salt:r,N:n,r:i,p:o,dkLen:64}}if("pbkdf2"===t.toLowerCase()){const t=(0,u.spelunk)(e,"crypto.kdfparams.salt:data!"),r=(0,u.spelunk)(e,"crypto.kdfparams.prf:string!"),n=r.split("-").pop();(0,s.assertArgument)("sha256"===n||"sha512"===n,"invalid kdf.pdf","kdf.pdf",r);const i=(0,u.spelunk)(e,"crypto.kdfparams.c:int!"),o=(0,u.spelunk)(e,"crypto.kdfparams.dklen:int!");return(0,s.assertArgument)(32===o,"invalid kdf.dklen","kdf.dklen",o),{name:"pbkdf2",salt:t,count:i,dkLen:o,algorithm:n}}}(0,s.assertArgument)(!1,"unsupported key-derivation function","kdf",t)}function d(e){return new Promise((t=>{setTimeout((()=>{t()}),e)}))}function p(e){const t=null!=e.salt?(0,s.getBytes)(e.salt,"options.salt"):(0,o.randomBytes)(32);let r=1<<17,n=8,i=1;return e.scrypt&&(e.scrypt.N&&(r=e.scrypt.N),e.scrypt.r&&(n=e.scrypt.r),e.scrypt.p&&(i=e.scrypt.p)),(0,s.assertArgument)("number"==typeof r&&r>0&&Number.isSafeInteger(r)&&(BigInt(r)&BigInt(r-1))===BigInt(0),"invalid scrypt N parameter","options.N",r),(0,s.assertArgument)("number"==typeof n&&n>0&&Number.isSafeInteger(n),"invalid scrypt r parameter","options.r",n),(0,s.assertArgument)("number"==typeof i&&i>0&&Number.isSafeInteger(i),"invalid scrypt p parameter","options.p",i),{name:"scrypt",dkLen:32,salt:t,N:r,r:n,p:i}}function m(e,t,r,i){const a=(0,s.getBytes)(r.privateKey,"privateKey"),f=null!=i.iv?(0,s.getBytes)(i.iv,"options.iv"):(0,o.randomBytes)(16);(0,s.assertArgument)(16===f.length,"invalid options.iv length","options.iv",i.iv);const h=null!=i.uuid?(0,s.getBytes)(i.uuid,"options.uuid"):(0,o.randomBytes)(16);(0,s.assertArgument)(16===h.length,"invalid options.uuid length","options.uuid",i.iv);const d=e.slice(0,16),p=e.slice(16,32),m=new n.CTR(d,f),y=(0,s.getBytes)(m.encrypt(a)),g=(0,o.keccak256)((0,s.concat)([p,y])),b={address:r.address.substring(2).toLowerCase(),id:(0,s.uuidV4)(h),version:3,Crypto:{cipher:"aes-128-ctr",cipherparams:{iv:(0,s.hexlify)(f).substring(2)},ciphertext:(0,s.hexlify)(y).substring(2),kdf:"scrypt",kdfparams:{salt:(0,s.hexlify)(t.salt).substring(2),n:t.N,dklen:32,p:t.p,r:t.r},mac:g.substring(2)}};if(r.mnemonic){const t=null!=i.client?i.client:`ethers/${c.version}`,a=r.mnemonic.path||l,f=r.mnemonic.locale||"en",h=e.slice(32,64),d=(0,s.getBytes)(r.mnemonic.entropy,"account.mnemonic.entropy"),p=(0,o.randomBytes)(16),m=new n.CTR(h,p),y=(0,s.getBytes)(m.encrypt(d)),g=new Date,v="UTC--"+(g.getUTCFullYear()+"-"+(0,u.zpad)(g.getUTCMonth()+1,2)+"-"+(0,u.zpad)(g.getUTCDate(),2)+"T"+(0,u.zpad)(g.getUTCHours(),2)+"-"+(0,u.zpad)(g.getUTCMinutes(),2)+"-"+(0,u.zpad)(g.getUTCSeconds(),2)+".0Z")+"--"+b.address;b["x-ethers"]={client:t,gethFilename:v,path:a,locale:f,mnemonicCounter:(0,s.hexlify)(p).substring(2),mnemonicCiphertext:(0,s.hexlify)(y).substring(2),version:"0.1"}}return JSON.stringify(b)}t.isKeystoreJson=function(e){try{const t=JSON.parse(e);if(3===(null!=t.version?parseInt(t.version):0))return!0}catch(e){}return!1},t.decryptKeystoreJsonSync=function(e,t){const r=JSON.parse(e),n=(0,u.getPassword)(t),i=h(r);if("pbkdf2"===i.name){const{salt:e,count:t,dkLen:a,algorithm:s}=i;return f(r,(0,o.pbkdf2)(n,e,t,a,s))}(0,s.assert)("scrypt"===i.name,"cannot be reached","UNKNOWN_ERROR",{params:i});const{salt:a,N:c,r:l,p:d,dkLen:p}=i;return f(r,(0,o.scryptSync)(n,a,c,l,d,p))},t.decryptKeystoreJson=async function(e,t,r){const n=JSON.parse(e),i=(0,u.getPassword)(t),a=h(n);if("pbkdf2"===a.name){r&&(r(0),await d(0));const{salt:e,count:t,dkLen:s,algorithm:u}=a,c=(0,o.pbkdf2)(i,e,t,s,u);return r&&(r(1),await d(0)),f(n,c)}(0,s.assert)("scrypt"===a.name,"cannot be reached","UNKNOWN_ERROR",{params:a});const{salt:c,N:l,r:p,p:m,dkLen:y}=a;return f(n,await(0,o.scrypt)(i,c,l,p,m,y,r))},t.encryptKeystoreJsonSync=function(e,t,r){null==r&&(r={});const n=(0,u.getPassword)(t),i=p(r),a=(0,o.scryptSync)(n,i.salt,i.N,i.r,i.p,64);return m((0,s.getBytes)(a),i,e,r)},t.encryptKeystoreJson=async function(e,t,r){null==r&&(r={});const n=(0,u.getPassword)(t),i=p(r),a=await(0,o.scrypt)(n,i.salt,i.N,i.r,i.p,64,r.progressCallback);return m((0,s.getBytes)(a),i,e,r)}},40075:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Mnemonic=void 0;const n=r(96965),i=r(42120),o=r(10847);function a(e){return(1<=12&&r.length<=24,"invalid mnemonic length","mnemonic","[ REDACTED ]");const s=new Uint8Array(Math.ceil(11*r.length/8));let u=0;for(let e=0;e=0,`invalid mnemonic word at index ${e}`,"mnemonic","[ REDACTED ]");for(let e=0;e<11;e++)n&1<<10-e&&(s[u>>3]|=1<<7-u%8),u++}const c=32*r.length/3,l=a(r.length/3),f=(0,i.getBytes)((0,n.sha256)(s.slice(0,c/8)))[0]&l;return(0,i.assertArgument)(f===(s[s.length-1]&l),"invalid mnemonic checksum","mnemonic","[ REDACTED ]"),(0,i.hexlify)(s.slice(0,c/8))}function u(e,t){(0,i.assertArgument)(e.length%4==0&&e.length>=16&&e.length<=32,"invalid entropy size","entropy","[ REDACTED ]"),null==t&&(t=o.LangEn.wordlist());const r=[0];let s=11;for(let t=0;t8?(r[r.length-1]<<=8,r[r.length-1]|=e[t],s-=8):(r[r.length-1]<<=s,r[r.length-1]|=e[t]>>8-s,r.push(e[t]&((1<<8-s)-1&255)),s+=3);const u=e.length/4,c=parseInt((0,n.sha256)(e).substring(2,4),16)&a(u);return r[r.length-1]<<=u,r[r.length-1]|=c>>8-u,t.join(r.map((e=>t.getWord(e))))}const c={};class l{phrase;password;wordlist;entropy;constructor(e,t,r,n,a){null==n&&(n=""),null==a&&(a=o.LangEn.wordlist()),(0,i.assertPrivate)(e,c,"Mnemonic"),(0,i.defineProperties)(this,{phrase:r,password:n,wordlist:a,entropy:t})}computeSeed(){const e=(0,i.toUtf8Bytes)("mnemonic"+this.password,"NFKD");return(0,n.pbkdf2)((0,i.toUtf8Bytes)(this.phrase,"NFKD"),e,2048,64,"sha512")}static fromPhrase(e,t,r){const n=s(e,r);return e=u((0,i.getBytes)(n),r),new l(c,n,e,t,r)}static fromEntropy(e,t,r){const n=(0,i.getBytes)(e,"entropy"),o=u(n,r);return new l(c,(0,i.hexlify)(n),o,t,r)}static entropyToPhrase(e,t){return u((0,i.getBytes)(e,"entropy"),t)}static phraseToEntropy(e,t){return s(e,t)}static isValidMnemonic(e,t){try{return s(e,t),!0}catch(e){}return!1}}t.Mnemonic=l},57668:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.spelunk=t.getPassword=t.zpad=t.looseArrayify=void 0;const n=r(42120);function i(e){return"string"!=typeof e||e.startsWith("0x")||(e="0x"+e),(0,n.getBytesCopy)(e)}t.looseArrayify=i,t.zpad=function(e,t){for(e=String(e);e.length{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Wallet=void 0;const n=r(96965),i=r(42120),o=r(85662),a=r(90483),s=r(78668),u=r(10630),c=r(40075);function l(e){return new Promise((t=>{setTimeout((()=>{t()}),e)}))}class f extends o.BaseWallet{constructor(e,t){"string"!=typeof e||e.startsWith("0x")||(e="0x"+e),super("string"==typeof e?new n.SigningKey(e):e,t)}connect(e){return new f(this.signingKey,e)}async encrypt(e,t){const r={address:this.address,privateKey:this.privateKey};return await(0,u.encryptKeystoreJson)(r,e,{progressCallback:t})}encryptSync(e){const t={address:this.address,privateKey:this.privateKey};return(0,u.encryptKeystoreJsonSync)(t,e)}static#It(e){if((0,i.assertArgument)(e,"invalid JSON wallet","json","[ REDACTED ]"),"mnemonic"in e&&e.mnemonic&&"en"===e.mnemonic.locale){const t=c.Mnemonic.fromEntropy(e.mnemonic.entropy),r=a.HDNodeWallet.fromMnemonic(t,e.mnemonic.path);if(r.address===e.address&&r.privateKey===e.privateKey)return r;console.log("WARNING: JSON mismatch address/privateKey != mnemonic; fallback onto private key")}const t=new f(e.privateKey);return(0,i.assertArgument)(t.address===e.address,"address/privateKey mismatch","json","[ REDACTED ]"),t}static async fromEncryptedJson(e,t,r){let n=null;return(0,u.isKeystoreJson)(e)?n=await(0,u.decryptKeystoreJson)(e,t,r):(0,s.isCrowdsaleJson)(e)&&(r&&(r(0),await l(0)),n=(0,s.decryptCrowdsaleJson)(e,t),r&&(r(1),await l(0))),f.#It(n)}static fromEncryptedJsonSync(e,t){let r=null;return(0,u.isKeystoreJson)(e)?r=(0,u.decryptKeystoreJsonSync)(e,t):(0,s.isCrowdsaleJson)(e)?r=(0,s.decryptCrowdsaleJson)(e,t):(0,i.assertArgument)(!1,"invalid JSON wallet","json","[ REDACTED ]"),f.#It(r)}static createRandom(e){const t=a.HDNodeWallet.createRandom();return e?t.connect(e):t}static fromPhrase(e,t){const r=a.HDNodeWallet.fromPhrase(e);return t?r.connect(t):r}}t.Wallet=f},75033:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBits=void 0;t.decodeBits=function(e,t){const r=(1<=e;){const t=i>>o-e;i&=(1<{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeOwl=t.decode=void 0;const n=r(42120),i=" !#$%&'()*+,-./<=>?@[]^_`{|}~",o=/^[a-z]*$/i;function a(e,t){let r=97;return e.reduce(((e,n)=>(n===t?r++:n.match(o)?e.push(String.fromCharCode(r)+n):(r=97,e.push(n)),e)),[])}function s(e,t){for(let r=i.length-1;r>=0;r--)e=e.split(i[r]).join(t.substring(2*r,2*r+2));const r=[],n=e.replace(/(:|([0-9])|([A-Z][a-z]*))/g,((e,t,n,i)=>{if(n)for(let e=parseInt(n);e>=0;e--)r.push(";");else r.push(t.toLowerCase());return""}));if(n)throw new Error(`leftovers: ${JSON.stringify(n)}`);return a(a(r,";"),":")}t.decode=s,t.decodeOwl=function(e){return(0,n.assertArgument)("0"===e[0],"unsupported auwl data","data",e),s(e.substring(1+2*i.length),e.substring(1,1+2*i.length))}},84603:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeOwlA=void 0;const n=r(42120),i=r(75033),o=r(82629);t.decodeOwlA=function(e,t){let r=(0,o.decodeOwl)(e).join(",");return t.split(/,/g).forEach((e=>{const o=e.match(/^([a-z]*)([0-9]+)([0-9])(.*)$/);(0,n.assertArgument)(null!==o,"internal error parsing accents","accents",t);let a=0;const s=(0,i.decodeBits)(parseInt(o[3]),o[4]),u=parseInt(o[2]),c=new RegExp(`([${o[1]}])`,"g");r=r.replace(c,((e,t)=>(0===--s[a]&&(t=String.fromCharCode(t.charCodeAt(0),u),a++),t)))})),r.split(",")}},60659:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wordlists=t.WordlistOwlA=t.WordlistOwl=t.LangEn=t.Wordlist=void 0;var n=r(51208);Object.defineProperty(t,"Wordlist",{enumerable:!0,get:function(){return n.Wordlist}});var i=r(10847);Object.defineProperty(t,"LangEn",{enumerable:!0,get:function(){return i.LangEn}});var o=r(21978);Object.defineProperty(t,"WordlistOwl",{enumerable:!0,get:function(){return o.WordlistOwl}});var a=r(99766);Object.defineProperty(t,"WordlistOwlA",{enumerable:!0,get:function(){return a.WordlistOwlA}});var s=r(84311);Object.defineProperty(t,"wordlists",{enumerable:!0,get:function(){return s.wordlists}})},8838:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangCz=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("cz","0itatkastcenaovo$taouleraeki&chor*teci%enbalodaeladet'!Chn=0Di#%E%^1Resa2Rese3CeT'#0EjKohol0Pu)%0A&sDul#Ekdo)Ke)Ti#Ul|3}aOgan%0FaltI$@tPi,%TmaTronom0LasL{i#Ol0Tobus4Yl:B#}R'?TaUb_U/!U^U+Ur!Xer2A^v#Ambo,An#AtrEp)Ike)KoLohOnzOskevUn{#Usin#Z^Zy2Bl.Bn|})D _D#D'aF{Jar(Kv?LdokLvaN^NkrRzaTikVolZola3D+tL.T'#0Ukot:PartRev&3DrDu+J/JnLaLerLkemLn?N.Nn(N'#NtrumNzZ(2O&2KolivUv!4It_N(0Dn(Ke)KrPot0Ak~AlIkRkot2Kli$a:L-oRe[T_Tum1E,1B!a}'#Cib_Fic Fla%KlKr{Mokr!PreseRbyS#T-tiv3Kob,zKt|O^P]mSkSp+jV`]Vo/2AhaOuhoUhopis1Es0BroByt-C@t}ut DnesH+dHo^H,JemJn?Kl`KolaKtAzeDolObn(OgerieOzdSn(T Z(2B@}'noD-HaH'#S SnoT(0Oj?Or>2Nam :9O]gOnomie0EktronIpsa0AilIseO%P!ie2Izo^O/aOpejOs2EjEn%K<)Kymo0Ike)0FR&S]Zky3StOhOup(T!Ub.U/o)0AtO)Yz0IsOjivoOut0Bl.Boj}DinyDl!Dno)D|Jn(KejLin#L#LubMo+N [No,%RalR^RizontRkoRliv>RmonRn.RoskopR$voSpo^St.T'(U[UfUp!Us#V<2Ad[An?Av(Az^Bo+kD.D]D(N-Ob#Oma^OtOu^Oz@St#Ub(Yz!2B@(B~D[KotMrS aSto)0Ozd2Bn(D,ntGie&M&Sterik:2Yl#3Ned2O&0Uze0Un a0F-%Fla%KasoOva%Sp-%Tern{Vali^Ve$N)rRmarkRoSanSnoT#VD+Dn!_HlanKotL@L oMn(NomP?S{erV Zd>Zero3NakNdyNo/Sk,Sto)Trn?Zva3En|1Gurt5R):Bar{B_Bin{}&D{Did]HanJakJu)KaoKtusLam aLhotyLibrLn(Me,MkolivM&Ni[lNoeNtB#BlihaBylaC*rH=J@>KosKtejlLapsLe^LizeLoMandoMe)MikMn!aMo,MpasMun aN!N%ptNd?N>NfeseNgresN.NkursN)ktNzervaPan>PieP~Pr'#Rb_R-tSt#T_T+)T*lUk!Up_&Us-Uz]VbojZaZMe+cMivoOcanOkOni#Op OupaOv#T-Uh`]Up?Ut(Vin#Y/+Yp)Y$alYt2Dlan#FrJn(KlaLaj^Li/L#Lom{Ltu,NaPodivuRtRzV`]:B,d<})nDn(IkKom>M_aMpaN'#S?SoStu,Tin#V.3B#CkdyD@Dn?D'#Dv.G@^GieG,%H%Hk(H~KtvarNo/odNtil#P@#Pid]T`]T>TmoTokruhVhartV a%Vobok3B,}ot#DojedDsk(H'.Jav>L-M{#NieN#No+umStop`T.T|5Bi$aDivodGi#GopedKal aK{Mc|P!aPu/RdSosTrU^lUhU#Usk!V>3Tiv(1Cer&CiferMpSkSt,%0I%2RaRi#S.:DamD]Gi$rHagonJ{-J _J< aKakK'?Kr_aL[L.L|Lv?Min#Nd+NkoRn(SakrSkotSopu$T?Tri#Tur aZan>ZivoZl Zur#2Lo[0}anikD a%D'.LasaL*nNtol#TlaTo^TrZe,3G,%H~Hu+K.KrofonL@>Lim{rL(Mi#Nc'&Ni[rNom{Nul(S#StrX|2Ad(HaH'.OkS!Uv 1I/Ohem0BilCn(D_#Dl [HylaKroL-ulaM@t#Nar/aNoklN$rumNt|NzunSazSkytStTiva%T<#Ty#U/aUdr(Zai#Z-Zol2AmKevTvolaZ{Zut(0T _1DrcF]nL!MieN?S{Ta%ZeumZi#nt3Sliv>0Da:B*r!}yt!Da%Dbyt-DhozDobroDpisHlasHn!Hodi+H,d Iv aJedn*Ji$oJm=K]n Kon>Krm LevoMaz!Mluv Nom{rOkoOpakO$roP`!PevnoPln P~Pos+dPr(oRod RubyRy/]S` S-!S+poSt!TolikV@-Vr/VzdR&Ru[RysSahSluhaS)r!UvVazVin VodVyk+Yv!_Z<0AsElEn Hl` Ho)H,&It~0BojByt}odCiz Ebr!Esl!Evzd!EzvaH`%Hod J{JinudKazK*p LivLu#Ml#Oln(P`PisPl=PLivoLu[Mf+tMls-N@#Ni#N&N|N$voNtof+Pri#Rke)RodieR)Ru#Ry[Se#Siv aSt_#T@tTro&V*kZnehtZ*r-3C#DagogJs-K]LotonNal)Ndr-NzeRiskopRoStr(Tar^T?Tro+jVn.Xeso3Ani$aHaJav?K+KnikL.Ln(Lul#Nze)Pe)S!_Sto+Tev&Vn?V'ar2A%n)Ak!Am@Ane)A$i#At Avid]AzE/Em@oEn)EsEtivoEv_Iv!N NoO/aOd.Om[OutUkYn2Bav Byt}odC Ctiv>D!D%n Deps!Dh+dDiv Dkl`Dman DnikDo[Dpo,D,zD$!aDvodDzimEzieHan#Hnut#H'S*d SpoluS)vaSud-SypTahT#nT+skTom-T,vaTupaTvo,U#zUtoUzdroVahaVidlaVlakVozVr/V$!VykVzde/Zd,vZem-Zn!-ZAp<-AseAv^IncipKnoObud O%ntoOdejOfeseOh,Oj-tO]m Omi+Onik!Op`OrokOs[OtonOut-OvazS#v#St@Udk(UtV-VohOvodTruh0Actvo0Ber)}DlKav>Kl.Kr+LtMpaNcP@SaSin#St.T|Ty#3Rami^SkT_::C-}otDia%Dn?DonFtGbyKe)K'.M@oMp*/NdeRa/R aS'&StrTo+$Zan%Zid]3Ag|Ak%CeptDaktMizd!Mo)N #Rdin#San#T_ Z[Z@?0Or0H|1B,n#CeseD`]Dim@tD]Hn!Jm=Ke,K)Kun^KvojeM@oNoRvisS` Sho,SkokSl!St,SuvSyp!T[T.Tk!T~Trv!VerZ&m2O^R~0FonLn?R#Rot-RupTua%1AfandrAliskoAnz@AutEptikIcaL`[L@?LoLuzO[O#nOroRip)RzUp.V(Vr&0Abi#Adid]An.A$Avn(Ed|Ep>EvaEz.IbI&Izn?OnOup-OvoU/UhaUn%Up#Za0A,gdE)&Il$voL*vaOgR`RkRt#Ut-Ysl0AdAhaOb0Bo)}aD'#KolP#TvaUbojUc Ud%UhlasUl`Um,kUp,vaUsedUtokUvis{0Al'&As _IsLavOd-Oj@>OluOnzOvn!P@StUb1An?Ar(aAti#Av[EhnoEz#OdolaO+kOpaOrnoOup!Ra/ResRh~RomRu&Ud&Upn?VolYk0Bj-tBtropy}arD(KnoNd!N=Rik!aR'.0AhAl$voEtrAt[Az-Is+It-Obo^Odid]Or#Rab2Kav#KotN-N'>P!Pk(R'(S_T(:B+t#Bu+H*nJemnoJfunJgaJ Jn(Kti#Mh+MponNc|N>NkerPe)V@.Z!_3}ni#HdyKut.LefonMno)Nd@%Ni$aNU/l Uhl?UsV!2DyH~H(Nd,Ri$aR&jZemsko0ArohOr[Rd(Rz2GrKev:0Oh(OzeR!R*s-RusYt'&0HoTiv(0Iv 3R` 1Edn!I$ M=0Az!_Lidn Lon Otv Roj 0I%I)Ov 0Yv`]0Av IfR*s 1Al Oln Oz'#3D,v ElEn.L.N!:GonL/aL*nNaN^lNil#RanRhanyR|1ElkuHod0Ova0DroGe)%J%Lbl*dL{rhL _LmocLry[Nk'Ran^RzeS_#SkrzeSn?SpoduS)Ter.Ver#3B,%}rDeoh,D.D+LaN?S{Tal aZeZ #0Ezd0L`Us0Aj#AkAs>EvoHk(IvN'#Oup!1Uc|Uk0DaDiv(Doz&kD$voJ@skyJ&JskoLantL[L LnoSk'#Zid]Z'&0Ravo1Ab>A%tAhA)Ba}o+kH!StvaTu+0Ad T*p Tup0Ip4Bav Br!}|D!D,Fot H+d!H~Hod H,d Hub Jasn J{Jm=K]p Kon!L-!Maz!Mez Miz{Mys+tNe/!Nik!Nut P`!Pl! P,v Pu$ Raz R'n!Rv!Sl' SokoS)v Su~Syp!Tas Tes!Tr! Vi~Vol!Vrh_Zdob Zn!0AduBud }op DJ{Ji$ K+p!K*p Lep Mez Mot!Mys+tNe/!Nik!Pl! Poj Ps!Raz S)v Su~Taj Temn Tk~Ujm=Val Ve+tVin Vol!Vrt!Zvon 0Av RusuUd|Yt-1A+#ArmaAtn(IvoOb RojVihYm`]0L@.ManM.Pt!Z`uZdola2At Lt~Lubo#Ot' Ru[0MaMn?0Emn 0Lam!Oum!R!#Umav#0AtoEh#O[OmO$Ozvyk0Ap|ArAt-IjeIz{Ocn Odr!Rzl.Ut|0AkAl(Am@!Ovu0B,z Tav Ub-Ufa+0Lod Omal RavaR( Rud#Rvu1A^An C`]N (NoOv&Y/l Zav(1I/aR! 0B'.Br0Ed~EnkuEs_aOnR!Uk'odYk","0x25f44555f4af25b51a711136e1c7d6e50ce9f8917d39d6b1f076b2bb4d2fac1a")}static wordlist(){return null==i&&(i=new o),i}}t.LangCz=o},10847:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangEn=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("en","0erleonalorenseinceregesticitStanvetearctssi#ch2Athck&tneLl0And#Il.yLeOutO=S|S%b/ra@SurdU'0Ce[Cid|CountCu'Hie=IdOu,-Qui*Ro[TT]T%T*[Tu$0AptDD-tD*[Ju,M.UltV<)Vi)0Rob-0FairF%dRaid0A(EEntRee0Ead0MRRp%tS!_rmBumCoholErtI&LLeyLowMo,O}PhaReadySoT Ways0A>urAz(gOngOuntU'd0Aly,Ch%Ci|G G!GryIm$K!Noun)Nu$O` Sw T&naTiqueXietyY1ArtOlogyPe?P!Pro=Ril1ChCt-EaEnaGueMMedM%MyOundR<+Re,Ri=RowTTefa@Ti,Tw%k0KPe@SaultSetSi,SumeThma0H!>OmTa{T&dT.udeTra@0Ct]D.Gu,NtTh%ToTumn0Era+OcadoOid0AkeA*AyEsomeFulKw?d0Is:ByChel%C#D+GL<)Lc#y~MbooN_{Ad!AftAmA}AshAt AwlAzyEamEd.EekEwI{etImeIspIt-OpO[Ou^OwdUci$UelUi'Umb!Un^UshYY,$2BeLtu*PPbo?dRiousRr|Rta(R=Sh]/omTe3C!:DMa+MpN)Ng R(gShUght WnY3AlBa>BrisCadeCemb CideCl(eC%a>C*a'ErF&'F(eFyG*eLayLiv M3AgramAlAm#dAryCeE'lEtFf G.$Gn.yLemmaNn NosaurRe@RtSag*eScov Sea'ShSmi[S%d Splay/<)V tVideV%)Zzy5Ct%Cum|G~Lph(Ma(Na>NkeyN%OrSeUb!Ve_ftAg#AmaA,-AwEamE[IftIllInkIpI=OpUmY2CkMbNeR(g/T^Ty1Arf1Nam-:G G!RlyRnR`Sily/Sy1HoOlogyOnomy0GeItUca>1F%t0G1GhtTh 2BowD E@r-EgSe0B?kBodyBra)Er+Ot]PloyPow Pty0Ab!A@DD![D%'EmyErgyF%)Ga+G(eH<)JoyLi,OughR-hRollSu*T Ti*TryVelope1Isode0U$Uip0AA'OdeOs]R%Upt0CapeSayS&)Ta>0Ern$H-s1Id&)IlOkeOl=1A@Amp!Ce[Ch<+C.eCludeCu'Ecu>Erci'Hau,Hib.I!I,ItOt-PM&'Mu}Pa@Po'Pro=Pul'0ChCludeComeC*a'DexD-a>Do%Du,ryFN Noc|PutQuirySSue0Em1Ory:CketGu?RZz3AlousAns~yWel9BInKeUr}yY5D+I)MpNg!Ni%Nk/:Ng?oo3EnEpT^upY3CkDD}yNdNgdomSsTT^&TeTt&Wi4EeIfeO{Ow:BBelB%Dd DyKeMpNgua+PtopR+T T(UghUndryVaWWnWsu.Y Zy3Ad AfArnA=Ctu*FtGG$G&dIsu*M#NdNg`NsOp?dSs#Tt Vel3ArB tyBr?yC&'FeFtGhtKeMbM.NkOnQuid/Tt!VeZ?d5AdAnB, C$CkG-NelyNgOpTt yUdUn+VeY$5CkyGga+Mb N?N^Xury3R-s:Ch(eDG-G}tIdIlInJ%KeMm$NNa+Nda>NgoNs]Nu$P!Rb!R^Rg(R(eRketRria+SkSs/ T^T i$ThTrixTt XimumZe3AdowAnAsu*AtCh<-D$DiaLodyLtMb M%yNt]NuRcyR+R.RryShSsa+T$Thod3Dd!DnightLk~]M-NdNimumN%Nu>Rac!Rr%S ySs/akeXXedXtu*5Bi!DelDifyMM|N.%NkeyN, N`OnR$ReRn(gSqu.oTh T]T%Unta(U'VeVie5ChFf(LeLtiplySc!SeumShroomS-/Tu$3Self/ yTh:I=MePk(Rrow/yT]Tu*3ArCkEdGati=G!@I` PhewR=/TTw%kUtr$V WsXt3CeGht5B!I'M(eeOd!Rm$R`SeTab!TeTh(gTi)VelW5C!?Mb R'T:K0EyJe@Li+Scu*S =Ta(Vious0CurEAyEa'Ed+U{UgUn+2EmEtIntL?LeLi)NdNyOlPul?Rt]S.]Ssib!/TatoTt yV tyWd W _@i)Ai'Ed-tEf Epa*Es|EttyEv|I)IdeIm?yIntI%.yIs#Iva>IzeOb!mO)[Odu)Of.OgramOje@Omo>OofOp tyOsp O>@OudOvide2Bl-Dd(g~LpL'Mpk(N^PilPpyR^a'R.yRpo'R'ShTZz!3Ramid:99Al.yAntumArt E,]I{ItIzO>:Bb.Cco#CeCkD?DioIlInI'~yMpN^NdomN+PidReTeTh V&WZ%3AdyAlAs#BelBuildC$lCei=CipeC%dCyc!Du)F!@F%mFu'G]G*tGul?Je@LaxLea'LiefLyMa(Memb M(dMo=Nd NewNtOp&PairPeatPla)P%tQui*ScueSemb!Si,Sour)Sp#'SultTi*T*atTurnUn]Ve$ViewW?d2Y`m0BBb#CeChDeD+F!GhtGidNgOtPp!SkTu$V$V 5AdA,BotBu,CketM<)OfOkieOmSeTa>UghUndU>Y$5Bb DeGLeNNwayR$:DDd!D}[FeIlLadLm#L#LtLu>MeMp!NdTisfyToshiU)Usa+VeY1A!AnA*Att E}HemeHoolI&)I[%sOrp]OutRapRe&RiptRub1AAr^As#AtC#dC*tCt]Cur.yEdEkGm|Le@~M(?Ni%N'Nt&)RiesRvi)Ss]Tt!TupV&_dowAftAllowA*EdEllEriffIeldIftI}IpIv O{OeOotOpOrtOuld O=RimpRugUff!Y0Bl(gCkDeE+GhtGnL|Lk~yLv Mil?Mp!N)NgR&/ Tua>XZe1A>Et^IIllInIrtUll0AbAmEepEnd I)IdeIghtImOgAyEakEelEmEpE*oI{IllIngO{Oma^O}OolOryO=Ra>gyReetRikeR#gRugg!Ud|UffUmb!Y!0Bje@Bm.BwayC)[ChDd&Ff G?G+,ItMm NNnyN'tP PplyP*meReRfa)R+Rpri'RroundR=ySpe@/a(1AllowAmpApArmE?EetIftImIngIt^Ord1MbolMptomRup/em:B!Ck!GIlL|LkNkPeR+tSk/eTtooXi3A^Am~NNGradeHoldOnP Set1BOng::Rd3Ar~ow9UUngU`:3BraRo9NeO","0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60")}static wordlist(){return null==i&&(i=new o),i}}t.LangEn=o},19321:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangEs=void 0;const n=r(99766);let i=null;class o extends n.WordlistOwlA{constructor(){super("es","0arertoiotadonoaRteirroenaNonaLsolocoiliaralaorrenadaChoN$n0A>Dom,EjaI!#Oga&O'Or#RazoR*Ue=U<0Ab Adem@CeLe%OmoRa!RozUn0DazD$GeLaM,#S,)T^0AlAnceA+EEl]`E`EstruzI.I<2ErU{U'0Af[nArO)Uc Uf_Ul:BaB^|eH@IleJ Lanz/c.LdeMbuN>Nd-oRb(>RnizR+Scu]S#nSu[Tal]T!@T*Tu%UlZ 3BeBid/=S SoSt@3|oEnNgo2An>OqueUsa2ABi`BoCaCi`DaDegaIn//!oLsaMb-{dNi#N}saiRdeRr SqueTeTinVe{Zal2AvoAzoEchaEveIl=In>IsaOcaOmaOnceO)UjaUs>U#2CeoCleE'EyFan{F.HoIt_L#Rbuj(l(+Sc TacaZ.:Bal=BezaBi`B[CaoDav!D,aErFeI{ImanJaJ.LLam Lc$L&Li{dLleLm/^LvoMaMb$Mel=Mi'Mp}c!Nd?Nel-gu+Nic-#N-.ObaOsPazPi%nPo)Pt Puch((b.RcelRe%Rg(i'RneRpe%R+R%SaS>S!oSpaS#rT^ceT_U{lUsaZo3Bol]D!D+Ld/eb_LoAmpuAnc]ApaAr]I>Is)IvoOqueOzaUle%Up 0Cl.EgoE=EnEr#F[G +M->NeN%P_sR>Rue]SneTaU{d2Am^AnA+AseAveI,)ImaInica2B_Cc~|i'Ci`CoDigoDoF_G!He)JinJoL/ch/eg$Lg Lin/l LmoLum`Mba)M!Mi{Mo&Mpr-deNej}g-oc!Nsej}t PaPi(az.Rba%RchoR&nR.(r!S!SmosS%2AneoAt!E Ec!Ei&EmaIaIm,Ip%IsisOmoOnicaOque%U&Uz2Ad+Ar#At+BoBr*| aEl=En#Er{Es%EvaId Lebr/p/#Mb_Mpl*N-e%O%P.Pul( R$Se'Sf[zVaVi'5BleCeL^Ming}N Ra&Rm*RAu%EchaOrO%U*UjoU^2B@CaGa%G.L$Lle#N&Rm(+Rtun(z SaTo2AcaA'AsaAtisAveIe%Il=IpeIsI#OG Gu!aJaMb_Ng}^Nr((mig('St?Yo5E>ElgaEr%ENgl-$Nt Pit!R S#V,?Zg :7Lo5A]:B$C$C[DoD+nG #GrimaGu`I>M!Mi`Mp --ch-gos%NzaPizRgoRvaStimaTaTexT*U_lV Zo3AlCc~|eC#rErG~Gumb_Ja'Ngu-#NaOnOp &S~TalT[VeY,{3B!%dB+C^D!Di EnzoGaG!oMaMi)M.Mp$NceN&Ne-go)N}t!`Qui&SoS%T!aT$T+2AgaAmaAn#AveEg En Ev Or Ov!Uv@2BoC~CoCu[GicaG+MbrizM}jaTe5|aC*G J}-esPaSt+ToZ:Ce%|oD!aD_Du+Est+F@G@GoIzL{dLe%Ll/oMaMboMutN>N&Nej Ng-iquiNj N}Re(f?Rg,Ri&RmolR+nR)sRzoSaSc aSivoT T!@TizTrizXimoY^Z^ca3|aDal]D$Du]J?]J^L,/.M^i-^NsajeN)NuRca&R,gueRi#SS.TaT!To&T+Zc]3E&ElEmb+G/Lag+Lit Ll.M}-!}im}u#OpeR SaS!@S?SmoTadTo5|?aC~DaDe=HoJ LdeL!Li'M,#Mi- c-ed-j-#NoRad(d!Re'R*R+Rs(%lScaStr TivoV!V?Zo5|oD EbleE]Er)Est[G_J!L/e%L%N&Nec(alRoScu=SeoSgoSicaS=:C C~D IpeRanj(izRr SalTalTivoTu[lUseaValVeVi{d3C$Ct G Goc$G+OnRv$ToUt+V V!a3|oDoEb]E#NezNoTi&Vel5Bleza|eMin(i(m()TaTic@Va#Ve]V$5BeCaCleoD?=DoE[EveEzLoM!oTr@:Sis0EC~E[In On!T TicaUes#1Ac~A&rAlBi%CaD,EjaGa'G@Gul=I,)Ig,Il]OQues%Uga0Ad@Cu+Ez'OT[0O'Ro1EjaU=1I&Ige'0En)0O':C#D_El]Gi`GoIsJ oLabr/>Le%Li&Lm/om/p NNalNi>Nt!-ue=PaPelP?]Que)R Rcel(edR*RoRpa&RqueR[foR)S SeoS~SoS%TaT$Tr@UsaU%VoYa<3A#nCa&C!a|oDalD*G IneL L{'Le/ig+LlejoLoLuc--s N.OnOrPi'Que'R(ch(d!Rez(f?Ri>Rl(mizEgun%Em$EnsaE|!oD^Eb=Er%Es#Lg/*Lm.LpoLrNd*N%P #Pet*PoN{PaP!oSaScaSt+T 5BiB^DoE{G*I&In/e%LoMboM^Ptu[TaTi`:Ba&B!B$BleC GazG[&L/&L!oL*Lm.L.Ls/#LudLv Mb-c~Ndi-e Ng_Ni{dN}#PoQueRdin()nSt_TanU`Xof.3Cc~CoC_#C%DGu*IsL=LvaMa`M?l-d-Re'Rg*S#T?:Ba>BiqueB]BuCoC#JoL L>L,#Ll/.Ma'Mb^Ng}quePaPe)P@P.Qu?l(deRe(if(je%RotR+R%TuajeU+ZaZ.3At+|oC]CnicaJa&J!Ji&L/efo'MaM^Mp=NazNd!N!NisNRmi'Rnur(+rSisSo+StigoT!aX#Z3B$Bu+nEmpoEn{Er[EPoR(.TanT!eTu=Za5Al]B?=C Ci'DoG/&M N}#P PeQueRaxR!oRm,%RneoRoRpe&R_RS!Xi>2AbajoAc#rA!Afi>AgoAjeAmoAnceA#AumaAz EbolEguaEin%EnEp EsIbuIgoIpaIs)IunfoOfeoOmpaOn>OpaO)OzoU>Ue'Ufa2B!@BoEr#MbaM^NelNic(bin(ismoR'T^:0Ic 9C!a0B[l0I{dIrIv!{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangFr=void 0;const n=r(99766);let i=null;class o extends n.WordlistOwlA{constructor(){super("fr","0erreleontiteurinueiriet cegeanseali medenel q)eniluxaus ch0Ais}And$Diqu E`#Ol*Ord Ou%rOy RasifReuv Ri,Rog RuptS_-SoluS'@UsifYss=0A@m+AjouAr+nCab]Cep,Clam Cola@Cro~eCu}ErbeHatHe,Idu]I Omp&Qu *R$y?Te'TifT)l0Ep&EquatHesifJec%fJug Mett!M* Op,Or Ouc*ResMab#S/-0Ou,Us,1Arm Chim+Er&Geb!G)I_ I?ntLeg Lia.Lou Lum O'd*PagaTesS' TicotT!Tu-0El>O?RiumRo-Ta^T_%fT* Trap 0Ba(eB .Da-Dib#G' Ro!Tom[Tru~e0A]Anc Ari-En*EreNqu>Rb>R`R$R^Rra.Ss(S%$Ta`#Te|T,+Udr>Vard 3Let&L>Lo&Nefi-R-|Rg Rl(eRmudaSa-Sog[Ta`Ur!3B $Cyc#Du#JouL/L(g)LlardNai!Olog+Ops+OtypeScuitS$Sto'iTu?Zar!2AfardAg)An~*Ess/tInd OndOqu Ous$2BardB(eI!I}Li@Nb$Nd*Nhe'Nif>NusRdu!R[T&Uc#Ue{Ug+Ul$Uqu(UrAveEbisE~eEuva.Ico]Iga@Ill/tIo~eI^O~u!Od Onz OusS^Ssu!U}U%$V=>V [Viar3D`#Intu!Les&Llu#Ndr>Ns' Ntr=Rc#Rebr=RiEr~ Ev=I_Iff!Ign$Im eIotLoru!OcolatOis*OI_tIgn ImatIva.O~eOna.Opor&2B=tBraCasFf!Gn Hesi$Iff Inc L eLibriLl(eLma,L$elMbatMed+Mm/@MpactNc tNdui!Nf>N.]Nno,Ns$[NtactNvexePa(P+Ra`Rbe|Rda.Rni~eRpusR!ctR&.Smi^Stu?T$U@Upu!Ura.U&|Uvr*Yo&2AbeA(&Ava&Ay$Eatu!Edi,E?{Eu}Evet&Ib]I Ist=I,eOi!Oqu Ota#Uci=UelYp,2Bi^E`l*Il]eIs(eIv!Lm( L%v Mu]Pi@Ra%fR<'3Anu!C#L(d!Ni^:Ign M>Ng N<'Uph(3Batt!Bi,Bord Brid But/tC= Cemb!Ch* Cid Clar Cor Cri!Cup]Da#Duc%fEsTa~ Tes,To' T!sTa%$U/>Ub#U-'U,Y_2Ag$Ap Es}Ibb]Oitu!2P +P#xeRab#Rc*3Nas%e:0Lou*0Ar,HarpeHel#La* LipUqu 1Fac Fec%fFig+FortFray Fusi$0Ali}Ar 2Ec,1Abor Arg*Ectr$Eg/tEph/tEveIgib#I%s?O.Ucid Ud 0B=]Bell*Bry$Er|@Issi$M_ O%$Ouvo*P e'Ploy Por,PriTo' Trav Um Vah*Viab#Voy Zy?0L+n0Aiss*Arg[At/tAu#Ic +I@m+I Ilog)I[Iso@ItapheO^ReuveRouv Uis/t0U !Uipe0Ig Osi$Re'Up%$0C=>Pad$Pe-P+g#Po*PritQuiv Say S_-S+uSor Ti?TomacTra@0Ag eA]An~eA%^E(d!Endo*Er[lH/olHi^Hn+Ir Off Oi#Onn/tO'd*R/.RoitU@0Phor+0Alu Asi$Enta`I@n-I,Olu%fOqu 1ActAg Auc Cel]Cit/tClusifCuPlor Po}Prim QuisT_sifTrai!Ul,:B#Bu#{Cet&Ci#Ctu!Ibl*Lai3AscoCe]C%fDe#Gu!Latu!Leta.L>eL#ulLm LouLtr N/c N*O#R?Ssu!X 2A* Am?As^At&'E|E~eE'Exi$Oc$O!Uctu Ui@Uvi=2L+Nd +Ngib#Nta(eRc Rg $Rmu]Rtu[Ssi#Ud!Ug eU`]Ulu!Urmi2Agi#AiC]RafeV!2A-AiveIs}ObeOi!Or+{2Lfe'M?Nf]R.R`#Udr$Uff!UlotUp`#Urm/dUt&2Ad)lAffi%A(eAndApp(AtuitAv*EnatIffu!Il]Imp Ogn Ond Ot&OupeUg U% Uy e2EpardErr>I@Im|veIta!Sta%f3Mnas&Rostat:Bitu@Cho*L&Me|NgarN[t$RicotRm$+Rp$Sard3LiumMato?RbeRiss$Rm(eR$Si,U!{3B n BouLar/tStoi!V 5MardMma.Mo.[N['Nor N&{R@Riz$Rlo.Rm$eRrib#U#{Us<5BlotI#{Ma(Mb#Mi@Mo'R]3Dro?lG+[M[Pno<:2Yl#2Nor U/e4Lici&Lusi$0A.Bib I,M_ReelRi,0O]2Oi!Res<:GuarIll*MbeNv>Rd(Ug U[Velot3Tab#T$UdiU[s<9Ind!N~ Ng]Ue'UissifUrn=Vi=Y|Ye{5Bi]Ge?ntNiorP$Ris&S%-Te{V_i#:Yak7M$oOs^:BelBi=Bo' C CtoVaboVo*3Ctu!G=G Gu?SsiveTt!V>Xi^Zard3AseS,ThiumTi.Ttor=V!'5Gi^Inta(Is*MbricT +U UrdUt!UveY=5B+Ci@Cra%fE'Gub!Is/tM>eNai!NdiR$T,X){:Ch(eGas(G_taGi^Ig!Ill$In%_Ir+Is$Jor Lax Lefi-Lhe'Li-L#t&MmouthNda,Niab#Nqu/tN&|N)lRath$Rb!R~/dRdiRi%?R^'Rr$R&]Scot&SsifT +lT>eTra^Udi!Ussa@UveXim=3Ch/tC$nuDa`#Dec(Di,DuUb#3Au]CrobeEt&Gn$Gr L+uLli$Mi^N-N =Nim=Nor Nu&Rac#Roi,Ssi#X&5Bi#D [El#{Ndi=Ni&'Nna+Not$eNst!Ntag[Nu?ntQ)'R-|Rsu!R% Te'TifU~eUf#Ul(Uss$Ut$Uv/t5L%p#Ni%$Ra`#Re[Rmu!Sc#SeumSic+nTa%$T T)l3Ria@R%l#S,eThi^:Ge'PpeRquoisRr Ta%$Ti$Tu!Ufra.U%^Vi!3Bu#{CtarFas&Ga%$Glig Goc>I.Rve{Ttoy Ur$eUtr$Veu3CheCkelTra&Ve|5B#CifCt'[Ir-'IToi!Urr*Uve|Va&'Vemb!Vi-5A.Anc I!Isib#M oP%=Q)Tri%f:0E*Jec%fLig Sc'S v Stac#T_*T' 0Casi$Cup E/Tob!Troy Tup]Ulai!0E'Or/t1F_}Fic>Fr*0Ive1Se|S`l$2Fac%fIv>0Bra.Ett!0Ct){Du]E!{Iri^1A#A^Er Ini$PortunPrim T Ti^1A.{An.Bi&D$n E`#G/eG)`Ifi-Ne?ntQ)T+0C`]MoPo,PyrusRadoxeR-l#ResIss$Iv!Lai!Lic>L#nLyg$eMma@Mp>Nct)lNd NeyR%^Si%$SZz#3Rami@:99AsarE!l#Es%$Ietu@It,O%_t:C(eC$,D+{G$d(I@'Is(L_%rLl$.Mas}Pi@Sa.Tis}Vag V(Y$n 3Ac%fAg*Ali}Anim Cevo*Ci,Clam Col,Cru,Cu]Cyc]Dig Dou,Fai!F#xeForm Fra(Fu.G=+nGi$Gla.Gul>I, Je,Jou La%fLev L+fMar^Me@MiPor,Prie5Che{M/-Mp!N-Nd(Se|S>Ta%fTorTu#U.U`#U#|U%[Y|?5B/BisCheEl#G){In Is<|S S%^3Th?:B]Bo,B!Co~eFariGesRcas?Rd(eT' Ug!nuUm$U,Uva.V/tV$n 1AlpelAnda#E]atEnarioEpt!HemaI_-Ind O!Ru%nUlp,1An-Cab#Ch Cou C!,Da%fDui!Ig['Jo'Lec%fMa(eMb]M_-M(=Na&'Nsib#N&n-Par Q)n-Re(R.ntR+{Rru!RumRvi-Sa?V*Vra.Xtup#3D =Ec#Eg Ff]G#Gn=L_-LiciumMp#Nc eNist!Ph$RopSmi^Tu 1I 3Ci=C#DiumIg[{LdatLe`Litu@Lub#Mb!M?`Mno]N@N.'N[t&No!Rc>R%rS+T%Rfa-Rica&R?n RpriC%#Il]L_tLism/L$n Mbo'Mi}Ngib#PisQu( Rd RifR%[SI$I^Itai!Iv s3AniumBa(Tic/t0A.I[UelU!0I#Op+:Car?Cc(Gab$dG)Ill/tInc!Is<|Lab#LiSe{Ss=S&3C&'Det&Get=Hicu#InardLo-Nd!diN Ng Ni?{Ntou{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangIt=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("it","0torea noica!iosorolotaleratelanena%oiadoencotivomai t ca%a0A]Bagl'Bin#E.Is(Oli!Rasi_Rog#0Cade!C[$Cus#E Roba+U 0Ag'Deb{DomeEgu#Eri!IpeOtt&Ul&1Fabi,Fe|Fis(F-n Oris`O(R~$0AveEn.E_,Ganc'I!It&OnismoR>*Rume Uzzo4AbardaA Bat)Ber#BoBumeCeCol>E|Ertu-OdePari!Pe^ Pogg'P)@Pun Ri,1Ab~AchideAgos+Ald~Anc'Atu-AzzoBit)Chiv'D{Eni,G[ GiSoTef%eZil*0Ciu|Col EpsiEtt>Fal I$O/Pir#P)Sagg'SeSolu Sur@TaT[u T%eT-|0Av>EismoOm>O$TesaTiv&Tor$Tr{Tua,0Sil'Str?Tis+To$moTun$0Anz#E!V[i!Vi(Volge!3IoS(Tos+Ttu U,VaVosa3C]FfaLg'LvaNdaNe_,Nig$Nzi=ReRli=Ta3Bi+CiDoR@S]Tan>T^$Zzo*2Acc'AdipoA`An}Avu-E.l/Eve|EzzaIgl?Il/n.Ind&Oc]*O@Onzi=Ul*U$2BboT+di$UffoVet+Vi,2Ass>In~O)2C]Dar@D%eE!n.G$meLl&Lm#Lo!Lpo(L^v#LzaMaMe+M`n@Mo@Mpu.rMuS+n.Ttu-V#2A.!Avat+E#Ede!Emo(Esci+E+Ice I=,IsiIt>OceO=}Os++Uc?,Us}2Ci!Cu*Gi$Ll#Po/R#!R(!R_Sci$S de:DoI$L`+Meri$Nie/N$(Nz&T#Van^Vve)3Bu|C[n'Ci(Cli$Col*C! D%#Fin{FormeG$Leg&Lfi$Lir'L+M[zaNot#Nt)Pos{Rapa+Riv&RogaScri|Ser Sider'Sume!Tersi_Vo 3Amet)Cemb!Ed)Fe(Ffu(Geri!Gi+,Luv'Nam>N=nziPin P*`Po*Rad&ReRo|RupoSag'Sc! Sf&Sge*Spos S+nzaSu`$ToVa$Vel Vide!Vor#5B*I}MoSaU(0An#B,`Es(I)O^_Oz'U*0Dem>Du)Erg?FasiO.}Tr&Zi`1A^.I*goI(d'O},Pu!0U#!0Ar'BaBo(EdeEmi+Ige!Met>OeOsi_Ran.0Ago$AmeAnimeAudi!CaEmp'Erc{Ib{Ig[.Is.!I OfagoOrt#O(Pan(P!s(S[zaSoTe(Tim&Ton?T)(Ult&0Il>N>Rus]To0ClideoRopa0A(Id[zaIt#Olu Viva:Bbr~Cc[daChi)L]Migl?Na,Nfa-NgoN+s`ReRfal/Ri$(R`]Sc?S (Sul*T%&ToVo*(3Bb!Co/DeG#LpaLt)Mmi=Nde!Nome$Rm[ R)R^,Ssu-S^_T+U@3AbaDuc?FaGur#LoNanzaNest-Ni!O!S},S>Ume2A]Cacc?Co(Der#Gl'La+Lc*!Lgo!Nd[.Net>N?N+=Rb{Rchet+Res+Rm~R='RoR.zzaRz&Sf#S(2A}s(A=Assi$A.l*Eccet+E=+Es]IgoOlli$OndeUga,Ut+2Ci/+Cs?Gg[.LmiT Ud'ZeboZzel/3CoLa^=L(Mel*Mm#NeN{!N='No^poRgo2Epar@Iacc'Isa0Al*LdaNep)Oc&Oiel*Or$OveR#RoAmmoAndeAtt&A_(Az?E}EggeIfoIll'O*RaR>Roge$2IeLude!0Bal*Bevu Boc]Bu MaO.siP~1IdeLandaOn>Rig#Ror&0Ol#O poTer>Titu Tr%e0Al?Er&:::Bb)Birin C}Cer#Cri`Cu=D@veGoMpoNcet+N.r=R@(RgaRingeSt-T[zaTi$TtugaVag=Vo)3Ga,Gge)MboN.zzaNzaOGl?G<.G)Iol~LafedeLg-@Lin.(Lsa$L Lumo!NaNc?N@r/Ngi&Nifes N=)Nov-NsardaN^deNubr'PpaR#=Rci!Ret+RmoRsup'Sche-Ssa?S^$Te-s(Tr>/T Ce=.DesimoDit&GaLassaLisLod?NingeNoN(/Rcur'R[daR*Schi$SeSse!S *Tal*To@T.!3Agol&CaCel'Che,C)boDol*E,Gl'!La$Li.MosaNe-,NiNo!Ri$R^l*Sce/SsivaS Sur&TezzaTig&T-T.n.4Emon>0Del*Dif~Du*Ga$G'LeLos(Nas.)N]Ndi=Ne+r'Ni,No $N(3Cch?NfaTi@5Bi,Ci_DoMeMi=Rd>R`,RvegeseSt-$T&Tiz?Ttur$Vel/5C,oL/Me)O_Tri!Vo/Z?,:Si0Bedi!BligoElis]L'O*So, 0Cas'B-EgaIss'<0Do(E!IceNi_)O!_,Ta1Er#In'IgiDel/D)Ri.RolisiTo2AceboAn&As`A+$E=r'2ChezzaDe)(DismoEs?Ggi&L[+Ligo$Ll%eLmoni.Lpet+L(Lt)=Lve!M%eMo@)N.Po*(Rfi@Ro(Rpo-R!R++SaSi^_Sses(Stul#Tass'Te!2AnzoAssiAt~Eclu(Ed~Efis(Egi#Elie_Eme!E$t&Epar#Es[zaE.s Eval(I`IncipeIv#Ob,`Ocu-Odur!OfumoOge|OlungaOmessaO$meOpos+O)gaO.(OvaUd[.Ug=Ur{0Iche1Bbl>D~Gil#G$LceL{Lsan.Nt&PazzoPil/Ro:99Ad)Al]saAsiE!/O+:C]l D@pp'D~,Dun#Ff~GazzoG'*Dur!Fas&F,s(For`Fug'G&Gett#Ghel*Lass#Lev#MaT)_Un'Bus Cc?CoDagg'De!D{!G{Ll'Mant>Mpe!Nz'Sol&SpoTan.Ton@Tu/Vesc'5BizzoBr~GaLli$Mi:B#Bbi&Bot#Go`Las(Ldatu-Lgem`Liv&LmoEtt)HedaHie=IarpaI[zaInde!IppoI)ppoI_*Ler&Odel/Olp{Ompar Onfor Opri!Or+Os(Mul#Nfon?Ngo*Nist)NoN.siNu(idePar'S`S ,Tu#2It+Ogatu-Ove$0Arr{Emor#En^ E-l@IlzoOnt&Ott#Uss#0Elli!Erv#O@0BbalzoBr'C]r(C?,Da,Ffi|G$Ld#L[M`NdaNe|Nnife)Pi!Ppe(P-Rge!Rpas(Rri(R(R.gg'R_l#Spi)S+T^,0AdaAl/Arge!A /Av[ Azzo/EcieEdi!EgRappoReg#Ridu*Rozz&Ru|Ucc&UfoUp[@0B[t)C](Do!Gger{GoL+$On&PerboPpor Rgel#R)g#Ssur)Tu-0Ag&EdeseEgl'El&Enu Ez?IluppoIs+Izze-Ol+Uot&:Bac]Bul#Cci&Citur$LeLis`$MpoVer=Vo/+Zza3CaCn>Lefo$Me-r'MpoMu N@Pog-foRagg'RoTan'To*Tuban.Z'Zzo<5Cc&L,r&L Mbo/MoNfoNsil/Paz'Po*g?PpaRbaRn&R)L,t+Lo)(Lut&L_/Mpa+Ng&N{(NoN+gg'Nve-Po!Ra$Rc#R?n.S}3Det+DovaDu Ge+,I]*Lc)Li=Llu LoceN#Ndemm?N RaceRba,Rgog=Rif~RoRru}Rt~,Sc~Ssil*S+,Te-$Tri=Tus 3Andan.B-n.C[daChingoCi=nzaDim&Gil?G< Go!LeL/$MiniNc{!O/Pe-Rgo/Ro*goRu,n S](S'5Cche)Fo*LuPpa","0x5c1362d88fd4cf614a96f3234941d29f7d37c08c5292fde03bf62c2db6ff7620")}static wordlist(){return null==i&&(i=new o),i}}t.LangIt=o},19642:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangJa=void 0;const n=r(98336),i=r(42120),o=r(51208),a=["AQRASRAGBAGUAIRAHBAghAURAdBAdcAnoAMEAFBAFCBKFBQRBSFBCXBCDBCHBGFBEQBpBBpQBIkBHNBeOBgFBVCBhBBhNBmOBmRBiHBiFBUFBZDBvFBsXBkFBlcBjYBwDBMBBTBBTRBWBBWXXaQXaRXQWXSRXCFXYBXpHXOQXHRXhRXuRXmXXbRXlXXwDXTRXrCXWQXWGaBWaKcaYgasFadQalmaMBacAKaRKKBKKXKKjKQRKDRKCYKCRKIDKeVKHcKlXKjHKrYNAHNBWNaRNKcNIBNIONmXNsXNdXNnBNMBNRBNrXNWDNWMNFOQABQAHQBrQXBQXFQaRQKXQKDQKOQKFQNBQNDQQgQCXQCDQGBQGDQGdQYXQpBQpQQpHQLXQHuQgBQhBQhCQuFQmXQiDQUFQZDQsFQdRQkHQbRQlOQlmQPDQjDQwXQMBQMDQcFQTBQTHQrDDXQDNFDGBDGQDGRDpFDhFDmXDZXDbRDMYDRdDTRDrXSAhSBCSBrSGQSEQSHBSVRShYShkSyQSuFSiBSdcSoESocSlmSMBSFBSFKSFNSFdSFcCByCaRCKcCSBCSRCCrCGbCEHCYXCpBCpQCIBCIHCeNCgBCgFCVECVcCmkCmwCZXCZFCdRClOClmClFCjDCjdCnXCwBCwXCcRCFQCFjGXhGNhGDEGDMGCDGCHGIFGgBGVXGVEGVRGmXGsXGdYGoSGbRGnXGwXGwDGWRGFNGFLGFOGFdGFkEABEBDEBFEXOEaBEKSENBENDEYXEIgEIkEgBEgQEgHEhFEudEuFEiBEiHEiFEZDEvBEsXEsFEdXEdREkFEbBEbRElFEPCEfkEFNYAEYAhYBNYQdYDXYSRYCEYYoYgQYgRYuRYmCYZTYdBYbEYlXYjQYRbYWRpKXpQopQnpSFpCXpIBpISphNpdBpdRpbRpcZpFBpFNpFDpFopFrLADLBuLXQLXcLaFLCXLEhLpBLpFLHXLeVLhILdHLdRLoDLbRLrXIABIBQIBCIBsIBoIBMIBRIXaIaRIKYIKRINBINuICDIGBIIDIIkIgRIxFIyQIiHIdRIbYIbRIlHIwRIMYIcRIRVITRIFBIFNIFQOABOAFOBQOaFONBONMOQFOSFOCDOGBOEQOpBOLXOIBOIFOgQOgFOyQOycOmXOsXOdIOkHOMEOMkOWWHBNHXNHXWHNXHDuHDRHSuHSRHHoHhkHmRHdRHkQHlcHlRHwBHWcgAEgAggAkgBNgBQgBEgXOgYcgLXgHjgyQgiBgsFgdagMYgWSgFQgFEVBTVXEVKBVKNVKDVKYVKRVNBVNYVDBVDxVSBVSRVCjVGNVLXVIFVhBVhcVsXVdRVbRVlRhBYhKYhDYhGShxWhmNhdahdkhbRhjohMXhTRxAXxXSxKBxNBxEQxeNxeQxhXxsFxdbxlHxjcxFBxFNxFQxFOxFoyNYyYoybcyMYuBQuBRuBruDMuCouHBudQukkuoBulVuMXuFEmCYmCRmpRmeDmiMmjdmTFmFQiADiBOiaRiKRiNBiNRiSFiGkiGFiERipRiLFiIFihYibHijBijEiMXiWBiFBiFCUBQUXFUaRUNDUNcUNRUNFUDBUSHUCDUGBUGFUEqULNULoUIRUeEUeYUgBUhFUuRUiFUsXUdFUkHUbBUjSUjYUwXUMDUcHURdUTBUrBUrXUrQZAFZXZZaRZKFZNBZQFZCXZGBZYdZpBZLDZIFZHXZHNZeQZVRZVFZmXZiBZvFZdFZkFZbHZbFZwXZcCZcRZRBvBQvBGvBLvBWvCovMYsAFsBDsaRsKFsNFsDrsSHsSFsCXsCRsEBsEHsEfspBsLBsLDsIgsIRseGsbRsFBsFQsFSdNBdSRdCVdGHdYDdHcdVbdySduDdsXdlRdwXdWYdWcdWRkBMkXOkaRkNIkNFkSFkCFkYBkpRkeNkgBkhVkmXksFklVkMBkWDkFNoBNoaQoaFoNBoNXoNaoNEoSRoEroYXoYCoYbopRopFomXojkowXorFbBEbEIbdBbjYlaRlDElMXlFDjKjjSRjGBjYBjYkjpRjLXjIBjOFjeVjbRjwBnXQnSHnpFnLXnINnMBnTRwXBwXNwXYwNFwQFwSBwGFwLXwLDweNwgBwuHwjDwnXMBXMpFMIBMeNMTHcaQcNBcDHcSFcCXcpBcLXcLDcgFcuFcnXcwXccDcTQcrFTQErXNrCHrpFrgFrbFrTHrFcWNYWNbWEHWMXWTR","ABGHABIJAEAVAYJQALZJAIaRAHNXAHdcAHbRAZJMAZJRAZTRAdVJAklmAbcNAjdRAMnRAMWYAWpRAWgRAFgBAFhBAFdcBNJBBNJDBQKBBQhcBQlmBDEJBYJkBYJTBpNBBpJFBIJBBIJDBIcABOKXBOEJBOVJBOiJBOZJBepBBeLXBeIFBegBBgGJBVJXBuocBiJRBUJQBlXVBlITBwNFBMYVBcqXBTlmBWNFBWiJBWnRBFGHBFwXXKGJXNJBXNZJXDTTXSHSXSVRXSlHXCJDXGQJXEhXXYQJXYbRXOfXXeNcXVJFXhQJXhEJXdTRXjdXXMhBXcQTXRGBXTEBXTnQXFCXXFOFXFgFaBaFaBNJaBCJaBpBaBwXaNJKaNJDaQIBaDpRaEPDaHMFamDJalEJaMZJaFaFaFNBaFQJaFLDaFVHKBCYKBEBKBHDKXaFKXGdKXEJKXpHKXIBKXZDKXwXKKwLKNacKNYJKNJoKNWcKDGdKDTRKChXKGaRKGhBKGbRKEBTKEaRKEPTKLMDKLWRKOHDKVJcKdBcKlIBKlOPKFSBKFEPKFpFNBNJNJBQNBGHNBEPNBHXNBgFNBVXNBZDNBsXNBwXNNaRNNJDNNJENNJkNDCJNDVDNGJRNJiDNZJNNsCJNJFNNFSBNFCXNFEPNFLXNFIFQJBFQCaRQJEQQLJDQLJFQIaRQOqXQHaFQHHQQVJXQVJDQhNJQmEIQZJFQsJXQJrFQWbRDJABDBYJDXNFDXCXDXLXDXZDDXsJDQqXDSJFDJCXDEPkDEqXDYmQDpSJDOCkDOGQDHEIDVJDDuDuDWEBDJFgSBNDSBSFSBGHSBIBSBTQSKVYSJQNSJQiSJCXSEqXSJYVSIiJSOMYSHAHSHaQSeCFSepQSegBSHdHSHrFShSJSJuHSJUFSkNRSrSrSWEBSFaHSJFQSFCXSFGDSFYXSFODSFgBSFVXSFhBSFxFSFkFSFbBSFMFCADdCJXBCXaFCXKFCXNFCXCXCXGBCXEJCXYBCXLDCXIBCXOPCXHXCXgBCXhBCXiBCXlDCXcHCJNBCJNFCDCJCDGBCDVXCDhBCDiDCDJdCCmNCpJFCIaRCOqXCHCHCHZJCViJCuCuCmddCJiFCdNBCdHhClEJCnUJCreSCWlgCWTRCFBFCFNBCFYBCFVFCFhFCFdSCFTBCFWDGBNBGBQFGJBCGBEqGBpBGBgQGNBEGNJYGNkOGNJRGDUFGJpQGHaBGJeNGJeEGVBlGVKjGiJDGvJHGsVJGkEBGMIJGWjNGFBFGFCXGFGBGFYXGFpBGFMFEASJEAWpEJNFECJVEIXSEIQJEOqXEOcFEeNcEHEJEHlFEJgFEhlmEmDJEmZJEiMBEUqXEoSREPBFEPXFEPKFEPSFEPEFEPpFEPLXEPIBEJPdEPcFEPTBEJnXEqlHEMpREFCXEFODEFcFYASJYJAFYBaBYBVXYXpFYDhBYCJBYJGFYYbRYeNcYJeVYiIJYZJcYvJgYvJRYJsXYsJFYMYMYreVpBNHpBEJpBwXpQxFpYEJpeNDpJeDpeSFpeCHpHUJpHbBpHcHpmUJpiiJpUJrpsJuplITpFaBpFQqpFGBpFEfpFYBpFpBpFLJpFIDpFgBpFVXpFyQpFuFpFlFpFjDpFnXpFwXpJFMpFTBLXCJLXEFLXhFLXUJLXbFLalmLNJBLSJQLCLCLGJBLLDJLHaFLeNFLeSHLeCXLepFLhaRLZsJLsJDLsJrLocaLlLlLMdbLFNBLFSBLFEHLFkFIBBFIBXFIBaQIBKXIBSFIBpHIBLXIBgBIBhBIBuHIBmXIBiFIBZXIBvFIBbFIBjQIBwXIBWFIKTRIQUJIDGFICjQIYSRIINXIJeCIVaRImEkIZJFIvJRIsJXIdCJIJoRIbBQIjYBIcqXITFVIreVIFKFIFSFIFCJIFGFIFLDIFIBIJFOIFgBIFVXIJFhIFxFIFmXIFdHIFbBIJFrIJFWOBGBOQfXOOKjOUqXOfXBOqXEOcqXORVJOFIBOFlDHBIOHXiFHNTRHCJXHIaRHHJDHHEJHVbRHZJYHbIBHRsJHRkDHWlmgBKFgBSBgBCDgBGHgBpBgBIBgBVJgBuBgBvFgKDTgQVXgDUJgGSJgOqXgmUMgZIJgTUJgWIEgFBFgFNBgFDJgFSFgFGBgFYXgJFOgFgQgFVXgFhBgFbHgJFWVJABVQKcVDgFVOfXVeDFVhaRVmGdViJYVMaRVFNHhBNDhBCXhBEqhBpFhBLXhNJBhSJRheVXhhKEhxlmhZIJhdBQhkIJhbMNhMUJhMZJxNJgxQUJxDEkxDdFxSJRxplmxeSBxeCXxeGFxeYXxepQxegBxWVcxFEQxFLXxFIBxFgBxFxDxFZtxFdcxFbBxFwXyDJXyDlcuASJuDJpuDIBuCpJuGSJuIJFueEFuZIJusJXudWEuoIBuWGJuFBcuFKEuFNFuFQFuFDJuFGJuFVJuFUtuFdHuFTBmBYJmNJYmQhkmLJDmLJomIdXmiJYmvJRmsJRmklmmMBymMuCmclmmcnQiJABiJBNiJBDiBSFiBCJiBEFiBYBiBpFiBLXiBTHiJNciDEfiCZJiECJiJEqiOkHiHKFieNDiHJQieQcieDHieSFieCXieGFieEFieIHiegFihUJixNoioNXiFaBiFKFiFNDiFEPiFYXitFOitFHiFgBiFVEiFmXiFitiFbBiFMFiFrFUCXQUIoQUIJcUHQJUeCEUHwXUUJDUUqXUdWcUcqXUrnQUFNDUFSHUFCFUFEfUFLXUtFOZBXOZXSBZXpFZXVXZEQJZEJkZpDJZOqXZeNHZeCDZUqXZFBQZFEHZFLXvBAFvBKFvBCXvBEPvBpHvBIDvBgFvBuHvQNJvFNFvFGBvFIBvJFcsXCDsXLXsXsXsXlFsXcHsQqXsJQFsEqXseIFsFEHsFjDdBxOdNpRdNJRdEJbdpJRdhZJdnSJdrjNdFNJdFQHdFhNkNJDkYaRkHNRkHSRkVbRkuMRkjSJkcqDoSJFoEiJoYZJoOfXohEBoMGQocqXbBAFbBXFbBaFbBNDbBGBbBLXbBTBbBWDbGJYbIJHbFQqbFpQlDgQlOrFlVJRjGEBjZJRnXvJnXbBnEfHnOPDngJRnxfXnUJWwXEJwNpJwDpBwEfXwrEBMDCJMDGHMDIJMLJDcQGDcQpHcqXccqNFcqCXcFCJRBSBRBGBRBEJRBpQTBNFTBQJTBpBTBVXTFABTFSBTFCFTFGBTFMDrXCJrXLDrDNJrEfHrFQJrFitWNjdWNTR","AKLJMANOPFASNJIAEJWXAYJNRAIIbRAIcdaAeEfDAgidRAdjNYAMYEJAMIbRAFNJBAFpJFBBIJYBDZJFBSiJhBGdEBBEJfXBEJqXBEJWRBpaUJBLXrXBIYJMBOcfXBeEfFBestXBjNJRBcDJOBFEqXXNvJRXDMBhXCJNYXOAWpXONJWXHDEBXeIaRXhYJDXZJSJXMDJOXcASJXFVJXaBQqXaBZJFasXdQaFSJQaFEfXaFpJHaFOqXKBNSRKXvJBKQJhXKEJQJKEJGFKINJBKIJjNKgJNSKVElmKVhEBKiJGFKlBgJKjnUJKwsJYKMFIJKFNJDKFIJFKFOfXNJBSFNJBCXNBpJFNJBvQNJBMBNJLJXNJOqXNJeCXNJeGFNdsJCNbTKFNwXUJQNFEPQDiJcQDMSJQSFpBQGMQJQJeOcQyCJEQUJEBQJFBrQFEJqDXDJFDJXpBDJXIMDGiJhDIJGRDJeYcDHrDJDVXgFDkAWpDkIgRDjDEqDMvJRDJFNFDJFIBSKclmSJQOFSJQVHSJQjDSJGJBSJGJFSECJoSHEJqSJHTBSJVJDSViJYSZJNBSJsJDSFSJFSFEfXSJFLXCBUJVCJXSBCJXpBCXVJXCJXsXCJXdFCJNJHCLIJgCHiJFCVNJMChCJhCUHEJCsJTRCJdYcCoQJCCFEfXCFIJgCFUJxCFstFGJBaQGJBIDGQJqXGYJNRGJHKFGeQqDGHEJFGJeLXGHIiJGHdBlGUJEBGkIJTGFQPDGJFEqEAGegEJIJBEJVJXEhQJTEiJNcEJZJFEJoEqEjDEqEPDsXEPGJBEPOqXEPeQFEfDiDEJfEFEfepQEfMiJEqXNBEqDIDEqeSFEqVJXEMvJRYXNJDYXEJHYKVJcYYJEBYJeEcYJUqXYFpJFYFstXpAZJMpBSJFpNBNFpeQPDpHLJDpHIJFpHgJFpeitFpHZJFpJFADpFSJFpJFCJpFOqXpFitBpJFZJLXIJFLIJgRLVNJWLVHJMLwNpJLFGJBLFLJDLFOqXLJFUJIBDJXIBGJBIJBYQIJBIBIBOqXIBcqDIEGJFILNJTIIJEBIOiJhIJeNBIJeIBIhiJIIWoTRIJFAHIJFpBIJFuHIFUtFIJFTHOSBYJOEcqXOHEJqOvBpFOkVJrObBVJOncqDOcNJkHhNJRHuHJuHdMhBgBUqXgBsJXgONJBgHNJDgHHJQgJeitgHsJXgJyNagyDJBgZJDrgsVJQgkEJNgkjSJgJFAHgFCJDgFZtMVJXNFVXQfXVJXDJVXoQJVQVJQVDEfXVDvJHVEqNFVeQfXVHpJFVHxfXVVJSRVVmaRVlIJOhCXVJhHjYkhxCJVhWVUJhWiJcxBNJIxeEqDxfXBFxcFEPxFSJFxFYJXyBDQJydaUJyFOPDuYCJYuLvJRuHLJXuZJLDuFOPDuFZJHuFcqXmKHJdmCQJcmOsVJiJAGFitLCFieOfXiestXiZJMEikNJQirXzFiFQqXiFIJFiFZJFiFvtFUHpJFUteIcUteOcUVCJkUhdHcUbEJEUJqXQUMNJhURjYkUFitFZDGJHZJIxDZJVJXZJFDJZJFpQvBNJBvBSJFvJxBrseQqDsVFVJdFLJDkEJNBkmNJYkFLJDoQJOPoGsJRoEAHBoEJfFbBQqDbBZJHbFVJXlFIJBjYIrXjeitcjjCEBjWMNBwXQfXwXOaFwDsJXwCJTRwrCZJMDNJQcDDJFcqDOPRYiJFTBsJXTQIJBTFEfXTFLJDrXEJFrEJXMrFZJFWEJdEWYTlm","ABCDEFACNJTRAMBDJdAcNJVXBLNJEBXSIdWRXErNJkXYDJMBXZJCJaXMNJaYKKVJKcKDEJqXKDcNJhKVJrNYKbgJVXKFVJSBNBYBwDNJeQfXNJeEqXNhGJWENJFiJRQlIJbEQJfXxDQqXcfXQFNDEJQFwXUJDYcnUJDJIBgQDIUJTRDJFEqDSJQSJFSJQIJFSOPeZtSJFZJHCJXQfXCTDEqFGJBSJFGJBOfXGJBcqXGJHNJDGJRLiJEJfXEqEJFEJPEFpBEJYJBZJFYBwXUJYiJMEBYJZJyTYTONJXpQMFXFpeGIDdpJFstXpJFcPDLBVSJRLHQJqXLJFZJFIJBNJDIJBUqXIBkFDJIJEJPTIYJGWRIJeQPDIJeEfHIJFsJXOqGDSFHXEJqXgJCsJCgGQJqXgdQYJEgFMFNBgJFcqDVJwXUJVJFZJchIgJCCxOEJqXxOwXUJyDJBVRuscisciJBiJBieUtqXiJFDJkiFsJXQUGEZJcUJFsJXZtXIrXZDZJDrZJFNJDZJFstXvJFQqXvJFCJEsJXQJqkhkNGBbDJdTRbYJMEBlDwXUJMEFiJFcfXNJDRcNJWMTBLJXC","BraFUtHBFSJFdbNBLJXVJQoYJNEBSJBEJfHSJHwXUJCJdAZJMGjaFVJXEJPNJBlEJfFiJFpFbFEJqIJBVJCrIBdHiJhOPFChvJVJZJNJWxGFNIFLueIBQJqUHEJfUFstOZJDrlXEASJRlXVJXSFwVJNJWD","QJEJNNJDQJEJIBSFQJEJxegBQJEJfHEPSJBmXEJFSJCDEJqXLXNJFQqXIcQsFNJFIFEJqXUJgFsJXIJBUJEJfHNFvJxEqXNJnXUJFQqD","IJBEJqXZJ"];let s=null;function u(e){return(0,i.hexlify)((0,i.toUtf8Bytes)(e))}function c(e){return(0,i.toUtf8String)(new Uint8Array(e))}function l(){if(null!==s)return s;const e=[],t={};function r(e){let r="";for(let n=0;nt?1:0})),"0xe3818de38284e3818f"===u(e[442])&&"0xe3818de38283e3818f"===u(e[443])){const t=e[442];e[442]=e[443],e[443]=t}if("0xcb36b09e6baa935787fd762ce65e80b0c6a8dabdfbc3a7f86ac0e2c4fd111600"!==(0,n.id)(e.join("\n")+"\n"))throw new Error("BIP39 Wordlist for ja (Japanese) FAILED");return s=e,e}let f=null;class h extends o.Wordlist{constructor(){super("ja")}getWord(e){const t=l();return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangKo=void 0;const n=r(98336),i=r(42120),o=r(51208),a=["OYAa","ATAZoATBl3ATCTrATCl8ATDloATGg3ATHT8ATJT8ATJl3ATLlvATLn4ATMT8ATMX8ATMboATMgoAToLbAToMTATrHgATvHnAT3AnAT3JbAT3MTAT8DbAT8JTAT8LmAT8MYAT8MbAT#LnAUHT8AUHZvAUJXrAUJX8AULnrAXJnvAXLUoAXLgvAXMn6AXRg3AXrMbAX3JTAX3QbAYLn3AZLgvAZrSUAZvAcAZ8AaAZ8AbAZ8AnAZ8HnAZ8LgAZ8MYAZ8MgAZ8OnAaAboAaDTrAaFTrAaJTrAaJboAaLVoAaMXvAaOl8AaSeoAbAUoAbAg8AbAl4AbGnrAbMT8AbMXrAbMn4AbQb8AbSV8AbvRlAb8AUAb8AnAb8HgAb8JTAb8NTAb8RbAcGboAcLnvAcMT8AcMX8AcSToAcrAaAcrFnAc8AbAc8MgAfGgrAfHboAfJnvAfLV8AfLkoAfMT8AfMnoAfQb8AfScrAfSgrAgAZ8AgFl3AgGX8AgHZvAgHgrAgJXoAgJX8AgJboAgLZoAgLn4AgOX8AgoATAgoAnAgoCUAgoJgAgoLXAgoMYAgoSeAgrDUAgrJTAhrFnAhrLjAhrQgAjAgoAjJnrAkMX8AkOnoAlCTvAlCV8AlClvAlFg4AlFl6AlFn3AloSnAlrAXAlrAfAlrFUAlrFbAlrGgAlrOXAlvKnAlvMTAl3AbAl3MnAnATrAnAcrAnCZ3AnCl8AnDg8AnFboAnFl3AnHX4AnHbrAnHgrAnIl3AnJgvAnLXoAnLX4AnLbrAnLgrAnLhrAnMXoAnMgrAnOn3AnSbrAnSeoAnvLnAn3OnCTGgvCTSlvCTvAUCTvKnCTvNTCT3CZCT3GUCT3MTCT8HnCUCZrCULf8CULnvCU3HnCU3JUCY6NUCbDb8CbFZoCbLnrCboOTCboScCbrFnCbvLnCb8AgCb8HgCb$LnCkLfoClBn3CloDUDTHT8DTLl3DTSU8DTrAaDTrLXDTrLjDTrOYDTrOgDTvFXDTvFnDT3HUDT3LfDUCT9DUDT4DUFVoDUFV8DUFkoDUGgrDUJnrDULl8DUMT8DUMXrDUMX4DUMg8DUOUoDUOgvDUOg8DUSToDUSZ8DbDXoDbDgoDbGT8DbJn3DbLg3DbLn4DbMXrDbMg8DbOToDboJXGTClvGTDT8GTFZrGTLVoGTLlvGTLl3GTMg8GTOTvGTSlrGToCUGTrDgGTrJYGTrScGTtLnGTvAnGTvQgGUCZrGUDTvGUFZoGUHXrGULnvGUMT8GUoMgGXoLnGXrMXGXrMnGXvFnGYLnvGZOnvGZvOnGZ8LaGZ8LmGbAl3GbDYvGbDlrGbHX3GbJl4GbLV8GbLn3GbMn4GboJTGboRfGbvFUGb3GUGb4JnGgDX3GgFl$GgJlrGgLX6GgLZoGgLf8GgOXoGgrAgGgrJXGgrMYGgrScGgvATGgvOYGnAgoGnJgvGnLZoGnLg3GnLnrGnQn8GnSbrGnrMgHTClvHTDToHTFT3HTQT8HToJTHToJgHTrDUHTrMnHTvFYHTvRfHT8MnHT8SUHUAZ8HUBb4HUDTvHUoMYHXFl6HXJX6HXQlrHXrAUHXrMnHXrSbHXvFYHXvKXHX3LjHX3MeHYvQlHZrScHZvDbHbAcrHbFT3HbFl3HbJT8HbLTrHbMT8HbMXrHbMbrHbQb8HbSX3HboDbHboJTHbrFUHbrHgHbrJTHb8JTHb8MnHb8QgHgAlrHgDT3HgGgrHgHgrHgJTrHgJT8HgLX@HgLnrHgMT8HgMX8HgMboHgOnrHgQToHgRg3HgoHgHgrCbHgrFnHgrLVHgvAcHgvAfHnAloHnCTrHnCnvHnGTrHnGZ8HnGnvHnJT8HnLf8HnLkvHnMg8HnRTrITvFUITvFnJTAXrJTCV8JTFT3JTFT8JTFn4JTGgvJTHT8JTJT8JTJXvJTJl3JTJnvJTLX4JTLf8JTLhvJTMT8JTMXrJTMnrJTObrJTQT8JTSlvJT8DUJT8FkJT8MTJT8OXJT8OgJT8QUJT8RfJUHZoJXFT4JXFlrJXGZ8JXGnrJXLV8JXLgvJXMXoJXMX3JXNboJXPlvJXoJTJXoLkJXrAXJXrHUJXrJgJXvJTJXvOnJX4KnJYAl3JYJT8JYLhvJYQToJYrQXJY6NUJbAl3JbCZrJbDloJbGT8JbGgrJbJXvJbJboJbLf8JbLhrJbLl3JbMnvJbRg8JbSZ8JboDbJbrCZJbrSUJb3KnJb8LnJfRn8JgAXrJgCZrJgDTrJgGZrJgGZ8JgHToJgJT8JgJXoJgJgvJgLX4JgLZ3JgLZ8JgLn4JgMgrJgMn4JgOgvJgPX6JgRnvJgSToJgoCZJgoJbJgoMYJgrJXJgrJgJgrLjJg6MTJlCn3JlGgvJlJl8Jl4AnJl8FnJl8HgJnAToJnATrJnAbvJnDUoJnGnrJnJXrJnJXvJnLhvJnLnrJnLnvJnMToJnMT8JnMXvJnMX3JnMg8JnMlrJnMn4JnOX8JnST4JnSX3JnoAgJnoAnJnoJTJnoObJnrAbJnrAkJnrHnJnrJTJnrJYJnrOYJnrScJnvCUJnvFaJnvJgJnvJnJnvOYJnvQUJnvRUJn3FnJn3JTKnFl3KnLT6LTDlvLTMnoLTOn3LTRl3LTSb4LTSlrLToAnLToJgLTrAULTrAcLTrCULTrHgLTrMgLT3JnLULnrLUMX8LUoJgLVATrLVDTrLVLb8LVoJgLV8MgLV8RTLXDg3LXFlrLXrCnLXrLXLX3GTLX4GgLX4OYLZAXrLZAcrLZAgrLZAhrLZDXyLZDlrLZFbrLZFl3LZJX6LZJX8LZLc8LZLnrLZSU8LZoJTLZoJnLZrAgLZrAnLZrJYLZrLULZrMgLZrSkLZvAnLZvGULZvJeLZvOTLZ3FZLZ4JXLZ8STLZ8ScLaAT3LaAl3LaHT8LaJTrLaJT8LaJXrLaJgvLaJl4LaLVoLaMXrLaMXvLaMX8LbClvLbFToLbHlrLbJn4LbLZ3LbLhvLbMXrLbMnoLbvSULcLnrLc8HnLc8MTLdrMnLeAgoLeOgvLeOn3LfAl3LfLnvLfMl3LfOX8Lf8AnLf8JXLf8LXLgJTrLgJXrLgJl8LgMX8LgRZrLhCToLhrAbLhrFULhrJXLhvJYLjHTrLjHX4LjJX8LjLhrLjSX3LjSZ4LkFX4LkGZ8LkGgvLkJTrLkMXoLkSToLkSU8LkSZ8LkoOYLl3FfLl3MgLmAZrLmCbrLmGgrLmHboLmJnoLmJn3LmLfoLmLhrLmSToLnAX6LnAb6LnCZ3LnCb3LnDTvLnDb8LnFl3LnGnrLnHZvLnHgvLnITvLnJT8LnJX8LnJlvLnLf8LnLg6LnLhvLnLnoLnMXrLnMg8LnQlvLnSbrLnrAgLnrAnLnrDbLnrFkLnrJdLnrMULnrOYLnrSTLnvAnLnvDULnvHgLnvOYLnvOnLn3GgLn4DULn4JTLn4JnMTAZoMTAloMTDb8MTFT8MTJnoMTJnrMTLZrMTLhrMTLkvMTMX8MTRTrMToATMTrDnMTrOnMT3JnMT4MnMT8FUMT8FaMT8FlMT8GTMT8GbMT8GnMT8HnMT8JTMT8JbMT8OTMUCl8MUJTrMUJU8MUMX8MURTrMUSToMXAX6MXAb6MXCZoMXFXrMXHXrMXLgvMXOgoMXrAUMXrAnMXrHgMXrJYMXrJnMXrMTMXrMgMXrOYMXrSZMXrSgMXvDUMXvOTMX3JgMX3OTMX4JnMX8DbMX8FnMX8HbMX8HgMX8HnMX8LbMX8MnMX8OnMYAb8MYGboMYHTvMYHX4MYLTrMYLnvMYMToMYOgvMYRg3MYSTrMbAToMbAXrMbAl3MbAn8MbGZ8MbJT8MbJXrMbMXvMbMX8MbMnoMbrMUMb8AfMb8FbMb8FkMcJXoMeLnrMgFl3MgGTvMgGXoMgGgrMgGnrMgHT8MgHZrMgJnoMgLnrMgLnvMgMT8MgQUoMgrHnMgvAnMg8HgMg8JYMg8LfMloJnMl8ATMl8AXMl8JYMnAToMnAT4MnAZ8MnAl3MnAl4MnCl8MnHT8MnHg8MnJnoMnLZoMnLhrMnMXoMnMX3MnMnrMnOgvMnrFbMnrFfMnrFnMnrNTMnvJXNTMl8OTCT3OTFV8OTFn3OTHZvOTJXrOTOl3OT3ATOT3JUOT3LZOT3LeOT3MbOT8ATOT8AbOT8AgOT8MbOUCXvOUMX3OXHXvOXLl3OXrMUOXvDbOX6NUOX8JbOYFZoOYLbrOYLkoOYMg8OYSX3ObHTrObHT4ObJgrObLhrObMX3ObOX8Ob8FnOeAlrOeJT8OeJXrOeJnrOeLToOeMb8OgJXoOgLXoOgMnrOgOXrOgOloOgoAgOgoJbOgoMYOgoSTOg8AbOjLX4OjMnoOjSV8OnLVoOnrAgOn3DUPXQlrPXvFXPbvFTPdAT3PlFn3PnvFbQTLn4QToAgQToMTQULV8QURg8QUoJnQXCXvQbFbrQb8AaQb8AcQb8FbQb8MYQb8ScQeAlrQeLhrQjAn3QlFXoQloJgQloSnRTLnvRTrGURTrJTRUJZrRUoJlRUrQnRZrLmRZrMnRZrSnRZ8ATRZ8JbRZ8ScRbMT8RbST3RfGZrRfMX8RfMgrRfSZrRnAbrRnGT8RnvJgRnvLfRnvMTRn8AaSTClvSTJgrSTOXrSTRg3STRnvSToAcSToAfSToAnSToHnSToLjSToMTSTrAaSTrEUST3BYST8AgST8LmSUAZvSUAgrSUDT4SUDT8SUGgvSUJXoSUJXvSULTrSU8JTSU8LjSV8AnSV8JgSXFToSXLf8SYvAnSZrDUSZrMUSZrMnSZ8HgSZ8JTSZ8JgSZ8MYSZ8QUSaQUoSbCT3SbHToSbQYvSbSl4SboJnSbvFbSb8HbSb8JgSb8OTScGZrScHgrScJTvScMT8ScSToScoHbScrMTScvAnSeAZrSeAcrSeHboSeJUoSeLhrSeMT8SeMXrSe6JgSgHTrSkJnoSkLnvSk8CUSlFl3SlrSnSl8GnSmAboSmGT8SmJU8","ATLnDlATrAZoATrJX4ATrMT8ATrMX4ATrRTrATvDl8ATvJUoATvMl8AT3AToAT3MX8AT8CT3AT8DT8AT8HZrAT8HgoAUAgFnAUCTFnAXoMX8AXrAT8AXrGgvAXrJXvAXrOgoAXvLl3AZvAgoAZvFbrAZvJXoAZvJl8AZvJn3AZvMX8AZvSbrAZ8FZoAZ8LZ8AZ8MU8AZ8OTvAZ8SV8AZ8SX3AbAgFZAboJnoAbvGboAb8ATrAb8AZoAb8AgrAb8Al4Ab8Db8Ab8JnoAb8LX4Ab8LZrAb8LhrAb8MT8Ab8OUoAb8Qb8Ab8ST8AcrAUoAcrAc8AcrCZ3AcrFT3AcrFZrAcrJl4AcrJn3AcrMX3AcrOTvAc8AZ8Ac8MT8AfAcJXAgoFn4AgoGgvAgoGnrAgoLc8AgoMXoAgrLnrAkrSZ8AlFXCTAloHboAlrHbrAlrLhrAlrLkoAl3CZrAl3LUoAl3LZrAnrAl4AnrMT8An3HT4BT3IToBX4MnvBb!Ln$CTGXMnCToLZ4CTrHT8CT3JTrCT3RZrCT#GTvCU6GgvCU8Db8CU8GZrCU8HT8CboLl3CbrGgrCbrMU8Cb8DT3Cb8GnrCb8LX4Cb8MT8Cb8ObrCgrGgvCgrKX4Cl8FZoDTrAbvDTrDboDTrGT6DTrJgrDTrMX3DTrRZrDTrRg8DTvAVvDTvFZoDT3DT8DT3Ln3DT4HZrDT4MT8DT8AlrDT8MT8DUAkGbDUDbJnDYLnQlDbDUOYDbMTAnDbMXSnDboAT3DboFn4DboLnvDj6JTrGTCgFTGTGgFnGTJTMnGTLnPlGToJT8GTrCT3GTrLVoGTrLnvGTrMX3GTrMboGTvKl3GZClFnGZrDT3GZ8DTrGZ8FZ8GZ8MXvGZ8On8GZ8ST3GbCnQXGbMbFnGboFboGboJg3GboMXoGb3JTvGb3JboGb3Mn6Gb3Qb8GgDXLjGgMnAUGgrDloGgrHX4GgrSToGgvAXrGgvAZvGgvFbrGgvLl3GgvMnvGnDnLXGnrATrGnrMboGnuLl3HTATMnHTAgCnHTCTCTHTrGTvHTrHTvHTrJX8HTrLl8HTrMT8HTrMgoHTrOTrHTuOn3HTvAZrHTvDTvHTvGboHTvJU8HTvLl3HTvMXrHTvQb4HT4GT6HT4JT8HT4Jb#HT8Al3HT8GZrHT8GgrHT8HX4HT8Jb8HT8JnoHT8LTrHT8LgvHT8SToHT8SV8HUoJUoHUoJX8HUoLnrHXrLZoHXvAl3HX3LnrHX4FkvHX4LhrHX4MXoHX4OnoHZrAZ8HZrDb8HZrGZ8HZrJnrHZvGZ8HZvLnvHZ8JnvHZ8LhrHbCXJlHbMTAnHboJl4HbpLl3HbrJX8HbrLnrHbrMnvHbvRYrHgoSTrHgrFV8HgrGZ8HgrJXoHgrRnvHgvBb!HgvGTrHgvHX4HgvHn!HgvLTrHgvSU8HnDnLbHnFbJbHnvDn8Hn6GgvHn!BTvJTCTLnJTQgFnJTrAnvJTrLX4JTrOUoJTvFn3JTvLnrJTvNToJT3AgoJT3Jn4JT3LhvJT3ObrJT8AcrJT8Al3JT8JT8JT8JnoJT8LX4JT8LnrJT8MX3JT8Rg3JT8Sc8JUoBTvJU8AToJU8GZ8JU8GgvJU8JTrJU8JXrJU8JnrJU8LnvJU8ScvJXHnJlJXrGgvJXrJU8JXrLhrJXrMT8JXrMXrJXrQUoJXvCTvJXvGZ8JXvGgrJXvQT8JX8Ab8JX8DT8JX8GZ8JX8HZvJX8LnrJX8MT8JX8MXoJX8MnvJX8ST3JYGnCTJbAkGbJbCTAnJbLTAcJboDT3JboLb6JbrAnvJbrCn3JbrDl8JbrGboJbrIZoJbrJnvJbrMnvJbrQb4Jb8RZrJeAbAnJgJnFbJgScAnJgrATrJgvHZ8JgvMn4JlJlFbJlLiQXJlLjOnJlRbOlJlvNXoJlvRl3Jl4AcrJl8AUoJl8MnrJnFnMlJnHgGbJnoDT8JnoFV8JnoGgvJnoIT8JnoQToJnoRg3JnrCZ3JnrGgrJnrHTvJnrLf8JnrOX8JnvAT3JnvFZoJnvGT8JnvJl4JnvMT8JnvMX8JnvOXrJnvPX6JnvSX3JnvSZrJn3MT8Jn3MX8Jn3RTrLTATKnLTJnLTLTMXKnLTRTQlLToGb8LTrAZ8LTrCZ8LTrDb8LTrHT8LT3PX6LT4FZoLT$CTvLT$GgrLUvHX3LVoATrLVoAgoLVoJboLVoMX3LVoRg3LV8CZ3LV8FZoLV8GTvLXrDXoLXrFbrLXvAgvLXvFlrLXvLl3LXvRn6LX4Mb8LX8GT8LYCXMnLYrMnrLZoSTvLZrAZvLZrAloLZrFToLZrJXvLZrJboLZrJl4LZrLnrLZrMT8LZrOgvLZrRnvLZrST4LZvMX8LZvSlvLZ8AgoLZ8CT3LZ8JT8LZ8LV8LZ8LZoLZ8Lg8LZ8SV8LZ8SbrLZ$HT8LZ$Mn4La6CTvLbFbMnLbRYFTLbSnFZLboJT8LbrAT9LbrGb3LbrQb8LcrJX8LcrMXrLerHTvLerJbrLerNboLgrDb8LgrGZ8LgrHTrLgrMXrLgrSU8LgvJTrLgvLl3Lg6Ll3LhrLnrLhrMT8LhvAl4LiLnQXLkoAgrLkoJT8LkoJn4LlrSU8Ll3FZoLl3HTrLl3JX8Ll3JnoLl3LToLmLeFbLnDUFbLnLVAnLnrATrLnrAZoLnrAb8LnrAlrLnrGgvLnrJU8LnrLZrLnrLhrLnrMb8LnrOXrLnrSZ8LnvAb4LnvDTrLnvDl8LnvHTrLnvHbrLnvJT8LnvJU8LnvJbrLnvLhvLnvMX8LnvMb8LnvNnoLnvSU8Ln3Al3Ln4FZoLn4GT6Ln4JgvLn4LhrLn4MT8Ln4SToMToCZrMToJX8MToLX4MToLf8MToRg3MTrEloMTvGb6MT3BTrMT3Lb6MT8AcrMT8AgrMT8GZrMT8JnoMT8LnrMT8MX3MUOUAnMXAbFnMXoAloMXoJX8MXoLf8MXoLl8MXrAb8MXrDTvMXrGT8MXrGgrMXrHTrMXrLf8MXrMU8MXrOXvMXrQb8MXvGT8MXvHTrMXvLVoMX3AX3MX3Jn3MX3LhrMX3MX3MX4AlrMX4OboMX8GTvMX8GZrMX8GgrMX8JT8MX8JX8MX8LhrMX8MT8MYDUFbMYMgDbMbGnFfMbvLX4MbvLl3Mb8Mb8Mb8ST4MgGXCnMg8ATrMg8AgoMg8CZrMg8DTrMg8DboMg8HTrMg8JgrMg8LT8MloJXoMl8AhrMl8JT8MnLgAUMnoJXrMnoLX4MnoLhrMnoMT8MnrAl4MnrDb8MnrOTvMnrOgvMnrQb8MnrSU8MnvGgrMnvHZ8Mn3MToMn4DTrMn4LTrMn4Mg8NnBXAnOTFTFnOToAToOTrGgvOTrJX8OT3JXoOT6MTrOT8GgrOT8HTpOT8MToOUoHT8OUoJT8OUoLn3OXrAgoOXrDg8OXrMT8OXvSToOX6CTvOX8CZrOX8OgrOb6HgvOb8AToOb8MT8OcvLZ8OgvAlrOgvHTvOgvJTrOgvJnrOgvLZrOgvLn4OgvMT8OgvRTrOg8AZoOg8DbvOnrOXoOnvJn4OnvLhvOnvRTrOn3GgoOn3JnvOn6JbvOn8OTrPTGYFTPbBnFnPbGnDnPgDYQTPlrAnvPlrETvPlrLnvPlrMXvPlvFX4QTMTAnQTrJU8QYCnJlQYJlQlQbGTQbQb8JnrQb8LZoQb8LnvQb8MT8Qb8Ml8Qb8ST4QloAl4QloHZvQloJX8QloMn8QnJZOlRTrAZvRTrDTrRTvJn4RTvLhvRT4Jb8RZrAZrRZ8AkrRZ8JU8RZ8LV8RZ8LnvRbJlQXRg3GboRg3MnvRg8AZ8Rg8JboRg8Jl4RnLTCbRnvFl3RnvQb8SToAl4SToCZrSToFZoSToHXrSToJU8SToJgvSToJl4SToLhrSToMX3STrAlvSTrCT9STrCgrSTrGgrSTrHXrSTrHboSTrJnoSTrNboSTvLnrST4AZoST8Ab8ST8JT8SUoJn3SU6HZ#SU6JTvSU8Db8SU8HboSU8LgrSV8JT8SZrAcrSZrAl3SZrJT8SZrJnvSZrMT8SZvLUoSZ4FZoSZ8JnoSZ8RZrScoLnrScoMT8ScoMX8ScrAT4ScrAZ8ScrLZ8ScrLkvScvDb8ScvLf8ScvNToSgrFZrShvKnrSloHUoSloLnrSlrMXoSl8HgrSmrJUoSn3BX6","ATFlOn3ATLgrDYAT4MTAnAT8LTMnAYJnRTrAbGgJnrAbLV8LnAbvNTAnAeFbLg3AgOYMXoAlQbFboAnDboAfAnJgoJTBToDgAnBUJbAl3BboDUAnCTDlvLnCTFTrSnCYoQTLnDTwAbAnDUDTrSnDUHgHgrDX8LXFnDbJXAcrETvLTLnGTFTQbrGTMnGToGT3DUFbGUJlPX3GbQg8LnGboJbFnGb3GgAYGgAg8ScGgMbAXrGgvAbAnGnJTLnvGnvATFgHTDT6ATHTrDlJnHYLnMn8HZrSbJTHZ8LTFnHbFTJUoHgSeMT8HgrLjAnHgvAbAnHlFUrDlHnDgvAnHnHTFT3HnQTGnrJTAaMXvJTGbCn3JTOgrAnJXvAXMnJbMg8SnJbMnRg3Jb8LTMnJnAl3OnJnGYrQlJnJlQY3LTDlCn3LTJjLg3LTLgvFXLTMg3GTLV8HUOgLXFZLg3LXNXrMnLX8QXFnLX9AlMYLYLXPXrLZAbJU8LZDUJU8LZMXrSnLZ$AgFnLaPXrDULbFYrMnLbMn8LXLboJgJgLeFbLg3LgLZrSnLgOYAgoLhrRnJlLkCTrSnLkOnLhrLnFX%AYLnFZoJXLnHTvJbLnLloAbMTATLf8MTHgJn3MTMXrAXMT3MTFnMUITvFnMXFX%AYMXMXvFbMXrFTDbMYAcMX3MbLf8SnMb8JbFnMgMXrMTMgvAXFnMgvGgCmMnAloSnMnFnJTrOXvMXSnOX8HTMnObJT8ScObLZFl3ObMXCZoPTLgrQXPUFnoQXPU3RXJlPX3RkQXPbrJXQlPlrJbFnQUAhrDbQXGnCXvQYLnHlvQbLfLnvRTOgvJbRXJYrQlRYLnrQlRbLnrQlRlFT8JlRlFnrQXSTClCn3STHTrAnSTLZQlrSTMnGTrSToHgGbSTrGTDnSTvGXCnST3HgFbSU3HXAXSbAnJn3SbFT8LnScLfLnv","AT3JgJX8AT8FZoSnAT8JgFV8AT8LhrDbAZ8JT8DbAb8GgLhrAb8SkLnvAe8MT8SnAlMYJXLVAl3GYDTvAl3LfLnvBUDTvLl3CTOn3HTrCT3DUGgrCU8MT8AbCbFTrJUoCgrDb8MTDTLV8JX8DTLnLXQlDT8LZrSnDUQb8FZ8DUST4JnvDb8ScOUoDj6GbJl4GTLfCYMlGToAXvFnGboAXvLnGgAcrJn3GgvFnSToGnLf8JnvGn#HTDToHTLnFXJlHTvATFToHTvHTDToHTvMTAgoHT3STClvHT4AlFl6HT8HTDToHUoDgJTrHUoScMX3HbRZrMXoHboJg8LTHgDb8JTrHgMToLf8HgvLnLnoHnHn3HT4Hn6MgvAnJTJU8ScvJT3AaQT8JT8HTrAnJXrRg8AnJbAloMXoJbrATFToJbvMnoSnJgDb6GgvJgDb8MXoJgSX3JU8JguATFToJlPYLnQlJlQkDnLbJlQlFYJlJl8Lf8OTJnCTFnLbJnLTHXMnJnLXGXCnJnoFfRg3JnrMYRg3Jn3HgFl3KT8Dg8LnLTRlFnPTLTvPbLbvLVoSbrCZLXMY6HT3LXNU7DlrLXNXDTATLX8DX8LnLZDb8JU8LZMnoLhrLZSToJU8LZrLaLnrLZvJn3SnLZ8LhrSnLaJnoMT8LbFlrHTvLbrFTLnrLbvATLlvLb6OTFn3LcLnJZOlLeAT6Mn4LeJT3ObrLg6LXFlrLhrJg8LnLhvDlPX4LhvLfLnvLj6JTFT3LnFbrMXoLnQluCTvLnrQXCY6LnvLfLnvLnvMgLnvLnvSeLf8MTMbrJn3MT3JgST3MT8AnATrMT8LULnrMUMToCZrMUScvLf8MXoDT8SnMX6ATFToMX8AXMT8MX8FkMT8MX8HTrDUMX8ScoSnMYJT6CTvMgAcrMXoMg8SToAfMlvAXLg3MnFl3AnvOT3AnFl3OUoATHT8OU3RnLXrOXrOXrSnObPbvFn6Og8HgrSnOg8OX8DbPTvAgoJgPU3RYLnrPXrDnJZrPb8CTGgvPlrLTDlvPlvFUJnoQUvFXrQlQeMnoAl3QlrQlrSnRTFTrJUoSTDlLiLXSTFg6HT3STJgoMn4STrFTJTrSTrLZFl3ST4FnMXoSUrDlHUoScvHTvSnSfLkvMXo","AUoAcrMXoAZ8HboAg8AbOg6ATFgAg8AloMXoAl3AT8JTrAl8MX8MXoCT3SToJU8Cl8Db8MXoDT8HgrATrDboOT8MXoGTOTrATMnGT8LhrAZ8GnvFnGnQXHToGgvAcrHTvAXvLl3HbrAZoMXoHgBlFXLg3HgMnFXrSnHgrSb8JUoHn6HT8LgvITvATrJUoJUoLZrRnvJU8HT8Jb8JXvFX8QT8JXvLToJTrJYrQnGnQXJgrJnoATrJnoJU8ScvJnvMnvMXoLTCTLgrJXLTJlRTvQlLbRnJlQYvLbrMb8LnvLbvFn3RnoLdCVSTGZrLeSTvGXCnLg3MnoLn3MToLlrETvMT8SToAl3MbrDU6GTvMb8LX4LhrPlrLXGXCnSToLf8Rg3STrDb8LTrSTvLTHXMnSb3RYLnMnSgOg6ATFg","HUDlGnrQXrJTrHgLnrAcJYMb8DULc8LTvFgGnCk3Mg8JbAnLX4QYvFYHnMXrRUoJnGnvFnRlvFTJlQnoSTrBXHXrLYSUJgLfoMT8Se8DTrHbDb","AbDl8SToJU8An3RbAb8ST8DUSTrGnrAgoLbFU6Db8LTrMg8AaHT8Jb8ObDl8SToJU8Pb3RlvFYoJl"];let s=null;function u(){if(null!=s)return s;const e=[];a.forEach(((t,r)=>{r+=4;for(let o=0;o=40?n=n+168-40:n>=19&&(n=n+97-19),(0,i.toUtf8String)(new Uint8Array([225,132+(n>>6),128+(63&n)])));e.push(a)}var n})),e.sort();if("0xf9eddeace9c5d3da9c93cf7d3cd38f6a13ed3affb933259ae865714e8a3ae71a"!==(0,n.id)(e.join("\n")+"\n"))throw new Error("BIP39 Wordlist for ko (Korean) FAILED");return s=e,e}let c=null;class l extends o.Wordlist{constructor(){super("ko")}getWord(e){const t=u();return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangPt=void 0;const n=r(21978);let i=null;class o extends n.WordlistOwl{constructor(){super("pt","0arad!ototealirertainrasoent hoandoaR#riareha!aroele'oronul0Aca%AixoAl A%rDuz'El]Er$IsmoO$ Rum S-&T(i&TigoVo[=0F&.Il#P' S?S* So&/Sun$Tr&0Ac#Adu+Al/A[f E End(Er_EuIng'Ir?IvoOl{oRac Revi=RizU&Um0Di$rM-.R>o+TismoT|@Tu 0Ali An%Ar@Ent&Es,I?Is Ul,1Ila1Ar E=Ei%Ulejo:B BosaC&]uCh `C@GagemI+c>~/Se#S)n%Ta)Te=rTidaTomTuc Unil]3B(IjoIr^IsebolLd!eLezaLgaLisc Ndi$Ng&aNz(RimbauRl*d>_Sou_XigaZ(_3CoCu=En&Foc&Furc G|naLhe%Mest[Mo$rOlog@OmboOsf(aPol Rr-$Scoi$Sne$SpoSsex$TolaZ _2Ind#OcoOque 2A$BagemC#CejoChec]Ico.L^LetimL]LoMb{oNdeNecoNi)Rb~h>d>e&R+c]V*oXe?2AncoAsaAvezaEuIgaIl/Inc OaOchu+Onze O$Uxo2C]DismoF LeRacoScaS$Z*a:Bimb Rn{oRpe%R['>)zRv&/SacoScaSeb[S%loS~oT a)Tiv UleUs?U%l V&oV(na3BolaDil]G}]Lebr L~ Nou+N,N%ioRc Rr#R%'oRvejaTimV^2Aco)Al{aAm#Ap^ArmeAticeAveEfeEg^E'oEqueIco%If[In`oOc&/Ov(UmboU.Uva0CatrizCl}eD!eD['aEn%Gcui$Rurg@T 2A[zaE_Ic OneUbe2A=Ag'Ba@B($rBr C^El/Ent_E,Gum`oIb'IfaIo%L L{aLh(Lid'Lme@L}oLunaM<=Mb* M-.MitivaMov(MplexoMumNc]N=rNec.Nfu,Ng` Nhec(Njug Nsum'Nt+$Nvi%Op( P{oPi?PoQue%lRagemRdi&Rne)R}h>p|&R[ioR%joRuj>voSs-oS%laT}e%U_UveVilZ*]2A%+AvoEcheE=rEmeErEspoI^Im*&Io~oIseItic Os)UaUz{o2B+m SafioSbo.Sc<,S-/Sfi#Sgas%Sigu&SlizeSmam SovaSpesaS)queSvi T&h T-$rT} Tri$UsaV(Vi=Vot#Z-a3Ag+maAle$Da)Fu,Gi.Lat#Lu-%M*u'Nast@Nh{oOceseRe$Sc[)Sf ceSp oSque%Ssip S)n%T?UrnoV(,Vi,rV~g Z(5Br?L|i=M?M*#NativoNz`>m-%Rs&SagemUr#U$r2EnagemIbleOg @2El EndeE$PloQues><%Vi=,:1Lod'O Olog@0Ific It&Uc#1Ei$Etiv 3E.1Ab| Eg(Ei$rEncoEv?Im* Ogi 0B goBol#Br~/Buti=EndaErg'Is,rPat@P-/P*#Polg P[goPurr Ul?0CaixeC-#Ch-%C}t_Deus Doss Faix Fei%FimGaj#G-/Glob Gom#G+x Gu@Jo La.Qu<$Raiz Rol#Rug SaioSe^S*oSop#T<$Te#Tid!eT|.Tr^T~/V(g Vi#Volv(XameX($Xof[Xu$1Id(me0Uip 0E$Gui=Ra)VaVil]0Bopeu0Acu Ap| AsivoEntu&Id-%Olu'1Ag(oAl Am* A$Aus$Ces,Ci.Clam Ecu.EmploIb'Ig-%On( Pof>p>tu+T@T|V|i)X*aZ-da3Ch#Ijo^I+n%L*oM**oNdaNoR>i#RrugemRv(S%j T&Ud&3ApoB_seC Ch{oGur#L{aL/LmeLtr RmezaSg^Ssu+TaV`aX?Xo2AcidezAm*goAn`aEch^O+Utu Uxo2C&C*/Foc GoGue%IceLg#Lhe$Rj Rmig>noR%ScoSsa2Aga)AldaAngoAscoA%rnoE'aEn%E.IezaI,Itu+On]Ustr U%'a2G'L+faSodu$S$TaTil/Ve)Z`a3L#Le@LoM^M(Mi=N(o,NgivaNi&NomaN_Ologi>?Rm* S,S$r3Nas)Nc*o2Aci&IcoseOb&Orio,2ElaIabaLfeLpe Rdu+Rje)R_S$,T{aV(n 2AcejoAdu&Afi%Al]AmpoAn^Atui$Ave$AxaEgoElh EveIloIs&/I.@Os,O%scoUd#Unhi=U)2AcheA+niAx*imEr[ I Inc/Is#LaLo,Ru:Bi.Rm}@S%V(3C.eRd Res@Si.3A$B(n D+.EnaNoPismoPnosePo%ca5JeLofo%MemNes$Nr#Rm}&Sped 5M|#:Te2E@O,2N|#RejaUdimR_SmimToV&iZida3Jum9An*]Elh^G?I>n&Rr Vem5BaDeuDocaIzLg?L/R#Ris)RoS)::B edaB|&C[C)n%Dril/G )GoaJeMb(M-.M* MpejoNchePid P,R{>gu+S<]St_T(&Ti=VfimRgemR*/Rmi)Ro$RquiseR[coR%loRujoSco%Sm|+SsagemStig Tag&T(noT*&Tu.Xil 3D&]DidaDusaGaf}eIgaLc/Sc~ SeuSic&:Ci}&D?JaMo_R*>r#Sc(TivaTu[zaV&]Veg Vio3Bl*aB~o,GativaGoci Gri$Rvo,TaUr&VascaVo{o3N N/TidezV` 5B[zaI%IvaMe M*&Rdes%R% T Tici TurnoV`oVil/Vo5Bl#DezM(&Pci&Tr'Vem:0Cec#Edec(JetivoRig#Scu_S%t+T(Tur 0Id-%Io,Orr(Ulis)Up#2Eg<%EnsivaEr-daIc*aUsc#0Iva4Ar@Eo,H Iv{a0B_Ele%Is,It'0D~#E_,Tem1Ci}&Er?On-%OrtunoOs$1ArBi.DemD*&Fci&Rd&RedeRtidaSmoSs#S%lTam T-%T* T_noUl^Us 3C~i D& Dest[D@t+D+G^I$r&IxeLeLicplexoRsi<>%nceRucaSc#SquisaS,aTisc 3AdaC#Ed!eGm-$Last+Lh#Lo.M-)Nc`NguimN]No%N.On{oPocaQue%ResRue)Sc S$laTg-$Rje)Tur Ud!eXof}eZ}&3C C~ DaD-$Di#Do,Du$rGm-$G[=Gun=IvaLe$LvagemM<&M-%N?N/rNsu&Nt#P #Rei>*g>+RvoTemb_T|3GiloLhue)Lic}eMetr@Mpat@M~ N&Nc(oNg~ NopseN$ni>-eRiTu#5B(fis)Rp[s>[&Rt'Sp'oS%n$:B`aBle%Bu^C/G `aLh(LoLvezMdioRef>j>+xaTuagemUr*oXativoXis)3Atr&C(Ci=Cl#Dio,IaIm Lef}eLh#Mp(oN-%N,rN.Rm&RnoRr-oSeSou+St#ToXtu+Xugo3A+G`aJoloMbr MidezNgi=N%'oRagemT~ 5Al]C]L( LiceM^Mil/N`Ntu+Pe%R>ci=RneioRqueRr!>$S.UcaUp{aX*a2Ab&/Acej Adu$rAfeg Aje$AmaAnc ApoAs{oAt?Av E*oEm(Epid EvoIagemIboIcicloId-%Ilog@Ind!eIploItur Iunf&Oc Ombe)OvaUnfoUque2B~ CquesaT` T|i&:7V 3Bigo0HaId!eIf|me3Olog@SoTigaUbu0A=InaUfru':C*aDi G o,I=,LaL-%Lid!eLo[sN)gemQu{oRe)Rr(Sc~ Sil]S,u+Z Zio3A=D Ge.Ic~ L{oLhiceLu=Nce=rNdav&N( Nt[Rb&Rd!eRe?Rg}h>m`/RnizRs R%n%SpaSti=T|i&3Adu$AgemAj Atu+Br?D{aDr @ElaGaG-%Gi G| L ejoNcoNhe)NilOle)R!>tudeSi.S$Tr&V{oZ*/5A=rArG&L<%LeibolL)gemLumo,Nt!e5L$Vuz`a::D[zRope3QueRe.Rife3Ng ::Ng#Rp 3BuL?9Mb Olog@5Mbi=","0x2219000926df7b50d8aa0a3d495826b988287df4657fbd100e6fe596c8f737ac")}static wordlist(){return null==i&&(i=new o),i}}t.LangPt=o},64065:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LangZh=void 0;const n=r(98336),i=r(42120),o=r(51208),a="}aE#4A=Yv&co#4N#6G=cJ&SM#66|/Z#4t&kn~46#4K~4q%b9=IR#7l,mB#7W_X2*dl}Uo~7s}Uf&Iw#9c&cw~6O&H6&wx&IG%v5=IQ~8a&Pv#47$PR&50%Ko&QM&3l#5f,D9#4L|/H&tQ;v0~6n]nN>2),128+c.indexOf(a[3*n+1]),128+c.indexOf(a[3*n+2])];if("zh_tw"===e){for(let e=o%4;e<3;e++)s[e]=c.indexOf("FAZDC6BALcLZCA+GBARCW8wNCcDDZ8LVFBOqqDUiou+M42TFAyERXFb7EjhP+vmBFpFrUpfDV2F7eB+eCltCHJFWLFCED+pWTojEIHFXc3aFn4F68zqjEuKidS1QBVPDEhE7NA4mhMF7oThD49ot3FgtzHFCK0acW1x8DH1EmLoIlrWFBLE+y5+NA3Cx65wJHTaEZVaK1mWAmPGxgYCdxwOjTDIt/faOEhTl1vqNsKtJCOhJWuio2g07KLZEQsFBUpNtwEByBgxFslFheFbiEPvi61msDvApxCzB6rBCzox7joYA5UdDc+Cb4FSgIabpXFAj3bjkmFAxCZE+mD/SFf/0ELecYCt3nLoxC6WEZf2tKDB4oZvrEmqFkKk7BwILA7gtYBpsTq//D4jD0F0wEB9pyQ1BD5Ba0oYHDI+sbDFhvrHXdDHfgFEIJLi5r8qercNFBgFLC4bo5ERJtamWBDFy73KCEb6M8VpmEt330ygCTK58EIIFkYgF84gtGA9Uyh3m68iVrFbWFbcbqiCYHZ9J1jeRPbL8yswhMiDbhEhdNoSwFbZrLT740ABEqgCkO8J1BLd1VhKKR4sD1yUo0z+FF59Mvg71CFbyEhbHSFBKEIKyoQNgQppq9T0KAqePu0ZFGrXOHdKJqkoTFhYvpDNyuuznrN84thJbsCoO6Cu6Xlvntvy0QYuAExQEYtTUBf3CoCqwgGFZ4u1HJFzDVwEy3cjcpV4QvsPaBC3rCGyCF23o4K3pp2gberGgFEJEHo4nHICtyKH2ZqyxhN05KBBJIQlKh/Oujv/DH32VrlqFdIFC7Fz9Ct4kaqFME0UETLprnN9kfy+kFmtQBB0+5CFu0N9Ij8l/VvJDh2oq3hT6EzjTHKFN7ZjZwoTsAZ4Exsko6Fpa6WC+sduz8jyrLpegTv2h1EBeYpLpm2czQW0KoCcS0bCVXCmuWJDBjN1nQNLdF58SFJ0h7i3pC3oEOKy/FjBklL70XvBEEIWp2yZ04xObzAWDDJG7f+DbqBEA7LyiR95j7MDVdDViz2RE5vWlBMv5e4+VfhP3aXNPhvLSynb9O2x4uFBV+3jqu6d5pCG28/sETByvmu/+IJ0L3wb4rj9DNOLBF6XPIODr4L19U9RRofAG6Nxydi8Bki8BhGJbBAJKzbJxkZSlF9Q2Cu8oKqggB9hBArwLLqEBWEtFowy8XK8bEyw9snT+BeyFk1ZCSrdmgfEwFePTgCjELBEnIbjaDDPJm36rG9pztcEzT8dGk23SBhXBB1H4z+OWze0ooFzz8pDBYFvp9j9tvFByf9y4EFdVnz026CGR5qMr7fxMHN8UUdlyJAzlTBDRC28k+L4FB8078ljyD91tUj1ocnTs8vdEf7znbzm+GIjEZnoZE5rnLL700Xc7yHfz05nWxy03vBB9YGHYOWxgMQGBCR24CVYNE1hpfKxN0zKnfJDmmMgMmBWqNbjfSyFCBWSCGCgR8yFXiHyEj+VtD1FB3FpC1zI0kFbzifiKTLm9yq5zFmur+q8FHqjoOBWsBPiDbnCC2ErunV6cJ6TygXFYHYp7MKN9RUlSIS8/xBAGYLzeqUnBF4QbsTuUkUqGs6CaiDWKWjQK9EJkjpkTmNCPYXL"[r++])+(0==e?228:128)}t.push((0,i.toUtf8String)(new Uint8Array(s)))}if((0,n.id)(t.join("\n")+"\n")!==u[e])throw new Error(`BIP39 Wordlist for ${e} (Chinese) FAILED`);return s[e]=t,t}const f={};class h extends o.Wordlist{constructor(e){super("zh_"+e)}getWord(e){const t=l(this.locale);return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WordlistOwl=void 0;const n=r(98336),i=r(42120),o=r(82629),a=r(51208);class s extends a.Wordlist{#r;#Ot;constructor(e,t,r){super(e),this.#r=t,this.#Ot=r,this.#Rt=null}get _data(){return this.#r}_decodeWords(){return(0,o.decodeOwl)(this.#r)}#Rt;#Ct(){if(null==this.#Rt){const e=this._decodeWords();if((0,n.id)(e.join("\n")+"\n")!==this.#Ot)throw new Error(`BIP39 Wordlist for ${this.locale} FAILED`);this.#Rt=e}return this.#Rt}getWord(e){const t=this.#Ct();return(0,i.assertArgument)(e>=0&&e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WordlistOwlA=void 0;const n=r(21978),i=r(84603);class o extends n.WordlistOwl{#Bt;constructor(e,t,r,n){super(e,t,n),this.#Bt=r}get _accent(){return this.#Bt}_decodeWords(){return(0,i.decodeOwlA)(this._data,this._accent)}}t.WordlistOwlA=o},51208:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Wordlist=void 0;const n=r(42120);t.Wordlist=class{locale;constructor(e){(0,n.defineProperties)(this,{locale:e})}split(e){return e.toLowerCase().split(/\s+/g)}join(e){return e.join(" ")}}},84311:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wordlists=void 0;const n=r(8838),i=r(10847),o=r(19321),a=r(42036),s=r(19642),u=r(86150),c=r(24555),l=r(58982),f=r(64065);t.wordlists={cz:n.LangCz.wordlist(),en:i.LangEn.wordlist(),es:o.LangEs.wordlist(),fr:a.LangFr.wordlist(),it:c.LangIt.wordlist(),pt:l.LangPt.wordlist(),ja:s.LangJa.wordlist(),ko:u.LangKo.wordlist(),zh_cn:f.LangZh.wordlist("cn"),zh_tw:f.LangZh.wordlist("tw")}},44946:e=>{"use strict";e.exports=JSON.parse('{"aes-128-ecb":{"cipher":"AES","key":128,"iv":0,"mode":"ECB","type":"block"},"aes-192-ecb":{"cipher":"AES","key":192,"iv":0,"mode":"ECB","type":"block"},"aes-256-ecb":{"cipher":"AES","key":256,"iv":0,"mode":"ECB","type":"block"},"aes-128-cbc":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes-192-cbc":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes-256-cbc":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes128":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes192":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes256":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes-128-cfb":{"cipher":"AES","key":128,"iv":16,"mode":"CFB","type":"stream"},"aes-192-cfb":{"cipher":"AES","key":192,"iv":16,"mode":"CFB","type":"stream"},"aes-256-cfb":{"cipher":"AES","key":256,"iv":16,"mode":"CFB","type":"stream"},"aes-128-cfb8":{"cipher":"AES","key":128,"iv":16,"mode":"CFB8","type":"stream"},"aes-192-cfb8":{"cipher":"AES","key":192,"iv":16,"mode":"CFB8","type":"stream"},"aes-256-cfb8":{"cipher":"AES","key":256,"iv":16,"mode":"CFB8","type":"stream"},"aes-128-cfb1":{"cipher":"AES","key":128,"iv":16,"mode":"CFB1","type":"stream"},"aes-192-cfb1":{"cipher":"AES","key":192,"iv":16,"mode":"CFB1","type":"stream"},"aes-256-cfb1":{"cipher":"AES","key":256,"iv":16,"mode":"CFB1","type":"stream"},"aes-128-ofb":{"cipher":"AES","key":128,"iv":16,"mode":"OFB","type":"stream"},"aes-192-ofb":{"cipher":"AES","key":192,"iv":16,"mode":"OFB","type":"stream"},"aes-256-ofb":{"cipher":"AES","key":256,"iv":16,"mode":"OFB","type":"stream"},"aes-128-ctr":{"cipher":"AES","key":128,"iv":16,"mode":"CTR","type":"stream"},"aes-192-ctr":{"cipher":"AES","key":192,"iv":16,"mode":"CTR","type":"stream"},"aes-256-ctr":{"cipher":"AES","key":256,"iv":16,"mode":"CTR","type":"stream"},"aes-128-gcm":{"cipher":"AES","key":128,"iv":12,"mode":"GCM","type":"auth"},"aes-192-gcm":{"cipher":"AES","key":192,"iv":12,"mode":"GCM","type":"auth"},"aes-256-gcm":{"cipher":"AES","key":256,"iv":12,"mode":"GCM","type":"auth"}}')},75207:e=>{"use strict";e.exports=JSON.parse('{"sha224WithRSAEncryption":{"sign":"rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"RSA-SHA224":{"sign":"ecdsa/rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"sha256WithRSAEncryption":{"sign":"rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"RSA-SHA256":{"sign":"ecdsa/rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"sha384WithRSAEncryption":{"sign":"rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"RSA-SHA384":{"sign":"ecdsa/rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"sha512WithRSAEncryption":{"sign":"rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA512":{"sign":"ecdsa/rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA1":{"sign":"rsa","hash":"sha1","id":"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{"sign":"ecdsa","hash":"sha1","id":""},"sha256":{"sign":"ecdsa","hash":"sha256","id":""},"sha224":{"sign":"ecdsa","hash":"sha224","id":""},"sha384":{"sign":"ecdsa","hash":"sha384","id":""},"sha512":{"sign":"ecdsa","hash":"sha512","id":""},"DSA-SHA":{"sign":"dsa","hash":"sha1","id":""},"DSA-SHA1":{"sign":"dsa","hash":"sha1","id":""},"DSA":{"sign":"dsa","hash":"sha1","id":""},"DSA-WITH-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-WITH-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-WITH-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-WITH-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-RIPEMD160":{"sign":"dsa","hash":"rmd160","id":""},"ripemd160WithRSA":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"RSA-RIPEMD160":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"md5WithRSAEncryption":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"},"RSA-MD5":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"}}')},1308:e=>{"use strict";e.exports=JSON.parse('{"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}')},29799:e=>{"use strict";e.exports=JSON.parse('{"modp1":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},"modp2":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},"modp5":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},"modp14":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},"modp15":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},"modp16":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},"modp17":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},"modp18":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}')},84064:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"assertionExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"}],"name":"createAssertion","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"deleteAssertion","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertion","outputs":[{"components":[{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"}],"internalType":"struct AssertionStructs.Assertion","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionChunksNumber","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionSize","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"getAssertionTriplesNumber","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},64776:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"AssetExpired","type":"error"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"CommitPhaseOngoing","type":"error"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"CommitPhaseSucceeded","type":"error"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"FirstEpochHasAlreadyEnded","type":"error"},{"inputs":[{"internalType":"address","name":"assetStorage","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"NoPendingUpdate","type":"error"},{"inputs":[{"internalType":"address","name":"assetStorage","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"latestStateIndex","type":"uint256"}],"name":"PendingUpdateFinalization","type":"error"},{"inputs":[{"internalType":"address","name":"assetStorage","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"latestState","type":"bytes32"}],"name":"UpdateIsNotFinalized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"returnedTokenAmount","type":"uint96"}],"name":"AssetBurnt","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"bytes32","name":"state","type":"bytes32"}],"name":"AssetMinted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"AssetPaymentIncreased","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"stateIndex","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"returnedTokenAmount","type":"uint96"}],"name":"AssetStateUpdateCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"stateIndex","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"AssetStateUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"AssetStoringPeriodExtended","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"AssetUpdatePaymentIncreased","type":"event"},{"inputs":[],"name":"assertionContract","outputs":[{"internalType":"contract Assertion","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burnAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"cancelAssetStateUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"clearOldCommitsMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contentAssetStorage","outputs":[{"internalType":"contract ContentAssetStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"bool","name":"immutable_","type":"bool"}],"internalType":"struct ContentAssetStructs.AssetInputArgs","name":"args","type":"tuple"}],"name":"createAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"bool","name":"immutable_","type":"bool"}],"name":"createAssetWithVariables","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"extendAssetStoringPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"hashingProxy","outputs":[{"internalType":"contract HashingProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"increaseAssetTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"increaseAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"parametersStorage","outputs":[{"internalType":"contract ParametersStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"serviceAgreementStorageProxy","outputs":[{"internalType":"contract ServiceAgreementStorageProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"serviceAgreementV1","outputs":[{"internalType":"contract ServiceAgreementV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_flag","type":"bool"}],"name":"setOldMetadataClearingFlag","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unfinalizedStateStorage","outputs":[{"internalType":"contract UnfinalizedStateStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"updateAssetState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},44664:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"assetAssertionId","type":"bytes32"}],"name":"assertionExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"deleteAssertionIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deleteAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"generateTokenId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getAssertionIdByIndex","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getAssertionIds","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getAssertionIdsLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint256","name":"assertionIndex","type":"uint256"}],"name":"getAssertionIssuer","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getAsset","outputs":[{"components":[{"internalType":"bool","name":"immutable_","type":"bool"},{"internalType":"bytes32[]","name":"assertionIds","type":"bytes32[]"}],"internalType":"struct ContentAssetStructs.Asset","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getLatestAssertionId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"isMutable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"issuers","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"}],"name":"pushAssertionId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"address","name":"issuer","type":"address"}],"name":"setAssertionIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bool","name":"immutable_","type":"bool"}],"name":"setMutability","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},67448:e=>{"use strict";e.exports=JSON.parse('[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"AssetStorageChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"ContractChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"NewAssetStorage","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractName","type":"string"},{"indexed":false,"internalType":"address","name":"newContractAddress","type":"address"}],"name":"NewContract","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"getAllAssetStorages","outputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"internalType":"struct UnorderedNamedContractDynamicSetLib.Contract[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllContracts","outputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"internalType":"struct UnorderedNamedContractDynamicSetLib.Contract[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"assetStorageName","type":"string"}],"name":"getAssetStorageAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"contractName","type":"string"}],"name":"getContractAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"assetStorageAddress","type":"address"}],"name":"isAssetStorage","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"assetStorageName","type":"string"}],"name":"isAssetStorage","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"selectedContractAddress","type":"address"}],"name":"isContract","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"contractName","type":"string"}],"name":"isContract","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"assetStorageName","type":"string"},{"internalType":"address","name":"assetStorageAddress","type":"address"}],"name":"setAssetStorageAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"contractName","type":"string"},{"internalType":"address","name":"newContractAddress","type":"address"}],"name":"setContractAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},11926:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"paranetKnowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"paranetTokenId","type":"uint256"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"KnowledgeAssetIsAPartOfOtherParanet","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetDoesntExist","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetHasAlreadyBeenRegistered","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetServiceDoesntExist","type":"error"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"paranetServiceId","type":"bytes32"}],"name":"ParanetServiceHasAlreadyBeenAdded","type":"error"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ParanetServiceHasAlreadyBeenRegistered","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"indexed":false,"internalType":"uint256","name":"knowledgeAssetTokenId","type":"uint256"}],"name":"KnowledgeAssetSubmittedToParanet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"string","name":"poolType","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"indexed":false,"internalType":"struct ParanetStructs.IncentivesPool","name":"incentivesPool","type":"tuple"}],"name":"ParanetIncetivesPoolDeployed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"newParanetName","type":"string"},{"indexed":false,"internalType":"string","name":"newParanetDescription","type":"string"}],"name":"ParanetMetadataUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"paranetName","type":"string"},{"indexed":false,"internalType":"string","name":"paranetDescription","type":"string"}],"name":"ParanetRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"indexed":false,"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"}],"name":"ParanetServiceAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"newParanetServiceName","type":"string"},{"indexed":false,"internalType":"string","name":"newParanetServiceDescription","type":"string"},{"indexed":false,"internalType":"address[]","name":"newParanetServiceAddresses","type":"address[]"}],"name":"ParanetServiceMetadataUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"paranetServiceName","type":"string"},{"indexed":false,"internalType":"string","name":"paranetServiceDescription","type":"string"},{"indexed":false,"internalType":"address[]","name":"paranetServiceAddresses","type":"address[]"}],"name":"ParanetServiceRegistered","type":"event"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"internalType":"struct ParanetStructs.UniversalAssetLocator[]","name":"services","type":"tuple[]"}],"name":"addParanetServices","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contentAsset","outputs":[{"internalType":"contract ContentAssetV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contentAssetStorage","outputs":[{"internalType":"contract ContentAssetStorageV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hashingProxy","outputs":[{"internalType":"contract HashingProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint128","name":"size","type":"uint128"},{"internalType":"uint32","name":"triplesNumber","type":"uint32"},{"internalType":"uint96","name":"chunksNumber","type":"uint96"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"bool","name":"immutable_","type":"bool"}],"internalType":"struct ContentAssetStructs.AssetInputArgs","name":"knowledgeAssetArgs","type":"tuple"}],"name":"mintKnowledgeAsset","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"paranetKnowledgeAssetsRegistry","outputs":[{"internalType":"contract ParanetKnowledgeAssetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetKnowledgeMinersRegistry","outputs":[{"internalType":"contract ParanetKnowledgeMinersRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetServicesRegistry","outputs":[{"internalType":"contract ParanetServicesRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"processUpdatedKnowledgeAssetStatesMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"string","name":"paranetName","type":"string"},{"internalType":"string","name":"paranetDescription","type":"string"}],"name":"registerParanet","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"internalType":"string","name":"paranetServiceName","type":"string"},{"internalType":"string","name":"paranetServiceDescription","type":"string"},{"internalType":"address[]","name":"paranetServiceAddresses","type":"address[]"}],"name":"registerParanetService","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"serviceAgreementStorageProxy","outputs":[{"internalType":"contract ServiceAgreementStorageProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_status","type":"bool"}],"name":"setStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"status","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"knowledgeAssetTokenId","type":"uint256"}],"name":"submitKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"string","name":"paranetName","type":"string"},{"internalType":"string","name":"paranetDescription","type":"string"}],"name":"updateParanetMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"paranetServiceKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetServiceKATokenId","type":"uint256"},{"internalType":"string","name":"paranetServiceName","type":"string"},{"internalType":"string","name":"paranetServiceDescription","type":"string"},{"internalType":"address[]","name":"paranetServiceAddresses","type":"address[]"}],"name":"updateParanetServiceMetadata","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},12936:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageAddress","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"poolType","type":"string"},{"internalType":"address","name":"poolAddress","type":"address"}],"name":"ParanetIncentivesPoolAlreadyExists","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"components":[{"internalType":"string","name":"poolType","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"indexed":false,"internalType":"struct ParanetStructs.IncentivesPool","name":"incentivesPool","type":"tuple"}],"name":"ParanetIncetivesPoolDeployed","type":"event"},{"inputs":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"uint256","name":"tracToNeuroEmissionMultiplier","type":"uint256"},{"internalType":"uint16","name":"paranetOperatorRewardPercentage","type":"uint16"},{"internalType":"uint16","name":"paranetIncentivizationProposalVotersRewardPercentage","type":"uint16"}],"name":"deployNeuroIncentivesPool","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_status","type":"bool"}],"name":"setStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"status","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},88767:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"addedCumulativeAwardedNeuro","type":"uint256"}],"name":"addCumulativeAwardedNeuro","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"addedTracSpent","type":"uint96"}],"name":"addCumulativeTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"addSubmittedKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint96","name":"addedTracSpent","type":"uint96"}],"name":"addTotalTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"addedUnrewardedTracSpent","type":"uint96"}],"name":"addUnrewardedTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"addUpdatingKnowledgeAssetState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"},{"internalType":"uint96","name":"addedUpdateTokenAmount","type":"uint96"}],"name":"addUpdatingKnowledgeAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"decrementTotalSubmittedKnowledgeAssetsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"deleteKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getCumulativeAwardedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getCumulativeTracSpent","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"getKnowledgeMinerMetadata","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"totalTracSpent","type":"uint96"},{"internalType":"uint256","name":"totalSubmittedKnowledgeAssetsCount","type":"uint256"}],"internalType":"struct ParanetStructs.KnowledgeMinerMetadata","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getSubmittedKnowledgeAssets","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"getSubmittedKnowledgeAssets","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"getTotalSubmittedKnowledgeAssetsCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"getTotalTracSpent","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getUnrewardedTracSpent","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"getUpdatingKnowledgeAssetStates","outputs":[{"components":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"internalType":"struct ParanetStructs.UpdatingKnowledgeAssetState[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getUpdatingKnowledgeAssetStates","outputs":[{"components":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"internalType":"struct ParanetStructs.UpdatingKnowledgeAssetState[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"incrementTotalSubmittedKnowledgeAssetsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"knowledgeMinerExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"}],"name":"registerKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"removeSubmittedKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"}],"name":"removeUpdatingKnowledgeAssetState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"cumulativeAwardedNeuro","type":"uint256"}],"name":"setCumulativeAwardedNeuro","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"cumulativeTracSpent","type":"uint96"}],"name":"setCumulativeTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint256","name":"totalSubmittedKnowledgeAssetsCount","type":"uint256"}],"name":"setTotalSubmittedKnowledgeAssetsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint96","name":"totalTracSpent","type":"uint96"}],"name":"setTotalTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"unrewardedTracSpent","type":"uint96"}],"name":"setUnrewardedTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"setUpdatingKnowledgeAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"subtractedCumulativeAwardedNeuro","type":"uint256"}],"name":"subCumulativeAwardedNeuro","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"subtractedTracSpent","type":"uint96"}],"name":"subCumulativeTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"uint96","name":"subtractedTracSpent","type":"uint96"}],"name":"subTotalTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"subtractedUnrewardedTracSpent","type":"uint96"}],"name":"subUnrewardedTracSpent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"miner","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetStateId","type":"bytes32"},{"internalType":"uint96","name":"subtractedUpdateTokenAmount","type":"uint96"}],"name":"subUpdatingKnowledgeAssetUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},64004:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"},{"internalType":"address","name":"paranetsRegistryAddress","type":"address"},{"internalType":"address","name":"knowledgeMinersRegistryAddress","type":"address"},{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"tracToNeuroEmissionMultiplier","type":"uint256"},{"internalType":"uint16","name":"paranetOperatorRewardPercentage_","type":"uint16"},{"internalType":"uint16","name":"paranetIncentivizationProposalVotersRewardPercentage_","type":"uint16"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"currentCumulativeWeight","type":"uint96"},{"internalType":"uint96","name":"targetCumulativeWeight","type":"uint96"}],"name":"InvalidCumulativeVotersWeight","type":"error"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"claimer","type":"address"}],"name":"NoRewardAvailable","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldMultiplier","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newMultiplier","type":"uint256"}],"name":"NeuroEmissionMultiplierUpdateFinalized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldMultiplier","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newMultiplier","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"NeuroEmissionMultiplierUpdateInitiated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"NeuroRewardDeposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"voter","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ParanetIncentivizationProposalVoterRewardClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"miner","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ParanetKnowledgeMinerRewardClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ParanetOperatorRewardClaimed","type":"event"},{"inputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"}],"internalType":"struct ParanetStructs.ParanetIncentivizationProposalVoterInput[]","name":"voters_","type":"tuple[]"}],"name":"addVoters","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimIncentivizationProposalVoterReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimKnowledgeMinerReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimParanetOperatorReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"claimedMinerRewards","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"claimedMinerRewardsIndexes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"claimedOperatorRewards","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"claimedOperatorRewardsIndexes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cumulativeVotersWeight","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"finalizeNeuroEmissionMultiplierUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getAllRewardedMiners","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivesPoolClaimedRewardsProfile[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllRewardedOperators","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivesPoolClaimedRewardsProfile[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableAllKnowledgeMinersRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableAllProposalVotersRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableKnowledgeMinerRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableParanetOperatorRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getClaimableProposalVoterRewardAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"getEffectiveNeuroEmissionMultiplier","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNeuroBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNeuroEmissionMultipliers","outputs":[{"components":[{"internalType":"uint256","name":"multiplier","type":"uint256"},{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"bool","name":"finalized","type":"bool"}],"internalType":"struct ParanetStructs.NeuroEmissionMultiplier[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalAllKnowledgeMinersIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalAllProposalVotersIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalKnowledgeMinerIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalParanetOperatorIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalProposalVoterIncentiveEstimation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"voterAddress","type":"address"}],"name":"getVoter","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivizationProposalVoter","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getVoters","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"internalType":"struct ParanetStructs.ParanetIncentivizationProposalVoter[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getVotersCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"newMultiplier","type":"uint256"}],"name":"initiateNeuroEmissionMultiplierUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"isKnowledgeMiner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"isParanetOperator","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"isProposalVoter","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"minerAddress","type":"address"}],"name":"minerClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"neuroEmissionMultiplierUpdateDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"neuroEmissionMultipliers","outputs":[{"internalType":"uint256","name":"multiplier","type":"uint256"},{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"bool","name":"finalized","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"operatorAddress","type":"address"}],"name":"operatorClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetIncentivizationProposalVotersRewardPercentage","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetKnowledgeMinersRegistry","outputs":[{"internalType":"contract ParanetKnowledgeMinersRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetOperatorRewardPercentage","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paranetsRegistry","outputs":[{"internalType":"contract ParanetsRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"parentParanetId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"limit","type":"uint256"}],"name":"removeVoters","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalMinersClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalNeuroReceived","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalOperatorsClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalVotersClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newRegistrar","type":"address"}],"name":"transferVotersRegistrarRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newDelay","type":"uint256"}],"name":"updateNeuroEmissionMultiplierUpdateDelay","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"voterAddress","type":"address"}],"name":"voterClaimedNeuro","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"voters","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint96","name":"weight","type":"uint96"},{"internalType":"uint256","name":"claimedNeuro","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"votersIndexes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"votersRegistrar","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]')},50575:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"addedKnowledgeValue","type":"uint96"}],"name":"addCumulativeKnowledgeValue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"addKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeMinerAddress","type":"address"}],"name":"addKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"serviceId","type":"bytes32"}],"name":"addService","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"deleteParanet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getAllIncentivesPools","outputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"address","name":"addr","type":"address"}],"internalType":"struct UnorderedNamedContractDynamicSetStructs.Contract[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getCumulativeKnowledgeValue","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getDescription","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"}],"name":"getIncentivesPoolAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeAssets","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeAssetsCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"},{"internalType":"uint256","name":"limit","type":"uint256"}],"name":"getKnowledgeAssetsStartingFromKnowledgeAssetId","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint256","name":"offset","type":"uint256"},{"internalType":"uint256","name":"limit","type":"uint256"}],"name":"getKnowledgeAssetsWithPagination","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeMiners","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getKnowledgeMinersCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getName","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getParanetKnowledgeAssetLocator","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getParanetMetadata","outputs":[{"components":[{"internalType":"address","name":"paranetKAStorageContract","type":"address"},{"internalType":"uint256","name":"paranetKATokenId","type":"uint256"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"description","type":"string"},{"internalType":"uint96","name":"cumulativeKnowledgeValue","type":"uint96"}],"internalType":"struct ParanetStructs.ParanetMetadata","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getServices","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"getServicesCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"hasIncentivesPoolByAddress","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"}],"name":"hasIncentivesPoolByType","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract HubV2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"isKnowledgeAssetRegistered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeMinerAddress","type":"address"}],"name":"isKnowledgeMinerRegistered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"serviceId","type":"bytes32"}],"name":"isServiceImplemented","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"}],"name":"paranetExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"knowledgeAssetStorageContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"paranetName","type":"string"},{"internalType":"string","name":"paranetDescription","type":"string"}],"name":"registerParanet","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"removeIncentivesPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"}],"name":"removeIncentivesPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"knowledgeAssetId","type":"bytes32"}],"name":"removeKnowledgeAsset","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"address","name":"knowledgeMinerAddress","type":"address"}],"name":"removeKnowledgeMiner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"bytes32","name":"serviceId","type":"bytes32"}],"name":"removeService","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"cumulativeKnowledgeValue","type":"uint96"}],"name":"setCumulativeKnowledgeValue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"description","type":"string"}],"name":"setDescription","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"setIncentivesPoolAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"name_","type":"string"}],"name":"setName","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"uint96","name":"subtractedKnowledgeValue","type":"uint96"}],"name":"subCumulativeKnowledgeValue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"paranetId","type":"bytes32"},{"internalType":"string","name":"incentivesPoolType","type":"string"},{"internalType":"address","name":"incentivesPoolAddress","type":"address"}],"name":"updateIncentivesPoolAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},26758:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"agreementV1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"agreementV1StorageAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"agreementV1U1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"agreementV1U1StorageAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"commitSubmissionExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"commitV1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"commitV1U1Exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"name":"createV1CommitSubmissionObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint128","name":"epochLength","type":"uint128"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"uint8","name":"proofWindowOffsetPerc","type":"uint8"}],"name":"createV1ServiceAgreementObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"name":"createV1U1CommitSubmissionObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint128","name":"epochLength","type":"uint128"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"},{"internalType":"uint8","name":"proofWindowOffsetPerc","type":"uint8"}],"name":"createV1U1ServiceAgreementObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"decrementAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"decrementCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"deleteAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"deleteCommitSubmissionsObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"deleteCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"deleteServiceAgreementObject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"deleteServiceAgreementV1Object","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"deleteServiceAgreementV1U1Object","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"stateId","type":"bytes32"}],"name":"deleteUpdateCommitsDeadline","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementData","outputs":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint128","name":"epochLength","type":"uint128"},{"internalType":"uint96[2]","name":"tokens","type":"uint96[2]"},{"internalType":"uint8[2]","name":"scoreFunctionIdAndProofWindowOffsetPerc","type":"uint8[2]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementEpochLength","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementEpochsNumber","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementProofWindowOffsetPerc","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getAgreementRewardedNodesNumber","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementScoreFunctionId","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementTokenAmount","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"getAgreementUpdateTokenAmount","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmission","outputs":[{"components":[{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"internalType":"struct ServiceAgreementStructsV1.CommitSubmission","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionIdentityId","outputs":[{"internalType":"uint72","name":"","type":"uint72"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionNextIdentityId","outputs":[{"internalType":"uint72","name":"","type":"uint72"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionPrevIdentityId","outputs":[{"internalType":"uint72","name":"","type":"uint72"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"}],"name":"getCommitSubmissionScore","outputs":[{"internalType":"uint40","name":"","type":"uint40"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"getCommitsCount","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"stateId","type":"bytes32"}],"name":"getUpdateCommitsDeadline","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getV1AgreementEpochSubmissionHead","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"uint256","name":"stateIndex","type":"uint256"}],"name":"getV1U1AgreementEpochSubmissionHead","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"incrementAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"}],"name":"incrementCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"migrateV1ServiceAgreement","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"serviceAgreementExists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint128","name":"epochLength","type":"uint128"}],"name":"setAgreementEpochLength","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"}],"name":"setAgreementEpochsNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint8","name":"proofWindowOffsetPerc","type":"uint8"}],"name":"setAgreementProofWindowOffsetPerc","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"uint32","name":"rewardedNodesNumber","type":"uint32"}],"name":"setAgreementRewardedNodesNumber","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint8","name":"newScoreFunctionId","type":"uint8"}],"name":"setAgreementScoreFunctionId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint256","name":"startTime","type":"uint256"}],"name":"setAgreementStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"setAgreementTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"setAgreementUpdateTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"identityId","type":"uint72"}],"name":"setCommitSubmissionIdentityId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"}],"name":"setCommitSubmissionNextIdentityId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"}],"name":"setCommitSubmissionPrevIdentityId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"commitId","type":"bytes32"},{"internalType":"uint40","name":"score","type":"uint40"}],"name":"setCommitSubmissionScore","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"epochStateId","type":"bytes32"},{"internalType":"uint8","name":"epochStateCommitsCount","type":"uint8"}],"name":"setCommitsCount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"stateId","type":"bytes32"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"setUpdateCommitsDeadline","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"bytes32","name":"headCommitId","type":"bytes32"}],"name":"setV1AgreementEpochSubmissionHead","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"uint256","name":"stateIndex","type":"uint256"},{"internalType":"bytes32","name":"headCommitId","type":"bytes32"}],"name":"setV1U1AgreementEpochSubmissionHead","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"storageV1","outputs":[{"internalType":"contract ServiceAgreementStorageV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"storageV1U1","outputs":[{"internalType":"contract ServiceAgreementStorageV1U1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"transferAgreementTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"transferV1AgreementTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"transferV1U1AgreementTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},60082:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ScoreError","type":"error"},{"inputs":[{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"}],"name":"ScoreFunctionDoesntExist","type":"error"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"TooLowAllowance","type":"error"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"TooLowBalance","type":"error"},{"inputs":[],"name":"ZeroEpochsNumber","type":"error"},{"inputs":[],"name":"ZeroTokenAmount","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"assetContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"keyword","type":"bytes"},{"indexed":false,"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"indexed":false,"internalType":"uint256","name":"startTime","type":"uint256"},{"indexed":false,"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"indexed":false,"internalType":"uint128","name":"epochLength","type":"uint128"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"ServiceAgreementV1Created","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"indexed":false,"internalType":"uint16","name":"epochsNumber","type":"uint16"}],"name":"ServiceAgreementV1Extended","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"indexed":false,"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"ServiceAgreementV1RewardRaised","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"ServiceAgreementV1Terminated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"indexed":false,"internalType":"uint96","name":"updateTokenAmount","type":"uint96"}],"name":"ServiceAgreementV1UpdateRewardRaised","type":"event"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"addTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"addUpdateTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"commitManagerV1","outputs":[{"internalType":"contract CommitManagerV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"commitManagerV1U1","outputs":[{"internalType":"contract CommitManagerV1U1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"assetCreator","type":"address"},{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"keyword","type":"bytes"},{"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"},{"internalType":"uint8","name":"scoreFunctionId","type":"uint8"}],"internalType":"struct ServiceAgreementStructsV1.ServiceAgreementInputArgs","name":"args","type":"tuple"}],"name":"createServiceAgreement","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epochsNumber","type":"uint16"},{"internalType":"uint96","name":"tokenAmount","type":"uint96"}],"name":"extendStoringPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getChallenge","outputs":[{"internalType":"bytes32","name":"assertionId","type":"bytes32"},{"internalType":"uint256","name":"challenge","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"getTopCommitSubmissions","outputs":[{"components":[{"internalType":"uint72","name":"identityId","type":"uint72"},{"internalType":"uint72","name":"prevIdentityId","type":"uint72"},{"internalType":"uint72","name":"nextIdentityId","type":"uint72"},{"internalType":"uint40","name":"score","type":"uint40"}],"internalType":"struct ServiceAgreementStructsV1.CommitSubmission[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hashingProxy","outputs":[{"internalType":"contract HashingProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"isCommitWindowOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"agreementId","type":"bytes32"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"name":"isProofWindowOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"parametersStorage","outputs":[{"internalType":"contract ParametersStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proofManagerV1","outputs":[{"internalType":"contract ProofManagerV1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proofManagerV1U1","outputs":[{"internalType":"contract ProofManagerV1U1","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"scoringProxy","outputs":[{"internalType":"contract ScoringProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"keyword","type":"bytes"},{"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"internalType":"uint16","name":"epoch","type":"uint16"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"internalType":"bytes32","name":"chunkHash","type":"bytes32"}],"internalType":"struct ServiceAgreementStructsV1.ProofInputArgs","name":"args","type":"tuple"}],"name":"sendProof","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"serviceAgreementStorageProxy","outputs":[{"internalType":"contract ServiceAgreementStorageProxy","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_status","type":"bool"}],"name":"setStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"status","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"assetContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"keyword","type":"bytes"},{"internalType":"uint8","name":"hashFunctionId","type":"uint8"},{"internalType":"uint16","name":"epoch","type":"uint16"}],"internalType":"struct ServiceAgreementStructsV1.CommitInputArgs","name":"args","type":"tuple"}],"name":"submitCommit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"assetOwner","type":"address"},{"internalType":"bytes32","name":"agreementId","type":"bytes32"}],"name":"terminateAgreement","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"tokenContract","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},65177:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"string","name":"tokenName","type":"string"},{"internalType":"string","name":"tokenSymbol","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"minter","type":"address"}],"name":"setupRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]')},74066:e=>{"use strict";e.exports=JSON.parse('[{"inputs":[{"internalType":"address","name":"hubAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deleteIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deleteUnfinalizedState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getIssuer","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getUnfinalizedState","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"hasPendingUpdate","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hub","outputs":[{"internalType":"contract Hub","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"issuer","type":"address"}],"name":"setIssuer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"state","type":"bytes32"}],"name":"setUnfinalizedState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"}]')},18597:e=>{"use strict";e.exports={i8:"6.5.4"}},22562:e=>{"use strict";e.exports=JSON.parse('{"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}')}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={id:n,loaded:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.loaded=!0,o.exports}r.amdO={},r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var n=r(46010);DKG=n})(); \ No newline at end of file diff --git a/managers/asset-operations-manager.js b/managers/asset-operations-manager.js index 444d737..7e3ccd2 100644 --- a/managers/asset-operations-manager.js +++ b/managers/asset-operations-manager.js @@ -9,6 +9,7 @@ const { sleepForMilliseconds, } = require('../services/utilities.js'); const { + ASSET_STATES, CONTENT_TYPES, OPERATIONS, OPERATIONS_STEP_STATUS, @@ -16,12 +17,12 @@ const { OPERATION_STATUSES, DEFAULT_GET_LOCAL_STORE_RESULT_FREQUENCY, PRIVATE_ASSERTION_PREDICATE, + STORE_TYPES, QUERY_TYPES, OT_NODE_TRIPLE_STORE_REPOSITORIES, ZERO_ADDRESS, } = require('../constants.js'); const emptyHooks = require('../util/empty-hooks'); -const { STORE_TYPES, ASSET_STATES } = require('../constants'); class AssetOperationsManager { constructor(services) { @@ -149,10 +150,14 @@ class AssetOperationsManager { ); } - return { - transactionHash: receipt.transactionHash, - status: receipt.status, - }; + if (receipt) { + return { + transactionHash: receipt.transactionHash, + status: receipt.status, + }; + } + + return { status: 'Skipped: Allowance is already equal to the requested amount.' }; } /** @@ -637,9 +642,10 @@ class AssetOperationsManager { } if (contentType !== CONTENT_TYPES.PUBLIC) { - const privateAssertionLinkTriple = publicAssertion.filter((element) => + const filteredTriples = publicAssertion.filter((element) => element.includes(PRIVATE_ASSERTION_PREDICATE), - )[0]; + ); + const privateAssertionLinkTriple = filteredTriples.length > 0 ? filteredTriples[0] : null; let queryPrivateOperationId; let queryPrivateOperationResult = {}; diff --git a/managers/paranet-operations-manager.js b/managers/paranet-operations-manager.js index 0d5732b..89ce36b 100644 --- a/managers/paranet-operations-manager.js +++ b/managers/paranet-operations-manager.js @@ -251,6 +251,7 @@ class ParanetOperationsManager { ); const receipt = await this.blockchainService.claimVoterReward(paranetId, blockchain); + return { transactionHash: receipt.transactionHash, status: receipt.status, @@ -279,6 +280,7 @@ class ParanetOperationsManager { ); const receipt = await this.blockchainService.claimOperatorReward(paranetId, blockchain); + return { transactionHash: receipt.transactionHash, status: receipt.status, diff --git a/package-lock.json b/package-lock.json index 2a23bd2..a904436 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "dkg.js", - "version": "6.5.1", + "version": "6.5.2", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "dkg.js", - "version": "6.5.1", + "version": "6.5.2", "license": "Apache-2.0", "dependencies": { "assertion-tools": "^2.1.0", diff --git a/package.json b/package.json index 1b2c4f7..d0372ec 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "dkg.js", - "version": "6.5.1", + "version": "6.5.2", "description": "Javascript library for interaction with the OriginTrail Decentralized Knowledge Graph", "main": "index.js", "scripts": { diff --git a/services/blockchain-service/blockchain-service-base.js b/services/blockchain-service/blockchain-service-base.js index 7bc50c8..2854578 100644 --- a/services/blockchain-service/blockchain-service-base.js +++ b/services/blockchain-service/blockchain-service-base.js @@ -58,7 +58,37 @@ class BlockchainServiceBase { // overridden by subclasses } + async ensureBlockchainInfo(blockchain) { + if (!this[blockchain.name]) { + this[blockchain.name] = { + contracts: { [blockchain.hubContract]: {} }, + contractAddresses: { + [blockchain.hubContract]: { + Hub: blockchain.hubContract, + }, + }, + }; + + const web3Instance = await this.getWeb3Instance(blockchain); + this[blockchain.name].contracts[blockchain.hubContract].Hub = + new web3Instance.eth.Contract(this.abis.Hub, blockchain.hubContract, { from: blockchain.publicKey }); + + } + } + + async getWeb3Instance(blockchain) { + if (!this[blockchain.name].web3) { + const blockchainOptions = { + transactionPollingTimeout: blockchain.transactionPollingTimeout, + }; + await this.initializeWeb3(blockchain.name, blockchain.rpc, blockchainOptions); + } + + return this[blockchain.name].web3; + } + async getNetworkGasPrice(blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3Instance = await this.getWeb3Instance(blockchain); try { @@ -99,7 +129,9 @@ class BlockchainServiceBase { } async callContractFunction(contractName, functionName, args, blockchain) { + await this.ensureBlockchainInfo(blockchain); let contractInstance = await this.getContractInstance(contractName, blockchain); + try { return await contractInstance.methods[functionName](...args).call(); } catch (error) { @@ -124,22 +156,59 @@ class BlockchainServiceBase { } async prepareTransaction(contractInstance, functionName, args, blockchain) { + await this.ensureBlockchainInfo(blockchain); + const web3Instance = await this.getWeb3Instance(blockchain); const publicKey = await this.getPublicKey(blockchain); - const gasLimit = await contractInstance.methods[functionName](...args).estimateGas({ - from: publicKey, - }); - const encodedABI = await contractInstance.methods[functionName](...args).encodeABI(); - let gasPrice = Number( - blockchain.previousTxGasPrice || - blockchain.gasPrice || - (await this.getNetworkGasPrice(blockchain)), + let gasLimit = Number( + await contractInstance.methods[functionName](...args).estimateGas({ + from: publicKey, + }) ); + gasLimit = Math.round(gasLimit * blockchain.gasLimitMultiplier); + + let gasPrice; + if (blockchain.previousTxGasPrice && blockchain.retryTx) { + // Increase previous tx gas price by 20% + gasPrice = Math.round(blockchain.previousTxGasPrice * 1.2); + } else if (blockchain.forceReplaceTxs) { + // Get the current transaction count (nonce) of the wallet, including pending transactions + const currentNonce = await web3Instance.eth.getTransactionCount(publicKey, 'pending'); - if (blockchain.retryTx) { - // Increase gas price by 20% - gasPrice = Math.round(gasPrice * 1.2); + // Get the transaction count of the wallet excluding pending transactions + const confirmedNonce = await web3Instance.eth.getTransactionCount(publicKey, 'latest'); + + // If there are any pending transactions + if (currentNonce > confirmedNonce) { + const pendingBlock = await web3Instance.eth.getBlock('pending', true); + + // Search for pending tx in the pending block + const pendingTx = Object.values(pendingBlock.transactions).find( + tx => tx.from.toLowerCase() === publicKey.toLowerCase() && tx.nonce === confirmedNonce + ); + + if (pendingTx) { + // If found, increase gas price of pending tx by 20% + gasPrice = Math.round(Number(pendingTx.gasPrice) * 1.2); + } else { + // If not found, use default/network gas price increased by 20% + // Theoretically this should never happen + gasPrice = Math.round((blockchain.gasPrice || (await this.getNetworkGasPrice(blockchain))) * 1.2); + } + } + } else { + gasPrice = blockchain.gasPrice || (await this.getNetworkGasPrice(blockchain)); + } + + if (blockchain.simulateTxs) { + await web3Instance.eth.call({ + to: contractInstance.options.address, + data: encodedABI, + from: publicKey, + gasPrice, + gas: gasLimit, + }); } return { @@ -151,41 +220,8 @@ class BlockchainServiceBase { }; } - ensureBlockchainInfo(blockchain) { - if (!this[blockchain.name]) { - this[blockchain.name] = { - contracts: { [blockchain.hubContract]: {} }, - contractAddresses: { - [blockchain.hubContract]: { - Hub: blockchain.hubContract, - }, - }, - }; - } - } - - async getWeb3Instance(blockchain) { - this.ensureBlockchainInfo(blockchain); - if (!this[blockchain.name].web3) { - const blockchainOptions = { - transactionPollingTimeout: blockchain.transactionPollingTimeout, - }; - await this.initializeWeb3(blockchain.name, blockchain.rpc, blockchainOptions); - } - - return this[blockchain.name].web3; - } - async getContractAddress(contractName, blockchain, force = false) { - this.ensureBlockchainInfo(blockchain); - if (!this[blockchain.name].contracts[blockchain.hubContract]) { - this[blockchain.name].contracts[blockchain.hubContract] = {}; - } - if (!this[blockchain.name].contracts[blockchain.hubContract].Hub) { - const web3Instance = await this.getWeb3Instance(blockchain); - this[blockchain.name].contracts[blockchain.hubContract].Hub = - new web3Instance.eth.Contract(this.abis.Hub, blockchain.hubContract, { from: blockchain.publicKey }); - } + await this.ensureBlockchainInfo(blockchain); if ( force || @@ -205,13 +241,9 @@ class BlockchainServiceBase { } async updateContractInstance(contractName, blockchain, force = false) { - this.ensureBlockchainInfo(blockchain); - if ( - force || - !this[blockchain.name].contractAddresses[blockchain.hubContract][contractName] - ) { - this[blockchain.name].contractAddresses[blockchain.hubContract][contractName] = await this.getContractAddress(contractName, blockchain, force); - } + await this.ensureBlockchainInfo(blockchain); + await this.getContractAddress(contractName, blockchain, force); + if (force || !this[blockchain.name].contracts[blockchain.hubContract][contractName]) { const web3Instance = await this.getWeb3Instance(blockchain); this[blockchain.name].contracts[blockchain.hubContract][contractName] = @@ -228,37 +260,61 @@ class BlockchainServiceBase { return this[blockchain.name].contracts[blockchain.hubContract][contractName]; } - // Knowledge assets operations - - async createAsset(requestData, paranetKaContract, paranetTokenId, blockchain, stepHooks = emptyHooks) { - const serviceAgreementV1Address = await this.getContractAddress( - 'ServiceAgreementV1', - blockchain, - ); - + async increaseServiceAgreementV1Allowance(sender, serviceAgreementV1Address, tokenAmount, blockchain) { const allowance = await this.callContractFunction( 'Token', 'allowance', - [await this.getPublicKey(blockchain), serviceAgreementV1Address], + [sender, serviceAgreementV1Address], blockchain, ); - const tokensNeeded = BigInt(requestData.tokenAmount) - BigInt(allowance); + const allowanceGap = BigInt(tokenAmount) - BigInt(allowance); - if (tokensNeeded > 0) { + if (allowanceGap > 0) { await this.executeContractFunction( 'Token', 'increaseAllowance', - [serviceAgreementV1Address, tokensNeeded], + [serviceAgreementV1Address, allowanceGap], blockchain, ); + return { + allowanceIncreased: true, + allowanceGap, + }; + } + + return { + allowanceIncreased: false, + allowanceGap, + } + } + + // Knowledge assets operations + + async createAsset(requestData, paranetKaContract, paranetTokenId, blockchain, stepHooks = emptyHooks) { + const sender = await this.getPublicKey(blockchain); + let serviceAgreementV1Address; + let allowanceIncreased = false; + let allowanceGap = 0; + + try { + serviceAgreementV1Address = await this.getContractAddress( + 'ServiceAgreementV1', + blockchain, + ); + + ({ allowanceIncreased, allowanceGap } = await this.increaseServiceAgreementV1Allowance( + sender, + serviceAgreementV1Address, + requestData.tokenAmount, + blockchain + )); + stepHooks.afterHook({ status: OPERATIONS_STEP_STATUS.INCREASE_ALLOWANCE_COMPLETED, }); - } - try { let receipt; if(paranetKaContract == null && paranetTokenId == null) { receipt = await this.executeContractFunction( @@ -287,11 +343,11 @@ class BlockchainServiceBase { return tokenId; } catch (error) { - if (tokensNeeded > 0) { + if (allowanceIncreased) { await this.executeContractFunction( 'Token', 'decreaseAllowance', - [serviceAgreementV1Address, tokensNeeded], + [serviceAgreementV1Address, allowanceGap], blockchain, ); } @@ -308,30 +364,24 @@ class BlockchainServiceBase { tokenAmount, blockchain, ) { - const serviceAgreementV1Address = await this.getContractAddress( - 'ServiceAgreementV1', - blockchain, - ); + const sender = await this.getPublicKey(blockchain); + let serviceAgreementV1Address; + let allowanceIncreased = false; + let allowanceGap = 0; - const allowance = await this.callContractFunction( - 'Token', - 'allowance', - [await this.getPublicKey(blockchain), serviceAgreementV1Address], - blockchain, - ); - - const tokensNeeded = BigInt(tokenAmount) - BigInt(allowance); - - if (tokensNeeded > 0) { - await this.executeContractFunction( - 'Token', - 'increaseAllowance', - [serviceAgreementV1Address, tokensNeeded], + try { + serviceAgreementV1Address = await this.getContractAddress( + 'ServiceAgreementV1', blockchain, ); - } - try { + ({ allowanceIncreased, allowanceGap } = await this.increaseServiceAgreementV1Allowance( + sender, + serviceAgreementV1Address, + tokenAmount, + blockchain + )); + return this.executeContractFunction( 'ContentAsset', 'updateAssetState', @@ -346,11 +396,11 @@ class BlockchainServiceBase { blockchain, ); } catch (error) { - if (tokensNeeded > 0) { + if (allowanceIncreased) { await this.executeContractFunction( 'Token', 'decreaseAllowance', - [serviceAgreementV1Address, tokensNeeded], + [serviceAgreementV1Address, allowanceGap], blockchain, ); } @@ -403,95 +453,116 @@ class BlockchainServiceBase { } async extendAssetStoringPeriod(tokenId, epochsNumber, tokenAmount, blockchain) { - const serviceAgreementV1Address = await this.getContractAddress( - 'ServiceAgreementV1', - blockchain, - ); - - await this.executeContractFunction( - 'Token', - 'increaseAllowance', - [serviceAgreementV1Address, tokenAmount], - blockchain, - ); + const sender = await this.getPublicKey(blockchain); + let serviceAgreementV1Address; + let allowanceIncreased = false; + let allowanceGap = 0; try { + serviceAgreementV1Address = await this.getContractAddress( + 'ServiceAgreementV1', + blockchain, + ); + + ({ allowanceIncreased, allowanceGap } = await this.increaseServiceAgreementV1Allowance( + sender, + serviceAgreementV1Address, + tokenAmount, + blockchain + )); + return this.executeContractFunction( 'ContentAsset', 'extendAssetStoringPeriod', [tokenId, epochsNumber, tokenAmount], blockchain, ); - } catch (e) { - await this.executeContractFunction( - 'Token', - 'decreaseAllowance', - [serviceAgreementV1Address, tokenAmount], - blockchain, - ); - throw e; + } catch (error) { + if (allowanceIncreased) { + await this.executeContractFunction( + 'Token', + 'decreaseAllowance', + [serviceAgreementV1Address, allowanceGap], + blockchain, + ); + } + throw error; } } async addTokens(tokenId, tokenAmount, blockchain) { - const serviceAgreementV1Address = await this.getContractAddress( - 'ServiceAgreementV1', - blockchain, - ); - - await this.executeContractFunction( - 'Token', - 'increaseAllowance', - [serviceAgreementV1Address, tokenAmount], - blockchain, - ); + const sender = await this.getPublicKey(blockchain); + let serviceAgreementV1Address; + let allowanceIncreased = false; + let allowanceGap = 0; try { + serviceAgreementV1Address = await this.getContractAddress( + 'ServiceAgreementV1', + blockchain, + ); + + ({ allowanceIncreased, allowanceGap } = await this.increaseServiceAgreementV1Allowance( + sender, + serviceAgreementV1Address, + tokenAmount, + blockchain + )); + return this.executeContractFunction( 'ContentAsset', 'increaseAssetTokenAmount', [tokenId, tokenAmount], blockchain, ); - } catch (e) { - await this.executeContractFunction( - 'Token', - 'decreaseAllowance', - [serviceAgreementV1Address, tokenAmount], - blockchain, - ); - throw e; + } catch (error) { + if (allowanceIncreased) { + await this.executeContractFunction( + 'Token', + 'decreaseAllowance', + [serviceAgreementV1Address, allowanceGap], + blockchain, + ); + } + throw error; } } async addUpdateTokens(tokenId, tokenAmount, blockchain) { - const serviceAgreementV1Address = await this.getContractAddress( - 'ServiceAgreementV1', - blockchain, - ); - - await this.executeContractFunction( - 'Token', - 'increaseAllowance', - [serviceAgreementV1Address, tokenAmount], - blockchain, - ); + const sender = await this.getPublicKey(blockchain); + let serviceAgreementV1Address; + let allowanceIncreased = false; + let allowanceGap = 0; try { + serviceAgreementV1Address = await this.getContractAddress( + 'ServiceAgreementV1', + blockchain, + ); + + ({ allowanceIncreased, allowanceGap } = await this.increaseServiceAgreementV1Allowance( + sender, + serviceAgreementV1Address, + tokenAmount, + blockchain + )); + return this.executeContractFunction( 'ContentAsset', 'increaseAssetUpdateTokenAmount', [tokenId, tokenAmount], blockchain, ); - } catch (e) { - await this.executeContractFunction( - 'Token', - 'decreaseAllowance', - [serviceAgreementV1Address, tokenAmount], - blockchain, - ); - throw e; + } catch (error) { + if (allowanceIncreased) { + await this.executeContractFunction( + 'Token', + 'decreaseAllowance', + [serviceAgreementV1Address, allowanceGap], + blockchain, + ); + } + throw error; } } @@ -635,11 +706,13 @@ class BlockchainServiceBase { } async setIncentivesPool(contractAddress, blockchain){ - const web3Instance = await this.getWeb3Instance(blockchain); + await this.ensureBlockchainInfo(blockchain); + // eslint-disable-next-line dot-notation if (this[blockchain.name].contractAddresses[blockchain.hubContract]['ParanetNeuroIncentivesPool'] !== contractAddress) { // eslint-disable-next-line dot-notation this[blockchain.name].contractAddresses[blockchain.hubContract]['ParanetNeuroIncentivesPool'] = contractAddress; + const web3Instance = await this.getWeb3Instance(blockchain); // eslint-disable-next-line dot-notation this[blockchain.name].contracts[blockchain.hubContract]['ParanetNeuroIncentivesPool'] = await new web3Instance.eth.Contract( @@ -798,6 +871,7 @@ class BlockchainServiceBase { // Blockchain operations async getChainId(blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3Instance = await this.getWeb3Instance(blockchain); return web3Instance.eth.getChainId(); @@ -811,6 +885,7 @@ class BlockchainServiceBase { } async getGasPrice(blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3Instance = await this.getWeb3Instance(blockchain); try { let gasPrice; @@ -847,6 +922,7 @@ class BlockchainServiceBase { } async getWalletBalances(blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3Instance = await this.getWeb3Instance(blockchain); const publicKey = await this.getPublicKey(blockchain); @@ -865,6 +941,7 @@ class BlockchainServiceBase { } async getLatestBlock(blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3 = await this.getWeb3Instance(blockchain); const blockNumber = await web3.eth.getBlockNumber(); diff --git a/services/blockchain-service/implementations/browser-blockchain-service.js b/services/blockchain-service/implementations/browser-blockchain-service.js index 2d4b7a3..a79b26f 100644 --- a/services/blockchain-service/implementations/browser-blockchain-service.js +++ b/services/blockchain-service/implementations/browser-blockchain-service.js @@ -37,25 +37,33 @@ class BrowserBlockchainService extends BlockchainServiceBase { } async decodeEventLogs(receipt, eventName, blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3Instance = await this.getWeb3Instance(blockchain); let result; const { hash, inputs } = this.events[eventName]; - Object.values(receipt.events).forEach((row) => { - if (row.raw.topics[0] === hash) + + const logs = Object.values(receipt.events); + for (const log of logs) { + if (log.raw.topics && log.raw.topics.length > 0 && log.raw.topics[0] === hash) { result = web3Instance.eth.abi.decodeLog( inputs, - row.raw.data, - row.raw.topics.slice(1), + log.raw.data, + log.raw.topics.slice(1), ); - }); + break; + } + } return result; } async executeContractFunction(contractName, functionName, args, blockchain) { + await this.ensureBlockchainInfo(blockchain); let contractInstance = await this.getContractInstance(contractName, blockchain); - const tx = await this.prepareTransaction(contractInstance, functionName, args, blockchain); + let tx; try { + tx = await this.prepareTransaction(contractInstance, functionName, args, blockchain); + return await contractInstance.methods[functionName](...args).send(tx); } catch (error) { if (/revert|VM Exception/i.test(error.message)) { @@ -69,6 +77,13 @@ class BrowserBlockchainService extends BlockchainServiceBase { if (!status) { await this.updateContractInstance(contractName, blockchain, true); contractInstance = await this.getContractInstance(contractName, blockchain); + const web3Instance = await this.getWeb3Instance(blockchain); + + await web3Instance.eth.call({ + to: contractInstance.options.address, + data: tx.data, + from: tx.from, + }); return contractInstance.methods[functionName](...args).send(tx); } diff --git a/services/blockchain-service/implementations/node-blockchain-service.js b/services/blockchain-service/implementations/node-blockchain-service.js index 8b02900..0c7434b 100644 --- a/services/blockchain-service/implementations/node-blockchain-service.js +++ b/services/blockchain-service/implementations/node-blockchain-service.js @@ -37,13 +37,17 @@ class NodeBlockchainService extends BlockchainServiceBase { } async decodeEventLogs(receipt, eventName, blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3Instance = await this.getWeb3Instance(blockchain); let result; const { hash, inputs } = this.events[eventName]; - receipt.logs.forEach((row) => { - if (row.topics[0] === hash) - result = web3Instance.eth.abi.decodeLog(inputs, row.data, row.topics.slice(1)); - }); + + for (const log of receipt.logs) { + if (log.topics && log.topics.length > 0 && log.topics[0] === hash) { + result = web3Instance.eth.abi.decodeLog(inputs, log.data, log.topics.slice(1)); + break; + } + } return result; } @@ -52,11 +56,13 @@ class NodeBlockchainService extends BlockchainServiceBase { } async executeContractFunction(contractName, functionName, args, blockchain) { + await this.ensureBlockchainInfo(blockchain); const web3Instance = await this.getWeb3Instance(blockchain); let contractInstance = await this.getContractInstance(contractName, blockchain); let result; let previousTxGasPrice; + let simulationSucceeded = false; let transactionRetried = false; while (result === undefined) { @@ -69,6 +75,8 @@ class NodeBlockchainService extends BlockchainServiceBase { blockchain, ); previousTxGasPrice = tx.gasPrice; + simulationSucceeded = true; + // eslint-disable-next-line no-await-in-loop const createdTransaction = await web3Instance.eth.accounts.signTransaction( tx, @@ -81,6 +89,7 @@ class NodeBlockchainService extends BlockchainServiceBase { ); } catch (error) { if ( + simulationSucceeded && !transactionRetried && blockchain.handleNotMinedError && TRANSACTION_RETRY_ERRORS.some((errorMsg) => diff --git a/services/input-service.js b/services/input-service.js index 7f89840..ef174ce 100644 --- a/services/input-service.js +++ b/services/input-service.js @@ -135,12 +135,24 @@ class InputService { options.blockchain?.handleNotMinedError ?? this.config.blockchain?.handleNotMinedError ?? DEFAULT_PARAMETERS.HANDLE_NOT_MINED_ERROR; + const gasLimitMultiplier = + options.blockchain?.gasLimitMultiplier ?? + this.config.blockchain?.gasLimitMultiplier ?? + DEFAULT_PARAMETERS.GAS_LIMIT_MULTIPLIER; const gasPrice = options.blockchain?.gasPrice ?? this.config.blockchain?.gasPrice ?? undefined; const transactionPollingTimeout = options.blockchain?.transactionPollingTimeout ?? this.config.blockchain?.transactionPollingTimeout ?? null; + const simulateTxs = + options.blockchain?.simulateTxs ?? + this.config.blockchain?.simulateTxs ?? + DEFAULT_PARAMETERS.SIMULATE_TXS; + const forceReplaceTxs = + options.blockchain?.forceReplaceTxs ?? + this.config.blockchain?.forceReplaceTxs ?? + DEFAULT_PARAMETERS.FORCE_REPLACE_TXS; const gasPriceOracleLink = options.blockchain?.gasPriceOracleLink ?? this.config.blockchain?.gasPriceOracleLink ?? @@ -153,9 +165,12 @@ class InputService { hubContract, publicKey, privateKey, + gasLimitMultiplier, gasPrice, transactionPollingTimeout, handleNotMinedError, + simulateTxs, + forceReplaceTxs, gasPriceOracleLink, }; } diff --git a/util/empty-hooks.js b/util/empty-hooks.js index bb7b039..f5e2454 100644 --- a/util/empty-hooks.js +++ b/util/empty-hooks.js @@ -3,6 +3,7 @@ * in case user doesn't provide his own implementation * @type {{emptyHooks: exports.emptyHooks}} */ +// TODO: Either to be deprecated or added to all operations module.exports = { afterHook: () => {}, };