UNPKG

commit-radar

Version:

AI-powered Semantic Firewall for your git commits. Detects blast radius and logic errors.

9 lines 612 kB
#!/usr/bin/env node var Gf=Object.defineProperty;var n=(e,A)=>Gf(e,"name",{value:A,configurable:!0});var C=(e,A)=>()=>(A||e((A={exports:{}}).exports,A),A.exports);var Js=C(Pt=>{"use strict";Object.defineProperty(Pt,"__esModule",{value:!0});Pt.toCommandProperties=Pt.toCommandValue=void 0;function Mf(e){return e==null?"":typeof e=="string"||e instanceof String?e:JSON.stringify(e)}n(Mf,"toCommandValue");Pt.toCommandValue=Mf;function vf(e){return Object.keys(e).length?{title:e.title,file:e.file,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}:{}}n(vf,"toCommandProperties");Pt.toCommandProperties=vf});var EE=C(aA=>{"use strict";var _f=aA&&aA.__createBinding||(Object.create?function(e,A,t,r){r===void 0&&(r=t);var s=Object.getOwnPropertyDescriptor(A,t);(!s||("get"in s?!A.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:n(function(){return A[t]},"get")}),Object.defineProperty(e,r,s)}:function(e,A,t,r){r===void 0&&(r=t),e[r]=A[t]}),xf=aA&&aA.__setModuleDefault||(Object.create?function(e,A){Object.defineProperty(e,"default",{enumerable:!0,value:A})}:function(e,A){e.default=A}),Yf=aA&&aA.__importStar||function(e){if(e&&e.__esModule)return e;var A={};if(e!=null)for(var t in e)t!=="default"&&Object.prototype.hasOwnProperty.call(e,t)&&_f(A,e,t);return xf(A,e),A};Object.defineProperty(aA,"__esModule",{value:!0});aA.issue=aA.issueCommand=void 0;var Jf=Yf(require("os")),cE=Js();function gE(e,A,t){let r=new oi(e,A,t);process.stdout.write(r.toString()+Jf.EOL)}n(gE,"issueCommand");aA.issueCommand=gE;function Of(e,A=""){gE(e,{},A)}n(Of,"issue");aA.issue=Of;var aE="::",oi=class{static{n(this,"Command")}constructor(A,t,r){A||(A="missing.command"),this.command=A,this.properties=t,this.message=r}toString(){let A=aE+this.command;if(this.properties&&Object.keys(this.properties).length>0){A+=" ";let t=!0;for(let r in this.properties)if(this.properties.hasOwnProperty(r)){let s=this.properties[r];s&&(t?t=!1:A+=",",A+=`${r}=${Hf(s)}`)}}return A+=`${aE}${Pf(this.message)}`,A}};function Pf(e){return(0,cE.toCommandValue)(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}n(Pf,"escapeData");function Hf(e){return(0,cE.toCommandValue)(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}n(Hf,"escapeProperty")});var QE=C(cA=>{"use strict";var qf=cA&&cA.__createBinding||(Object.create?function(e,A,t,r){r===void 0&&(r=t);var s=Object.getOwnPropertyDescriptor(A,t);(!s||("get"in s?!A.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:n(function(){return A[t]},"get")}),Object.defineProperty(e,r,s)}:function(e,A,t,r){r===void 0&&(r=t),e[r]=A[t]}),Vf=cA&&cA.__setModuleDefault||(Object.create?function(e,A){Object.defineProperty(e,"default",{enumerable:!0,value:A})}:function(e,A){e.default=A}),ii=cA&&cA.__importStar||function(e){if(e&&e.__esModule)return e;var A={};if(e!=null)for(var t in e)t!=="default"&&Object.prototype.hasOwnProperty.call(e,t)&&qf(A,e,t);return Vf(A,e),A};Object.defineProperty(cA,"__esModule",{value:!0});cA.prepareKeyValueMessage=cA.issueFileCommand=void 0;var Wf=ii(require("crypto")),lE=ii(require("fs")),ni=ii(require("os")),uE=Js();function jf(e,A){let t=process.env[`GITHUB_${e}`];if(!t)throw new Error(`Unable to find environment variable for file command ${e}`);if(!lE.existsSync(t))throw new Error(`Missing file at path: ${t}`);lE.appendFileSync(t,`${(0,uE.toCommandValue)(A)}${ni.EOL}`,{encoding:"utf8"})}n(jf,"issueFileCommand");cA.issueFileCommand=jf;function Zf(e,A){let t=`ghadelimiter_${Wf.randomUUID()}`,r=(0,uE.toCommandValue)(A);if(e.includes(t))throw new Error(`Unexpected input: name should not contain the delimiter "${t}"`);if(r.includes(t))throw new Error(`Unexpected input: value should not contain the delimiter "${t}"`);return`${e}<<${t}${ni.EOL}${r}${ni.EOL}${t}`}n(Zf,"prepareKeyValueMessage");cA.prepareKeyValueMessage=Zf});var CE=C(Ht=>{"use strict";Object.defineProperty(Ht,"__esModule",{value:!0});Ht.checkBypass=Ht.getProxyUrl=void 0;function Xf(e){let A=e.protocol==="https:";if(hE(e))return;let t=A?process.env.https_proxy||process.env.HTTPS_PROXY:process.env.http_proxy||process.env.HTTP_PROXY;if(t)try{return new Os(t)}catch{if(!t.startsWith("http://")&&!t.startsWith("https://"))return new Os(`http://${t}`)}else return}n(Xf,"getProxyUrl");Ht.getProxyUrl=Xf;function hE(e){if(!e.hostname)return!1;let A=e.hostname;if(Kf(A))return!0;let t=process.env.no_proxy||process.env.NO_PROXY||"";if(!t)return!1;let r;e.port?r=Number(e.port):e.protocol==="http:"?r=80:e.protocol==="https:"&&(r=443);let s=[e.hostname.toUpperCase()];typeof r=="number"&&s.push(`${s[0]}:${r}`);for(let o of t.split(",").map(i=>i.trim().toUpperCase()).filter(i=>i))if(o==="*"||s.some(i=>i===o||i.endsWith(`.${o}`)||o.startsWith(".")&&i.endsWith(`${o}`)))return!0;return!1}n(hE,"checkBypass");Ht.checkBypass=hE;function Kf(e){let A=e.toLowerCase();return A==="localhost"||A.startsWith("127.")||A.startsWith("[::1]")||A.startsWith("[0:0:0:0:0:0:0:1]")}n(Kf,"isLoopbackAddress");var Os=class extends URL{static{n(this,"DecodedURL")}constructor(A,t){super(A,t),this._decodedUsername=decodeURIComponent(super.username),this._decodedPassword=decodeURIComponent(super.password)}get username(){return this._decodedUsername}get password(){return this._decodedPassword}}});var fE=C(qt=>{"use strict";var bM=require("net"),zf=require("tls"),ai=require("http"),BE=require("https"),$f=require("events"),kM=require("assert"),ep=require("util");qt.httpOverHttp=Ap;qt.httpsOverHttp=tp;qt.httpOverHttps=rp;qt.httpsOverHttps=sp;function Ap(e){var A=new OA(e);return A.request=ai.request,A}n(Ap,"httpOverHttp");function tp(e){var A=new OA(e);return A.request=ai.request,A.createSocket=IE,A.defaultPort=443,A}n(tp,"httpsOverHttp");function rp(e){var A=new OA(e);return A.request=BE.request,A}n(rp,"httpOverHttps");function sp(e){var A=new OA(e);return A.request=BE.request,A.createSocket=IE,A.defaultPort=443,A}n(sp,"httpsOverHttps");function OA(e){var A=this;A.options=e||{},A.proxyOptions=A.options.proxy||{},A.maxSockets=A.options.maxSockets||ai.Agent.defaultMaxSockets,A.requests=[],A.sockets=[],A.on("free",n(function(r,s,o,i){for(var a=dE(s,o,i),c=0,E=A.requests.length;c<E;++c){var g=A.requests[c];if(g.host===a.host&&g.port===a.port){A.requests.splice(c,1),g.request.onSocket(r);return}}r.destroy(),A.removeSocket(r)},"onFree"))}n(OA,"TunnelingAgent");ep.inherits(OA,$f.EventEmitter);OA.prototype.addRequest=n(function(A,t,r,s){var o=this,i=ci({request:A},o.options,dE(t,r,s));if(o.sockets.length>=this.maxSockets){o.requests.push(i);return}o.createSocket(i,function(a){a.on("free",c),a.on("close",E),a.on("agentRemove",E),A.onSocket(a);function c(){o.emit("free",a,i)}n(c,"onFree");function E(g){o.removeSocket(a),a.removeListener("free",c),a.removeListener("close",E),a.removeListener("agentRemove",E)}n(E,"onCloseOrRemove")})},"addRequest");OA.prototype.createSocket=n(function(A,t){var r=this,s={};r.sockets.push(s);var o=ci({},r.proxyOptions,{method:"CONNECT",path:A.host+":"+A.port,agent:!1,headers:{host:A.host+":"+A.port}});A.localAddress&&(o.localAddress=A.localAddress),o.proxyAuth&&(o.headers=o.headers||{},o.headers["Proxy-Authorization"]="Basic "+new Buffer(o.proxyAuth).toString("base64")),rt("making CONNECT request");var i=r.request(o);i.useChunkedEncodingByDefault=!1,i.once("response",a),i.once("upgrade",c),i.once("connect",E),i.once("error",g),i.end();function a(l){l.upgrade=!0}n(a,"onResponse");function c(l,u,Q){process.nextTick(function(){E(l,u,Q)})}n(c,"onUpgrade");function E(l,u,Q){if(i.removeAllListeners(),u.removeAllListeners(),l.statusCode!==200){rt("tunneling socket could not be established, statusCode=%d",l.statusCode),u.destroy();var h=new Error("tunneling socket could not be established, statusCode="+l.statusCode);h.code="ECONNRESET",A.request.emit("error",h),r.removeSocket(s);return}if(Q.length>0){rt("got illegal response body from proxy"),u.destroy();var h=new Error("got illegal response body from proxy");h.code="ECONNRESET",A.request.emit("error",h),r.removeSocket(s);return}return rt("tunneling connection has established"),r.sockets[r.sockets.indexOf(s)]=u,t(u)}n(E,"onConnect");function g(l){i.removeAllListeners(),rt(`tunneling socket could not be established, cause=%s `,l.message,l.stack);var u=new Error("tunneling socket could not be established, cause="+l.message);u.code="ECONNRESET",A.request.emit("error",u),r.removeSocket(s)}n(g,"onError")},"createSocket");OA.prototype.removeSocket=n(function(A){var t=this.sockets.indexOf(A);if(t!==-1){this.sockets.splice(t,1);var r=this.requests.shift();r&&this.createSocket(r,function(s){r.request.onSocket(s)})}},"removeSocket");function IE(e,A){var t=this;OA.prototype.createSocket.call(t,e,function(r){var s=e.request.getHeader("host"),o=ci({},t.options,{socket:r,servername:s?s.replace(/:.*$/,""):e.host}),i=zf.connect(0,o);t.sockets[t.sockets.indexOf(r)]=i,A(i)})}n(IE,"createSecureSocket");function dE(e,A,t){return typeof e=="string"?{host:e,port:A,localAddress:t}:e}n(dE,"toOptions");function ci(e){for(var A=1,t=arguments.length;A<t;++A){var r=arguments[A];if(typeof r=="object")for(var s=Object.keys(r),o=0,i=s.length;o<i;++o){var a=s[o];r[a]!==void 0&&(e[a]=r[a])}}return e}n(ci,"mergeOptions");var rt;process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)?rt=n(function(){var e=Array.prototype.slice.call(arguments);typeof e[0]=="string"?e[0]="TUNNEL: "+e[0]:e.unshift("TUNNEL:"),console.error.apply(console,e)},"debug"):rt=n(function(){},"debug");qt.debug=rt});var mE=C((TM,pE)=>{pE.exports=fE()});var K=C((NM,yE)=>{yE.exports={kClose:Symbol("close"),kDestroy:Symbol("destroy"),kDispatch:Symbol("dispatch"),kUrl:Symbol("url"),kWriting:Symbol("writing"),kResuming:Symbol("resuming"),kQueue:Symbol("queue"),kConnect:Symbol("connect"),kConnecting:Symbol("connecting"),kHeadersList:Symbol("headers list"),kKeepAliveDefaultTimeout:Symbol("default keep alive timeout"),kKeepAliveMaxTimeout:Symbol("max keep alive timeout"),kKeepAliveTimeoutThreshold:Symbol("keep alive timeout threshold"),kKeepAliveTimeoutValue:Symbol("keep alive timeout"),kKeepAlive:Symbol("keep alive"),kHeadersTimeout:Symbol("headers timeout"),kBodyTimeout:Symbol("body timeout"),kServerName:Symbol("server name"),kLocalAddress:Symbol("local address"),kHost:Symbol("host"),kNoRef:Symbol("no ref"),kBodyUsed:Symbol("used"),kRunning:Symbol("running"),kBlocking:Symbol("blocking"),kPending:Symbol("pending"),kSize:Symbol("size"),kBusy:Symbol("busy"),kQueued:Symbol("queued"),kFree:Symbol("free"),kConnected:Symbol("connected"),kClosed:Symbol("closed"),kNeedDrain:Symbol("need drain"),kReset:Symbol("reset"),kDestroyed:Symbol.for("nodejs.stream.destroyed"),kMaxHeadersSize:Symbol("max headers size"),kRunningIdx:Symbol("running index"),kPendingIdx:Symbol("pending index"),kError:Symbol("error"),kClients:Symbol("clients"),kClient:Symbol("client"),kParser:Symbol("parser"),kOnDestroyed:Symbol("destroy callbacks"),kPipelining:Symbol("pipelining"),kSocket:Symbol("socket"),kHostHeader:Symbol("host header"),kConnector:Symbol("connector"),kStrictContentLength:Symbol("strict content length"),kMaxRedirections:Symbol("maxRedirections"),kMaxRequests:Symbol("maxRequestsPerClient"),kProxy:Symbol("proxy agent options"),kCounter:Symbol("socket request counter"),kInterceptors:Symbol("dispatch interceptors"),kMaxResponseSize:Symbol("max response size"),kHTTP2Session:Symbol("http2Session"),kHTTP2SessionState:Symbol("http2Session state"),kHTTP2BuildRequest:Symbol("http2 build request"),kHTTP1BuildRequest:Symbol("http1 build request"),kHTTP2CopyHeaders:Symbol("http2 copy headers"),kHTTPConnVersion:Symbol("http connection version"),kRetryHandlerDefaultRetry:Symbol("retry agent default retry"),kConstruct:Symbol("constructable")}});var W=C((UM,wE)=>{"use strict";var ce=class extends Error{static{n(this,"UndiciError")}constructor(A){super(A),this.name="UndiciError",this.code="UND_ERR"}},gi=class e extends ce{static{n(this,"ConnectTimeoutError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="ConnectTimeoutError",this.message=A||"Connect Timeout Error",this.code="UND_ERR_CONNECT_TIMEOUT"}},Ei=class e extends ce{static{n(this,"HeadersTimeoutError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="HeadersTimeoutError",this.message=A||"Headers Timeout Error",this.code="UND_ERR_HEADERS_TIMEOUT"}},li=class e extends ce{static{n(this,"HeadersOverflowError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="HeadersOverflowError",this.message=A||"Headers Overflow Error",this.code="UND_ERR_HEADERS_OVERFLOW"}},ui=class e extends ce{static{n(this,"BodyTimeoutError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="BodyTimeoutError",this.message=A||"Body Timeout Error",this.code="UND_ERR_BODY_TIMEOUT"}},Qi=class e extends ce{static{n(this,"ResponseStatusCodeError")}constructor(A,t,r,s){super(A),Error.captureStackTrace(this,e),this.name="ResponseStatusCodeError",this.message=A||"Response Status Code Error",this.code="UND_ERR_RESPONSE_STATUS_CODE",this.body=s,this.status=t,this.statusCode=t,this.headers=r}},hi=class e extends ce{static{n(this,"InvalidArgumentError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="InvalidArgumentError",this.message=A||"Invalid Argument Error",this.code="UND_ERR_INVALID_ARG"}},Ci=class e extends ce{static{n(this,"InvalidReturnValueError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="InvalidReturnValueError",this.message=A||"Invalid Return Value Error",this.code="UND_ERR_INVALID_RETURN_VALUE"}},Bi=class e extends ce{static{n(this,"RequestAbortedError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="AbortError",this.message=A||"Request aborted",this.code="UND_ERR_ABORTED"}},Ii=class e extends ce{static{n(this,"InformationalError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="InformationalError",this.message=A||"Request information",this.code="UND_ERR_INFO"}},di=class e extends ce{static{n(this,"RequestContentLengthMismatchError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="RequestContentLengthMismatchError",this.message=A||"Request body length does not match content-length header",this.code="UND_ERR_REQ_CONTENT_LENGTH_MISMATCH"}},fi=class e extends ce{static{n(this,"ResponseContentLengthMismatchError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="ResponseContentLengthMismatchError",this.message=A||"Response body length does not match content-length header",this.code="UND_ERR_RES_CONTENT_LENGTH_MISMATCH"}},pi=class e extends ce{static{n(this,"ClientDestroyedError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="ClientDestroyedError",this.message=A||"The client is destroyed",this.code="UND_ERR_DESTROYED"}},mi=class e extends ce{static{n(this,"ClientClosedError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="ClientClosedError",this.message=A||"The client is closed",this.code="UND_ERR_CLOSED"}},yi=class e extends ce{static{n(this,"SocketError")}constructor(A,t){super(A),Error.captureStackTrace(this,e),this.name="SocketError",this.message=A||"Socket error",this.code="UND_ERR_SOCKET",this.socket=t}},Ps=class e extends ce{static{n(this,"NotSupportedError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="NotSupportedError",this.message=A||"Not supported error",this.code="UND_ERR_NOT_SUPPORTED"}},wi=class extends ce{static{n(this,"BalancedPoolMissingUpstreamError")}constructor(A){super(A),Error.captureStackTrace(this,Ps),this.name="MissingUpstreamError",this.message=A||"No upstream has been added to the BalancedPool",this.code="UND_ERR_BPL_MISSING_UPSTREAM"}},Di=class e extends Error{static{n(this,"HTTPParserError")}constructor(A,t,r){super(A),Error.captureStackTrace(this,e),this.name="HTTPParserError",this.code=t?`HPE_${t}`:void 0,this.data=r?r.toString():void 0}},Ri=class e extends ce{static{n(this,"ResponseExceededMaxSizeError")}constructor(A){super(A),Error.captureStackTrace(this,e),this.name="ResponseExceededMaxSizeError",this.message=A||"Response content exceeded max size",this.code="UND_ERR_RES_EXCEEDED_MAX_SIZE"}},bi=class e extends ce{static{n(this,"RequestRetryError")}constructor(A,t,{headers:r,data:s}){super(A),Error.captureStackTrace(this,e),this.name="RequestRetryError",this.message=A||"Request retry error",this.code="UND_ERR_REQ_RETRY",this.statusCode=t,this.data=s,this.headers=r}};wE.exports={HTTPParserError:Di,UndiciError:ce,HeadersTimeoutError:Ei,HeadersOverflowError:li,BodyTimeoutError:ui,RequestContentLengthMismatchError:di,ConnectTimeoutError:gi,ResponseStatusCodeError:Qi,InvalidArgumentError:hi,InvalidReturnValueError:Ci,RequestAbortedError:Bi,ClientDestroyedError:pi,ClientClosedError:mi,InformationalError:Ii,SocketError:yi,NotSupportedError:Ps,ResponseContentLengthMismatchError:fi,BalancedPoolMissingUpstreamError:wi,ResponseExceededMaxSizeError:Ri,RequestRetryError:bi}});var RE=C((GM,DE)=>{"use strict";var Hs={},ki=["Accept","Accept-Encoding","Accept-Language","Accept-Ranges","Access-Control-Allow-Credentials","Access-Control-Allow-Headers","Access-Control-Allow-Methods","Access-Control-Allow-Origin","Access-Control-Expose-Headers","Access-Control-Max-Age","Access-Control-Request-Headers","Access-Control-Request-Method","Age","Allow","Alt-Svc","Alt-Used","Authorization","Cache-Control","Clear-Site-Data","Connection","Content-Disposition","Content-Encoding","Content-Language","Content-Length","Content-Location","Content-Range","Content-Security-Policy","Content-Security-Policy-Report-Only","Content-Type","Cookie","Cross-Origin-Embedder-Policy","Cross-Origin-Opener-Policy","Cross-Origin-Resource-Policy","Date","Device-Memory","Downlink","ECT","ETag","Expect","Expect-CT","Expires","Forwarded","From","Host","If-Match","If-Modified-Since","If-None-Match","If-Range","If-Unmodified-Since","Keep-Alive","Last-Modified","Link","Location","Max-Forwards","Origin","Permissions-Policy","Pragma","Proxy-Authenticate","Proxy-Authorization","RTT","Range","Referer","Referrer-Policy","Refresh","Retry-After","Sec-WebSocket-Accept","Sec-WebSocket-Extensions","Sec-WebSocket-Key","Sec-WebSocket-Protocol","Sec-WebSocket-Version","Server","Server-Timing","Service-Worker-Allowed","Service-Worker-Navigation-Preload","Set-Cookie","SourceMap","Strict-Transport-Security","Supports-Loading-Mode","TE","Timing-Allow-Origin","Trailer","Transfer-Encoding","Upgrade","Upgrade-Insecure-Requests","User-Agent","Vary","Via","WWW-Authenticate","X-Content-Type-Options","X-DNS-Prefetch-Control","X-Frame-Options","X-Permitted-Cross-Domain-Policies","X-Powered-By","X-Requested-With","X-XSS-Protection"];for(let e=0;e<ki.length;++e){let A=ki[e],t=A.toLowerCase();Hs[A]=Hs[t]=t}Object.setPrototypeOf(Hs,null);DE.exports={wellknownHeaderNames:ki,headerNameLowerCasedRecord:Hs}});var x=C((MM,vE)=>{"use strict";var SE=require("assert"),{kDestroyed:TE,kBodyUsed:bE}=K(),{IncomingMessage:op}=require("http"),Vt=require("stream"),np=require("net"),{InvalidArgumentError:de}=W(),{Blob:kE}=require("buffer"),qs=require("util"),{stringify:ip}=require("querystring"),{headerNameLowerCasedRecord:ap}=RE(),[Fi,FE]=process.versions.node.split(".").map(e=>Number(e));function cp(){}n(cp,"nop");function Si(e){return e&&typeof e=="object"&&typeof e.pipe=="function"&&typeof e.on=="function"}n(Si,"isStream");function NE(e){return kE&&e instanceof kE||e&&typeof e=="object"&&(typeof e.stream=="function"||typeof e.arrayBuffer=="function")&&/^(Blob|File)$/.test(e[Symbol.toStringTag])}n(NE,"isBlobLike");function gp(e,A){if(e.includes("?")||e.includes("#"))throw new Error('Query params cannot be passed when url already contains "?" or "#".');let t=ip(A);return t&&(e+="?"+t),e}n(gp,"buildURL");function UE(e){if(typeof e=="string"){if(e=new URL(e),!/^https?:/.test(e.origin||e.protocol))throw new de("Invalid URL protocol: the URL must start with `http:` or `https:`.");return e}if(!e||typeof e!="object")throw new de("Invalid URL: The URL argument must be a non-null object.");if(!/^https?:/.test(e.origin||e.protocol))throw new de("Invalid URL protocol: the URL must start with `http:` or `https:`.");if(!(e instanceof URL)){if(e.port!=null&&e.port!==""&&!Number.isFinite(parseInt(e.port)))throw new de("Invalid URL: port must be a valid integer or a string representation of an integer.");if(e.path!=null&&typeof e.path!="string")throw new de("Invalid URL path: the path must be a string or null/undefined.");if(e.pathname!=null&&typeof e.pathname!="string")throw new de("Invalid URL pathname: the pathname must be a string or null/undefined.");if(e.hostname!=null&&typeof e.hostname!="string")throw new de("Invalid URL hostname: the hostname must be a string or null/undefined.");if(e.origin!=null&&typeof e.origin!="string")throw new de("Invalid URL origin: the origin must be a string or null/undefined.");let A=e.port!=null?e.port:e.protocol==="https:"?443:80,t=e.origin!=null?e.origin:`${e.protocol}//${e.hostname}:${A}`,r=e.path!=null?e.path:`${e.pathname||""}${e.search||""}`;t.endsWith("/")&&(t=t.substring(0,t.length-1)),r&&!r.startsWith("/")&&(r=`/${r}`),e=new URL(t+r)}return e}n(UE,"parseURL");function Ep(e){if(e=UE(e),e.pathname!=="/"||e.search||e.hash)throw new de("invalid url");return e}n(Ep,"parseOrigin");function lp(e){if(e[0]==="["){let t=e.indexOf("]");return SE(t!==-1),e.substring(1,t)}let A=e.indexOf(":");return A===-1?e:e.substring(0,A)}n(lp,"getHostname");function up(e){if(!e)return null;SE.strictEqual(typeof e,"string");let A=lp(e);return np.isIP(A)?"":A}n(up,"getServerName");function Qp(e){return JSON.parse(JSON.stringify(e))}n(Qp,"deepClone");function hp(e){return e!=null&&typeof e[Symbol.asyncIterator]=="function"}n(hp,"isAsyncIterable");function Cp(e){return e!=null&&(typeof e[Symbol.iterator]=="function"||typeof e[Symbol.asyncIterator]=="function")}n(Cp,"isIterable");function Bp(e){if(e==null)return 0;if(Si(e)){let A=e._readableState;return A&&A.objectMode===!1&&A.ended===!0&&Number.isFinite(A.length)?A.length:null}else{if(NE(e))return e.size!=null?e.size:null;if(GE(e))return e.byteLength}return null}n(Bp,"bodyLength");function Ti(e){return!e||!!(e.destroyed||e[TE])}n(Ti,"isDestroyed");function LE(e){let A=e&&e._readableState;return Ti(e)&&A&&!A.endEmitted}n(LE,"isReadableAborted");function Ip(e,A){e==null||!Si(e)||Ti(e)||(typeof e.destroy=="function"?(Object.getPrototypeOf(e).constructor===op&&(e.socket=null),e.destroy(A)):A&&process.nextTick((t,r)=>{t.emit("error",r)},e,A),e.destroyed!==!0&&(e[TE]=!0))}n(Ip,"destroy");var dp=/timeout=(\d+)/;function fp(e){let A=e.toString().match(dp);return A?parseInt(A[1],10)*1e3:null}n(fp,"parseKeepAliveTimeout");function pp(e){return ap[e]||e.toLowerCase()}n(pp,"headerNameToString");function mp(e,A={}){if(!Array.isArray(e))return e;for(let t=0;t<e.length;t+=2){let r=e[t].toString().toLowerCase(),s=A[r];s?(Array.isArray(s)||(s=[s],A[r]=s),s.push(e[t+1].toString("utf8"))):Array.isArray(e[t+1])?A[r]=e[t+1].map(o=>o.toString("utf8")):A[r]=e[t+1].toString("utf8")}return"content-length"in A&&"content-disposition"in A&&(A["content-disposition"]=Buffer.from(A["content-disposition"]).toString("latin1")),A}n(mp,"parseHeaders");function yp(e){let A=[],t=!1,r=-1;for(let s=0;s<e.length;s+=2){let o=e[s+0].toString(),i=e[s+1].toString("utf8");o.length===14&&(o==="content-length"||o.toLowerCase()==="content-length")?(A.push(o,i),t=!0):o.length===19&&(o==="content-disposition"||o.toLowerCase()==="content-disposition")?r=A.push(o,i)-1:A.push(o,i)}return t&&r!==-1&&(A[r]=Buffer.from(A[r]).toString("latin1")),A}n(yp,"parseRawHeaders");function GE(e){return e instanceof Uint8Array||Buffer.isBuffer(e)}n(GE,"isBuffer");function wp(e,A,t){if(!e||typeof e!="object")throw new de("handler must be an object");if(typeof e.onConnect!="function")throw new de("invalid onConnect method");if(typeof e.onError!="function")throw new de("invalid onError method");if(typeof e.onBodySent!="function"&&e.onBodySent!==void 0)throw new de("invalid onBodySent method");if(t||A==="CONNECT"){if(typeof e.onUpgrade!="function")throw new de("invalid onUpgrade method")}else{if(typeof e.onHeaders!="function")throw new de("invalid onHeaders method");if(typeof e.onData!="function")throw new de("invalid onData method");if(typeof e.onComplete!="function")throw new de("invalid onComplete method")}}n(wp,"validateHandler");function Dp(e){return!!(e&&(Vt.isDisturbed?Vt.isDisturbed(e)||e[bE]:e[bE]||e.readableDidRead||e._readableState&&e._readableState.dataEmitted||LE(e)))}n(Dp,"isDisturbed");function Rp(e){return!!(e&&(Vt.isErrored?Vt.isErrored(e):/state: 'errored'/.test(qs.inspect(e))))}n(Rp,"isErrored");function bp(e){return!!(e&&(Vt.isReadable?Vt.isReadable(e):/state: 'readable'/.test(qs.inspect(e))))}n(bp,"isReadable");function kp(e){return{localAddress:e.localAddress,localPort:e.localPort,remoteAddress:e.remoteAddress,remotePort:e.remotePort,remoteFamily:e.remoteFamily,timeout:e.timeout,bytesWritten:e.bytesWritten,bytesRead:e.bytesRead}}n(kp,"getSocketInfo");async function*Fp(e){for await(let A of e)yield Buffer.isBuffer(A)?A:Buffer.from(A)}n(Fp,"convertIterableToBuffer");var Pr;function Sp(e){if(Pr||(Pr=require("stream/web").ReadableStream),Pr.from)return Pr.from(Fp(e));let A;return new Pr({async start(){A=e[Symbol.asyncIterator]()},async pull(t){let{done:r,value:s}=await A.next();if(r)queueMicrotask(()=>{t.close()});else{let o=Buffer.isBuffer(s)?s:Buffer.from(s);t.enqueue(new Uint8Array(o))}return t.desiredSize>0},async cancel(t){await A.return()}},0)}n(Sp,"ReadableStreamFrom");function Tp(e){return e&&typeof e=="object"&&typeof e.append=="function"&&typeof e.delete=="function"&&typeof e.get=="function"&&typeof e.getAll=="function"&&typeof e.has=="function"&&typeof e.set=="function"&&e[Symbol.toStringTag]==="FormData"}n(Tp,"isFormDataLike");function Np(e){if(e){if(typeof e.throwIfAborted=="function")e.throwIfAborted();else if(e.aborted){let A=new Error("The operation was aborted");throw A.name="AbortError",A}}}n(Np,"throwIfAborted");function Up(e,A){return"addEventListener"in e?(e.addEventListener("abort",A,{once:!0}),()=>e.removeEventListener("abort",A)):(e.addListener("abort",A),()=>e.removeListener("abort",A))}n(Up,"addAbortListener");var Lp=!!String.prototype.toWellFormed;function Gp(e){return Lp?`${e}`.toWellFormed():qs.toUSVString?qs.toUSVString(e):`${e}`}n(Gp,"toUSVString");function Mp(e){if(e==null||e==="")return{start:0,end:null,size:null};let A=e?e.match(/^bytes (\d+)-(\d+)\/(\d+)?$/):null;return A?{start:parseInt(A[1]),end:A[2]?parseInt(A[2]):null,size:A[3]?parseInt(A[3]):null}:null}n(Mp,"parseRangeHeader");var ME=Object.create(null);ME.enumerable=!0;vE.exports={kEnumerableProperty:ME,nop:cp,isDisturbed:Dp,isErrored:Rp,isReadable:bp,toUSVString:Gp,isReadableAborted:LE,isBlobLike:NE,parseOrigin:Ep,parseURL:UE,getServerName:up,isStream:Si,isIterable:Cp,isAsyncIterable:hp,isDestroyed:Ti,headerNameToString:pp,parseRawHeaders:yp,parseHeaders:mp,parseKeepAliveTimeout:fp,destroy:Ip,bodyLength:Bp,deepClone:Qp,ReadableStreamFrom:Sp,isBuffer:GE,validateHandler:wp,getSocketInfo:kp,isFormDataLike:Tp,buildURL:gp,throwIfAborted:Np,addAbortListener:Up,parseRangeHeader:Mp,nodeMajor:Fi,nodeMinor:FE,nodeHasAutoSelectFamily:Fi>18||Fi===18&&FE>=13,safeHTTPMethods:["GET","HEAD","OPTIONS","TRACE"]}});var YE=C((_M,xE)=>{"use strict";var Ni=Date.now(),st,ot=[];function vp(){Ni=Date.now();let e=ot.length,A=0;for(;A<e;){let t=ot[A];t.state===0?t.state=Ni+t.delay:t.state>0&&Ni>=t.state&&(t.state=-1,t.callback(t.opaque)),t.state===-1?(t.state=-2,A!==e-1?ot[A]=ot.pop():ot.pop(),e-=1):A+=1}ot.length>0&&_E()}n(vp,"onTimeout");function _E(){st&&st.refresh?st.refresh():(clearTimeout(st),st=setTimeout(vp,1e3),st.unref&&st.unref())}n(_E,"refreshTimeout");var Vs=class{static{n(this,"Timeout")}constructor(A,t,r){this.callback=A,this.delay=t,this.opaque=r,this.state=-2,this.refresh()}refresh(){this.state===-2&&(ot.push(this),(!st||ot.length===1)&&_E()),this.state=0}clear(){this.state=-1}};xE.exports={setTimeout(e,A,t){return A<1e3?setTimeout(e,A,t):new Vs(e,A,t)},clearTimeout(e){e instanceof Vs?e.clear():clearTimeout(e)}}});var Ui=C((YM,JE)=>{"use strict";var _p=require("node:events").EventEmitter,xp=require("node:util").inherits;function It(e){if(typeof e=="string"&&(e=Buffer.from(e)),!Buffer.isBuffer(e))throw new TypeError("The needle has to be a String or a Buffer.");let A=e.length;if(A===0)throw new Error("The needle cannot be an empty String/Buffer.");if(A>256)throw new Error("The needle cannot have a length bigger than 256.");this.maxMatches=1/0,this.matches=0,this._occ=new Array(256).fill(A),this._lookbehind_size=0,this._needle=e,this._bufpos=0,this._lookbehind=Buffer.alloc(A);for(var t=0;t<A-1;++t)this._occ[e[t]]=A-1-t}n(It,"SBMH");xp(It,_p);It.prototype.reset=function(){this._lookbehind_size=0,this.matches=0,this._bufpos=0};It.prototype.push=function(e,A){Buffer.isBuffer(e)||(e=Buffer.from(e,"binary"));let t=e.length;this._bufpos=A||0;let r;for(;r!==t&&this.matches<this.maxMatches;)r=this._sbmh_feed(e);return r};It.prototype._sbmh_feed=function(e){let A=e.length,t=this._needle,r=t.length,s=t[r-1],o=-this._lookbehind_size,i;if(o<0){for(;o<0&&o<=A-r;){if(i=this._sbmh_lookup_char(e,o+r-1),i===s&&this._sbmh_memcmp(e,o,r-1))return this._lookbehind_size=0,++this.matches,this.emit("info",!0),this._bufpos=o+r;o+=this._occ[i]}if(o<0)for(;o<0&&!this._sbmh_memcmp(e,o,A-o);)++o;if(o>=0)this.emit("info",!1,this._lookbehind,0,this._lookbehind_size),this._lookbehind_size=0;else{let a=this._lookbehind_size+o;return a>0&&this.emit("info",!1,this._lookbehind,0,a),this._lookbehind.copy(this._lookbehind,0,a,this._lookbehind_size-a),this._lookbehind_size-=a,e.copy(this._lookbehind,this._lookbehind_size),this._lookbehind_size+=A,this._bufpos=A,A}}if(o+=(o>=0)*this._bufpos,e.indexOf(t,o)!==-1)return o=e.indexOf(t,o),++this.matches,o>0?this.emit("info",!0,e,this._bufpos,o):this.emit("info",!0),this._bufpos=o+r;for(o=A-r;o<A&&(e[o]!==t[0]||Buffer.compare(e.subarray(o,o+A-o),t.subarray(0,A-o))!==0);)++o;return o<A&&(e.copy(this._lookbehind,0,o,o+(A-o)),this._lookbehind_size=A-o),o>0&&this.emit("info",!1,e,this._bufpos,o<A?o:A),this._bufpos=A,A};It.prototype._sbmh_lookup_char=function(e,A){return A<0?this._lookbehind[this._lookbehind_size+A]:e[A]};It.prototype._sbmh_memcmp=function(e,A,t){for(var r=0;r<t;++r)if(this._sbmh_lookup_char(e,A+r)!==this._needle[r])return!1;return!0};JE.exports=It});var HE=C((OM,PE)=>{"use strict";var Yp=require("node:util").inherits,OE=require("node:stream").Readable;function Li(e){OE.call(this,e)}n(Li,"PartStream");Yp(Li,OE);Li.prototype._read=function(e){};PE.exports=Li});var Ws=C((HM,qE)=>{"use strict";qE.exports=n(function(A,t,r){if(!A||A[t]===void 0||A[t]===null)return r;if(typeof A[t]!="number"||isNaN(A[t]))throw new TypeError("Limit "+t+" is not a valid number");return A[t]},"getLimit")});var ZE=C((VM,jE)=>{"use strict";var WE=require("node:events").EventEmitter,Jp=require("node:util").inherits,VE=Ws(),Op=Ui(),Pp=Buffer.from(`\r \r `),Hp=/\r\n/g,qp=/^([^:]+):[ \t]?([\x00-\xFF]+)?$/;function Wt(e){WE.call(this),e=e||{};let A=this;this.nread=0,this.maxed=!1,this.npairs=0,this.maxHeaderPairs=VE(e,"maxHeaderPairs",2e3),this.maxHeaderSize=VE(e,"maxHeaderSize",80*1024),this.buffer="",this.header={},this.finished=!1,this.ss=new Op(Pp),this.ss.on("info",function(t,r,s,o){r&&!A.maxed&&(A.nread+o-s>=A.maxHeaderSize?(o=A.maxHeaderSize-A.nread+s,A.nread=A.maxHeaderSize,A.maxed=!0):A.nread+=o-s,A.buffer+=r.toString("binary",s,o)),t&&A._finish()})}n(Wt,"HeaderParser");Jp(Wt,WE);Wt.prototype.push=function(e){let A=this.ss.push(e);if(this.finished)return A};Wt.prototype.reset=function(){this.finished=!1,this.buffer="",this.header={},this.ss.reset()};Wt.prototype._finish=function(){this.buffer&&this._parseHeader(),this.ss.matches=this.ss.maxMatches;let e=this.header;this.header={},this.buffer="",this.finished=!0,this.nread=this.npairs=0,this.maxed=!1,this.emit("header",e)};Wt.prototype._parseHeader=function(){if(this.npairs===this.maxHeaderPairs)return;let e=this.buffer.split(Hp),A=e.length,t,r;for(var s=0;s<A;++s){if(e[s].length===0)continue;if((e[s][0]===" "||e[s][0]===" ")&&r){this.header[r][this.header[r].length-1]+=e[s];continue}let o=e[s].indexOf(":");if(o===-1||o===0)return;if(t=qp.exec(e[s]),r=t[1].toLowerCase(),this.header[r]=this.header[r]||[],this.header[r].push(t[2]||""),++this.npairs===this.maxHeaderPairs)break}};jE.exports=Wt});var Mi=C((jM,KE)=>{"use strict";var Gi=require("node:stream").Writable,Vp=require("node:util").inherits,Wp=Ui(),XE=HE(),jp=ZE(),Zp=45,Xp=Buffer.from("-"),Kp=Buffer.from(`\r `),zp=n(function(){},"EMPTY_FN");function fA(e){if(!(this instanceof fA))return new fA(e);if(Gi.call(this,e),!e||!e.headerFirst&&typeof e.boundary!="string")throw new TypeError("Boundary required");typeof e.boundary=="string"?this.setBoundary(e.boundary):this._bparser=void 0,this._headerFirst=e.headerFirst,this._dashes=0,this._parts=0,this._finished=!1,this._realFinish=!1,this._isPreamble=!0,this._justMatched=!1,this._firstWrite=!0,this._inHeader=!0,this._part=void 0,this._cb=void 0,this._ignoreData=!1,this._partOpts={highWaterMark:e.partHwm},this._pause=!1;let A=this;this._hparser=new jp(e),this._hparser.on("header",function(t){A._inHeader=!1,A._part.emit("header",t)})}n(fA,"Dicer");Vp(fA,Gi);fA.prototype.emit=function(e){if(e==="finish"&&!this._realFinish){if(!this._finished){let A=this;process.nextTick(function(){if(A.emit("error",new Error("Unexpected end of multipart data")),A._part&&!A._ignoreData){let t=A._isPreamble?"Preamble":"Part";A._part.emit("error",new Error(t+" terminated early due to unexpected end of multipart data")),A._part.push(null),process.nextTick(function(){A._realFinish=!0,A.emit("finish"),A._realFinish=!1});return}A._realFinish=!0,A.emit("finish"),A._realFinish=!1})}}else Gi.prototype.emit.apply(this,arguments)};fA.prototype._write=function(e,A,t){if(!this._hparser&&!this._bparser)return t();if(this._headerFirst&&this._isPreamble){this._part||(this._part=new XE(this._partOpts),this.listenerCount("preamble")!==0?this.emit("preamble",this._part):this._ignore());let r=this._hparser.push(e);if(!this._inHeader&&r!==void 0&&r<e.length)e=e.slice(r);else return t()}this._firstWrite&&(this._bparser.push(Kp),this._firstWrite=!1),this._bparser.push(e),this._pause?this._cb=t:t()};fA.prototype.reset=function(){this._part=void 0,this._bparser=void 0,this._hparser=void 0};fA.prototype.setBoundary=function(e){let A=this;this._bparser=new Wp(`\r --`+e),this._bparser.on("info",function(t,r,s,o){A._oninfo(t,r,s,o)})};fA.prototype._ignore=function(){this._part&&!this._ignoreData&&(this._ignoreData=!0,this._part.on("error",zp),this._part.resume())};fA.prototype._oninfo=function(e,A,t,r){let s,o=this,i=0,a,c=!0;if(!this._part&&this._justMatched&&A){for(;this._dashes<2&&t+i<r;)if(A[t+i]===Zp)++i,++this._dashes;else{this._dashes&&(s=Xp),this._dashes=0;break}if(this._dashes===2&&(t+i<r&&this.listenerCount("trailer")!==0&&this.emit("trailer",A.slice(t+i,r)),this.reset(),this._finished=!0,o._parts===0&&(o._realFinish=!0,o.emit("finish"),o._realFinish=!1)),this._dashes)return}this._justMatched&&(this._justMatched=!1),this._part||(this._part=new XE(this._partOpts),this._part._read=function(E){o._unpause()},this._isPreamble&&this.listenerCount("preamble")!==0?this.emit("preamble",this._part):this._isPreamble!==!0&&this.listenerCount("part")!==0?this.emit("part",this._part):this._ignore(),this._isPreamble||(this._inHeader=!0)),A&&t<r&&!this._ignoreData&&(this._isPreamble||!this._inHeader?(s&&(c=this._part.push(s)),c=this._part.push(A.slice(t,r)),c||(this._pause=!0)):!this._isPreamble&&this._inHeader&&(s&&this._hparser.push(s),a=this._hparser.push(A.slice(t,r)),!this._inHeader&&a!==void 0&&a<r&&this._oninfo(!1,A,t+a,r))),e&&(this._hparser.reset(),this._isPreamble?this._isPreamble=!1:t!==r&&(++this._parts,this._part.on("end",function(){--o._parts===0&&(o._finished?(o._realFinish=!0,o.emit("finish"),o._realFinish=!1):o._unpause())})),this._part.push(null),this._part=void 0,this._ignoreData=!1,this._justMatched=!0,this._dashes=0)};fA.prototype._unpause=function(){if(this._pause&&(this._pause=!1,this._cb)){let e=this._cb;this._cb=void 0,e()}};KE.exports=fA});var js=C((vi,el)=>{"use strict";var zE=new TextDecoder("utf-8"),$E=new Map([["utf-8",zE],["utf8",zE]]);function $p(e){let A;for(;;)switch(e){case"utf-8":case"utf8":return Hr.utf8;case"latin1":case"ascii":case"us-ascii":case"iso-8859-1":case"iso8859-1":case"iso88591":case"iso_8859-1":case"windows-1252":case"iso_8859-1:1987":case"cp1252":case"x-cp1252":return Hr.latin1;case"utf16le":case"utf-16le":case"ucs2":case"ucs-2":return Hr.utf16le;case"base64":return Hr.base64;default:if(A===void 0){A=!0,e=e.toLowerCase();continue}return Hr.other.bind(e)}}n($p,"getDecoder");var Hr={utf8:n((e,A)=>e.length===0?"":(typeof e=="string"&&(e=Buffer.from(e,A)),e.utf8Slice(0,e.length)),"utf8"),latin1:n((e,A)=>e.length===0?"":typeof e=="string"?e:e.latin1Slice(0,e.length),"latin1"),utf16le:n((e,A)=>e.length===0?"":(typeof e=="string"&&(e=Buffer.from(e,A)),e.ucs2Slice(0,e.length)),"utf16le"),base64:n((e,A)=>e.length===0?"":(typeof e=="string"&&(e=Buffer.from(e,A)),e.base64Slice(0,e.length)),"base64"),other:n((e,A)=>{if(e.length===0)return"";if(typeof e=="string"&&(e=Buffer.from(e,A)),$E.has(vi.toString()))try{return $E.get(vi).decode(e)}catch{}return typeof e=="string"?e:e.toString()},"other")};function em(e,A,t){return e&&$p(t)(e,A)}n(em,"decodeText");el.exports=em});var xi=C((KM,ol)=>{"use strict";var Zs=js(),Al=/%[a-fA-F0-9][a-fA-F0-9]/g,Am={"%00":"\0","%01":"","%02":"","%03":"","%04":"","%05":"","%06":"","%07":"\x07","%08":"\b","%09":" ","%0a":` `,"%0A":` `,"%0b":"\v","%0B":"\v","%0c":"\f","%0C":"\f","%0d":"\r","%0D":"\r","%0e":"","%0E":"","%0f":"","%0F":"","%10":"","%11":"","%12":"","%13":"","%14":"","%15":"","%16":"","%17":"","%18":"","%19":"","%1a":"","%1A":"","%1b":"\x1B","%1B":"\x1B","%1c":"","%1C":"","%1d":"","%1D":"","%1e":"","%1E":"","%1f":"","%1F":"","%20":" ","%21":"!","%22":'"',"%23":"#","%24":"$","%25":"%","%26":"&","%27":"'","%28":"(","%29":")","%2a":"*","%2A":"*","%2b":"+","%2B":"+","%2c":",","%2C":",","%2d":"-","%2D":"-","%2e":".","%2E":".","%2f":"/","%2F":"/","%30":"0","%31":"1","%32":"2","%33":"3","%34":"4","%35":"5","%36":"6","%37":"7","%38":"8","%39":"9","%3a":":","%3A":":","%3b":";","%3B":";","%3c":"<","%3C":"<","%3d":"=","%3D":"=","%3e":">","%3E":">","%3f":"?","%3F":"?","%40":"@","%41":"A","%42":"B","%43":"C","%44":"D","%45":"E","%46":"F","%47":"G","%48":"H","%49":"I","%4a":"J","%4A":"J","%4b":"K","%4B":"K","%4c":"L","%4C":"L","%4d":"M","%4D":"M","%4e":"N","%4E":"N","%4f":"O","%4F":"O","%50":"P","%51":"Q","%52":"R","%53":"S","%54":"T","%55":"U","%56":"V","%57":"W","%58":"X","%59":"Y","%5a":"Z","%5A":"Z","%5b":"[","%5B":"[","%5c":"\\","%5C":"\\","%5d":"]","%5D":"]","%5e":"^","%5E":"^","%5f":"_","%5F":"_","%60":"`","%61":"a","%62":"b","%63":"c","%64":"d","%65":"e","%66":"f","%67":"g","%68":"h","%69":"i","%6a":"j","%6A":"j","%6b":"k","%6B":"k","%6c":"l","%6C":"l","%6d":"m","%6D":"m","%6e":"n","%6E":"n","%6f":"o","%6F":"o","%70":"p","%71":"q","%72":"r","%73":"s","%74":"t","%75":"u","%76":"v","%77":"w","%78":"x","%79":"y","%7a":"z","%7A":"z","%7b":"{","%7B":"{","%7c":"|","%7C":"|","%7d":"}","%7D":"}","%7e":"~","%7E":"~","%7f":"\x7F","%7F":"\x7F","%80":"\x80","%81":"\x81","%82":"\x82","%83":"\x83","%84":"\x84","%85":"\x85","%86":"\x86","%87":"\x87","%88":"\x88","%89":"\x89","%8a":"\x8A","%8A":"\x8A","%8b":"\x8B","%8B":"\x8B","%8c":"\x8C","%8C":"\x8C","%8d":"\x8D","%8D":"\x8D","%8e":"\x8E","%8E":"\x8E","%8f":"\x8F","%8F":"\x8F","%90":"\x90","%91":"\x91","%92":"\x92","%93":"\x93","%94":"\x94","%95":"\x95","%96":"\x96","%97":"\x97","%98":"\x98","%99":"\x99","%9a":"\x9A","%9A":"\x9A","%9b":"\x9B","%9B":"\x9B","%9c":"\x9C","%9C":"\x9C","%9d":"\x9D","%9D":"\x9D","%9e":"\x9E","%9E":"\x9E","%9f":"\x9F","%9F":"\x9F","%a0":"\xA0","%A0":"\xA0","%a1":"\xA1","%A1":"\xA1","%a2":"\xA2","%A2":"\xA2","%a3":"\xA3","%A3":"\xA3","%a4":"\xA4","%A4":"\xA4","%a5":"\xA5","%A5":"\xA5","%a6":"\xA6","%A6":"\xA6","%a7":"\xA7","%A7":"\xA7","%a8":"\xA8","%A8":"\xA8","%a9":"\xA9","%A9":"\xA9","%aa":"\xAA","%Aa":"\xAA","%aA":"\xAA","%AA":"\xAA","%ab":"\xAB","%Ab":"\xAB","%aB":"\xAB","%AB":"\xAB","%ac":"\xAC","%Ac":"\xAC","%aC":"\xAC","%AC":"\xAC","%ad":"\xAD","%Ad":"\xAD","%aD":"\xAD","%AD":"\xAD","%ae":"\xAE","%Ae":"\xAE","%aE":"\xAE","%AE":"\xAE","%af":"\xAF","%Af":"\xAF","%aF":"\xAF","%AF":"\xAF","%b0":"\xB0","%B0":"\xB0","%b1":"\xB1","%B1":"\xB1","%b2":"\xB2","%B2":"\xB2","%b3":"\xB3","%B3":"\xB3","%b4":"\xB4","%B4":"\xB4","%b5":"\xB5","%B5":"\xB5","%b6":"\xB6","%B6":"\xB6","%b7":"\xB7","%B7":"\xB7","%b8":"\xB8","%B8":"\xB8","%b9":"\xB9","%B9":"\xB9","%ba":"\xBA","%Ba":"\xBA","%bA":"\xBA","%BA":"\xBA","%bb":"\xBB","%Bb":"\xBB","%bB":"\xBB","%BB":"\xBB","%bc":"\xBC","%Bc":"\xBC","%bC":"\xBC","%BC":"\xBC","%bd":"\xBD","%Bd":"\xBD","%bD":"\xBD","%BD":"\xBD","%be":"\xBE","%Be":"\xBE","%bE":"\xBE","%BE":"\xBE","%bf":"\xBF","%Bf":"\xBF","%bF":"\xBF","%BF":"\xBF","%c0":"\xC0","%C0":"\xC0","%c1":"\xC1","%C1":"\xC1","%c2":"\xC2","%C2":"\xC2","%c3":"\xC3","%C3":"\xC3","%c4":"\xC4","%C4":"\xC4","%c5":"\xC5","%C5":"\xC5","%c6":"\xC6","%C6":"\xC6","%c7":"\xC7","%C7":"\xC7","%c8":"\xC8","%C8":"\xC8","%c9":"\xC9","%C9":"\xC9","%ca":"\xCA","%Ca":"\xCA","%cA":"\xCA","%CA":"\xCA","%cb":"\xCB","%Cb":"\xCB","%cB":"\xCB","%CB":"\xCB","%cc":"\xCC","%Cc":"\xCC","%cC":"\xCC","%CC":"\xCC","%cd":"\xCD","%Cd":"\xCD","%cD":"\xCD","%CD":"\xCD","%ce":"\xCE","%Ce":"\xCE","%cE":"\xCE","%CE":"\xCE","%cf":"\xCF","%Cf":"\xCF","%cF":"\xCF","%CF":"\xCF","%d0":"\xD0","%D0":"\xD0","%d1":"\xD1","%D1":"\xD1","%d2":"\xD2","%D2":"\xD2","%d3":"\xD3","%D3":"\xD3","%d4":"\xD4","%D4":"\xD4","%d5":"\xD5","%D5":"\xD5","%d6":"\xD6","%D6":"\xD6","%d7":"\xD7","%D7":"\xD7","%d8":"\xD8","%D8":"\xD8","%d9":"\xD9","%D9":"\xD9","%da":"\xDA","%Da":"\xDA","%dA":"\xDA","%DA":"\xDA","%db":"\xDB","%Db":"\xDB","%dB":"\xDB","%DB":"\xDB","%dc":"\xDC","%Dc":"\xDC","%dC":"\xDC","%DC":"\xDC","%dd":"\xDD","%Dd":"\xDD","%dD":"\xDD","%DD":"\xDD","%de":"\xDE","%De":"\xDE","%dE":"\xDE","%DE":"\xDE","%df":"\xDF","%Df":"\xDF","%dF":"\xDF","%DF":"\xDF","%e0":"\xE0","%E0":"\xE0","%e1":"\xE1","%E1":"\xE1","%e2":"\xE2","%E2":"\xE2","%e3":"\xE3","%E3":"\xE3","%e4":"\xE4","%E4":"\xE4","%e5":"\xE5","%E5":"\xE5","%e6":"\xE6","%E6":"\xE6","%e7":"\xE7","%E7":"\xE7","%e8":"\xE8","%E8":"\xE8","%e9":"\xE9","%E9":"\xE9","%ea":"\xEA","%Ea":"\xEA","%eA":"\xEA","%EA":"\xEA","%eb":"\xEB","%Eb":"\xEB","%eB":"\xEB","%EB":"\xEB","%ec":"\xEC","%Ec":"\xEC","%eC":"\xEC","%EC":"\xEC","%ed":"\xED","%Ed":"\xED","%eD":"\xED","%ED":"\xED","%ee":"\xEE","%Ee":"\xEE","%eE":"\xEE","%EE":"\xEE","%ef":"\xEF","%Ef":"\xEF","%eF":"\xEF","%EF":"\xEF","%f0":"\xF0","%F0":"\xF0","%f1":"\xF1","%F1":"\xF1","%f2":"\xF2","%F2":"\xF2","%f3":"\xF3","%F3":"\xF3","%f4":"\xF4","%F4":"\xF4","%f5":"\xF5","%F5":"\xF5","%f6":"\xF6","%F6":"\xF6","%f7":"\xF7","%F7":"\xF7","%f8":"\xF8","%F8":"\xF8","%f9":"\xF9","%F9":"\xF9","%fa":"\xFA","%Fa":"\xFA","%fA":"\xFA","%FA":"\xFA","%fb":"\xFB","%Fb":"\xFB","%fB":"\xFB","%FB":"\xFB","%fc":"\xFC","%Fc":"\xFC","%fC":"\xFC","%FC":"\xFC","%fd":"\xFD","%Fd":"\xFD","%fD":"\xFD","%FD":"\xFD","%fe":"\xFE","%Fe":"\xFE","%fE":"\xFE","%FE":"\xFE","%ff":"\xFF","%Ff":"\xFF","%fF":"\xFF","%FF":"\xFF"};function tl(e){return Am[e]}n(tl,"encodedReplacer");var Xs=0,rl=1,_i=2,sl=3;function tm(e){let A=[],t=Xs,r="",s=!1,o=!1,i=0,a="",c=e.length;for(var E=0;E<c;++E){let g=e[E];if(g==="\\"&&s)if(o)o=!1;else{o=!0;continue}else if(g==='"')if(o)o=!1;else{s?(s=!1,t=Xs):s=!0;continue}else if(o&&s&&(a+="\\"),o=!1,(t===_i||t===sl)&&g==="'"){t===_i?(t=sl,r=a.substring(1)):t=rl,a="";continue}else if(t===Xs&&(g==="*"||g==="=")&&A.length){t=g==="*"?_i:rl,A[i]=[a,void 0],a="";continue}else if(!s&&g===";"){t=Xs,r?(a.length&&(a=Zs(a.replace(Al,tl),"binary",r)),r=""):a.length&&(a=Zs(a,"binary","utf8")),A[i]===void 0?A[i]=a:A[i][1]=a,a="",++i;continue}else if(!s&&(g===" "||g===" "))continue;a+=g}return r&&a.length?a=Zs(a.replace(Al,tl),"binary",r):a&&(a=Zs(a,"binary","utf8")),A[i]===void 0?a&&(A[i]=a):A[i][1]=a,A}n(tm,"parseParams");ol.exports=tm});var il=C(($M,nl)=>{"use strict";nl.exports=n(function(A){if(typeof A!="string")return"";for(var t=A.length-1;t>=0;--t)switch(A.charCodeAt(t)){case 47:case 92:return A=A.slice(t+1),A===".."||A==="."?"":A}return A===".."||A==="."?"":A},"basename")});var El=C((Av,gl)=>{"use strict";var{Readable:cl}=require("node:stream"),{inherits:rm}=require("node:util"),sm=Mi(),al=xi(),om=js(),nm=il(),dt=Ws(),im=/^boundary$/i,am=/^form-data$/i,cm=/^charset$/i,gm=/^filename$/i,Em=/^name$/i;Ks.detect=/^multipart\/form-data/i;function Ks(e,A){let t,r,s=this,o,i=A.limits,a=A.isPartAFile||((Ze,J,oe)=>J==="application/octet-stream"||oe!==void 0),c=A.parsedConType||[],E=A.defCharset||"utf8",g=A.preservePath,l={highWaterMark:A.fileHwm};for(t=0,r=c.length;t<r;++t)if(Array.isArray(c[t])&&im.test(c[t][0])){o=c[t][1];break}function u(){se===0&&iA&&!e._done&&(iA=!1,s.end())}if(n(u,"checkFinished"),typeof o!="string")throw new Error("Multipart: Boundary not found");let Q=dt(i,"fieldSize",1*1024*1024),h=dt(i,"fileSize",1/0),B=dt(i,"files",1/0),I=dt(i,"fields",1/0),d=dt(i,"parts",1/0),w=dt(i,"headerPairs",2e3),R=dt(i,"headerSize",80*1024),k=0,re=0,se=0,he,we,iA=!1;this._needDrain=!1,this._pause=!1,this._cb=void 0,this._nparts=0,this._boy=e;let je={boundary:o,maxHeaderPairs:w,maxHeaderSize:R,partHwm:l.highWaterMark,highWaterMark:A.highWaterMark};this.parser=new sm(je),this.parser.on("drain",function(){if(s._needDrain=!1,s._cb&&!s._pause){let Ze=s._cb;s._cb=void 0,Ze()}}).on("part",n(function Ze(J){if(++s._nparts>d)return s.parser.removeListener("part",Ze),s.parser.on("part",jt),e.hitPartsLimit=!0,e.emit("partsLimit"),jt(J);if(we){let oe=we;oe.emit("end"),oe.removeAllListeners("end")}J.on("header",function(oe){let Me,tt,Xe,xs,Ys,Jr,Or=0;if(oe["content-type"]&&(Xe=al(oe["content-type"][0]),Xe[0])){for(Me=Xe[0].toLowerCase(),t=0,r=Xe.length;t<r;++t)if(cm.test(Xe[t][0])){xs=Xe[t][1].toLowerCase();break}}if(Me===void 0&&(Me="text/plain"),xs===void 0&&(xs=E),oe["content-disposition"]){if(Xe=al(oe["content-disposition"][0]),!am.test(Xe[0]))return jt(J);for(t=0,r=Xe.length;t<r;++t)Em.test(Xe[t][0])?tt=Xe[t][1]:gm.test(Xe[t][0])&&(Jr=Xe[t][1],g||(Jr=nm(Jr)))}else return jt(J);oe["content-transfer-encoding"]?Ys=oe["content-transfer-encoding"][0].toLowerCase():Ys="7bit";let ri,si;if(a(tt,Me,Jr)){if(k===B)return e.hitFilesLimit||(e.hitFilesLimit=!0,e.emit("filesLimit")),jt(J);if(++k,e.listenerCount("file")===0){s.parser._ignore();return}++se;let Be=new Yi(l);he=Be,Be.on("end",function(){if(--se,s._pause=!1,u(),s._cb&&!s._needDrain){let RA=s._cb;s._cb=void 0,RA()}}),Be._read=function(RA){if(s._pause&&(s._pause=!1,s._cb&&!s._needDrain)){let JA=s._cb;s._cb=void 0,JA()}},e.emit("file",tt,Be,Jr,Ys,Me),ri=n(function(RA){if((Or+=RA.length)>h){let JA=h-Or+RA.length;JA>0&&Be.push(RA.slice(0,JA)),Be.truncated=!0,Be.bytesRead=h,J.removeAllListeners("data"),Be.emit("limit");return}else Be.push(RA)||(s._pause=!0);Be.bytesRead=Or},"onData"),si=n(function(){he=void 0,Be.push(null)},"onEnd")}else{if(re===I)return e.hitFieldsLimit||(e.hitFieldsLimit=!0,e.emit("fieldsLimit")),jt(J);++re,++se;let Be="",RA=!1;we=J,ri=n(function(JA){if((Or+=JA.length)>Q){let Lf=Q-(Or-JA.length);Be+=JA.toString("binary",0,Lf),RA=!0,J.removeAllListeners("data")}else Be+=JA.toString("binary")},"onData"),si=n(function(){we=void 0,Be.length&&(Be=om(Be,"binary",xs)),e.emit("field",tt,Be,!1,RA,Ys,Me),--se,u()},"onEnd")}J._readableState.sync=!1,J.on("data",ri),J.on("end",si)}).on("error",function(oe){he&&he.emit("error",oe)})},"onPart")).on("error",function(Ze){e.emit("error",Ze)}).on("finish",function(){iA=!0,u()})}n(Ks,"Multipart");Ks.prototype.write=function(e,A){let t=this.parser.write(e);t&&!this._pause?A():(this._needDrain=!t,this._cb=A)};Ks.prototype.end=function(){let e=this;e.parser.writable?e.parser.end():e._boy._done||process.nextTick(function(){e._boy._done=!0,e._boy.emit("finish")})};function jt(e){e.resume()}n(jt,"skipPart");function Yi(e){cl.call(this,e),this.bytesRead=0,this.truncated=!1}n(Yi,"FileStream");rm(Yi,cl);Yi.prototype._read=function(e){};gl.exports=Ks});var ul=C((rv,ll)=>{"use strict";var lm=/\+/g,um=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];function Ji(){this.buffer=void 0}n(Ji,"Decoder");Ji.prototype.write=function(e){e=e.replace(lm," ");let A="",t=0,r=0,s=e.length;for(;t<s;++t)this.buffer!==void 0?um[e.charCodeAt(t)]?(this.buffer+=e[t],++r,this.buffer.length===2&&(A+=String.fromCharCode(parseInt(this.buffer,16)),this.buffer=void 0)):(A+="%"+this.buffer,this.buffer=void 0,--t):e[t]==="%"&&(t>r&&(A+=e.substring(r,t),r=t),this.buffer="",++r);return r<s&&this.buffer===void 0&&(A+=e.substring(r)),A};Ji.prototype.reset=function(){this.buffer=void 0};ll.exports=Ji});var hl=C((ov,Ql)=>{"use strict";var Qm=ul(),Zt=js(),Oi=Ws(),hm=/^charset$/i;zs.detect=/^application\/x-www-form-urlencoded/i;function zs(e,A){let t=A.limits,r=A.parsedConType;this.boy=e,this.fieldSizeLimit=Oi(t,"fieldSize",1*1024*1024),this.fieldNameSizeLimit=Oi(t,"fieldNameSize",100),this.fieldsLimit=Oi(t,"fields",1/0);let s;for(var o=0,i=r.length;o<i;++o)if(Array.isArray(r[o])&&hm.test(r[o][0])){s=r[o][1].toLowerCase();break}s===void 0&&(s=A.defCharset||"utf8"),this.decoder=new Qm,this.charset=s,this._fields=0,this._state="key",this._checkingBytes=!0,this._bytesKey=0,this._bytesVal=0,this._key="",this._val="",this._keyTrunc=!1,this._valTrunc=!1,this._hitLimit=!1}n(zs,"UrlEncoded");zs.prototype.write=function(e,A){if(this._fields===this.fieldsLimit)return this.boy.hitFieldsLimit||(this.boy.hitFieldsLimit=!0,this.boy.emit("fieldsLimit")),A();let t,r,s,o=0,i=e.length;for(;o<i;)if(this._state==="key"){fo