text: (function (root, factory) {(typeof module === 'object' && module.exports) ? module.exports = factory() : root.Multiaddr = factory()}(typeof self !== 'undefined' ? self : this, function () {
  var Multiaddr=(()=>{var o=(e,n)=>()=>(n||e((n={exports:{}}).exports,n),n.exports);var Ve=o((gr,Oe)=>{"use strict";var Re="[a-fA-F\\d:]",C=e=>e&&e.includeBoundaries?`(?:(?<=\\s|^)(?=${Re})|(?<=${Re})(?=\\s|$))`:"",m="(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}",x="[a-fA-F\\d]{1,4}",W=`
  (?:
  (?:${x}:){7}(?:${x}|:)|                                    // 1:2:3:4:5:6:7::  1:2:3:4:5:6:7:8
  (?:${x}:){6}(?:${m}|:${x}|:)|                             // 1:2:3:4:5:6::    1:2:3:4:5:6::8   1:2:3:4:5:6::8  1:2:3:4:5:6::1.2.3.4
  (?:${x}:){5}(?::${m}|(?::${x}){1,2}|:)|                   // 1:2:3:4:5::      1:2:3:4:5::7:8   1:2:3:4:5::8    1:2:3:4:5::7:1.2.3.4
  (?:${x}:){4}(?:(?::${x}){0,1}:${m}|(?::${x}){1,3}|:)| // 1:2:3:4::        1:2:3:4::6:7:8   1:2:3:4::8      1:2:3:4::6:7:1.2.3.4
  (?:${x}:){3}(?:(?::${x}){0,2}:${m}|(?::${x}){1,4}|:)| // 1:2:3::          1:2:3::5:6:7:8   1:2:3::8        1:2:3::5:6:7:1.2.3.4
  (?:${x}:){2}(?:(?::${x}){0,3}:${m}|(?::${x}){1,5}|:)| // 1:2::            1:2::4:5:6:7:8   1:2::8          1:2::4:5:6:7:1.2.3.4
  (?:${x}:){1}(?:(?::${x}){0,4}:${m}|(?::${x}){1,6}|:)| // 1::              1::3:4:5:6:7:8   1::8            1::3:4:5:6:7:1.2.3.4
  (?::(?:(?::${x}){0,5}:${m}|(?::${x}){1,7}|:))             // ::2:3:4:5:6:7:8  ::2:3:4:5:6:7:8  ::8             ::1.2.3.4
  )(?:%[0-9a-zA-Z]{1,})?                                             // %eth0            %1
  `.replace(/\s*\/\/.*$/gm,"").replace(/\n/g,"").trim(),Zt=new RegExp(`(?:^${m}$)|(?:^${W}$)`),Wt=new RegExp(`^${m}$`),Ht=new RegExp(`^${W}$`),ke=e=>e&&e.exact?Zt:new RegExp(`(?:${C(e)}${m}${C(e)})|(?:${C(e)}${W}${C(e)})`,"g");ke.v4=e=>e&&e.exact?Wt:new RegExp(`${C(e)}${m}${C(e)}`,"g");ke.v6=e=>e&&e.exact?Ht:new RegExp(`${C(e)}${W}${C(e)}`,"g");Oe.exports=ke});var Pe=o((wr,Le)=>{"use strict";var de=Ve(),z=e=>de({exact:!0}).test(e);z.v4=e=>de.v4({exact:!0}).test(e);z.v6=e=>de.v6({exact:!0}).test(e);z.version=e=>z(e)?z.v4(e)?4:6:void 0;Le.exports=z});var Je=o((mr,Ge)=>{"use strict";function Yt(e){if(e.length>=255)throw new TypeError("Alphabet too long");for(var n=new Uint8Array(256),t=0;t<n.length;t++)n[t]=255;for(var s=0;s<e.length;s++){var r=e.charAt(s),i=r.charCodeAt(0);if(n[i]!==255)throw new TypeError(r+" is ambiguous");n[i]=s}var b=e.length,c=e.charAt(0),$=Math.log(b)/Math.log(256),p=Math.log(256)/Math.log(b);function Q(a){if(a instanceof Uint8Array||(ArrayBuffer.isView(a)?a=new Uint8Array(a.buffer,a.byteOffset,a.byteLength):Array.isArray(a)&&(a=Uint8Array.from(a))),!(a instanceof Uint8Array))throw new TypeError("Expected Uint8Array");if(a.length===0)return"";for(var d=0,M=0,g=0,E=a.length;g!==E&&a[g]===0;)g++,d++;for(var A=(E-g)*p+1>>>0,h=new Uint8Array(A);g!==E;){for(var S=a[g],N=0,w=A-1;(S!==0||N<M)&&w!==-1;w--,N++)S+=256*h[w]>>>0,h[w]=S%b>>>0,S=S/b>>>0;if(S!==0)throw new Error("Non-zero carry");M=N,g++}for(var T=A-M;T!==A&&h[T]===0;)T++;for(var Z=c.repeat(d);T<A;++T)Z+=e.charAt(h[T]);return Z}function De(a){if(typeof a!="string")throw new TypeError("Expected String");if(a.length===0)return new Uint8Array;var d=0;if(a[d]!==" "){for(var M=0,g=0;a[d]===c;)M++,d++;for(var E=(a.length-d)*$+1>>>0,A=new Uint8Array(E);a[d];){var h=n[a.charCodeAt(d)];if(h===255)return;for(var S=0,N=E-1;(h!==0||S<g)&&N!==-1;N--,S++)h+=b*A[N]>>>0,A[N]=h%256>>>0,h=h/256>>>0;if(h!==0)throw new Error("Non-zero carry");g=S,d++}if(a[d]!==" "){for(var w=E-g;w!==E&&A[w]===0;)w++;for(var T=new Uint8Array(M+(E-w)),Z=M;w!==E;)T[Z++]=A[w++];return T}}}function Qt(a){var d=De(a);if(d)return d;throw new Error("Non-base"+b+" character")}return{encode:Q,decodeUnsafe:De,decode:Qt}}Ge.exports=Yt});var H=o((yr,Ke)=>{"use strict";var _t=new TextDecoder,es=e=>_t.decode(e),ns=new TextEncoder,ts=e=>ns.encode(e);function ss(e,n){let t=new Uint8Array(n),s=0;for(let r of e)t.set(r,s),s+=r.length;return t}Ke.exports={decodeText:es,encodeText:ts,concat:ss}});var Ze=o((vr,Xe)=>{"use strict";var{encodeText:rs}=H(),Qe=class{constructor(n,t,s,r){this.name=n,this.code=t,this.codeBuf=rs(this.code),this.alphabet=r,this.codec=s(r)}encode(n){return this.codec.encode(n)}decode(n){for(let t of n)if(this.alphabet&&this.alphabet.indexOf(t)<0)throw new Error(`invalid character '${t}' in '${n}'`);return this.codec.decode(n)}};Xe.exports=Qe});var He=o((Er,We)=>{"use strict";var is=(e,n,t)=>{let s={};for(let p=0;p<n.length;++p)s[n[p]]=p;let r=e.length;for(;e[r-1]==="=";)--r;let i=new Uint8Array(r*t/8|0),b=0,c=0,$=0;for(let p=0;p<r;++p){let Q=s[e[p]];if(Q===void 0)throw new SyntaxError("Invalid character "+e[p]);c=c<<t|Q,b+=t,b>=8&&(b-=8,i[$++]=255&c>>b)}if(b>=t||255&c<<8-b)throw new SyntaxError("Unexpected end of data");return i},bs=(e,n,t)=>{let s=n[n.length-1]==="=",r=(1<<t)-1,i="",b=0,c=0;for(let $=0;$<e.length;++$)for(c=c<<8|e[$],b+=8;b>t;)b-=t,i+=n[r&c>>b];if(b&&(i+=n[r&c<<t-b]),s)for(;i.length*t&7;)i+="=";return i},os=e=>n=>({encode(t){return bs(t,n,e)},decode(t){return is(t,n,e)}});We.exports={rfc4648:os}});var nn=o((Ar,Ye)=>{"use strict";var P=Je(),as=Ze(),{rfc4648:l}=He(),{decodeText:cs,encodeText:xs}=H(),ls=()=>({encode:cs,decode:xs}),_e=[["identity","\0",ls,""],["base2","0",l(1),"01"],["base8","7",l(3),"01234567"],["base10","9",P,"0123456789"],["base16","f",l(4),"0123456789abcdef"],["base16upper","F",l(4),"0123456789ABCDEF"],["base32hex","v",l(5),"0123456789abcdefghijklmnopqrstuv"],["base32hexupper","V",l(5),"0123456789ABCDEFGHIJKLMNOPQRSTUV"],["base32hexpad","t",l(5),"0123456789abcdefghijklmnopqrstuv="],["base32hexpadupper","T",l(5),"0123456789ABCDEFGHIJKLMNOPQRSTUV="],["base32","b",l(5),"abcdefghijklmnopqrstuvwxyz234567"],["base32upper","B",l(5),"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"],["base32pad","c",l(5),"abcdefghijklmnopqrstuvwxyz234567="],["base32padupper","C",l(5),"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567="],["base32z","h",l(5),"ybndrfg8ejkmcpqxot1uwisza345h769"],["base36","k",P,"0123456789abcdefghijklmnopqrstuvwxyz"],["base36upper","K",P,"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"],["base58btc","z",P,"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"],["base58flickr","Z",P,"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"],["base64","m",l(6),"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],["base64pad","M",l(6),"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],["base64url","u",l(6),"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],["base64urlpad","U",l(6),"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_="]],en=_e.reduce((e,n)=>(e[n[0]]=new as(n[0],n[1],n[2],n[3]),e),{}),ks=_e.reduce((e,n)=>(e[n[1]]=en[n[0]],e),{});Ye.exports={names:en,codes:ks}});var F=o((q,tn)=>{"use strict";var B=nn(),{encodeText:ds,decodeText:Y,concat:sn}=H();function hs(e,n){if(!n)throw new Error("requires an encoded Uint8Array");let{name:t,codeBuf:s}=j(e);return us(t,n),sn([s,n],s.length+n.length)}function fs(e,n){let t=j(e),s=ds(t.encode(n));return sn([t.codeBuf,s],t.codeBuf.length+s.length)}function ps(e){e instanceof Uint8Array&&(e=Y(e));let n=e[0];return["f","F","v","V","t","T","b","B","c","C","h","k","K"].includes(n)&&(e=e.toLowerCase()),j(e[0]).decode(e.substring(1))}function gs(e){if(e instanceof Uint8Array&&(e=Y(e)),Object.prototype.toString.call(e)!=="[object String]")return!1;try{return j(e[0]).name}catch(n){return!1}}function us(e,n){j(e).decode(Y(n))}function j(e){if(Object.prototype.hasOwnProperty.call(B.names,e))return B.names[e];if(Object.prototype.hasOwnProperty.call(B.codes,e))return B.codes[e];throw new Error(`Unsupported encoding: ${e}`)}function ws(e){return e instanceof Uint8Array&&(e=Y(e)),j(e[0])}q=tn.exports=hs;q.encode=fs;q.decode=ps;q.isEncoded=gs;q.encoding=j;q.encodingFromData=ws;var ms=Object.freeze(B.names),ys=Object.freeze(B.codes);q.names=ms;q.codes=ys});var U=o((Sr,rn)=>{"use strict";var{encoding:vs}=F(),Es=new TextDecoder("utf8");function As(e){let n="";for(let t=0;t<e.length;t++)n+=String.fromCharCode(e[t]);return n}function Ss(e,n="utf8"){return n==="utf8"||n==="utf-8"?Es.decode(e):n==="ascii"?As(e):vs(n).encode(e)}rn.exports=Ss});var xn=o((Tr,bn)=>{"use strict";var ue=Pe(),on=U(),Ts=ue,he=ue.v4,an=ue.v6,cn=function(e,n,t){t=~~t;let s;if(he(e))s=n||new Uint8Array(t+4),e.split(/\./g).map(function(i){s[t++]=parseInt(i,10)&255});else if(an(e)){let i=e.split(":",8),b;for(b=0;b<i.length;b++){let c=he(i[b]);var r;c&&(r=cn(i[b]),i[b]=on(r.slice(0,2),"base16")),r&&++b<8&&i.splice(b,0,on(r.slice(2,4),"base16"))}if(i[0]==="")for(;i.length<8;)i.unshift("0");else if(i[i.length-1]==="")for(;i.length<8;)i.push("0");else if(i.length<8){for(b=0;b<i.length&&i[b]!=="";b++);let c=[b,"1"];for(b=9-i.length;b>0;b--)c.push("0");i.splice.apply(i,c)}for(s=n||new Uint8Array(t+16),b=0;b<i.length;b++){let c=parseInt(i[b],16);s[t++]=c>>8&255,s[t++]=c&255}}if(!s)throw Error("Invalid ip address: "+e);return s},qs=function(e,n,t){n=~~n,t=t||e.length-n;let s=[],r,i=new DataView(e.buffer);if(t===4){for(let b=0;b<t;b++)s.push(e[n+b]);r=s.join(".")}else if(t===16){for(let b=0;b<t;b+=2)s.push(i.getUint16(n+b).toString(16));r=s.join(":"),r=r.replace(/(^|:)0(:0)*:0(:|$)/,"$1::$3"),r=r.replace(/:{3,4}/,"::")}return r};bn.exports={isIP:Ts,isV4:he,isV6:an,toBytes:cn,toString:qs}});var _=o((qr,ln)=>{"use strict";function u(e){if(typeof e=="number"){if(u.codes[e])return u.codes[e];throw new Error("no protocol with code: "+e)}else if(typeof e=="string"){if(u.names[e])return u.names[e];throw new Error("no protocol with name: "+e)}throw new Error("invalid protocol id type: "+e)}var f=-1;u.lengthPrefixedVarSize=f;u.V=f;u.table=[[4,32,"ip4"],[6,16,"tcp"],[33,16,"dccp"],[41,128,"ip6"],[42,f,"ip6zone"],[53,f,"dns","resolvable"],[54,f,"dns4","resolvable"],[55,f,"dns6","resolvable"],[56,f,"dnsaddr","resolvable"],[132,16,"sctp"],[273,16,"udp"],[275,0,"p2p-webrtc-star"],[276,0,"p2p-webrtc-direct"],[277,0,"p2p-stardust"],[290,0,"p2p-circuit"],[301,0,"udt"],[302,0,"utp"],[400,f,"unix",!1,"path"],[421,f,"ipfs"],[421,f,"p2p"],[443,0,"https"],[444,96,"onion"],[445,296,"onion3"],[446,f,"garlic64"],[460,0,"quic"],[477,0,"ws"],[478,0,"wss"],[479,0,"p2p-websocket-star"],[480,0,"http"],[777,f,"memory"]];u.names={};u.codes={};u.table.map(e=>{let n=kn.apply(null,e);return u.codes[n.code]=n,u.names[n.name]=n,null});u.object=kn;function kn(e,n,t,s,r){return{code:e,size:n,name:t,resolvable:Boolean(s),path:Boolean(r)}}ln.exports=u});var fn=o((Nr,dn)=>{dn.exports=un;var hn=128,Ns=127,Cs=~Ns,Us=Math.pow(2,31);function un(e,n,t){n=n||[],t=t||0;for(var s=t;e>=Us;)n[t++]=e&255|hn,e/=128;for(;e&Cs;)n[t++]=e&255|hn,e>>>=7;return n[t]=e|0,un.bytes=t-s+1,n}});var wn=o((Cr,pn)=>{pn.exports=fe;var $s=128,gn=127;function fe(e,n){var t=0,n=n||0,s=0,r=n,i,b=e.length;do{if(r>=b)throw fe.bytes=0,new RangeError("Could not decode varint");i=e[r++],t+=s<28?(i&gn)<<s:(i&gn)*Math.pow(2,s),s+=7}while(i>=$s);return fe.bytes=r-n,t}});var yn=o((Ur,mn)=>{var Ms=Math.pow(2,7),js=Math.pow(2,14),Is=Math.pow(2,21),zs=Math.pow(2,28),Bs=Math.pow(2,35),Fs=Math.pow(2,42),Ds=Math.pow(2,49),Os=Math.pow(2,56),Rs=Math.pow(2,63);mn.exports=function(e){return e<Ms?1:e<js?2:e<Is?3:e<zs?4:e<Bs?5:e<Fs?6:e<Ds?7:e<Os?8:e<Rs?9:10}});var En=o(($r,vn)=>{vn.exports={encode:fn(),decode:wn(),encodingLength:yn()}});var Sn=o((Mr,An)=>{"use strict";var Vs=Object.freeze({identity:0,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,"murmur3-128":34,"murmur3-32":35,"dbl-sha2-256":86,md4:212,md5:213,bmt:214,"sha2-256-trunc254-padded":4114,"ripemd-128":4178,"ripemd-160":4179,"ripemd-256":4180,"ripemd-320":4181,x11:4352,kangarootwelve:7425,"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":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,"poseidon-bls12_381-a2-fc1":46081,"poseidon-bls12_381-a2-fc1-sc":46082});An.exports={names:Vs}});var ee=o((jr,Tn)=>{"use strict";var{encoding:Ls}=F(),Ps=new TextEncoder;function Gs(e){let n=new Uint8Array(e.length);for(let t=0;t<e.length;t++)n[t]=e.charCodeAt(t);return n}function Js(e,n="utf8"){return n==="utf8"||n==="utf-8"?Ps.encode(e):n==="ascii"?Gs(e):Ls(n).decode(e)}Tn.exports=Js});var D=o((Ir,qn)=>{"use strict";function Ks(e,n){n||(n=e.reduce((r,i)=>r+i.length,0));let t=new Uint8Array(n),s=0;for(let r of e)t.set(r,s),s+=r.length;return t}qn.exports=Ks});var ge=o((zr,Nn)=>{"use strict";var Cn=F(),O=En(),{names:G}=Sn(),ne=U(),Xs=ee(),Qs=D(),R={};for(let e in G){let n=e;R[G[n]]=n}Object.freeze(R);function Zs(e){if(!(e instanceof Uint8Array))throw new Error("must be passed a Uint8Array");return ne(e,"base16")}function Ws(e){return Xs(e,"base16")}function Hs(e){if(!(e instanceof Uint8Array))throw new Error("must be passed a Uint8Array");return ne(Cn.encode("base58btc",e)).slice(1)}function Ys(e){let n=e instanceof Uint8Array?ne(e):e;return Cn.decode("z"+n)}function $n(e){if(!(e instanceof Uint8Array))throw new Error("multihash must be a Uint8Array");if(e.length<2)throw new Error("multihash too short. must be > 2 bytes.");let n=O.decode(e);if(!Un(n))throw new Error(`multihash unknown function code: 0x${n.toString(16)}`);e=e.slice(O.decode.bytes);let t=O.decode(e);if(t<0)throw new Error(`multihash invalid length: ${t}`);if(e=e.slice(O.decode.bytes),e.length!==t)throw new Error(`multihash length inconsistent: 0x${ne(e,"base16")}`);return{code:n,name:R[n],length:t,digest:e}}function _s(e,n,t){if(!e||n===void 0)throw new Error("multihash encode requires at least two args: digest, code");let s=Mn(n);if(!(e instanceof Uint8Array))throw new Error("digest should be a Uint8Array");if(t==null&&(t=e.length),t&&e.length!==t)throw new Error("digest length should be equal to specified length.");let r=O.encode(s),i=O.encode(t);return Qs([r,i,e],r.length+i.length+e.length)}function Mn(e){let n=e;if(typeof e=="string"){if(G[e]===void 0)throw new Error(`Unrecognized hash function named: ${e}`);n=G[e]}if(typeof n!="number")throw new Error(`Hash function code should be a number. Got: ${n}`);if(R[n]===void 0&&!pe(n))throw new Error(`Unrecognized function code: ${n}`);return n}function pe(e){return e>0&&e<16}function Un(e){return!!(pe(e)||R[e])}function jn(e){$n(e)}function e0(e){return jn(e),e.subarray(0,2)}Nn.exports={names:G,codes:R,toHexString:Zs,fromHexString:Ws,toB58String:Hs,fromB58String:Ys,decode:$n,encode:_s,coerceCode:Mn,isAppCode:pe,validate:jn,prefix:e0,isValidCode:Un}});var Fn=o((Br,In)=>{In.exports=zn;var Bn=128,n0=127,t0=~n0,s0=Math.pow(2,31);function zn(e,n,t){n=n||[],t=t||0;for(var s=t;e>=s0;)n[t++]=e&255|Bn,e/=128;for(;e&t0;)n[t++]=e&255|Bn,e>>>=7;return n[t]=e|0,zn.bytes=t-s+1,n}});var Rn=o((Fr,Dn)=>{Dn.exports=we;var r0=128,On=127;function we(e,n){var t=0,n=n||0,s=0,r=n,i,b=e.length;do{if(r>=b)throw we.bytes=0,new RangeError("Could not decode varint");i=e[r++],t+=s<28?(i&On)<<s:(i&On)*Math.pow(2,s),s+=7}while(i>=r0);return we.bytes=r-n,t}});var Ln=o((Dr,Vn)=>{var i0=Math.pow(2,7),b0=Math.pow(2,14),o0=Math.pow(2,21),a0=Math.pow(2,28),c0=Math.pow(2,35),x0=Math.pow(2,42),l0=Math.pow(2,49),k0=Math.pow(2,56),d0=Math.pow(2,63);Vn.exports=function(e){return e<i0?1:e<b0?2:e<o0?3:e<a0?4:e<c0?5:e<x0?6:e<l0?7:e<k0?8:e<d0?9:10}});var me=o((Or,Pn)=>{Pn.exports={encode:Fn(),decode:Rn(),encodingLength:Ln()}});var ye=o((Rr,Gn)=>{"use strict";var Jn=me(),u0=U(),h0=ee();Gn.exports={numberToUint8Array:f0,uint8ArrayToNumber:Kn,varintUint8ArrayEncode:p0,varintEncode:g0};function Kn(e){return parseInt(u0(e,"base16"),16)}function f0(e){let n=e.toString(16);return n.length%2==1&&(n="0"+n),h0(n,"base16")}function p0(e){return Uint8Array.from(Jn.encode(Kn(e)))}function g0(e){return Uint8Array.from(Jn.encode(e))}});var Qn=o((Vr,Xn)=>{"use strict";var w0=Object.freeze({identity:0,cidv1:1,cidv2:2,cidv3:3,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,docid:206,"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,"bls12_381-g1g2-pub":238,"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,thread:406,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,"p256-pub":4608,"p384-pub":4609,"p521-pub":4610,"ed448-pub":4611,"x448-pub":4612,"ed25519-priv":4864,kangarootwelve:7425,"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":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,"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,"skynet-ns":11639056});Xn.exports={baseTable:w0}});var Wn=o((Lr,Zn)=>{"use strict";var{baseTable:ve}=Qn(),m0=ye().varintEncode,Ee={},Ae={},te={};for(let e in ve){let n=e,t=ve[n];Ee[n]=m0(t);let s=n.toUpperCase().replace(/-/g,"_");Ae[s]=t,te[t]||(te[t]=n)}Object.freeze(Ee);Object.freeze(Ae);Object.freeze(te);var y0=Object.freeze(ve);Zn.exports={nameToVarint:Ee,constantToCode:Ae,nameToCode:y0,codeToName:te}});var bt=o((Pr,Hn)=>{"use strict";var se=me(),v0=D(),Yn=ye(),{nameToVarint:re,constantToCode:E0,nameToCode:_n,codeToName:Se}=Wn();function A0(e,n){let t;if(e instanceof Uint8Array)t=Yn.varintUint8ArrayEncode(e);else if(re[e])t=re[e];else throw new Error("multicodec not recognized");return v0([t,n],t.length+n.length)}function S0(e){return se.decode(e),e.slice(se.decode.bytes)}function et(e){let n=se.decode(e),t=Se[n];if(t===void 0)throw new Error(`Code "${n}" not found`);return t}function nt(e){return Se[e]}function tt(e){let n=_n[e];if(n===void 0)throw new Error(`Codec "${e}" not found`);return n}function st(e){return se.decode(e)}function rt(e){let n=re[e];if(n===void 0)throw new Error(`Codec "${e}" not found`);return n}function it(e){return Yn.varintEncode(e)}function T0(e){return et(e)}function q0(e){return nt(e)}function N0(e){return tt(e)}function C0(e){return st(e)}function U0(e){return rt(e)}function $0(e){return Array.from(it(e))}Hn.exports={addPrefix:A0,rmPrefix:S0,getNameFromData:et,getNameFromCode:nt,getCodeFromName:tt,getCodeFromData:st,getVarintFromName:rt,getVarintFromCode:it,getCodec:T0,getName:q0,getNumber:N0,getCode:C0,getCodeVarint:U0,getVarint:$0,...E0,nameToVarint:re,nameToCode:_n,codeToName:Se}});var at=o((Gr,ot)=>{"use strict";var M0=ge(),j0={checkCIDComponents:function(e){if(e==null)return"null values are not valid CIDs";if(!(e.version===0||e.version===1))return"Invalid version, must be a number equal to 1 or 0";if(typeof e.codec!="string")return"codec must be string";if(e.version===0){if(e.codec!=="dag-pb")return"codec must be 'dag-pb' for CIDv0";if(e.multibaseName!=="base58btc")return"multibaseName must be 'base58btc' for CIDv0"}if(!(e.multihash instanceof Uint8Array))return"multihash must be a Uint8Array";try{M0.validate(e.multihash)}catch(n){let t=n.message;return t||(t="Multihash validation failed"),t}}};ot.exports=j0});var Te=o((Jr,ct)=>{"use strict";function I0(e,n){if(e===n)return!0;if(e.byteLength!==n.byteLength)return!1;for(let t=0;t<e.byteLength;t++)if(e[t]!==n[t])return!1;return!0}ct.exports=I0});var Ne=o((Kr,xt)=>{"use strict";var ie=ge(),qe=F(),I=bt(),z0=at(),lt=D(),B0=U(),F0=Te(),be=I.nameToCode,D0=Object.keys(be).reduce((e,n)=>(e[be[n]]=n,e),{}),kt=Symbol.for("@ipld/js-cid/CID"),y=class{constructor(n,t,s,r){if(this.version,this.codec,this.multihash,Object.defineProperty(this,kt,{value:!0}),y.isCID(n)){let i=n;this.version=i.version,this.codec=i.codec,this.multihash=i.multihash,this.multibaseName=i.multibaseName||(i.version===0?"base58btc":"base32");return}if(typeof n=="string"){let i=qe.isEncoded(n);if(i){let b=qe.decode(n);this.version=parseInt(b[0].toString(),16),this.codec=I.getCodec(b.slice(1)),this.multihash=I.rmPrefix(b.slice(1)),this.multibaseName=i}else this.version=0,this.codec="dag-pb",this.multihash=ie.fromB58String(n),this.multibaseName="base58btc";y.validateCID(this),Object.defineProperty(this,"string",{value:n});return}if(n instanceof Uint8Array){let i=parseInt(n[0].toString(),16);if(i===1){let b=n;this.version=i,this.codec=I.getCodec(b.slice(1)),this.multihash=I.rmPrefix(b.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=n,this.multibaseName="base58btc";y.validateCID(this);return}this.version=n,typeof t=="number"&&(t=D0[t]),this.codec=t,this.multihash=s,this.multibaseName=r||(n===0?"base58btc":"base32"),y.validateCID(this)}get bytes(){let n=this._bytes;if(!n){if(this.version===0)n=this.multihash;else if(this.version===1){let t=I.getCodeVarint(this.codec);n=lt([[1],t,this.multihash],1+t.byteLength+this.multihash.byteLength)}else throw new Error("unsupported version");Object.defineProperty(this,"_bytes",{value:n})}return n}get prefix(){let n=I.getCodeVarint(this.codec),t=ie.prefix(this.multihash);return lt([[this.version],n,t],1+n.byteLength+t.byteLength)}get code(){return be[this.codec]}toV0(){if(this.codec!=="dag-pb")throw new Error("Cannot convert a non dag-pb CID to CIDv0");let{name:n,length:t}=ie.decode(this.multihash);if(n!=="sha2-256")throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(t!==32)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new y(0,this.codec,this.multihash)}toV1(){return new y(1,this.codec,this.multihash)}toBaseEncodedString(n=this.multibaseName){if(this.string&&this.string.length!==0&&n===this.multibaseName)return this.string;let t;if(this.version===0){if(n!=="base58btc")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=ie.toB58String(this.multihash)}else if(this.version===1)t=B0(qe.encode(n,this.bytes));else throw new Error("unsupported version");return n===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}[Symbol.for("nodejs.util.inspect.custom")](){return"CID("+this.toString()+")"}toString(n){return this.toBaseEncodedString(n)}toJSON(){return{codec:this.codec,version:this.version,hash:this.multihash}}equals(n){return this.codec===n.codec&&this.version===n.version&&F0(this.multihash,n.multihash)}static validateCID(n){let t=z0.checkCIDComponents(n);if(t)throw new Error(t)}static isCID(n){return n instanceof y||Boolean(n&&n[kt])}};y.codecs=be;xt.exports=y});var ht=o((Xr,dt)=>{dt.exports=Ce;var ut=128,O0=127,R0=~O0,V0=Math.pow(2,31);function Ce(e,n,t){if(Number.MAX_SAFE_INTEGER&&e>Number.MAX_SAFE_INTEGER)throw Ce.bytes=0,new RangeError("Could not encode varint");n=n||[],t=t||0;for(var s=t;e>=V0;)n[t++]=e&255|ut,e/=128;for(;e&R0;)n[t++]=e&255|ut,e>>>=7;return n[t]=e|0,Ce.bytes=t-s+1,n}});var gt=o((Qr,ft)=>{ft.exports=Ue;var L0=128,pt=127;function Ue(e,n){var t=0,n=n||0,s=0,r=n,i,b=e.length;do{if(r>=b||s>49)throw Ue.bytes=0,new RangeError("Could not decode varint");i=e[r++],t+=s<28?(i&pt)<<s:(i&pt)*Math.pow(2,s),s+=7}while(i>=L0);return Ue.bytes=r-n,t}});var mt=o((Zr,wt)=>{var P0=Math.pow(2,7),G0=Math.pow(2,14),J0=Math.pow(2,21),K0=Math.pow(2,28),X0=Math.pow(2,35),Q0=Math.pow(2,42),Z0=Math.pow(2,49),W0=Math.pow(2,56),H0=Math.pow(2,63);wt.exports=function(e){return e<P0?1:e<G0?2:e<J0?3:e<K0?4:e<X0?5:e<Q0?6:e<Z0?7:e<W0?8:e<H0?9:10}});var oe=o((Wr,yt)=>{yt.exports={encode:ht(),decode:gt(),encodingLength:mt()}});var Ct=o((Hr,vt)=>{"use strict";var ae=xn(),Et=_(),Y0=Ne(),At=F(),V=oe(),ce=U(),St=ee(),xe=D();vt.exports=J;function J(e,n){return n instanceof Uint8Array?J.toString(e,n):J.toBytes(e,n)}J.toString=function(n,t){switch(Et(n).code){case 4:case 41:return _0(t);case 6:case 273:case 33:case 132:return Tt(t).toString();case 53:case 54:case 55:case 56:case 400:case 777:return er(t);case 421:return nr(t);case 444:return qt(t);case 445:return qt(t);default:return ce(t,"base16")}};J.toBytes=function(n,t){switch(Et(n).code){case 4:return Nt(t);case 41:return Nt(t);case 6:case 273:case 33:case 132:return $e(parseInt(t,10));case 53:case 54:case 55:case 56:case 400:case 777:return tr(t);case 421:return sr(t);case 444:return rr(t);case 445:return ir(t);default:return St(t,"base16")}};function Nt(e){if(!ae.isIP(e))throw new Error("invalid ip address");return ae.toBytes(e)}function _0(e){let n=ae.toString(e);if(!n||!ae.isIP(n))throw new Error("invalid ip address");return n}function $e(e){let n=new ArrayBuffer(2);return new DataView(n).setUint16(0,e),new Uint8Array(n)}function Tt(e){return new DataView(e.buffer).getUint16(0)}function tr(e){let n=St(e),t=Uint8Array.from(V.encode(n.length));return xe([t,n],t.length+n.length)}function er(e){let n=V.decode(e);if(e=e.slice(V.decode.bytes),e.length!==n)throw new Error("inconsistent lengths");return ce(e)}function sr(e){let n=new Y0(e).multihash,t=Uint8Array.from(V.encode(n.length));return xe([t,n],t.length+n.length)}function nr(e){let n=V.decode(e),t=e.slice(V.decode.bytes);if(t.length!==n)throw new Error("inconsistent lengths");return ce(t,"base58btc")}function rr(e){let n=e.split(":");if(n.length!==2)throw new Error("failed to parse onion addr: "+n+" does not contain a port number");if(n[0].length!==16)throw new Error("failed to parse onion addr: "+n[0]+" not a Tor onion address.");let t=At.decode("b"+n[0]),s=parseInt(n[1],10);if(s<1||s>65536)throw new Error("Port number is not in range(1, 65536)");let r=$e(s);return xe([t,r],t.length+r.length)}function ir(e){let n=e.split(":");if(n.length!==2)throw new Error("failed to parse onion addr: "+n+" does not contain a port number");if(n[0].length!==56)throw new Error("failed to parse onion addr: "+n[0]+" not a Tor onion3 address.");let t=At.decode("b"+n[0]),s=parseInt(n[1],10);if(s<1||s>65536)throw new Error("Port number is not in range(1, 65536)");let r=$e(s);return xe([t,r],t.length+r.length)}function qt(e){let n=e.slice(0,e.length-2),t=e.slice(e.length-2),s=ce(n,"base32"),r=Tt(t);return s+":"+r}});var Vt=o((Yr,Ut)=>{"use strict";var $t=Ct(),Me=_(),K=oe(),Mt=D(),br=U();Ut.exports={stringToStringTuples:jt,stringTuplesToString:It,tuplesToStringTuples:Bt,stringTuplesToTuples:zt,bytesToTuples:je,tuplesToBytes:Ft,bytesToString:or,stringToBytes:Ot,fromString:ar,fromBytes:Rt,validateBytes:Ie,isValidBytes:cr,cleanPath:le,ParseError:ze,protoFromTuple:X,sizeForAddr:Dt};function jt(e){let n=[],t=e.split("/").slice(1);if(t.length===1&&t[0]==="")return[];for(let s=0;s<t.length;s++){let r=t[s],i=Me(r);if(i.size===0){n.push([r]);continue}if(s++,s>=t.length)throw ze("invalid address: "+e);if(i.path){n.push([r,le(t.slice(s).join("/"))]);break}n.push([r,t[s]])}return n}function It(e){let n=[];return e.map(t=>{let s=X(t);return n.push(s.name),t.length>1&&n.push(t[1]),null}),le(n.join("/"))}function zt(e){return e.map(n=>{Array.isArray(n)||(n=[n]);let t=X(n);return n.length>1?[t.code,$t.toBytes(t.code,n[1])]:[t.code]})}function Bt(e){return e.map(n=>{let t=X(n);return n[1]?[t.code,$t.toString(t.code,n[1])]:[t.code]})}function Ft(e){return Rt(Mt(e.map(n=>{let t=X(n),s=Uint8Array.from(K.encode(t.code));return n.length>1&&(s=Mt([s,n[1]])),s})))}function Dt(e,n){return e.size>0?e.size/8:e.size===0?0:K.decode(n)+K.decode.bytes}function je(e){let n=[],t=0;for(;t<e.length;){let s=K.decode(e,t),r=K.decode.bytes,i=Me(s),b=Dt(i,e.slice(t+r));if(b===0){n.push([s]),t+=r;continue}let c=e.slice(t+r,t+r+b);if(t+=b+r,t>e.length)throw ze("Invalid address Uint8Array: "+br(e,"base16"));n.push([s,c])}return n}function or(e){let n=je(e),t=Bt(n);return It(t)}function Ot(e){e=le(e);let n=jt(e),t=zt(n);return Ft(t)}function ar(e){return Ot(e)}function Rt(e){let n=Ie(e);if(n)throw n;return Uint8Array.from(e)}function Ie(e){try{je(e)}catch(n){return n}}function cr(e){return Ie(e)===void 0}function le(e){return"/"+e.trim().split("/").filter(n=>n).join("/")}function ze(e){return new Error("Error parsing address: "+e)}function X(e){return Me(e[0])}});var Gt=o((_r,Lt)=>{"use strict";function Pt(e,n){for(let t in n)Object.defineProperty(e,t,{value:n[t],enumerable:!0,configurable:!0});return e}function xr(e,n,t){if(!e||typeof e=="string")throw new TypeError("Please pass an Error to err-code");t||(t={}),typeof n=="object"&&(t=n,n=""),n&&(t.code=n);try{return Pt(e,t)}catch(s){t.message=e.message,t.stack=e.stack;let r=function(){};return r.prototype=Object.create(Object.getPrototypeOf(e)),Pt(new r,t)}}Lt.exports=xr});var fr=o((ei,Jt)=>{"use strict";var v=Vt(),L=_(),Kt=oe(),lr=Ne(),kr=Gt(),dr=Symbol.for("nodejs.util.inspect.custom"),Be=U(),ur=Te(),Fe=new Map,Xt=Symbol.for("@multiformats/js-multiaddr/multiaddr"),k=class{constructor(n){if(n==null&&(n=""),Object.defineProperty(this,Xt,{value:!0}),n instanceof Uint8Array)this.bytes=v.fromBytes(n);else if(typeof n=="string"){if(n.length>0&&n.charAt(0)!=="/")throw new Error(`multiaddr "${n}" must start with a "/"`);this.bytes=v.fromString(n)}else if(k.isMultiaddr(n))this.bytes=v.fromBytes(n.bytes);else throw new Error("addr must be a string, Buffer, or another Multiaddr")}toString(){return v.bytesToString(this.bytes)}toJSON(){return this.toString()}toOptions(){let n={},t=this.toString().split("/");return n.family=t[1]==="ip4"?4:6,n.host=t[2],n.transport=t[3],n.port=parseInt(t[4]),n}protos(){return this.protoCodes().map(n=>Object.assign({},L(n)))}protoCodes(){let n=[],t=this.bytes,s=0;for(;s<t.length;){let r=Kt.decode(t,s),i=Kt.decode.bytes,b=L(r);s+=v.sizeForAddr(b,t.slice(s+i))+i,n.push(r)}return n}protoNames(){return this.protos().map(n=>n.name)}tuples(){return v.bytesToTuples(this.bytes)}stringTuples(){let n=v.bytesToTuples(this.bytes);return v.tuplesToStringTuples(n)}encapsulate(n){return n=new k(n),new k(this.toString()+n.toString())}decapsulate(n){let t=n.toString(),s=this.toString(),r=s.lastIndexOf(t);if(r<0)throw new Error("Address "+this+" does not contain subaddress: "+n);return new k(s.slice(0,r))}decapsulateCode(n){let t=this.tuples();for(let s=t.length-1;s>=0;s--)if(t[s][0]===n)return new k(v.tuplesToBytes(t.slice(0,s)));return this}getPeerId(){try{let t=this.stringTuples().filter(s=>s[0]===L.names.ipfs.code).pop();return t&&t[1]?Be(new lr(t[1]).multihash,"base58btc"):null}catch(n){return null}}getPath(){let n=null;try{n=this.stringTuples().filter(t=>!!L(t[0]).path)[0][1],n||(n=null)}catch(t){n=null}return n}equals(n){return ur(this.bytes,n.bytes)}async resolve(){let n=this.protos().find(r=>r.resolvable);if(!n)return[this];let t=Fe.get(n.name);if(!t)throw kr(new Error(`no available resolver for ${n.name}`),"ERR_NO_AVAILABLE_RESOLVER");return(await t(this)).map(r=>new k(r))}nodeAddress(){let n=this.protoCodes(),t=this.protoNames(),s=this.toString().split("/").slice(1);if(s.length<4)throw new Error('multiaddr must have a valid format: "/{ip4, ip6, dns4, dns6}/{address}/{tcp, udp}/{port}".');if(n[0]!==4&&n[0]!==41&&n[0]!==54&&n[0]!==55)throw new Error(`no protocol with name: "'${t[0]}'". Must have a valid family name: "{ip4, ip6, dns4, dns6}".`);if(s[2]!=="tcp"&&s[2]!=="udp")throw new Error(`no protocol with name: "'${t[1]}'". Must have a valid transport protocol: "{tcp, udp}".`);return{family:n[0]===41||n[0]===55?6:4,address:s[1],port:parseInt(s[3])}}isThinWaistAddress(n){let t=(n||this).protos();return!(t.length!==2||t[0].code!==4&&t[0].code!==41||t[1].code!==6&&t[1].code!==273)}static fromNodeAddress(n,t){if(!n)throw new Error("requires node address object");if(!t)throw new Error("requires transport protocol");let s;switch(n.family){case 4:s="ip4";break;case 6:s="ip6";break;default:throw Error(`Invalid addr family. Got '${n.family}' instead of 4 or 6`)}return new k("/"+[s,n.address,t,n.port].join("/"))}static isName(n){return k.isMultiaddr(n)?n.protos().some(t=>t.resolvable):!1}static isMultiaddr(n){return n instanceof k||Boolean(n&&n[Xt])}[dr](){return"<Multiaddr "+Be(this.bytes,"base16")+" - "+v.bytesToString(this.bytes)+">"}inspect(){return"<Multiaddr "+Be(this.bytes,"base16")+" - "+v.bytesToString(this.bytes)+">"}};k.protocols=L;k.resolvers=Fe;function hr(e){return new k(e)}Jt.exports={Multiaddr:k,multiaddr:hr,protocols:L,resolvers:Fe}});return fr();})();
  return Multiaddr}));
  