PageSourceSearch

https://devconnect.org/_next/static/chunks/8720.742ba074941e3fb1.js

js devconnect.org collected 2026-10-03 21:04:36 UTC 26,055 bytes, 1 lines download raw bytes

vendor: 3,313 bytes, line 1
1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8720],{52811:(t,e,r)=>{r.d(e,{w:()=>o});var n=r(55848);class i extends n.Vw{constructor(t,e){super(),this.finished=!1,this.destroyed=!1,(0,n.sd)(t);const r=(0,n.ZJ)(e);if(this.iHash=t.create(),"function"!=typeof this.iHash.update)throw Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const i=this.blockLen,o=new Uint8Array(i);o.set(r.length>i?t.create().update(r).digest():r);for(let t=0;t<o.length;t++)o[t]^=54;this.iHash.update(o),this.oHash=t.create();for(let t=0;t<o.length;t++)o[t]^=106;this.oHash.update(o),(0,n.uH)(o)}update(t){return(0,n.CC)(this),this.iHash.update(t),this}digestInto(t){(0,n.CC)(this),(0,n.DO)(t,this.outputLen),this.finished=!0,this.iHash.digestInto(t),this.oHash.update(t),this.oHash.digestInto(t),this.destroy()}digest(){let t=new Uint8Array(this.oHash.outputLen);return this.digestInto(t),t}_cloneInto(t){t||(t=Object.create(Object.getPrototypeOf(this),{}));let{oHash:e,iHash:r,finished:n,destroyed:i,blockLen:o,outputLen:l}=this;return t.finished=n,t.destroyed=i,t.blockLen=o,t.outputLen=l,t.oHash=e._cloneInto(t.oHash),t.iHash=r._cloneInto(t.iHash),t}clone(){return this._cloneInto()}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}}let o=(t,e,r)=>new i(t,e).update(r).digest();o.create=(t,e)=>new i(t,e)},78720:(t,e,r)=>{let n;r.d(e,{secp256k1:()=>tS});var i,o,l=r(24461),f=r(52811),s=r(55848);let a=BigInt(0),u=BigInt(1);function d(t){return t instanceof Uint8Array||ArrayBuffer.isView(t)&&"Uint8Array"===t.constructor.name}function h(t){if(!d(t))throw Error("Uint8Array expected")}function c(t,e){if("boolean"!=typeof e)throw Error(t+" boolean expected, got "+e)}function g(t){let e=t.toString(16);return 1&e.length?"0"+e:e}function p(t){if("string"!=typeof t)throw Error("hex string expected, got "+typeof t);return""===t?a:BigInt("0x"+t)}let y="function"==typeof Uint8Array.from([]).toHex&&"function"==typeof Uint8Array.fromHex,m=Array.from({length:256},(t,e)=>e.toString(16).padStart(2,"0"));function w(t){if(h(t),y)return t.toHex();let e="";for(let r=0;r<t.length;r++)e+=m[t[r]];return e}function E(t){return t>=48&&t<=57?t-48:t>=65&&t<=70?t-55:t>=97&&t<=102?t-87:void 0}function b(t){if("string"!=typeof t)throw Error("hex string expected, got "+typeof t);if(y)return Uint8Array.fromHex(t);let e=t.length,r=e/2;if(e%2)throw Error("hex string expected, got unpadded hex of length "+e);let n=new Uint8Array(r);for(let e=0,i=0;e<r;e++,i+=2){let r=E(t.charCodeAt(i)),o=E(t.charCodeAt(i+1));if(void 0===r||void 0===o)throw Error('hex string expected, got non-hex character "'+(t[i]+t[i+1])+'" at index '+i);n[e]=16*r+o}return n}function v(t){return p(w(t))}function B(t){return h(t),p(w(Uint8Array.from(t).reverse()))}function x(t,e){return b(t.toString(16).padStart(2*e,"0"))}function S(t,e){return x(t,e).reverse()}function A(t,e,r){let n;if("string"==typeof e)try{n=b(e)}catch(e){throw Error(t+" must be hex string or Uint8Array, cause: "+e)}else if(d(e))n=Uint8Array.from(e);else throw Error(t+" must be hex string or Uint8Array");let i=n.length;if("number"==typeof r&&i!==r)throw Error(t+" of length "+r+" expected, got "+i);return n}function I(...t){let e=0;for(let r=0;r<t.length;r++){let n=t[r];
vendor: 22,742 bytes, line 1
1h(n),e+=n.length}let r=new Uint8Array(e);for(let e=0,n=0;e<t.length;e++){let i=t[e];r.set(i,n),n+=i.length}return r}let O=t=>"bigint"==typeof t&&a<=t;function R(t,e,r){return O(t)&&O(e)&&O(r)&&e<=t&&t<r}function q(t,e,r,n){if(!R(e,r,n))throw Error("expected valid "+t+": "+r+" <= n < "+n+", got "+e)}let N=t=>(u<<BigInt(t))-u,H=t=>new Uint8Array(t),z={bigint:t=>"bigint"==typeof t,function:t=>"function"==typeof t,boolean:t=>"boolean"==typeof t,string:t=>"string"==typeof t,stringOrUint8Array:t=>"string"==typeof t||d(t),isSafeInteger:t=>Number.isSafeInteger(t),array:t=>Array.isArray(t),field:(t,e)=>e.Fp.isValid(t),hash:t=>"function"==typeof t&&Number.isSafeInteger(t.outputLen)};function U(t,e,r={}){let n=(e,r,n)=>{let i=z[r];if("function"!=typeof i)throw Error("invalid validator function");let o=t[e];if((!n||void 0!==o)&&!i(o,t))throw Error("param "+String(e)+" is invalid. Expected "+r+", got "+o)};for(let[t,r]of Object.entries(e))n(t,r,!1);for(let[t,e]of Object.entries(r))n(t,e,!0);return t}function P(t){let e=new WeakMap;return(r,...n)=>{let i=e.get(r);if(void 0!==i)return i;let o=t(r,...n);return e.set(r,o),o}}let Z=BigInt(0),C=BigInt(1),F=BigInt(2),L=BigInt(3),k=BigInt(4),T=BigInt(5),V=BigInt(8);function _(t,e){let r=t%e;return r>=Z?r:e+r}function j(t,e,r){let n=t;for(;e-- >Z;)n*=n,n%=r;return n}function D(t,e){if(t===Z)throw Error("invert: expected non-zero number");if(e<=Z)throw Error("invert: expected positive modulus, got "+e);let r=_(t,e),n=e,i=Z,o=C,l=C,f=Z;for(;r!==Z;){let t=n/r,e=n%r,s=i-l*t,a=o-f*t;n=r,r=e,i=l,o=f,l=s,f=a}if(n!==C)throw Error("invert: does not exist");return _(i,e)}function K(t,e){let r=(t.ORDER+C)/k,n=t.pow(e,r);if(!t.eql(t.sqr(n),e))throw Error("Cannot find square root");return n}function Y(t,e){let r=(t.ORDER-T)/V,n=t.mul(e,F),i=t.pow(n,r),o=t.mul(e,i),l=t.mul(t.mul(o,F),i),f=t.mul(o,t.sub(l,t.ONE));if(!t.eql(t.sqr(f),e))throw Error("Cannot find square root");return f}let M=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function W(t,e,r=!1){let n=Array(e.length).fill(r?t.ZERO:void 0),i=e.reduce((e,r,i)=>t.is0(r)?e:(n[i]=e,t.mul(e,r)),t.ONE),o=t.inv(i);return e.reduceRight((e,r,i)=>t.is0(r)?e:(n[i]=t.mul(e,n[i]),t.mul(e,r)),o),n}function G(t,e){let r=(t.ORDER-C)/F,n=t.pow(e,r),i=t.eql(n,t.ONE),o=t.eql(n,t.ZERO),l=t.eql(n,t.neg(t.ONE));if(!i&&!o&&!l)throw Error("invalid Legendre symbol result");return i?1:o?0:-1}function J(t,e){void 0!==e&&(0,s.Fe)(e);let r=void 0!==e?e:t.toString(2).length,n=Math.ceil(r/8);return{nBitLength:r,nByteLength:n}}function Q(t,e,r=!1,n={}){let i;if(t<=Z)throw Error("invalid field: expected ORDER > 0, got "+t);let{nBitLength:o,nByteLength:l}=J(t,e);if(l>2048)throw Error("invalid field: expected ORDER of <= 2048 bytes");let f=Object.freeze({ORDER:t,isLE:r,BITS:o,BYTES:l,MASK:N(o),ZERO:Z,ONE:C,create:e=>_(e,t),isValid:e=>{if("bigint"!=typeof e)throw Error("invalid field element: expected bigint, got "+typeof e);return Z<=e&&e<t},is0:t=>t===Z,isOdd:t=>(t&C)===C,neg:e=>_(-e,t),eql:(t,e)=>t===e,sqr:e=>_(e*e,t),add:(e,r)=>_(e+r,t),sub:(e,r)=>_(e-r,t),mul:(e,r)=>_(e*r,t),pow:(t,e)=>(function(t,e,r){if(r<Z)throw Error("invalid exponent, negatives unsupported");if(r===Z)return t.ONE;if(r===C)return e;let n=t.ONE,i=e;for(;r>Z;)r&C&&(n=t.mul(n,i)),i=t.sqr(i),r>>=C;return n})(f,t,e),div:(e,r)=>_(e*D(r,t),t),sqrN:t=>t*t,addN:(t,e)=>t+e,subN:(t,e)=>t-e,mulN:(t,e)=>t*e,inv:e=>D(e,t),sqrt:n.sqrt||(e=>(i||(i=t%k===L?K:t%V===T?Y:function(t){if(t<BigInt(3))throw Error("sqrt is not defined for small field");let e=t-C,r=0;for(;e%F===Z;)e/=F,r++;let n=F,i=Q(t);for(;1===G(i,n);)if(n++>1e3)throw Error("Cannot find square root: probably non-prime P");if(1===r)return K;let o=i.pow(n,e),l=(e+C)/F;return function(t,n){if(t.is0(n))return n;if(1!==G(t,n))throw Error("Cannot find square root");let i=r,f=t.mul(t.ONE,o),s=t.pow(n,e),a=t.pow(n,l);for(;!t.eql(s,t.ONE);){if(t.is0(s))return t.ZERO;let e=1,r=t.sqr(s);for(;!t.eql(r,t.ONE);)if(e++,r=t.sqr(r),e===i)throw Error("Cannot find square root");let n=C<<BigInt(i-e-1),o=t.pow(f,n);i=e,f=t.sqr(o),s=t.mul(s,f),a=t.mul(a,o)}return a}}(t)),i(f,e))),toBytes:t=>r?S(t,l):x(t,l),fromBytes:t=>{if(t.length!==l)throw Error("Field.fromBytes: expected "+l+" bytes, got "+t.length);return r?B(t):v(t)},invertBatch:t=>W(f,t),cmov:(t,e,r)=>r?e:t});return Object.freeze(f)}function X(t){if("bigint"!=typeof t)throw Error("field order must be bigint");return Math.ceil(t.toString(2).length/8)}function $(t){let e=X(t);return e+Math.ceil(e/2)}let tt=BigInt(0),te=BigInt(1);function tr(t,e){let r=e.negate();return t?r:e}function tn(t,e){if(!Number.isSafeInteger(t)||t<=0||t>e)throw Error("invalid window size, expected [1.."+e+"], got W="+t)}function ti(t,e){tn(t,e);let r=Math.ceil(e/t)+1,n=2**(t-1),i=2**t;return{windows:r,windowSize:n,mask:N(t),maxNumber:i,shiftBy:BigInt(t)}}function to(t,e,r){let{windowSize:n,mask:i,maxNumber:o,shiftBy:l}=r,f=Number(t&i),s=t>>l;f>n&&(f-=o,s+=te);let a=e*n,u=a+Math.abs(f)-1,d=0===f;return{nextN:s,offset:u,isZero:d,isNeg:f<0,isNegF:e%2!=0,offsetF:a}}let tl=new WeakMap,tf=new WeakMap;function ts(t){return tf.get(t)||1}function ta(t){return U(t.Fp,M.reduce((t,e)=>(t[e]="function",t),{ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"})),U(t,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...J(t.n,t.nBitLength),...t,...{p:t.Fp.ORDER}})}function tu(t){void 0!==t.lowS&&c("lowS",t.lowS),void 0!==t.prehash&&c("prehash",t.prehash)}class td extends Error{constructor(t=""){super(t)}}let th={Err:td,_tlv:{encode:(t,e)=>{let{Err:r}=th;if(t<0||t>256)throw new r("tlv.encode: wrong tag");if(1&e.length)throw new r("tlv.encode: unpadded data");let n=e.length/2,i=g(n);if(i.length/2&128)throw new r("tlv.encode: long form length too big");let o=n>127?g(i.length/2|128):"";return g(t)+o+i+e},decode(t,e){let{Err:r}=th,n=0;if(t<0||t>256)throw new r("tlv.encode: wrong tag");if(e.length<2||e[n++]!==t)throw new r("tlv.decode: wrong tlv");let i=e[n++],o=0;if(128&i){let t=127&i;if(!t)throw new r("tlv.decode(long): indefinite length not supported");if(t>4)throw new r("tlv.decode(long): byte length is too big");let l=e.subarray(n,n+t);if(l.length!==t)throw new r("tlv.decode: length bytes not complete");if(0===l[0])throw new r("tlv.decode(long): zero leftmost byte");for(let t of l)o=o<<8|t;if(n+=t,o<128)throw new r("tlv.decode(long): not minimal encoding")}else o=i;let l=e.subarray(n,n+o);if(l.length!==o)throw new r("tlv.decode: wrong value length");return{v:l,l:e.subarray(n+o)}}},_int:{encode(t){let{Err:e}=th;if(t<tc)throw new e("integer: negative integers are not allowed");let r=g(t);if(8&Number.parseInt(r[0],16)&&(r="00"+r),1&r.length)throw new e("unexpected DER parsing assertion: unpadded hex");return r},decode(t){let{Err:e}=th;if(128&t[0])throw new e("invalid signature integer: negative");if(0===t[0]&&!(128&t[1]))throw new e("invalid signature integer: unnecessary leading zero");return v(t)}},toSig(t){let{Err:e,_int:r,_tlv:n}=th,i=A("signature",t),{v:o,l:l}=n.decode(48,i);if(l.length)throw new e("invalid signature: left bytes after parsing");let{v:f,l:s}=n.decode(2,o),{v:a,l:u}=n.decode(2,s);if(u.length)throw new e("invalid signature: left bytes after parsing");return{r:r.decode(f),s:r.decode(a)}},hexFromSig(t){let{_tlv:e,_int:r}=th,n=e.encode(2,r.encode(t.r)),i=e.encode(2,r.encode(t.s));return e.encode(48,n+i)}},tc=BigInt(0),tg=BigInt(1),tp=(BigInt(2),BigInt(3)),ty=BigInt(4),tm=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),tw=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),tE=BigInt(0),tb=BigInt(1),tv=BigInt(2),tB=(t,e)=>(t+e/tv)/e,tx=Q(tm,void 0,void 0,{sqrt:function(t){let e=BigInt(3),r=BigInt(6),n=BigInt(11),i=BigInt(22),o=BigInt(23),l=BigInt(44),f=BigInt(88),s=t*t*t%tm,a=s*s*t%tm,u=j(a,e,tm)*a%tm,d=j(u,e,tm)*a%tm,h=j(d,tv,tm)*s%tm,c=j(h,n,tm)*h%tm,g=j(c,i,tm)*c%tm,p=j(g,l,tm)*g%tm,y=j(p,f,tm)*p%tm,m=j(y,l,tm)*g%tm,w=j(m,e,tm)*a%tm,E=j(w,o,tm)*c%tm,b=j(E,r,tm)*s%tm,v=j(b,tv,tm);if(!tx.eql(tx.sqr(v),t))throw Error("Cannot find square root");return v}}),tS=(i={a:tE,b:BigInt(7),Fp:tx,n:tw,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:t=>{let e=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),r=-tb*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),n=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),i=BigInt("0x100000000000000000000000000000000"),o=tB(e*t,tw),l=tB(-r*t,tw),f=_(t-o*e-l*n,tw),s=_(-o*r-l*e,tw),a=f>i,u=s>i;if(a&&(f=tw-f),u&&(s=tw-s),f>i||s>i)throw Error("splitScalar: Endomorphism failed, k="+t);return{k1neg:a,k1:f,k2neg:u,k2:s}}}},o=l.sc,{...(n=t=>(function(t){let e,r=(U(e=ta(t),{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...e})),{Fp:n,n:i,nByteLength:o,nBitLength:l}=r,f=n.BYTES+1,s=2*n.BYTES+1;function h(t){return _(t,i)}let{ProjectivePoint:g,normPrivateKeyToScalar:p,weierstrassEquation:y,isWithinCurveOrder:m}=function(t){var e;let r=function(t){let e=ta(t);U(e,{a:"field",b:"field"},{allowInfinityPoint:"boolean",allowedPrivateKeyLengths:"array",clearCofactor:"function",fromBytes:"function",isTorsionFree:"function",toBytes:"function",wrapPrivateKey:"boolean"});let{endo:r,Fp:n,a:i}=e;if(r){if(!n.eql(i,n.ZERO))throw Error("invalid endo: CURVE.a must be 0");if("object"!=typeof r||"bigint"!=typeof r.beta||"function"!=typeof r.splitScalar)throw Error('invalid endo: expected "beta": bigint and "splitScalar": function')}return Object.freeze({...e})}(t),{Fp:n}=r,i=Q(r.n,r.nBitLength),o=r.toBytes||((t,e,r)=>{let i=e.toAffine();return I(Uint8Array.from([4]),n.toBytes(i.x),n.toBytes(i.y))}),l=r.fromBytes||(t=>{let e=t.subarray(1);return{x:n.fromBytes(e.subarray(0,n.BYTES)),y:n.fromBytes(e.subarray(n.BYTES,2*n.BYTES))}});function f(t){let{a:e,b:i}=r,o=n.sqr(t),l=n.mul(o,t);return n.add(n.add(l,n.mul(t,e)),i)}function s(t,e){let r=n.sqr(e),i=f(t);return n.eql(r,i)}if(!s(r.Gx,r.Gy))throw Error("bad curve params: generator point");let h=n.mul(n.pow(r.a,tp),ty),g=n.mul(n.sqr(r.b),BigInt(27));if(n.is0(n.add(h,g)))throw Error("bad curve params: a or b");function p(t){let e,{allowedPrivateKeyLengths:n,nByteLength:i,wrapPrivateKey:o,n:l}=r;if(n&&"bigint"!=typeof t){if(d(t)&&(t=w(t)),"string"!=typeof t||!n.includes(t.length))throw Error("invalid private key");t=t.padStart(2*i,"0")}try{e="bigint"==typeof t?t:v(A("private key",t,i))}catch(e){throw Error("invalid private key, expected hex or "+i+" bytes, got "+typeof t)}return o&&(e=_(e,l)),q("private key",e,tg,l),e}function y(t){if(!(t instanceof b))throw Error("ProjectivePoint expected")}let m=P((t,e)=>{let{px:r,py:i,pz:o}=t;if(n.eql(o,n.ONE))return{x:r,y:i};let l=t.is0();null==e&&(e=l?n.ONE:n.inv(o));let f=n.mul(r,e),s=n.mul(i,e),a=n.mul(o,e);if(l)return{x:n.ZERO,y:n.ZERO};if(!n.eql(a,n.ONE))throw Error("invZ was invalid");return{x:f,y:s}}),E=P(t=>{if(t.is0()){if(r.allowInfinityPoint&&!n.is0(t.py))return;throw Error("bad point: ZERO")}let{x:e,y:i}=t.toAffine();if(!n.isValid(e)||!n.isValid(i))throw Error("bad point: x or y not FE");if(!s(e,i))throw Error("bad point: equation left != right");if(!t.isTorsionFree())throw Error("bad point: not in prime-order subgroup");return!0});class b{constructor(t,e,r){if(null==t||!n.isValid(t))throw Error("x required");if(null==e||!n.isValid(e)||n.is0(e))throw Error("y required");if(null==r||!n.isValid(r))throw Error("z required");this.px=t,this.py=e,this.pz=r,Object.freeze(this)}static fromAffine(t){let{x:e,y:r}=t||{};if(!t||!n.isValid(e)||!n.isValid(r))throw Error("invalid affine point");if(t instanceof b)throw Error("projective point not allowed");let i=t=>n.eql(t,n.ZERO);return i(e)&&i(r)?b.ZERO:new b(e,r,n.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(t){let e=W(n,t.map(t=>t.pz));return t.map((t,r)=>t.toAffine(e[r])).map(b.fromAffine)}static fromHex(t){let e=b.fromAffine(l(A("pointHex",t)));return e.assertValidity(),e}static fromPrivateKey(t){return b.BASE.multiply(p(t))}static msm(t,e){return function(t,e,r,n){if(!Array.isArray(r))throw Error("array expected");r.forEach((e,r)=>{if(!(e instanceof t))throw Error("invalid point at index "+r)});if(!Array.isArray(n))throw Error("array of scalars expected");n.forEach((t,r)=>{if(!e.isValid(t))throw Error("invalid scalar at index "+r)});let i=r.length,o=n.length;if(i!==o)throw Error("arrays of points and scalars must have equal length");let l=t.ZERO,f=function(t){let e;for(e=0;t>a;t>>=u,e+=1);return e}(BigInt(i)),s=1;f>12?s=f-3:f>4?s=f-2:f>0&&(s=2);let d=N(s),h=Array(Number(d)+1).fill(l),c=Math.floor((e.BITS-1)/s)*s,g=l;for(let t=c;t>=0;t-=s){h.fill(l);for(let e=0;e<o;e++){let i=Number(n[e]>>BigInt(t)&d);h[i]=h[i].add(r[e])}let e=l;for(let t=h.length-1,r=l;t>0;t--)r=r.add(h[t]),e=e.add(r);if(g=g.add(e),0!==t)for(let t=0;t<s;t++)g=g.double()}return g}(b,i,t,e)}_setWindowSize(t){S.setWindowSize(this,t)}assertValidity(){E(this)}hasEvenY(){let{y:t}=this.toAffine();if(n.isOdd)return!n.isOdd(t);throw Error("Field doesn't support isOdd")}equals(t){y(t);let{px:e,py:r,pz:i}=this,{px:o,py:l,pz:f}=t,s=n.eql(n.mul(e,f),n.mul(o,i)),a=n.eql(n.mul(r,f),n.mul(l,i));return s&&a}negate(){return new b(this.px,n.neg(this.py),this.pz)}double(){let{a:t,b:e}=r,i=n.mul(e,tp),{px:o,py:l,pz:f}=this,s=n.ZERO,a=n.ZERO,u=n.ZERO,d=n.mul(o,o),h=n.mul(l,l),c=n.mul(f,f),g=n.mul(o,l);return g=n.add(g,g),u=n.mul(o,f),u=n.add(u,u),s=n.mul(t,u),a=n.mul(i,c),a=n.add(s,a),s=n.sub(h,a),a=n.add(h,a),a=n.mul(s,a),s=n.mul(g,s),u=n.mul(i,u),c=n.mul(t,c),g=n.sub(d,c),g=n.mul(t,g),g=n.add(g,u),u=n.add(d,d),d=n.add(u,d),d=n.add(d,c),d=n.mul(d,g),a=n.add(a,d),c=n.mul(l,f),c=n.add(c,c),d=n.mul(c,g),s=n.sub(s,d),u=n.mul(c,h),u=n.add(u,u),new b(s,a,u=n.add(u,u))}add(t){y(t);let{px:e,py:i,pz:o}=this,{px:l,py:f,pz:s}=t,a=n.ZERO,u=n.ZERO,d=n.ZERO,h=r.a,c=n.mul(r.b,tp),g=n.mul(e,l),p=n.mul(i,f),m=n.mul(o,s),w=n.add(e,i),E=n.add(l,f);w=n.mul(w,E),E=n.add(g,p),w=n.sub(w,E),E=n.add(e,o);let v=n.add(l,s);return E=n.mul(E,v),v=n.add(g,m),E=n.sub(E,v),v=n.add(i,o),a=n.add(f,s),v=n.mul(v,a),a=n.add(p,m),v=n.sub(v,a),d=n.mul(h,E),a=n.mul(c,m),d=n.add(a,d),a=n.sub(p,d),d=n.add(p,d),u=n.mul(a,d),p=n.add(g,g),p=n.add(p,g),m=n.mul(h,m),E=n.mul(c,E),p=n.add(p,m),m=n.sub(g,m),m=n.mul(h,m),E=n.add(E,m),g=n.mul(p,E),u=n.add(u,g),g=n.mul(v,E),a=n.mul(w,a),a=n.sub(a,g),g=n.mul(w,p),d=n.mul(v,d),new b(a,u,d=n.add(d,g))}subtract(t){return this.add(t.negate())}is0(){return this.equals(b.ZERO)}wNAF(t){return S.wNAFCached(this,t,b.normalizeZ)}multiplyUnsafe(t){let{endo:e,n:i}=r;q("scalar",t,tc,i);let o=b.ZERO;if(t===tc)return o;if(this.is0()||t===tg)return this;if(!e||S.hasPrecomputes(this))return S.wNAFCachedUnsafe(this,t,b.normalizeZ);let{k1neg:l,k1:f,k2neg:s,k2:a}=e.splitScalar(t),u=o,d=o,h=this;for(;f>tc||a>tc;)f&tg&&(u=u.add(h)),a&tg&&(d=d.add(h)),h=h.double(),f>>=tg,a>>=tg;return l&&(u=u.negate()),s&&(d=d.negate()),d=new b(n.mul(d.px,e.beta),d.py,d.pz),u.add(d)}multiply(t){let e,i,{endo:o,n:l}=r;if(q("scalar",t,tg,l),o){let{k1neg:r,k1:l,k2neg:f,k2:s}=o.splitScalar(t),{p:a,f:u}=this.wNAF(l),{p:d,f:h}=this.wNAF(s);a=S.constTimeNegate(r,a),d=S.constTimeNegate(f,d),d=new b(n.mul(d.px,o.beta),d.py,d.pz),e=a.add(d),i=u.add(h)}else{let{p:r,f:n}=this.wNAF(t);e=r,i=n}return b.normalizeZ([e,i])[0]}multiplyAndAddUnsafe(t,e,r){let n=b.BASE,i=(t,e)=>e!==tc&&e!==tg&&t.equals(n)?t.multiply(e):t.multiplyUnsafe(e),o=i(this,e).add(i(t,r));return o.is0()?void 0:o}toAffine(t){return m(this,t)}isTorsionFree(){let{h:t,isTorsionFree:e}=r;if(t===tg)return!0;if(e)return e(b,this);throw Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){let{h:t,clearCofactor:e}=r;return t===tg?this:e?e(b,this):this.multiplyUnsafe(r.h)}toRawBytes(t=!0){return c("isCompressed",t),this.assertValidity(),o(b,this,t)}toHex(t=!0){return c("isCompressed",t),w(this.toRawBytes(t))}}b.BASE=new b(r.Gx,r.Gy,n.ONE),b.ZERO=new b(n.ZERO,n.ONE,n.ZERO);let{endo:B,nBitLength:x}=r,S=(e=B?Math.ceil(x/2):x,{constTimeNegate:tr,hasPrecomputes:t=>1!==ts(t),unsafeLadder(t,e,r=b.ZERO){let n=t;for(;e>tt;)e&te&&(r=r.add(n)),n=n.double(),e>>=te;return r},precomputeWindow(t,r){let{windows:n,windowSize:i}=ti(r,e),o=[],l=t,f=l;for(let t=0;t<n;t++){f=l,o.push(f);for(let t=1;t<i;t++)f=f.add(l),o.push(f);l=f.double()}return o},wNAF(t,r,n){let i=b.ZERO,o=b.BASE,l=ti(t,e);for(let t=0;t<l.windows;t++){let{nextN:e,offset:f,isZero:s,isNeg:a,isNegF:u,offsetF:d}=to(n,t,l);n=e,s?o=o.add(tr(u,r[d])):i=i.add(tr(a,r[f]))}return{p:i,f:o}},wNAFUnsafe(t,r,n,i=b.ZERO){let o=ti(t,e);for(let t=0;t<o.windows&&n!==tt;t++){let{nextN:e,offset:l,isZero:f,isNeg:s}=to(n,t,o);if(n=e,!f){let t=r[l];i=i.add(s?t.negate():t)}}return i},getPrecomputes(t,e,r){let n=tl.get(e);return n||(n=this.precomputeWindow(e,t),1!==t&&tl.set(e,r(n))),n},wNAFCached(t,e,r){let n=ts(t);return this.wNAF(n,this.getPrecomputes(n,t,r),e)},wNAFCachedUnsafe(t,e,r,n){let i=ts(t);return 1===i?this.unsafeLadder(t,e,n):this.wNAFUnsafe(i,this.getPrecomputes(i,t,r),e,n)},setWindowSize(t,r){tn(r,e),tf.set(t,r),tl.delete(t)}});return{CURVE:r,ProjectivePoint:b,normPrivateKeyToScalar:p,weierstrassEquation:f,isWithinCurveOrder:function(t){return R(t,tg,r.n)}}}({...r,toBytes(t,e,r){let i=e.toAffine(),o=n.toBytes(i.x);return(c("isCompressed",r),r)?I(Uint8Array.from([e.hasEvenY()?2:3]),o):I(Uint8Array.from([4]),o,n.toBytes(i.y))},fromBytes(t){let e=t.length,r=t[0],i=t.subarray(1);if(e===f&&(2===r||3===r)){let t,e=v(i);if(!R(e,tg,n.ORDER))throw Error("Point is not on curve");let o=y(e);try{t=n.sqrt(o)}catch(t){throw Error("Point is not on curve"+(t instanceof Error?": "+t.message:""))}return(1&r)==1!=((t&tg)===tg)&&(t=n.neg(t)),{x:e,y:t}}if(e===s&&4===r)return{x:n.fromBytes(i.subarray(0,n.BYTES)),y:n.fromBytes(i.subarray(n.BYTES,2*n.BYTES))};throw Error("invalid Point, expected length of "+f+", or uncompressed "+s+", got "+e)}}),E=(t,e,r)=>v(t.slice(e,r));class O{constructor(t,e,r){q("r",t,tg,i),q("s",e,tg,i),this.r=t,this.s=e,null!=r&&(this.recovery=r),Object.freeze(this)}static fromCompact(t){return new O(E(t=A("compactSignature",t,2*o),0,o),E(t,o,2*o))}static fromDER(t){let{r:e,s:r}=th.toSig(A("DER",t));return new O(e,r)}assertValidity(){}addRecoveryBit(t){return new O(this.r,this.s,t)}recoverPublicKey(t){let{r:e,s:o,recovery:l}=this,f=F(A("msgHash",t));if(null==l||![0,1,2,3].includes(l))throw Error("recovery id invalid");let s=2===l||3===l?e+r.n:e;if(s>=n.ORDER)throw Error("recovery id 2 or 3 invalid");let a=(1&l)==0?"02":"03",u=g.fromHex(a+w(x(s,n.BYTES))),d=D(s,i),c=h(-f*d),p=h(o*d),y=g.BASE.multiplyAndAddUnsafe(u,c,p);if(!y)throw Error("point at infinify");return y.assertValidity(),y}hasHighS(){return this.s>i>>tg}normalizeS(){return this.hasHighS()?new O(this.r,h(-this.s),this.recovery):this}toDERRawBytes(){return b(this.toDERHex())}toDERHex(){return th.hexFromSig(this)}toCompactRawBytes(){return b(this.toCompactHex())}toCompactHex(){return w(x(this.r,o))+w(x(this.s,o))}}function z(t){if("bigint"==typeof t)return!1;if(t instanceof g)return!0;let e=A("key",t).length,i=n.BYTES,l=i+1;if(!r.allowedPrivateKeyLengths&&o!==l)return e===l||e===2*i+1}let Z=r.bits2int||function(t){if(t.length>8192)throw Error("input is too large");let e=v(t),r=8*t.length-l;return r>0?e>>BigInt(r):e},F=r.bits2int_modN||function(t){return h(Z(t))},L=N(l);function k(t){return q("num < 2^"+l,t,tc,L),x(t,o)}let T={lowS:r.lowS,prehash:!1},V={lowS:r.lowS,prehash:!1};return g.BASE._setWindowSize(8),{CURVE:r,getPublicKey:function(t,e=!0){return g.fromPrivateKey(t).toRawBytes(e)},getSharedSecret:function(t,e,r=!0){if(!0===z(t))throw Error("first arg must be private key");if(!1===z(e))throw Error("second arg must be public key");return g.fromHex(e).multiply(p(t)).toRawBytes(r)},sign:function(t,e,o=T){let{seed:l,k2sig:f}=function(t,e,o=T){if(["recovered","canonical"].some(t=>t in o))throw Error("sign() legacy options not supported");let{hash:l,randomBytes:f}=r,{lowS:s,prehash:a,extraEntropy:u}=o;null==s&&(s=!0),t=A("msgHash",t),tu(o),a&&(t=A("prehashed msgHash",l(t)));let d=F(t),c=p(e),y=[k(c),k(d)];if(null!=u&&!1!==u){let t=!0===u?f(n.BYTES):u;y.push(A("extraEntropy",t))}return{seed:I(...y),k2sig:function(t){var e;let r=Z(t);if(!m(r))return;let n=D(r,i),o=g.BASE.multiply(r).toAffine(),l=h(o.x);if(l===tc)return;let f=h(n*h(d+l*c));if(f===tc)return;let a=2*(o.x!==l)|Number(o.y&tg),u=f;return s&&f>i>>tg&&(u=(e=f)>i>>tg?h(-e):e,a^=1),new O(l,u,a)}}}(t,e,o);return(function(t,e,r){if("number"!=typeof t||t<2)throw Error("hashLen must be a number");if("number"!=typeof e||e<2)throw Error("qByteLen must be a number");if("function"!=typeof r)throw Error("hmacFn must be a function");let n=H(t),i=H(t),o=0,l=()=>{n.fill(1),i.fill(0),o=0},f=(...t)=>r(i,n,...t),s=(t=H(0))=>{let e;if(i=f((e=[0],Uint8Array.from(e)),t),n=f(),0!==t.length){let e;i=f((e=[1],Uint8Array.from(e)),t),n=f()}},a=()=>{if(o++>=1e3)throw Error("drbg: tried 1000 values");let t=0,r=[];for(;t<e;){let e=(n=f()).slice();r.push(e),t+=n.length}return I(...r)};return(t,e)=>{let r;for(l(),s(t);!(r=e(a()));)s();return l(),r}})(r.hash.outputLen,r.nByteLength,r.hmac)(l,f)},verify:function(t,e,n,o=V){let l,f;e=A("msgHash",e),n=A("publicKey",n);let{lowS:s,prehash:a,format:u}=o;if(tu(o),"strict"in o)throw Error("options.strict was renamed to lowS");if(void 0!==u&&"compact"!==u&&"der"!==u)throw Error("format must be compact or der");let c="string"==typeof t||d(t),p=!c&&!u&&"object"==typeof t&&null!==t&&"bigint"==typeof t.r&&"bigint"==typeof t.s;if(!c&&!p)throw Error("invalid signature, expected Uint8Array, hex string or Signature instance");try{if(p&&(f=new O(t.r,t.s)),c){try{"compact"!==u&&(f=O.fromDER(t))}catch(t){if(!(t instanceof th.Err))throw t}f||"der"===u||(f=O.fromCompact(t))}l=g.fromHex(n)}catch(t){return!1}if(!f||s&&f.hasHighS())return!1;a&&(e=r.hash(e));let{r:y,s:m}=f,w=F(e),E=D(m,i),b=h(w*E),v=h(y*E),B=g.BASE.multiplyAndAddUnsafe(l,b,v)?.toAffine();return!!B&&h(B.x)===y},ProjectivePoint:g,Signature:O,utils:{isValidPrivateKey(t){try{return p(t),!0}catch(t){return!1}},normPrivateKeyToScalar:p,randomPrivateKey:()=>{let t=$(r.n);return function(t,e,r=!1){let n=t.length,i=X(e),o=$(e);if(n<16||n<o||n>1024)throw Error("expected "+o+"-1024 bytes of input, got "+n);let l=_(r?B(t):v(t),e-C)+C;return r?S(l,i):x(l,i)}(r.randomBytes(t),r.n)},precompute:(t=8,e=g.BASE)=>(e._setWindowSize(t),e.multiply(BigInt(3)),e)}}})({...i,...{hash:t,hmac:(e,...r)=>(0,f.w)(t,e,(0,s.Id)(...r)),randomBytes:s.po}}))(o),create:n})}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.