-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path3345.b94050522537783b63af.js
1 lines (1 loc) · 36.2 KB
/
3345.b94050522537783b63af.js
1
(self.webpackChunktimeless_frontend=self.webpackChunktimeless_frontend||[]).push([[3345],{3671:(_,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createHashFunction=function(v){return function(b){var o=v();return o.update(b),Buffer.from(o.digest())}}},93825:(_,e,d)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var v=d(3671),b=d(58577);e.keccak224=v.createHashFunction(function(){return b("keccak224")}),e.keccak256=v.createHashFunction(function(){return b("keccak256")}),e.keccak384=v.createHashFunction(function(){return b("keccak384")}),e.keccak512=v.createHashFunction(function(){return b("keccak512")})},12283:(_,e,d)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var v=d(16589);e.getRandomBytes=function(h){return new Promise(function(s,u){v(h,function(t,f){t?u(t):s(f)})})},e.getRandomBytesSync=function(h){return v(h)}},29787:function(_,e,d){"use strict";var v=this&&this.__awaiter||function(n,i,r,c){return new(r||(r=Promise))(function(y,E){function S(T){try{g(c.next(T))}catch(w){E(w)}}function B(T){try{g(c.throw(T))}catch(w){E(w)}}function g(T){T.done?y(T.value):function(y){return y instanceof r?y:new r(function(E){E(y)})}(T.value).then(S,B)}g((c=c.apply(n,i||[])).next())})},b=this&&this.__generator||function(n,i){var c,l,y,E,r={label:0,sent:function(){if(1&y[0])throw y[1];return y[1]},trys:[],ops:[]};return E={next:S(0),throw:S(1),return:S(2)},"function"==typeof Symbol&&(E[Symbol.iterator]=function(){return this}),E;function S(g){return function(T){return function(g){if(c)throw new TypeError("Generator is already executing.");for(;r;)try{if(c=1,l&&(y=2&g[0]?l.return:g[0]?l.throw||((y=l.return)&&y.call(l),0):l.next)&&!(y=y.call(l,g[1])).done)return y;switch(l=0,y&&(g=[2&g[0],y.value]),g[0]){case 0:case 1:y=g;break;case 4:return r.label++,{value:g[1],done:!1};case 5:r.label++,l=g[1],g=[0];continue;case 7:g=r.ops.pop(),r.trys.pop();continue;default:if(!(y=(y=r.trys).length>0&&y[y.length-1])&&(6===g[0]||2===g[0])){r=0;continue}if(3===g[0]&&(!y||g[1]>y[0]&&g[1]<y[3])){r.label=g[1];break}if(6===g[0]&&r.label<y[1]){r.label=y[1],y=g;break}if(y&&r.label<y[2]){r.label=y[2],r.ops.push(g);break}y[2]&&r.ops.pop(),r.trys.pop();continue}g=i.call(n,r)}catch(T){g=[6,T],l=0}finally{c=y=0}if(5&g[0])throw g[1];return{value:g[0]?g[1]:void 0,done:!0}}([g,T])}}};Object.defineProperty(e,"__esModule",{value:!0});var h=d(5802),s=d(12283);e.createPrivateKey=function(){return v(this,void 0,void 0,function(){var n;return b(this,function(i){switch(i.label){case 0:return[4,s.getRandomBytes(32)];case 1:return n=i.sent(),h.privateKeyVerify(n)?[2,n]:[3,0];case 2:return[2]}})})},e.createPrivateKeySync=function(){for(;;){var n=s.getRandomBytesSync(32);if(h.privateKeyVerify(n))return n}},function(n){for(var i in n)e.hasOwnProperty(i)||(e[i]=n[i])}(d(5802))},5514:function(_,e,d){"use strict";var v=this&&this.__read||function(A,a){var m="function"==typeof Symbol&&A[Symbol.iterator];if(!m)return A;var I,O,K=m.call(A),R=[];try{for(;(void 0===a||a-- >0)&&!(I=K.next()).done;)R.push(I.value)}catch(L){O={error:L}}finally{try{I&&!I.done&&(m=K.return)&&m.call(K)}finally{if(O)throw O.error}}return R},b=this&&this.__importDefault||function(A){return A&&A.__esModule?A:{default:A}};Object.defineProperty(e,"__esModule",{value:!0}),e.isZeroAddress=e.zeroAddress=e.importPublic=e.privateToAddress=e.privateToPublic=e.publicToAddress=e.pubToAddress=e.isValidPublic=e.isValidPrivate=e.generateAddress2=e.generateAddress=e.isValidChecksumAddress=e.toChecksumAddress=e.isValidAddress=e.Account=void 0;var o=b(d(33114)),h=d(48472),s=d(29787),u=d(63125),t=d(76602),f=d(40951),n=d(56915),i=d(51950),r=d(4442),c=function(){function A(a,m,K,I){void 0===a&&(a=new h.BN(0)),void 0===m&&(m=new h.BN(0)),void 0===K&&(K=t.KECCAK256_RLP),void 0===I&&(I=t.KECCAK256_NULL),this.nonce=a,this.balance=m,this.stateRoot=K,this.codeHash=I,this._validate()}return A.fromAccountData=function(a){var m=a.nonce,K=a.balance,I=a.stateRoot,R=a.codeHash;return new A(m?new h.BN((0,f.toBuffer)(m)):void 0,K?new h.BN((0,f.toBuffer)(K)):void 0,I?(0,f.toBuffer)(I):void 0,R?(0,f.toBuffer)(R):void 0)},A.fromRlpSerializedAccount=function(a){var m=h.rlp.decode(a);if(!Array.isArray(m))throw new Error("Invalid serialized account input. Must be array");return this.fromValuesArray(m)},A.fromValuesArray=function(a){var m=v(a,4),I=m[1],R=m[2],O=m[3];return new A(new h.BN(m[0]),new h.BN(I),R,O)},A.prototype._validate=function(){if(this.nonce.lt(new h.BN(0)))throw new Error("nonce must be greater than zero");if(this.balance.lt(new h.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")},A.prototype.raw=function(){return[(0,r.bnToUnpaddedBuffer)(this.nonce),(0,r.bnToUnpaddedBuffer)(this.balance),this.stateRoot,this.codeHash]},A.prototype.serialize=function(){return h.rlp.encode(this.raw())},A.prototype.isContract=function(){return!this.codeHash.equals(t.KECCAK256_NULL)},A.prototype.isEmpty=function(){return this.balance.isZero()&&this.nonce.isZero()&&this.codeHash.equals(t.KECCAK256_NULL)},A}();e.Account=c,e.isValidAddress=function(A){try{(0,i.assertIsString)(A)}catch{return!1}return/^0x[0-9a-fA-F]{40}$/.test(A)},e.toChecksumAddress=function(A,a){(0,i.assertIsHexString)(A);var m=(0,u.stripHexPrefix)(A).toLowerCase(),K="";a&&(K=(0,r.toType)(a,r.TypeOutput.BN).toString()+"0x");for(var R=(0,n.keccakFromString)(K+m).toString("hex"),O="0x",L=0;L<m.length;L++)parseInt(R[L],16)>=8?O+=m[L].toUpperCase():O+=m[L];return O},e.isValidChecksumAddress=function(A,a){return(0,e.isValidAddress)(A)&&(0,e.toChecksumAddress)(A,a)===A},e.generateAddress=function(A,a){(0,i.assertIsBuffer)(A),(0,i.assertIsBuffer)(a);var m=new h.BN(a);return m.isZero()?(0,n.rlphash)([A,null]).slice(-20):(0,n.rlphash)([A,Buffer.from(m.toArray())]).slice(-20)},e.generateAddress2=function(A,a,m){return(0,i.assertIsBuffer)(A),(0,i.assertIsBuffer)(a),(0,i.assertIsBuffer)(m),(0,o.default)(20===A.length),(0,o.default)(32===a.length),(0,n.keccak256)(Buffer.concat([Buffer.from("ff","hex"),A,a,(0,n.keccak256)(m)])).slice(-20)},e.isValidPrivate=function(A){return(0,s.privateKeyVerify)(A)},e.isValidPublic=function(A,a){return void 0===a&&(a=!1),(0,i.assertIsBuffer)(A),64===A.length?(0,s.publicKeyVerify)(Buffer.concat([Buffer.from([4]),A])):!!a&&(0,s.publicKeyVerify)(A)},e.pubToAddress=function(A,a){return void 0===a&&(a=!1),(0,i.assertIsBuffer)(A),a&&64!==A.length&&(A=Buffer.from((0,s.publicKeyConvert)(A,!1).slice(1))),(0,o.default)(64===A.length),(0,n.keccak)(A).slice(-20)},e.publicToAddress=e.pubToAddress,e.privateToPublic=function(A){return(0,i.assertIsBuffer)(A),Buffer.from((0,s.publicKeyCreate)(A,!1)).slice(1)},e.privateToAddress=function(A){return(0,e.publicToAddress)((0,e.privateToPublic)(A))},e.importPublic=function(A){return(0,i.assertIsBuffer)(A),64!==A.length&&(A=Buffer.from((0,s.publicKeyConvert)(A,!1).slice(1))),A},e.zeroAddress=function(){var a=(0,f.zeros)(20);return(0,f.bufferToHex)(a)},e.isZeroAddress=function(A){try{(0,i.assertIsString)(A)}catch{return!1}return(0,e.zeroAddress)()===A}},21892:function(_,e,d){"use strict";var v=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Address=void 0;var b=v(d(33114)),o=d(48472),h=d(40951),s=d(5514),u=function(){function t(f){(0,b.default)(20===f.length,"Invalid address length"),this.buf=f}return t.zero=function(){return new t((0,h.zeros)(20))},t.fromString=function(f){return(0,b.default)((0,s.isValidAddress)(f),"Invalid address"),new t((0,h.toBuffer)(f))},t.fromPublicKey=function(f){return(0,b.default)(Buffer.isBuffer(f),"Public key should be Buffer"),new t((0,s.pubToAddress)(f))},t.fromPrivateKey=function(f){return(0,b.default)(Buffer.isBuffer(f),"Private key should be Buffer"),new t((0,s.privateToAddress)(f))},t.generate=function(f,n){return(0,b.default)(o.BN.isBN(n)),new t((0,s.generateAddress)(f.buf,n.toArrayLike(Buffer)))},t.generate2=function(f,n,i){return(0,b.default)(Buffer.isBuffer(n)),(0,b.default)(Buffer.isBuffer(i)),new t((0,s.generateAddress2)(f.buf,n,i))},t.prototype.equals=function(f){return this.buf.equals(f.buf)},t.prototype.isZero=function(){return this.equals(t.zero())},t.prototype.isPrecompileOrSystemAddress=function(){var f=new o.BN(this.buf),n=new o.BN(0),i=new o.BN("ffff","hex");return f.gte(n)&&f.lte(i)},t.prototype.toString=function(){return"0x"+this.buf.toString("hex")},t.prototype.toBuffer=function(){return Buffer.from(this.buf)},t}();e.Address=u},40951:function(_,e,d){"use strict";var v=this&&this.__values||function(a){var m="function"==typeof Symbol&&Symbol.iterator,K=m&&a[m],I=0;if(K)return K.call(a);if(a&&"number"==typeof a.length)return{next:function(){return a&&I>=a.length&&(a=void 0),{value:a&&a[I++],done:!a}}};throw new TypeError(m?"Object is not iterable.":"Symbol.iterator is not defined.")},b=this&&this.__read||function(a,m){var K="function"==typeof Symbol&&a[Symbol.iterator];if(!K)return a;var R,L,I=K.call(a),O=[];try{for(;(void 0===m||m-- >0)&&!(R=I.next()).done;)O.push(R.value)}catch(p){L={error:p}}finally{try{R&&!R.done&&(K=I.return)&&K.call(I)}finally{if(L)throw L.error}}return O};Object.defineProperty(e,"__esModule",{value:!0}),e.bufArrToArr=e.arrToBufArr=e.validateNoLeadingZeroes=e.baToJSON=e.toUtf8=e.addHexPrefix=e.toUnsigned=e.fromSigned=e.bufferToHex=e.bufferToInt=e.toBuffer=e.unpadHexString=e.unpadArray=e.unpadBuffer=e.setLengthRight=e.setLengthLeft=e.zeros=e.intToBuffer=e.intToHex=void 0;var o=d(48472),h=d(63125),s=d(51950);e.intToHex=function(a){if(!Number.isSafeInteger(a)||a<0)throw new Error("Received an invalid integer type: ".concat(a));return"0x".concat(a.toString(16))},e.intToBuffer=function(a){var m=(0,e.intToHex)(a);return Buffer.from((0,h.padToEven)(m.slice(2)),"hex")},e.zeros=function(a){return Buffer.allocUnsafe(a).fill(0)};var n=function(a,m,K){var I=(0,e.zeros)(m);return K?a.length<m?(a.copy(I),I):a.slice(0,m):a.length<m?(a.copy(I,m-a.length),I):a.slice(-m)};e.setLengthLeft=function(a,m){return(0,s.assertIsBuffer)(a),n(a,m,!1)},e.setLengthRight=function(a,m){return(0,s.assertIsBuffer)(a),n(a,m,!0)};var c=function(a){for(var m=a[0];a.length>0&&"0"===m.toString();)m=(a=a.slice(1))[0];return a};e.unpadBuffer=function(a){return(0,s.assertIsBuffer)(a),c(a)},e.unpadArray=function(a){return(0,s.assertIsArray)(a),c(a)},e.unpadHexString=function(a){return(0,s.assertIsHexString)(a),a=(0,h.stripHexPrefix)(a),c(a)},e.toBuffer=function(a){if(null==a)return Buffer.allocUnsafe(0);if(Buffer.isBuffer(a)||Array.isArray(a)||a instanceof Uint8Array)return Buffer.from(a);if("string"==typeof a){if(!(0,h.isHexString)(a))throw new Error("Cannot convert string to buffer. toBuffer only supports 0x-prefixed hex strings and this string was given: ".concat(a));return Buffer.from((0,h.padToEven)((0,h.stripHexPrefix)(a)),"hex")}if("number"==typeof a)return(0,e.intToBuffer)(a);if(o.BN.isBN(a)){if(a.isNeg())throw new Error("Cannot convert negative BN to buffer. Given: ".concat(a));return a.toArrayLike(Buffer)}if(a.toArray)return Buffer.from(a.toArray());if(a.toBuffer)return Buffer.from(a.toBuffer());throw new Error("invalid type")},e.bufferToInt=function(a){return new o.BN((0,e.toBuffer)(a)).toNumber()},e.bufferToHex=function(a){return"0x"+(a=(0,e.toBuffer)(a)).toString("hex")},e.fromSigned=function(a){return new o.BN(a).fromTwos(256)},e.toUnsigned=function(a){return Buffer.from(a.toTwos(256).toArray())},e.addHexPrefix=function(a){return"string"!=typeof a||(0,h.isHexPrefixed)(a)?a:"0x"+a},e.toUtf8=function(a){if((a=(0,h.stripHexPrefix)(a)).length%2!=0)throw new Error("Invalid non-even hex string input for toUtf8() provided");return Buffer.from(a.replace(/^(00)+|(00)+$/g,""),"hex").toString("utf8")},e.baToJSON=function(a){if(Buffer.isBuffer(a))return"0x".concat(a.toString("hex"));if(a instanceof Array){for(var m=[],K=0;K<a.length;K++)m.push((0,e.baToJSON)(a[K]));return m}},e.validateNoLeadingZeroes=function(a){var m,K;try{for(var I=v(Object.entries(a)),R=I.next();!R.done;R=I.next()){var O=b(R.value,2),p=O[1];if(void 0!==p&&p.length>0&&0===p[0])throw new Error("".concat(O[0]," cannot have leading zeroes, received: ").concat(p.toString("hex")))}}catch(M){m={error:M}}finally{try{R&&!R.done&&(K=I.return)&&K.call(I)}finally{if(m)throw m.error}}},e.arrToBufArr=function U(a){return Array.isArray(a)?a.map(function(m){return U(m)}):Buffer.from(a)},e.bufArrToArr=function A(a){return Array.isArray(a)?a.map(function(m){return A(m)}):Uint8Array.from(a??[])}},76602:(_,e,d)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.KECCAK256_RLP=e.KECCAK256_RLP_S=e.KECCAK256_RLP_ARRAY=e.KECCAK256_RLP_ARRAY_S=e.KECCAK256_NULL=e.KECCAK256_NULL_S=e.TWO_POW256=e.MAX_INTEGER=e.MAX_UINT64=void 0;var v=d(3875),b=d(48472);e.MAX_UINT64=new b.BN("ffffffffffffffff",16),e.MAX_INTEGER=new b.BN("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16),e.TWO_POW256=new b.BN("10000000000000000000000000000000000000000000000000000000000000000",16),e.KECCAK256_NULL_S="c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",e.KECCAK256_NULL=v.Buffer.from(e.KECCAK256_NULL_S,"hex"),e.KECCAK256_RLP_ARRAY_S="1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",e.KECCAK256_RLP_ARRAY=v.Buffer.from(e.KECCAK256_RLP_ARRAY_S,"hex"),e.KECCAK256_RLP_S="56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",e.KECCAK256_RLP=v.Buffer.from(e.KECCAK256_RLP_S,"hex")},48472:function(_,e,d){"use strict";var v=this&&this.__createBinding||(Object.create?function(t,f,n,i){void 0===i&&(i=n);var r=Object.getOwnPropertyDescriptor(f,n);(!r||("get"in r?!f.__esModule:r.writable||r.configurable))&&(r={enumerable:!0,get:function(){return f[n]}}),Object.defineProperty(t,i,r)}:function(t,f,n,i){void 0===i&&(i=n),t[i]=f[n]}),b=this&&this.__setModuleDefault||(Object.create?function(t,f){Object.defineProperty(t,"default",{enumerable:!0,value:f})}:function(t,f){t.default=f}),o=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var f={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&v(f,t,n);return b(f,t),f},h=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.rlp=e.BN=void 0;var s=h(d(62630));e.BN=s.default;var u=o(d(89153));e.rlp=u},56915:(_,e,d)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.rlphash=e.ripemd160FromArray=e.ripemd160FromString=e.ripemd160=e.sha256FromArray=e.sha256FromString=e.sha256=e.keccakFromArray=e.keccakFromHexString=e.keccakFromString=e.keccak256=e.keccak=void 0;var v=d(93825),b=d(12506),o=d(48472),h=d(40951),s=d(51950);e.keccak=function(w,P){switch(void 0===P&&(P=256),(0,s.assertIsBuffer)(w),P){case 224:return(0,v.keccak224)(w);case 256:return(0,v.keccak256)(w);case 384:return(0,v.keccak384)(w);case 512:return(0,v.keccak512)(w);default:throw new Error("Invald algorithm: keccak".concat(P))}},e.keccak256=function(w){return(0,e.keccak)(w)},e.keccakFromString=function(w,P){void 0===P&&(P=256),(0,s.assertIsString)(w);var N=Buffer.from(w,"utf8");return(0,e.keccak)(N,P)},e.keccakFromHexString=function(w,P){return void 0===P&&(P=256),(0,s.assertIsHexString)(w),(0,e.keccak)((0,h.toBuffer)(w),P)},e.keccakFromArray=function(w,P){return void 0===P&&(P=256),(0,s.assertIsArray)(w),(0,e.keccak)((0,h.toBuffer)(w),P)};var r=function(w){return w=(0,h.toBuffer)(w),b("sha256").update(w).digest()};e.sha256=function(w){return(0,s.assertIsBuffer)(w),r(w)},e.sha256FromString=function(w){return(0,s.assertIsString)(w),r(w)},e.sha256FromArray=function(w){return(0,s.assertIsArray)(w),r(w)};var E=function(w,P){w=(0,h.toBuffer)(w);var N=b("rmd160").update(w).digest();return!0===P?(0,h.setLengthLeft)(N,32):N};e.ripemd160=function(w,P){return(0,s.assertIsBuffer)(w),E(w,P)},e.ripemd160FromString=function(w,P){return(0,s.assertIsString)(w),E(w,P)},e.ripemd160FromArray=function(w,P){return(0,s.assertIsArray)(w),E(w,P)},e.rlphash=function(w){return(0,e.keccak)(o.rlp.encode(w))}},51950:(_,e,d)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.assertIsString=e.assertIsArray=e.assertIsBuffer=e.assertIsHexString=void 0;var v=d(63125);e.assertIsHexString=function(u){if(!(0,v.isHexString)(u)){var t="This method only supports 0x-prefixed hex strings but input was: ".concat(u);throw new Error(t)}},e.assertIsBuffer=function(u){if(!Buffer.isBuffer(u)){var t="This method only supports Buffer but input was: ".concat(u);throw new Error(t)}},e.assertIsArray=function(u){if(!Array.isArray(u)){var t="This method only supports number arrays but input was: ".concat(u);throw new Error(t)}},e.assertIsString=function(u){if("string"!=typeof u){var t="This method only supports strings but input was: ".concat(u);throw new Error(t)}}},93345:function(_,e,d){"use strict";var v=this&&this.__createBinding||(Object.create?function(h,s,u,t){void 0===t&&(t=u);var f=Object.getOwnPropertyDescriptor(s,u);(!f||("get"in f?!s.__esModule:f.writable||f.configurable))&&(f={enumerable:!0,get:function(){return s[u]}}),Object.defineProperty(h,t,f)}:function(h,s,u,t){void 0===t&&(t=u),h[t]=s[u]}),b=this&&this.__exportStar||function(h,s){for(var u in h)"default"!==u&&!Object.prototype.hasOwnProperty.call(s,u)&&v(s,h,u)};Object.defineProperty(e,"__esModule",{value:!0}),e.isHexString=e.getKeys=e.fromAscii=e.fromUtf8=e.toAscii=e.arrayContainsArray=e.getBinarySize=e.padToEven=e.stripHexPrefix=e.isHexPrefixed=void 0,b(d(76602),e),b(d(5514),e),b(d(21892),e),b(d(56915),e),b(d(53528),e),b(d(40951),e),b(d(49327),e),b(d(48472),e),b(d(4442),e);var o=d(63125);Object.defineProperty(e,"isHexPrefixed",{enumerable:!0,get:function(){return o.isHexPrefixed}}),Object.defineProperty(e,"stripHexPrefix",{enumerable:!0,get:function(){return o.stripHexPrefix}}),Object.defineProperty(e,"padToEven",{enumerable:!0,get:function(){return o.padToEven}}),Object.defineProperty(e,"getBinarySize",{enumerable:!0,get:function(){return o.getBinarySize}}),Object.defineProperty(e,"arrayContainsArray",{enumerable:!0,get:function(){return o.arrayContainsArray}}),Object.defineProperty(e,"toAscii",{enumerable:!0,get:function(){return o.toAscii}}),Object.defineProperty(e,"fromUtf8",{enumerable:!0,get:function(){return o.fromUtf8}}),Object.defineProperty(e,"fromAscii",{enumerable:!0,get:function(){return o.fromAscii}}),Object.defineProperty(e,"getKeys",{enumerable:!0,get:function(){return o.getKeys}}),Object.defineProperty(e,"isHexString",{enumerable:!0,get:function(){return o.isHexString}})},63125:(_,e)=>{"use strict";function d(i){if("string"!=typeof i)throw new Error("[isHexPrefixed] input must be type 'string', received type ".concat(typeof i));return"0"===i[0]&&"x"===i[1]}function b(i){var r=i;if("string"!=typeof r)throw new Error("[padToEven] value must be type 'string', received ".concat(typeof r));return r.length%2&&(r="0".concat(r)),r}Object.defineProperty(e,"__esModule",{value:!0}),e.isHexString=e.getKeys=e.fromAscii=e.fromUtf8=e.toAscii=e.arrayContainsArray=e.getBinarySize=e.padToEven=e.stripHexPrefix=e.isHexPrefixed=void 0,e.isHexPrefixed=d,e.stripHexPrefix=function(i){if("string"!=typeof i)throw new Error("[stripHexPrefix] input must be type 'string', received ".concat(typeof i));return d(i)?i.slice(2):i},e.padToEven=b,e.getBinarySize=function(i){if("string"!=typeof i)throw new Error("[getBinarySize] method requires input type 'string', recieved ".concat(typeof i));return Buffer.byteLength(i,"utf8")},e.arrayContainsArray=function(i,r,c){if(!0!==Array.isArray(i))throw new Error("[arrayContainsArray] method requires input 'superset' to be an array, got type '".concat(typeof i,"'"));if(!0!==Array.isArray(r))throw new Error("[arrayContainsArray] method requires input 'subset' to be an array, got type '".concat(typeof r,"'"));return r[c?"some":"every"](function(l){return i.indexOf(l)>=0})},e.toAscii=function(i){var r="",c=0,l=i.length;for("0x"===i.substring(0,2)&&(c=2);c<l;c+=2){var y=parseInt(i.substr(c,2),16);r+=String.fromCharCode(y)}return r},e.fromUtf8=function(i){var r=Buffer.from(i,"utf8");return"0x".concat(b(r.toString("hex")).replace(/^0+|0+$/g,""))},e.fromAscii=function(i){for(var r="",c=0;c<i.length;c++){var y=i.charCodeAt(c).toString(16);r+=y.length<2?"0".concat(y):y}return"0x".concat(r)},e.getKeys=function(i,r,c){if(!Array.isArray(i))throw new Error("[getKeys] method expects input 'params' to be an array, got ".concat(typeof i));if("string"!=typeof r)throw new Error("[getKeys] method expects input 'key' to be type 'string', got ".concat(typeof i));for(var l=[],y=0;y<i.length;y++){var E=i[y][r];if(c&&!E)E="";else if("string"!=typeof E)throw new Error("invalid abi - expected type 'string', received ".concat(typeof E));l.push(E)}return l},e.isHexString=function(i,r){return!("string"!=typeof i||!i.match(/^0x[0-9A-Fa-f]*$/)||r&&i.length!==2+2*r)}},49327:function(_,e,d){"use strict";var v=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.defineProperties=void 0;var b=v(d(33114)),o=d(63125),h=d(48472),s=d(40951);e.defineProperties=function(t,f,n){if(t.raw=[],t._fields=[],t.toJSON=function(r){if(void 0===r&&(r=!1),r){var c={};return t._fields.forEach(function(l){c[l]="0x".concat(t[l].toString("hex"))}),c}return(0,s.baToJSON)(t.raw)},t.serialize=function(){return h.rlp.encode(t.raw)},f.forEach(function(r,c){function l(){return t.raw[c]}function y(E){"00"===(E=(0,s.toBuffer)(E)).toString("hex")&&!r.allowZero&&(E=Buffer.allocUnsafe(0)),r.allowLess&&r.length?(E=(0,s.unpadBuffer)(E),(0,b.default)(r.length>=E.length,"The field ".concat(r.name," must not have more ").concat(r.length," bytes"))):!(r.allowZero&&0===E.length)&&r.length&&(0,b.default)(r.length===E.length,"The field ".concat(r.name," must have byte length of ").concat(r.length)),t.raw[c]=E}t._fields.push(r.name),Object.defineProperty(t,r.name,{enumerable:!0,configurable:!0,get:l,set:y}),r.default&&(t[r.name]=r.default),r.alias&&Object.defineProperty(t,r.alias,{enumerable:!1,configurable:!0,set:y,get:l})}),n)if("string"==typeof n&&(n=Buffer.from((0,o.stripHexPrefix)(n),"hex")),Buffer.isBuffer(n)&&(n=h.rlp.decode(n)),Array.isArray(n)){if(n.length>t._fields.length)throw new Error("wrong number of fields in data");n.forEach(function(r,c){t[t._fields[c]]=(0,s.toBuffer)(r)})}else{if("object"!=typeof n)throw new Error("invalid data");var i=Object.keys(n);f.forEach(function(r){-1!==i.indexOf(r.name)&&(t[r.name]=n[r.name]),-1!==i.indexOf(r.alias)&&(t[r.alias]=n[r.alias])})}}},53528:(_,e,d)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.hashPersonalMessage=e.isValidSignature=e.fromRpcSig=e.toCompactSig=e.toRpcSig=e.ecrecover=e.ecsign=void 0;var v=d(29787),b=d(48472),o=d(40951),h=d(56915),s=d(51950),u=d(4442);function f(S,B){var g=(0,u.toType)(S,u.TypeOutput.BN);if(g.eqn(0)||g.eqn(1))return(0,u.toType)(S,u.TypeOutput.BN);if(!B)return g.subn(27);var T=(0,u.toType)(B,u.TypeOutput.BN);return g.sub(T.muln(2).addn(35))}function n(S){var B=new b.BN(S);return B.eqn(0)||B.eqn(1)}e.ecsign=function(S,B,g){var T=(0,v.ecdsaSign)(S,B),w=T.signature,P=T.recid,N=Buffer.from(w.slice(0,32)),C=Buffer.from(w.slice(32,64));if(!g||"number"==typeof g){if(g&&!Number.isSafeInteger(g))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative input type)");return{r:N,s:C,v:g?P+(2*g+35):P+27}}return{r:N,s:C,v:(0,u.toType)(g,u.TypeOutput.BN).muln(2).addn(35).addn(P).toArrayLike(Buffer)}},e.ecrecover=function(S,B,g,T,w){var P=Buffer.concat([(0,o.setLengthLeft)(g,32),(0,o.setLengthLeft)(T,32)],64),N=f(B,w);if(!n(N))throw new Error("Invalid signature v value");var C=(0,v.ecdsaRecover)(P,N.toNumber(),S);return Buffer.from((0,v.publicKeyConvert)(C,!1).slice(1))},e.toRpcSig=function(S,B,g,T){if(!n(f(S,T)))throw new Error("Invalid signature v value");return(0,o.bufferToHex)(Buffer.concat([(0,o.setLengthLeft)(B,32),(0,o.setLengthLeft)(g,32),(0,o.toBuffer)(S)]))},e.toCompactSig=function(S,B,g,T){if(!n(f(S,T)))throw new Error("Invalid signature v value");var P=(0,u.toType)(S,u.TypeOutput.Number),N=g;return(P>28&&P%2==1||1===P||28===P)&&((N=Buffer.from(g))[0]|=128),(0,o.bufferToHex)(Buffer.concat([(0,o.setLengthLeft)(B,32),(0,o.setLengthLeft)(N,32)]))},e.fromRpcSig=function(S){var g,T,w,B=(0,o.toBuffer)(S);if(B.length>=65)g=B.slice(0,32),T=B.slice(32,64),w=(0,o.bufferToInt)(B.slice(64));else{if(64!==B.length)throw new Error("Invalid signature length");g=B.slice(0,32),T=B.slice(32,64),w=(0,o.bufferToInt)(B.slice(32,33))>>7,T[0]&=127}return w<27&&(w+=27),{v:w,r:g,s:T}},e.isValidSignature=function(S,B,g,T,w){void 0===T&&(T=!0);var P=new b.BN("7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0",16),N=new b.BN("fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141",16);if(32!==B.length||32!==g.length||!n(f(S,w)))return!1;var C=new b.BN(B),H=new b.BN(g);return!(C.isZero()||C.gt(N)||H.isZero()||H.gt(N)||T&&1===H.cmp(P))},e.hashPersonalMessage=function(S){(0,s.assertIsBuffer)(S);var B=Buffer.from("\x19Ethereum Signed Message:\n".concat(S.length),"utf-8");return(0,h.keccak)(Buffer.concat([B,S]))}},4442:(_,e,d)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toType=e.TypeOutput=e.bnToRlp=e.bnToUnpaddedBuffer=e.bnToHex=void 0;var t,n,v=d(48472),b=d(63125),o=d(40951);function s(n){return(0,o.unpadBuffer)(n.toArrayLike(Buffer))}e.bnToHex=function(n){return"0x".concat(n.toString(16))},e.bnToUnpaddedBuffer=s,e.bnToRlp=function(n){return s(n)},(n=t=e.TypeOutput||(e.TypeOutput={}))[n.Number=0]="Number",n[n.BN=1]="BN",n[n.Buffer=2]="Buffer",n[n.PrefixedHexString=3]="PrefixedHexString",e.toType=function(n,i){if(null===n)return null;if(void 0!==n){if("string"==typeof n&&!(0,b.isHexString)(n))throw new Error("A string must be provided with a 0x-prefix, given: ".concat(n));if("number"==typeof n&&!Number.isSafeInteger(n))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative input type)");var r=(0,o.toBuffer)(n);if(i===t.Buffer)return r;if(i===t.BN)return new v.BN(r);if(i===t.Number){var c=new v.BN(r),l=new v.BN(Number.MAX_SAFE_INTEGER.toString());if(c.gt(l))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative output type)");return c.toNumber()}return"0x".concat(r.toString("hex"))}}},5802:(_,e,d)=>{_.exports=d(50911)(d(35092))},35092:(_,e,d)=>{const b=new(0,d(5247).ec)("secp256k1"),o=b.curve,h=o.n.constructor;function t(n){const i=n[0];switch(i){case 2:case 3:return 33!==n.length?null:function(n,i){let r=new h(i);if(r.cmp(o.p)>=0)return null;r=r.toRed(o.red);let c=r.redSqr().redIMul(r).redIAdd(o.b).redSqrt();return 3===n!==c.isOdd()&&(c=c.redNeg()),b.keyPair({pub:{x:r,y:c}})}(i,n.subarray(1,33));case 4:case 6:case 7:return 65!==n.length?null:function(n,i,r){let c=new h(i),l=new h(r);if(c.cmp(o.p)>=0||l.cmp(o.p)>=0||(c=c.toRed(o.red),l=l.toRed(o.red),(6===n||7===n)&&l.isOdd()!==(7===n)))return null;const y=c.redSqr().redIMul(c);return l.redSqr().redISub(y.redIAdd(o.b)).isZero()?b.keyPair({pub:{x:c,y:l}}):null}(i,n.subarray(1,33),n.subarray(33,65));default:return null}}function f(n,i){const r=i.encode(null,33===n.length);for(let c=0;c<n.length;++c)n[c]=r[c]}_.exports={contextRandomize:()=>0,privateKeyVerify(n){const i=new h(n);return i.cmp(o.n)<0&&!i.isZero()?0:1},privateKeyNegate(n){const i=new h(n),r=o.n.sub(i).umod(o.n).toArrayLike(Uint8Array,"be",32);return n.set(r),0},privateKeyTweakAdd(n,i){const r=new h(i);if(r.cmp(o.n)>=0||(r.iadd(new h(n)),r.cmp(o.n)>=0&&r.isub(o.n),r.isZero()))return 1;const c=r.toArrayLike(Uint8Array,"be",32);return n.set(c),0},privateKeyTweakMul(n,i){let r=new h(i);if(r.cmp(o.n)>=0||r.isZero())return 1;r.imul(new h(n)),r.cmp(o.n)>=0&&(r=r.umod(o.n));const c=r.toArrayLike(Uint8Array,"be",32);return n.set(c),0},publicKeyVerify:n=>null===t(n)?1:0,publicKeyCreate(n,i){const r=new h(i);return r.cmp(o.n)>=0||r.isZero()?1:(f(n,b.keyFromPrivate(i).getPublic()),0)},publicKeyConvert(n,i){const r=t(i);return null===r?1:(f(n,r.getPublic()),0)},publicKeyNegate(n,i){const r=t(i);if(null===r)return 1;const c=r.getPublic();return c.y=c.y.redNeg(),f(n,c),0},publicKeyCombine(n,i){const r=new Array(i.length);for(let l=0;l<i.length;++l)if(r[l]=t(i[l]),null===r[l])return 1;let c=r[0].getPublic();for(let l=1;l<r.length;++l)c=c.add(r[l].pub);return c.isInfinity()?2:(f(n,c),0)},publicKeyTweakAdd(n,i,r){const c=t(i);if(null===c)return 1;if((r=new h(r)).cmp(o.n)>=0)return 2;const l=c.getPublic().add(o.g.mul(r));return l.isInfinity()?2:(f(n,l),0)},publicKeyTweakMul(n,i,r){const c=t(i);return null===c?1:(r=new h(r)).cmp(o.n)>=0||r.isZero()?2:(f(n,c.getPublic().mul(r)),0)},signatureNormalize(n){const i=new h(n.subarray(0,32)),r=new h(n.subarray(32,64));return i.cmp(o.n)>=0||r.cmp(o.n)>=0?1:(1===r.cmp(b.nh)&&n.set(o.n.sub(r).toArrayLike(Uint8Array,"be",32),32),0)},signatureExport(n,i){const r=i.subarray(0,32),c=i.subarray(32,64);if(new h(r).cmp(o.n)>=0||new h(c).cmp(o.n)>=0)return 1;const{output:l}=n;let y=l.subarray(4,37);y[0]=0,y.set(r,1);let E=33,S=0;for(;E>1&&0===y[S]&&!(128&y[S+1]);--E,++S);if(y=y.subarray(S),128&y[0]||E>1&&0===y[0]&&!(128&y[1]))return 1;let B=l.subarray(39,72);B[0]=0,B.set(c,1);let g=33,T=0;for(;g>1&&0===B[T]&&!(128&B[T+1]);--g,++T);return B=B.subarray(T),128&B[0]||g>1&&0===B[0]&&!(128&B[1])?1:(n.outputlen=6+E+g,l[0]=48,l[1]=n.outputlen-2,l[2]=2,l[3]=y.length,l.set(y,4),l[4+E]=2,l[5+E]=B.length,l.set(B,6+E),0)},signatureImport(n,i){if(i.length<8||i.length>72||48!==i[0]||i[1]!==i.length-2||2!==i[2])return 1;const r=i[3];if(0===r||5+r>=i.length||2!==i[4+r])return 1;const c=i[5+r];if(0===c||6+r+c!==i.length||128&i[4]||r>1&&0===i[4]&&!(128&i[5])||128&i[r+6]||c>1&&0===i[r+6]&&!(128&i[r+7]))return 1;let l=i.subarray(4,4+r);if(33===l.length&&0===l[0]&&(l=l.subarray(1)),l.length>32)return 1;let y=i.subarray(6+r);if(33===y.length&&0===y[0]&&(y=y.slice(1)),y.length>32)throw new Error("S length is too long");let E=new h(l);E.cmp(o.n)>=0&&(E=new h(0));let S=new h(i.subarray(6+r));return S.cmp(o.n)>=0&&(S=new h(0)),n.set(E.toArrayLike(Uint8Array,"be",32),0),n.set(S.toArrayLike(Uint8Array,"be",32),32),0},ecdsaSign(n,i,r,c,l){if(l){const S=l;l=B=>{const g=S(i,r,null,c,B);if(!(g instanceof Uint8Array&&32===g.length))throw new Error("This is the way");return new h(g)}}const y=new h(r);if(y.cmp(o.n)>=0||y.isZero())return 1;let E;try{E=b.sign(i,r,{canonical:!0,k:l,pers:c})}catch{return 1}return n.signature.set(E.r.toArrayLike(Uint8Array,"be",32),0),n.signature.set(E.s.toArrayLike(Uint8Array,"be",32),32),n.recid=E.recoveryParam,0},ecdsaVerify(n,i,r){const c={r:n.subarray(0,32),s:n.subarray(32,64)},l=new h(c.r),y=new h(c.s);if(l.cmp(o.n)>=0||y.cmp(o.n)>=0)return 1;if(1===y.cmp(b.nh)||l.isZero()||y.isZero())return 3;const E=t(r);if(null===E)return 2;const S=E.getPublic();return b.verify(i,c,S)?0:3},ecdsaRecover(n,i,r,c){const l={r:i.slice(0,32),s:i.slice(32,64)},y=new h(l.r),E=new h(l.s);if(y.cmp(o.n)>=0||E.cmp(o.n)>=0)return 1;if(y.isZero()||E.isZero())return 2;let S;try{S=b.recoverPubKey(c,l,r)}catch{return 2}return f(n,S),0},ecdh(n,i,r,c,l,y,E){const S=t(i);if(null===S)return 1;const B=new h(r);if(B.cmp(o.n)>=0||B.isZero())return 2;const g=S.getPublic().mul(B);if(void 0===l){const T=g.encode(null,!0),w=b.hash().update(T).digest();for(let P=0;P<32;++P)n[P]=w[P]}else{y||(y=new Uint8Array(32));const T=g.getX().toArray("be",32);for(let C=0;C<32;++C)y[C]=T[C];E||(E=new Uint8Array(32));const w=g.getY().toArray("be",32);for(let C=0;C<32;++C)E[C]=w[C];const P=l(y,E,c);if(!(P instanceof Uint8Array&&P.length===n.length))return 2;n.set(P)}return 0}}},50911:_=>{const e_IMPOSSIBLE_CASE="Impossible case. Please create issue.",e_TWEAK_ADD="The tweak was out of range or the resulted private key is invalid",e_TWEAK_MUL="The tweak was out of range or equal to zero",e_PUBKEY_PARSE="Public Key could not be parsed",e_PUBKEY_SERIALIZE="Public Key serialization error",e_SIG_PARSE="Signature could not be parsed";function d(s,u){if(!s)throw new Error(u)}function v(s,u,t){if(d(u instanceof Uint8Array,`Expected ${s} to be an Uint8Array`),void 0!==t)if(Array.isArray(t)){const n=`Expected ${s} to be an Uint8Array with length [${t.join(", ")}]`;d(t.includes(u.length),n)}else d(u.length===t,`Expected ${s} to be an Uint8Array with length ${t}`)}function b(s){d("Boolean"===h(s),"Expected compressed to be a Boolean")}function o(s=(t=>new Uint8Array(t)),u){return"function"==typeof s&&(s=s(u)),v("output",s,u),s}function h(s){return Object.prototype.toString.call(s).slice(8,-1)}_.exports=s=>({contextRandomize(u){if(1===(d(null===u||u instanceof Uint8Array,"Expected seed to be an Uint8Array or null"),null!==u&&v("seed",u,32),s.contextRandomize(u)))throw new Error("Unknow error on context randomization")},privateKeyVerify:u=>(v("private key",u,32),0===s.privateKeyVerify(u)),privateKeyNegate(u){switch(v("private key",u,32),s.privateKeyNegate(u)){case 0:return u;case 1:throw new Error(e_IMPOSSIBLE_CASE)}},privateKeyTweakAdd(u,t){switch(v("private key",u,32),v("tweak",t,32),s.privateKeyTweakAdd(u,t)){case 0:return u;case 1:throw new Error(e_TWEAK_ADD)}},privateKeyTweakMul(u,t){switch(v("private key",u,32),v("tweak",t,32),s.privateKeyTweakMul(u,t)){case 0:return u;case 1:throw new Error(e_TWEAK_MUL)}},publicKeyVerify:u=>(v("public key",u,[33,65]),0===s.publicKeyVerify(u)),publicKeyCreate(u,t=!0,f){switch(v("private key",u,32),b(t),f=o(f,t?33:65),s.publicKeyCreate(f,u)){case 0:return f;case 1:throw new Error("Private Key is invalid");case 2:throw new Error(e_PUBKEY_SERIALIZE)}},publicKeyConvert(u,t=!0,f){switch(v("public key",u,[33,65]),b(t),f=o(f,t?33:65),s.publicKeyConvert(f,u)){case 0:return f;case 1:throw new Error(e_PUBKEY_PARSE);case 2:throw new Error(e_PUBKEY_SERIALIZE)}},publicKeyNegate(u,t=!0,f){switch(v("public key",u,[33,65]),b(t),f=o(f,t?33:65),s.publicKeyNegate(f,u)){case 0:return f;case 1:throw new Error(e_PUBKEY_PARSE);case 2:throw new Error(e_IMPOSSIBLE_CASE);case 3:throw new Error(e_PUBKEY_SERIALIZE)}},publicKeyCombine(u,t=!0,f){d(Array.isArray(u),"Expected public keys to be an Array"),d(u.length>0,"Expected public keys array will have more than zero items");for(const n of u)v("public key",n,[33,65]);switch(b(t),f=o(f,t?33:65),s.publicKeyCombine(f,u)){case 0:return f;case 1:throw new Error(e_PUBKEY_PARSE);case 2:throw new Error("The sum of the public keys is not valid");case 3:throw new Error(e_PUBKEY_SERIALIZE)}},publicKeyTweakAdd(u,t,f=!0,n){switch(v("public key",u,[33,65]),v("tweak",t,32),b(f),n=o(n,f?33:65),s.publicKeyTweakAdd(n,u,t)){case 0:return n;case 1:throw new Error(e_PUBKEY_PARSE);case 2:throw new Error(e_TWEAK_ADD)}},publicKeyTweakMul(u,t,f=!0,n){switch(v("public key",u,[33,65]),v("tweak",t,32),b(f),n=o(n,f?33:65),s.publicKeyTweakMul(n,u,t)){case 0:return n;case 1:throw new Error(e_PUBKEY_PARSE);case 2:throw new Error(e_TWEAK_MUL)}},signatureNormalize(u){switch(v("signature",u,64),s.signatureNormalize(u)){case 0:return u;case 1:throw new Error(e_SIG_PARSE)}},signatureExport(u,t){v("signature",u,64);const f={output:t=o(t,72),outputlen:72};switch(s.signatureExport(f,u)){case 0:return t.slice(0,f.outputlen);case 1:throw new Error(e_SIG_PARSE);case 2:throw new Error(e_IMPOSSIBLE_CASE)}},signatureImport(u,t){switch(v("signature",u),t=o(t,64),s.signatureImport(t,u)){case 0:return t;case 1:throw new Error(e_SIG_PARSE);case 2:throw new Error(e_IMPOSSIBLE_CASE)}},ecdsaSign(u,t,f={},n){v("message",u,32),v("private key",t,32),d("Object"===h(f),"Expected options to be an Object"),void 0!==f.data&&v("options.data",f.data),void 0!==f.noncefn&&d("Function"===h(f.noncefn),"Expected options.noncefn to be a Function");const i={signature:n=o(n,64),recid:null};switch(s.ecdsaSign(i,u,t,f.data,f.noncefn)){case 0:return i;case 1:throw new Error("The nonce generation function failed, or the private key was invalid");case 2:throw new Error(e_IMPOSSIBLE_CASE)}},ecdsaVerify(u,t,f){switch(v("signature",u,64),v("message",t,32),v("public key",f,[33,65]),s.ecdsaVerify(u,t,f)){case 0:return!0;case 3:return!1;case 1:throw new Error(e_SIG_PARSE);case 2:throw new Error(e_PUBKEY_PARSE)}},ecdsaRecover(u,t,f,n=!0,i){switch(v("signature",u,64),d("Number"===h(t)&&t>=0&&t<=3,"Expected recovery id to be a Number within interval [0, 3]"),v("message",f,32),b(n),i=o(i,n?33:65),s.ecdsaRecover(i,u,t,f)){case 0:return i;case 1:throw new Error(e_SIG_PARSE);case 2:throw new Error("Public key could not be recover");case 3:throw new Error(e_IMPOSSIBLE_CASE)}},ecdh(u,t,f={},n){switch(v("public key",u,[33,65]),v("private key",t,32),d("Object"===h(f),"Expected options to be an Object"),void 0!==f.data&&v("options.data",f.data),void 0!==f.hashfn?(d("Function"===h(f.hashfn),"Expected options.hashfn to be a Function"),void 0!==f.xbuf&&v("options.xbuf",f.xbuf,32),void 0!==f.ybuf&&v("options.ybuf",f.ybuf,32),v("output",n)):n=o(n,32),s.ecdh(n,u,t,f.data,f.hashfn,f.xbuf,f.ybuf)){case 0:return n;case 1:throw new Error(e_PUBKEY_PARSE);case 2:throw new Error("Scalar was invalid (zero or overflow)")}}})}}]);