varjNe=Object.create;varkz=Object.defineProperty;var$Ne=Object.getOwnPropertyDescriptor;varKNe=Object.getOwnPropertyNames;varZNe=Object.getPrototypeOf,ewe=Object.prototype.hasOwnProperty;vari=(t,e)=>kz(t,"name",{value:e,configurable:!0});varh=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),twe=(t,e)=>{for(varrine)kz(t,r,{get:e[r],enumerable:!0})},rwe=(t,e,r,n)=>{if(e&&typeofe=="object"||typeofe=="function")for(letoofKNe(e))!ewe.call(t,o)&&o!==r&&kz(t,o,{get:()=>e[o],enumerable:!(n=$Ne(e,o))||n.enumerable});returnt};varw=(t,e,r)=>(r=t!=null?jNe(ZNe(t)):{},rwe(e||!t||!t.__esModule?kz(r,"default",{value:t,enumerable:!0}):r,t));varkG=h(NA=>{"use strict";varmN0=require("net"),cwe=require("tls"),lI=require("http"),QG=require("https"),uwe=require("events"),zN0=require("assert"),pwe=require("util");NA.httpOverHttp=Awe;NA.httpsOverHttp=lwe;NA.httpOverHttps=dwe;NA.httpsOverHttps=bwe;functionAwe(t){vare=newIi(t);returne.request=lI.request,e}i(Awe,"httpOverHttp");functionlwe(t){vare=newIi(t);returne.request=lI.request,e.createSocket=_G,e.defaultPort=443,e}i(lwe,"httpsOverHttp");functiondwe(t){vare=newIi(t);returne.request=QG.request,e}i(dwe,"httpOverHttps");functionbwe(t){vare=newIi(t);returne.request=QG.request,e.createSocket=_G,e.defaultPort=443,e}i(bwe,"httpsOverHttps");functionIi(t){vare=this;e.options=t||{},e.proxyOptions=e.options.proxy||{},e.maxSockets=e.options.maxSockets||lI.Agent.defaultMaxSockets,e.requests=[],e.sockets=[],e.on("free",i(function(n,o,s,a){for(varc=PG(o,s,a),u=0,p=e.requests.length;u<p;++u){varl=e.requests[u];if(l.host===c.host&&l.port===c.port){e.requests.splice(u,1),l.request.onSocket(n);return}}n.destroy(),e.removeSocket(n)},"onFree"))}i(Ii,"TunnelingAgent");pwe.inherits(Ii,uwe.EventEmitter);Ii.prototype.addRequest=i(function(e,r,n,o){vars=this,a=dI({request:e},s.options,PG(r,n,o));if(s.sockets.length>=this.maxSockets){s.requests.push(a);return}s.createSocket(a,function(c){c.on("free",u),c.on("close",p),c.on("agentRemove",p),e.onSocket(c);functionu(){s.emit("free",c,a)}i(u,"onFree");functionp(l){s.removeSocket(c),c.removeListener("free",u),c.removeListener("close",p),c.removeListener("agentRemove",p)}i(p,"onCloseOrRemove")})},"addRequest");Ii.prototype.createSocket=i(function(e,r){varn=this,o={};n.sockets.push(o);vars=dI({},n.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:!1,headers:{host:e.host+":"+e.port}});e.localAddress&&(s.localAddress=e.localAddress),s.proxyAuth&&(s.headers=s.headers||{},s.headers["Proxy-Authorization"]="Basic "+newBuffer(s.proxyAuth).toString("base64")),Pa("making CONNECT request");vara=n.request(s);a.useChunkedEncodingByDefault=!1,a.once("response",c),a.once("upgrade",u),a.once("connect",p),a.once("error",l),a.end();functionc(A){A.upgrade=!0}i(c,"onResponse");functionu(A,b,M){process.nextTick(function(){p(A,b,M)})}i(u,"onUpgrade");functionp(A,b,M){if(a.removeAllListeners(),b.removeAllListeners(),A.statusCode!==200){Pa("tunneling socket could not be established, statusCode=%d",A.statusCode),b.destroy();varz=newError("tunneling socket could not be established, statusCode="+A.statusCode);z.code="ECONNRESET",e.request.emit("error",z),n.removeSocket(o);return}if(M.length>0){Pa("got illegal response body from proxy"),b.destroy();varz=newError("got illegal response body from proxy");z.code="ECONNRESET",e.request.emit("error",z),n.removeSocket(o);return}returnPa("tunneling connection has established"),n.sockets[n.sockets.indexOf(o)]=b,r(b)}i(p,"onConnect");functionl(A){a.removeAllListeners(),Pa(`tunneling socket could not be established, cause=%s
`);b.push(O),s+=O.byteLength,z&&(s=null),o=t,n=i(async function*(){for(let y of b)y.stream?yield*y.stream():yield y},"action"),a=`multipart/form-data; boundary=${u}`}else if(JX(t))o=t,s=t.size,t.type&&(a=t.type);else if(typeof t[Symbol.asyncIterator]=="function"){if(e)throw new TypeError("keepalive");if(Sb.isDisturbed(t)||t.locked)throw new TypeError("Response body object should not be disturbed or locked");r=t instanceof ReadableStream?t:SFe(t)}if((typeof o=="string"||Sb.isBuffer(o))&&(s=Buffer.byteLength(o)),n!=null){let u;r=new ReadableStream({async start(){u=n(t)[Symbol.asyncIterator]()},async pull(p){let{value:l,done:A}=await u.next();if(A)queueMicrotask(()=>{p.close(),p.byobRequest?.respond(0)});else if(!ZX(r)){let b=new Uint8Array(l);b.byteLength&&p.enqueue(b)}return p.desiredSize>0},async cancel(p){await u.return()},type:"bytes"})}return[{stream:r,source:o,length:s},a]}i(rV,"extractBody");function HFe(t,e=!1){return t instanceof ReadableStream&&(hR(!Sb.isDisturbed(t),"The body has already been consumed."),hR(!t.locked,"The stream is locked.")),rV(t,e)}i(HFe,"safelyExtractBody");function XFe(t,e){let[r,n]=e.stream.tee();return e.stream=r,{stream:n,length:e.length,source:e.source}}i(XFe,"cloneBody");function VFe(t){if(t.aborted)throw new DOMException("The operation was aborted.","AbortError")}i(VFe,"throwIfAborted");function YFe(t){return{blob(){return UA(this,r=>{let n=$X(this);return n===null?n="":n&&(n=kFe(n)),new QFe([r],{type:n})},t)},arrayBuffer(){return UA(this,r=>new Uint8Array(r).buffer,t)},text(){return UA(this,KX,t)},json(){return UA(this,jFe,t)},formData(){return UA(this,r=>{let n=$X(this);if(n!==null)switch(n.essence){case"multipart/form-data":{let o=UFe(r,n);if(o==="failure")throw new TypeError("Failed to parse body as FormData.");let s=new jX;return s[GA]=o,s}case"application/x-www-form-urlencoded":{let o=new URLSearchParams(r.toString()),s=new jX;for(let[a,c]of o)s.append(a,c);return s}}throw new TypeError('Content-Typewasnotoneof"multipart/form-data"or"application/x-www-form-urlencoded".')},t)},bytes(){returnUA(this,r=>newUint8Array(r),t)}}}i(YFe,"bodyMixinMethods");functionJFe(t){Object.assign(t.prototype,YFe(t))}i(JFe,"mixinBody");asyncfunctionUA(t,e,r){if(LFe.brandCheck(t,r),nV(t))thrownewTypeError("Body is unusable: Body has already been read");VFe(t[GA]);letn=xFe(),o=i(a=>n.reject(a),"errorSteps"),s=i(a=>{try{n.resolve(e(a))}catch(c){o(c)}},"successSteps");returnt[GA].body==null?(s(Buffer.allocUnsafe(0)),n.promise):(awaitvFe(t[GA].body,s,o),n.promise)}i(UA,"consumeBody");functionnV(t){lete=t[GA].body;returne!=null&&(e.stream.locked||Sb.isDisturbed(e.stream))}i(nV,"bodyUnusable");functionjFe(t){returnJSON.parse(KX(t))}i(jFe,"parseJSONFromBytes");function$X(t){lete=t[GA].headersList,r=TFe(e);returnr==="failure"?null:r}i($X,"bodyMimeType");oV.exports={extractBody:rV,safelyExtractBody:HFe,cloneBody:XFe,mixinBody:JFe,streamRegistry:tV,hasFinalizationRegistry:eV,bodyUnusable:nV}});vargV=h((lw0,zV)=>{"use strict";varfe=require("node:assert"),me=He(),{channels:sV}=SA(),zR=eR(),{RequestContentLengthMismatchError:Mu,ResponseContentLengthMismatchError:iV,RequestAbortedError:bV,InvalidArgumentError:$Fe,HeadersTimeoutError:KFe,HeadersOverflowError:ZFe,SocketError:XA,InformationalError:VA,BodyTimeoutError:eWe,HTTPParserError:tWe,ResponseExceededMaxSizeError:rWe}=i0(),{kUrl:fV,kReset:rr,kClient:Og,kParser:W0,kBlocking:xb,kRunning:R1,kPending:MV,kSize:aV,kWriting:Ua,kQueue:po,kNoRef:Fb,kKeepAliveDefaultTimeout:nWe,kHostHeader:oWe,kPendingIdx:sWe,kRunningIdx:fn,kError:Ft,kPipelining:Eg,kSocket:mu,kKeepAliveTimeoutValue:yg,kMaxHeadersSize:gR,kKeepAliveMaxTimeout:iWe,kKeepAliveTimeoutThreshold:aWe,kHeadersTimeout:cWe,kBodyTimeout:uWe,kStrictContentLength:CR,kMaxRequests:cV,kCounter:pWe,kMaxResponseSize:AWe,kOnError:uV,kResume:Wi,kHTTPContext:hV}=k0(),Sr=tX(),pV=Buffer.alloc(0),mg=Buffer[Symbol.species],zg=me.addListener,lWe=me.removeAllListeners,zu=Symbol("kIdleSocketValidation"),hu=Symbol("kIdleSocketValidationTimeout"),DR=Symbol("kSocketUsed"),OR;asyncfunctiondWe(){lett=process.e
`}return sV.sendHeaders.hasSubscribers&&sV.sendHeaders.publish({request:e,headers:O,socket:M}),!u||b===0?lV(z,null,t,e,M,l,O,A):me.isBuffer(u)?lV(z,u,t,e,M,l,O,A):me.isBlobLike(u)?typeof u.stream=="function"?dV(z,u.stream(),t,e,M,l,O,A):OWe(z,u,t,e,M,l,O,A):me.isStream(u)?gWe(z,u,t,e,M,l,O,A):me.isIterable(u)?dV(z,u,t,e,M,l,O,A):fe(!1),!0}i(zWe,"writeH1");function gWe(t,e,r,n,o,s,a,c){fe(s!==0||r[R1]===0,"stream body cannot be pipelined");let u=!1,p=new Bg({abort:t,socket:o,request:n,contentLength:s,client:r,expectsPayload:c,header:a}),l=i(function(z){if(!u)try{!p.write(z)&&this.pause&&this.pause()}catch(O){me.destroy(this,O)}},"onData"),A=i(function(){u||e.resume&&e.resume()},"onDrain"),b=i(function(){if(queueMicrotask(()=>{e.removeListener("error",M)}),!u){let z=new bV;queueMicrotask(()=>M(z))}},"onClose"),M=i(function(z){if(!u){if(u=!0,fe(o.destroyed||o[Ua]&&r[R1]<=1),o.off("drain",A).off("error",M),e.removeListener("data",l).removeListener("end",M).removeListener("close",b),!z)try{p.end()}catch(O){z=O}p.destroy(z),z&&(z.code!=="UND_ERR_INFO"||z.message!=="reset")?me.destroy(e,z):me.destroy(e)}},"onFinished");e.on("data",l).on("end",M).on("error",M).on("close",b),e.resume&&e.resume(),o.on("drain",A).on("error",M),e.errorEmitted??e.errored?setImmediate(()=>M(e.errored)):(e.endEmitted??e.readableEnded)&&setImmediate(()=>M(null)),(e.closeEmitted??e.closed)&&setImmediate(b)}i(gWe,"writeStream");function lV(t,e,r,n,o,s,a,c){try{e?me.isBuffer(e)&&(fe(s===e.byteLength,"buffer body must have content length"),o.cork(),o.write(`${a}content-length:${s}\r
`,"latin1"):(fe(s===null,"no body must not have content length"),o.write(`${a}\r
`,"latin1")),n.onRequestSent(),r[Wi]()}catch(u){t(u)}}i(lV,"writeBuffer");async function OWe(t,e,r,n,o,s,a,c){fe(s===e.size,"blob body must have content length");try{if(s!=null&&s!==e.size)throw new Mu;let u=Buffer.from(await e.arrayBuffer());o.cork(),o.write(`${a}content-length:${s}\r
`,"latin1"),o.write(u),o.uncork(),n.onBodySent(u),n.onRequestSent(),!c&&n.reset!==!1&&(o[rr]=!0),r[Wi]()}catch(u){t(u)}}i(OWe,"writeBlob");async function dV(t,e,r,n,o,s,a,c){fe(s!==0||r[R1]===0,"iterator body cannot be pipelined");let u=null;function p(){if(u){let b=u;u=null,b()}}i(p,"onDrain");let l=i(()=>new Promise((b,M)=>{fe(u===null),o[Ft]?M(o[Ft]):u=b}),"waitForDrain");o.on("close",p).on("drain",p);let A=new Bg({abort:t,socket:o,request:n,contentLength:s,client:r,expectsPayload:c,header:a});try{for await(let b of e){if(o[Ft])throw o[Ft];A.write(b)||await l()}A.end()}catch(b){A.destroy(b)}finally{o.off("close",p).off("drain",p)}}i(dV,"writeIterable");var Bg=class{static{i(this,"AsyncWriter")}constructor({abort:e,socket:r,request:n,contentLength:o,client:s,expectsPayload:a,header:c}){this.socket=r,this.request=n,this.contentLength=o,this.client=s,this.bytesWritten=0,this.expectsPayload=a,this.header=c,this.abort=e,r[Ua]=!0}write(e){let{socket:r,request:n,contentLength:o,client:s,bytesWritten:a,expectsPayload:c,header:u}=this;if(r[Ft])throw r[Ft];if(r.destroyed)return!1;let p=Buffer.byteLength(e);if(!p)return!0;if(o!==null&&a+p>o){if(s[CR])throw new Mu;process.emitWarning(new Mu)}r.cork(),a===0&&(!c&&n.reset!==!1&&(r[rr]=!0),o===null?r.write(`${u}transfer-encoding:chunked\r
`,"latin1"),r!==null&&o!==r){if(n[CR])throw new Mu;process.emitWarning(new Mu)}e[W0].timeout&&e[W0].timeoutType===YA&&e[W0].timeout.refresh&&e[W0].timeout.refresh(),n[Wi]()}}destroy(e){let{socket:r,client:n,abort:o}=this;r[Ua]=!1,e&&(fe(n[R1]<=1,"pipeline should only contain this request"),o(e))}};zV.exports=fWe});var IV=h((bw0,DV)=>{"use strict";var Mn=require("node:assert"),{pipeline:EWe}=require("node:stream"),Je=He(),{RequestContentLengthMismatchError:IR,RequestAbortedError:OV,SocketError:vb,InformationalError:RR}=i0(),{kUrl:qg,kReset:Ig,kClient:JA,kRunning:Rg,kPending:CWe,kQueue:Ga,kPendingIdx:NR,kRunningIdx:Ao,kError:bo,kSocket:j1,kStrictContentLength:yWe,kOnError:wR,kMaxConcurrentStreams:qV,kHTTP2Session:lo,kResume:Ha,kSize:BWe,kHTTPContext:qWe}=k0(),xi=Symbol("open streams"),EV,CV=!1,Dg;try{Dg=require("node:http2")}catch{Dg={constants:{}}}var{constants:{HTTP2_HEADER_AUTHORITY:DWe,HTTP2_HEADER_METHOD:IWe,HTTP2_HEADER_PATH:RWe,HTTP2_HEADER_SCHEME:NWe,HTTP2_HEADER_CONTENT_LENGTH:wWe,HTTP2_HEADER_EXPECT:SWe,HTTP2_HEADER_STATUS:FWe}}=Dg;function WWe(t){let e=[];for(let[r,n]of Object.entries(t))if(Array.isArray(n))for(let o of n)e.push(Buffer.from(r),Buffer.from(o));else e.push(Buffer.from(r),Buffer.from(n));return e}i(WWe,"parseH2Headers");async function xWe(t,e){t[j1]=e,CV||(CV=!0,process.emitWarning("H2 support is experimental, expect them to change at any time.",{code:"UNDICI-H2"}));let r=Dg.connect(t[qg],{createConnection:i(()=>e,"createConnection"),peerMaxConcurrentStreams:t[qV]});r[xi]=0,r[JA]=t,r[j1]=e,Je.addListener(r,"error",TWe),Je.addListener(r,"frameError",LWe),Je.addListener(r,"end",QWe),Je.addListener(r,"goaway",_We),Je.addListener(r,"close",function(){let{[JA]:o}=this,{[j1]:s}=o,a=this[j1][bo]||this[bo]||new vb("closed",Je.getSocketInfo(s));if(o[lo]=null,o.destroyed){Mn(o[CWe]===0);let c=o[Ga].splice(o[Ao]);for(let u=0;u<c.length;u++){let p=c[u];Je.errorRequest(o,p,a)}}}),r.unref(),t[lo]=r,e[lo]=r,Je.addListener(e,"error",function(o){Mn(o.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[bo]=o,this[JA][wR](o)}),Je.addListener(e,"end",function(){Je.destroy(this,new vb("other side closed",Je.getSocketInfo(this)))}),Je.addListener(e,"close",function(){let o=this[bo]||new vb("closed",Je.getSocketInfo(this));t[j1]=null,this[lo]!=null&&this[lo].destroy(o),t[NR]=t[Ao],Mn(t[Rg]===0),t.emit("disconnect",t[qg],[t],o),t[Ha]()});let n=!1;return e.on("close",()=>{n=!0}),{version:"h2",defaultPipelining:1/0,write(...o){return kWe(t,...o)},resume(){vWe(t)},destroy(o,s){n?queueMicrotask(s):e.destroy(o).on("close",s)},get destroyed(){return e.destroyed},busy(){return!1}}}i(xWe,"connectH2");function vWe(t){let e=t[j1];e?.destroyed===!1&&(t[BWe]===0&&t[qV]===0?(e.unref(),t[lo].unref()):(e.ref(),t[lo].ref()))}i(vWe,"resumeH2");function TWe(t){Mn(t.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[j1][bo]=t,this[JA][wR](t)}i(TWe,"onHttp2SessionError");function LWe(t,e,r){if(r===0){let n=new RR(`HTTP/2:"frameError"received-type${t},code${e}`);this[j1][bo]=n,this[JA][wR](n)}}i(LWe,"onHttp2FrameError");function QWe(){let t=new vb("other side closed",Je.getSocketInfo(this[j1]));this.destroy(t),Je.destroy(this[j1],t)}i(QWe,"onHttp2SessionEnd");function _We(t){let e=this[bo]||new vb(`HTTP/2:"GOAWAY"framereceivedwithcode${t}`,Je.getSocketInfo(this)),r=this[JA];if(r[j1]=null,r[qWe]=null,this[lo]!=null&&(this[lo].destroy(e),this[lo]=null),Je.destroy(this[j1],e),r[Ao]<r[Ga].length){let n=r[Ga][r[Ao]];r[Ga][r[Ao]++]=null,Je.errorRequest(r,n,e),r[NR]=r[Ao]}Mn(r[Rg]===0),r.emit("disconnect",r[qg],[r],e),r[Ha]()}i(_We,"onHTTP2GoAway");function PWe(t){return t!=="GET"&&t!=="HEAD"&&t!=="OPTIONS"&&t!=="TRACE"&&t!=="CONNECT"}i(PWe,"shouldSendContentLength");function kWe(t,e){let r=t[lo],{method:n,path:o,host:s,upgrade:a,expectContinue:c,signal:u,headers:p}=e,{body:l}=e;if(a)return Je.errorRequest(t,e,new Error("Upgrade not supported for H2")),!1;let A={};for(let D=0;D<p.length;D+=2){let x=p[D+0],W=p[D+1];if(Array.isArray(W))for(let v=0;v<W.length;v++)A[x]?A[x]+=`,${W[v]}`:A[x]=W[v];else A[x]=W}let b,{hostname:M,port:z}=t[qg];A[DWe]=s||`${M}
`.trim())}};cj.exports=HN});varKg=h((B60,dj)=>{"use strict";varpj=Symbol.for("undici.globalDispatcher.1"),{InvalidArgumentError:bLe}=i0(),fLe=el();lj()===void0&&Aj(newfLe);functionAj(t){if(!t||typeoft.dispatch!="function")thrownewbLe("Argument agent must implement Agent");Object.defineProperty(globalThis,pj,{value:t,writable:!0,enumerable:!1,configurable:!1})}i(Aj,"setGlobalDispatcher");functionlj(){returnglobalThis[pj]}i(lj,"getGlobalDispatcher");dj.exports={setGlobalDispatcher:Aj,getGlobalDispatcher:lj}});varZg=h((I60,bj)=>{"use strict";bj.exports=class{static{i(this,"DecoratorHandler")}#e;constructor(e){if(typeofe!="object"||e===null)thrownewTypeError("handler must be an object");this.#e=e}onConnect(...e){returnthis.#e.onConnect?.(...e)}onError(...e){returnthis.#e.onError?.(...e)}onUpgrade(...e){returnthis.#e.onUpgrade?.(...e)}onResponseStarted(...e){returnthis.#e.onResponseStarted?.(...e)}onHeaders(...e){returnthis.#e.onHeaders?.(...e)}onData(...e){returnthis.#e.onData?.(...e)}onComplete(...e){returnthis.#e.onComplete?.(...e)}onBodySent(...e){returnthis.#e.onBodySent?.(...e)}}});varMj=h((N60,fj)=>{"use strict";varMLe=wg();fj.exports=t=>{lete=t?.maxRedirections;returnr=>i(function(o,s){let{maxRedirections:a=e,...c}=o;if(!a)returnr(o,s);letu=newMLe(r,a,o,s);returnr(c,u)},"redirectInterceptor")}});varmj=h((S60,hj)=>{"use strict";varhLe=kg();hj.exports=t=>e=>i(function(n,o){returne(n,newhLe({...n,retryOptions:{...t,...n.retryOptions}},{handler:o,dispatch:e}))},"retryInterceptor")});vargj=h((W60,zj)=>{"use strict";varmLe=He(),{InvalidArgumentError:zLe,RequestAbortedError:gLe}=i0(),OLe=Zg(),XN=classextendsOLe{static{i(this,"DumpHandler")}#e=1024*1024;#t=null;#n=!1;#r=!1;#o=0;#s=null;#a=null;constructor({maxSize:e},r){if(super(r),e!=null&&(!Number.isFinite(e)||e<1))thrownewzLe("maxSize must be a number greater than 0");this.#e=e??this.#e,this.#a=r}onConnect(e){this.#t=e,this.#a.onConnect(this.#i.bind(this))}#i(e){this.#r=!0,this.#s=e}onHeaders(e,r,n,o){leta=mLe.parseHeaders(r)["content-length"];if(a!=null&&a>this.#e)thrownewgLe(`Response size (${a}) larger than maxSize (${this.#e})`);returnthis.#r?!0:this.#a.onHeaders(e,r,n,o)}onError(e){this.#n||(e=this.#s??e,this.#a.onError(e))}onData(e){returnthis.#o=this.#o+e.length,this.#o>=this.#e&&(this.#n=!0,this.#r?this.#a.onError(this.#s):this.#a.onComplete([])),!0}onComplete(e){if(!this.#n){if(this.#r){this.#a.onError(this.reason);return}this.#a.onComplete(e)}}};functionELe({maxSize:t}={maxSize:1024*1024}){returne=>i(function(n,o){let{dumpMaxSize:s=t}=n,a=newXN({maxSize:s},o);returne(n,a)},"Intercept")}i(ELe,"createDumpInterceptor");zj.exports=ELe});varCj=h((v60,Ej)=>{"use strict";var{isIP:CLe}=require("node:net"),{lookup:yLe}=require("node:dns"),BLe=Zg(),{InvalidArgumentError:Al,InformationalError:qLe}=i0(),Oj=Math.pow(2,31)-1,VN=class{static{i(this,"DNSInstance")}#e=0;#t=0;#n=newMap;dualStack=!0;affinity=null;lookup=null;pick=null;constructor(e){this.#e=e.maxTTL,this.#t=e.maxItems,this.dualStack=e.dualStack,this.affinity=e.affinity,this.lookup=e.lookup??this.#r,this.pick=e.pick??this.#o}getfull(){returnthis.#n.size===this.#t}runLookup(e,r,n){leto=this.#n.get(e.hostname);if(o==null&&this.full){n(null,e.origin);return}lets={affinity:this.affinity,dualStack:this.dualStack,lookup:this.lookup,pick:this.pick,...r.dns,maxTTL:this.#e,maxItems:this.#t};if(o==null)this.lookup(e,s,(a,c)=>{if(a||c==null||c.length===0){n(a??newqLe("No DNS entries found"));return}this.setRecords(e,c);letu=this.#n.get(e.hostname),p=this.pick(e,u,s.affinity),l;typeofp.port=="number"?l=`:${p.port}`:e.port!==""?l=`:${e.port}`:l="",n(null,`${e.protocol}//${p.family===6?`[${p.address}]`:p.address}${l}`)});else{leta=this.pick(e,o,s.affinity);if(a==null){this.#n.delete(e.hostname),this.runLookup(e,r,n);return}letc;typeofa.port=="number"?c=`:${a.port}`:e.port!==""?c=`:${e.port}`:c="",n(null,`${e.protocol}//${a.family===6?`[${a.address}]`:a.address}${c}`)}}#r(e,r,n){yLe(e.hostname,{all:!0,family:this.dualStack===!1?this.affinity:0,order:"ipv4first"},(o,s)=>
${s}`;break;case"retry":tZ(s)&&(r[o]=s);break;case"id":rZ(s)&&(r[o]=s);break;case"event":s.length>0&&(r[o]=s);break}}processEvent(e){e.retry&&tZ(e.retry)&&(this.state.reconnectionTime=parseInt(e.retry,10)),e.id&&rZ(e.id)&&(this.state.lastEventId=e.id),e.data!==void 0&&this.push({type:e.event||"message",options:{data:e.data,lastEventId:this.state.lastEventId,origin:this.state.origin}})}clearEvent(){this.event={data:void 0,event:void 0,id:void 0,retry:void 0}}};nZ.exports={EventSourceStream:Tw}});var lZ=h((QS0,AZ)=>{"use strict";var{pipeline:WPe}=require("node:stream"),{fetching:xPe}=nf(),{makeRequest:vPe}=bl(),{webidl:ki}=it(),{EventSourceStream:TPe}=oZ(),{parseMIMEType:LPe}=tr(),{createFastMessageEvent:QPe}=gl(),{isNetworkError:sZ}=tf(),{delay:_Pe}=xw(),{kEnumerableProperty:Tu}=He(),{environmentSettingsObject:iZ}=wr(),aZ=!1,cZ=3e3,mf=0,uZ=1,zf=2,PPe="anonymous",kPe="use-credentials",Bl=class t extends EventTarget{static{i(this,"EventSource")}#e={open:null,error:null,message:null};#t=null;#n=!1;#r=mf;#o=null;#s=null;#a;#i;constructor(e,r={}){super(),ki.util.markAsUncloneable(this);let n="EventSource constructor";ki.argumentLengthCheck(arguments,1,n),aZ||(aZ=!0,process.emitWarning("EventSource is experimental, expect them to change at any time.",{code:"UNDICI-ES"})),e=ki.converters.USVString(e,n,"url"),r=ki.converters.EventSourceInitDict(r,n,"eventSourceInitDict"),this.#a=r.dispatcher,this.#i={lastEventId:"",reconnectionTime:cZ};let o=iZ,s;try{s=new URL(e,o.settingsObject.baseUrl),this.#i.origin=s.origin}catch(u){throw new DOMException(u,"SyntaxError")}this.#t=s.href;let a=PPe;r.withCredentials&&(a=kPe,this.#n=!0);let c={redirect:"follow",keepalive:!0,mode:"cors",credentials:a==="anonymous"?"same-origin":"omit",referrer:"no-referrer"};c.client=iZ.settingsObject,c.headersList=[["accept",{name:"accept",value:"text/event-stream"}]],c.cache="no-store",c.initiator="other",c.urlList=[new URL(this.#t)],this.#o=vPe(c),this.#u()}get readyState(){return this.#r}get url(){return this.#t}get withCredentials(){return this.#n}#u(){if(this.#r===zf)return;this.#r=mf;let e={request:this.#o,dispatcher:this.#a},r=i(n=>{sZ(n)&&(this.dispatchEvent(new Event("error")),this.close()),this.#c()},"processEventSourceEndOfBody");e.processResponseEndOfBody=r,e.processResponse=n=>{if(sZ(n))if(n.aborted){this.close(),this.dispatchEvent(new Event("error"));return}else{this.#c();return}let o=n.headersList.get("content-type",!0),s=o!==null?LPe(o):"failure",a=s!=="failure"&&s.essence==="text/event-stream";if(n.status!==200||a===!1){this.close(),this.dispatchEvent(new Event("error"));return}this.#r=uZ,this.dispatchEvent(new Event("open")),this.#i.origin=n.urlList[n.urlList.length-1].origin;let c=new TPe({eventSourceSettings:this.#i,push:i(u=>{this.dispatchEvent(QPe(u.type,u.options))},"push")});WPe(n.body.stream,c,u=>{u?.aborted===!1&&(this.close(),this.dispatchEvent(new Event("error")))})},this.#s=xPe(e)}async#c(){this.#r!==zf&&(this.#r=mf,this.dispatchEvent(new Event("error")),await _Pe(this.#i.reconnectionTime),this.#r===mf&&(this.#i.lastEventId.length&&this.#o.headersList.set("last-event-id",this.#i.lastEventId,!0),this.#u()))}close(){ki.brandCheck(this,t),this.#r!==zf&&(this.#r=zf,this.#s.abort(),this.#o=null)}get onopen(){return this.#e.open}set onopen(e){this.#e.open&&this.removeEventListener("open",this.#e.open),typeof e=="function"?(this.#e.open=e,this.addEventListener("open",e)):this.#e.open=null}get onmessage(){return this.#e.message}set onmessage(e){this.#e.message&&this.removeEventListener("message",this.#e.message),typeof e=="function"?(this.#e.message=e,this.addEventListener("message",e)):this.#e.message=null}get onerror(){return this.#e.error}set onerror(e){this.#e.error&&this.removeEventListener("error",this.#e.error),typeof e=="function"?(this.#e.error=e,this.addEventListener("error",e)):this.#e.error=null}},pZ={CONNECTING:{__proto__:null,configurable:!1,enumerable:!0,value:mf,writable:!1},OPEN:{__proto__:null,configurable:!1,enumerable:!0,value:uZ,writable:!1},CLOSED:{__proto__:null,configurable:!1,enumerable:!0,value:zf,writable:!1}};Obj
%s`,x,x,B,n);varW=B.type==="*"?k6:B.type==="?"?P6:"\\"+B.type;o=!0,n=n.slice(0,B.reStart)+W+"\\("+x}z(),s&&(n+="\\\\");varv=!1;switch(n.charAt(0)){case"[":case".":case"(":v=!0}for(varie=c.length-1;ie>-1;ie--){varDe=c[ie],Ne=n.slice(0,De.reStart),Ee=n.slice(De.reStart,De.reEnd-8),Ae=n.slice(De.reEnd-8,De.reEnd),Fe=n.slice(De.reEnd);Ae+=Fe;varae=Ne.split("(").length-1,We=Fe;for(O=0;O<ae;O++)We=We.replace(/\)[+*?]?/,"");Fe=We;vark="";Fe===""&&e!==p3&&(k="$");varke=Ne+Ee+Fe+k+Ae;n=ke}if(n!==""&&o&&(n="(?=.)"+n),v&&(n=b+n),e===p3)return[n,o];if(!o)returnCGe(t);varC0=r.nocase?"i":"";try{varht=newRegExp("^"+n+"$",C0)}catch{returnnewRegExp("$.")}returnht._glob=t,ht._src=n,ht}i(OGe,"parse");Gr.makeRe=function(t,e){returnnewut(t,e||{}).makeRe()};ut.prototype.makeRe=EGe;functionEGe(){if(this.regexp||this.regexp===!1)returnthis.regexp;vart=this.set;if(!t.length)returnthis.regexp=!1,this.regexp;vare=this.options,r=e.noglobstar?k6:e.dot?bGe:fGe,n=e.nocase?"i":"",o=t.map(function(s){returns.map(function(a){returna===U6?r:typeofa=="string"?yGe(a):a._src}).join("\\/")}).join("|");o="^(?:"+o+")$",this.negate&&(o="^(?!"+o+").*$");try{this.regexp=newRegExp(o,n)}catch{this.regexp=!1}returnthis.regexp}i(EGe,"makeRe");Gr.match=function(t,e,r){r=r||{};varn=newut(e,r);returnt=t.filter(function(o){returnn.match(o)}),n.options.nonull&&!t.length&&t.push(e),t};ut.prototype.match=i(function(e,r){if(typeofr>"u"&&(r=this.partial),this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)returne==="";if(e==="/"&&r)return!0;varn=this.options;kf.sep!=="/"&&(e=e.split(kf.sep).join("/")),e=e.split(O1e),this.debug(this.pattern,"split",e);varo=this.set;this.debug(this.pattern,"set",o);vars,a;for(a=e.length-1;a>=0&&(s=e[a],!s);a--);for(a=0;a<o.length;a++){varc=o[a],u=e;n.matchBase&&c.length===1&&(u=[s]);varp=this.matchOne(u,c,r);if(p)returnn.flipNegate?!0:!this.negate}returnn.flipNegate?!1:this.negate},"match");ut.prototype.matchOne=function(t,e,r){varn=this.options;this.debug("matchOne",{this:this,file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(varo=0,s=0,a=t.length,c=e.length;o<a&&s<c;o++,s++){this.debug("matchOne loop");varu=e[s],p=t[o];if(this.debug(e,u,p),u===!1)return!1;if(u===U6){this.debug("GLOBSTAR",[e,u,p]);varl=o,A=s+1;if(A===c){for(this.debug("** at the end");o<a;o++)if(t[o]==="."||t[o]===".."||!n.dot&&t[o].charAt(0)===".")return!1;return!0}for(;l<a;){varb=t[l];if(this.debug(`
globstar while`,t,l,e,A,b),this.matchOne(t.slice(l),e.slice(A),r))returnthis.debug("globstar found match!",l,a,b),!0;if(b==="."||b===".."||!n.dot&&b.charAt(0)==="."){this.debug("dot detected!",t,l,e,A);break}this.debug("globstar swallow a segment, and continue"),l++}return!!(r&&(this.debug(`
>>> no match, partial?`,t,l,e,A),l===a))}varM;if(typeofu=="string"?(M=p===u,this.debug("string match",u,p,M)):(M=p.match(u),this.debug("pattern match",u,p,M)),!M)return!1}if(o===a&&s===c)return!0;if(o===a)returnr;if(s===c)returno===a-1&&t[o]==="";thrownewError("wtf?")};functionCGe(t){returnt.replace(/\\(.)/g,"$1")}i(CGe,"globUnescape");functionyGe(t){returnt.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}i(yGe,"regExpEscape")});varTl=h((mT0,I1e)=>{"use strict";varSGe="2.0.0",FGe=Number.MAX_SAFE_INTEGER||9007199254740991,WGe=16,xGe=250,vGe=["major","premajor","minor","preminor","patch","prepatch","prerelease"];I1e.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:WGe,MAX_SAFE_BUILD_LENGTH:xGe,MAX_SAFE_INTEGER:FGe,RELEASE_TYPES:vGe,SEMVER_SPEC_VERSION:SGe,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});varHf=h((zT0,R1e)=>{"use strict";varTGe=typeofprocess=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};R1e.exports=TGe});varLl=h((ps,N1e)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:H6,MAX_SAFE_BUILD_LENGTH:LGe,MAX_LENGTH:QGe}=Tl(),_Ge=Hf();ps=N1e.exports={};varPGe=ps.re=[],kGe=ps.safeRe=[],Z=ps.src=[],UGe=ps.safeSrc=[],ee=ps.t={},GGe=0,X6="[a-zA-Z0-9-]",HGe=[["\\s",1],["\\d",QGe],[X6,LGe]],XGe=i(t=>{for(let[e,r]ofHGe)t=t.split(`${e}*`).join(`${e}{0,${r}}`).split(`${e}+`).join(`${e}{1,${r}}`);returnt},"makeSafeRegex"),ve=i((t,e,r)=>{letn=XGe(e),o=GGe++;_Ge(t,o,e),ee[t]=o,Z[o]=e,UGe[o]=n,PGe[o]=newRegExp(e,r?"g":void0),kGe[o]=newRegExp(n,r?"g":void0)},"createToken");ve("NUMERICIDENTIFIER","0|[1-9]\\d*");ve("NUMERICIDENTIFIERLOOSE","\\d+");ve("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${X6}*`);ve("MAINVERSION",`(${Z[ee.NUMERICIDENTIFIER]})\\.(${Z[ee.NUMERICIDENTIFIER]})\\.(${Z[ee.NUMERICIDENTIFIER]})`);ve("MAINVERSIONLOOSE",`(${Z[ee.NUMERICIDENTIFIERLOOSE]})\\.(${Z[ee.NUMERICIDENTIFIERLOOSE]})\\.(${Z[ee.NUMERICIDENTIFIERLOOSE]})`);ve("PRERELEASEIDENTIFIER",`(?:${Z[ee.NONNUMERICIDENTIFIER]}|${Z[ee.NUMERICIDENTIFIER]})`);ve("PRERELEASEIDENTIFIERLOOSE",`(?:${Z[ee.NONNUMERICIDENTIFIER]}|${Z[ee.NUMERICIDENTIFIERLOOSE]})`);ve("PRERELEASE",`(?:-(${Z[ee.PRERELEASEIDENTIFIER]}(?:\\.${Z[ee.PRERELEASEIDENTIFIER]})*))`);ve("PRERELEASELOOSE",`(?:-?(${Z[ee.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${Z[ee.PRERELEASEIDENTIFIERLOOSE]})*))`);ve("BUILDIDENTIFIER",`${X6}+`);ve("BUILD",`(?:\\+(${Z[ee.BUILDIDENTIFIER]}(?:\\.${Z[ee.BUILDIDENTIFIER]})*))`);ve("FULLPLAIN",`v?${Z[ee.MAINVERSION]}${Z[ee.PRERELEASE]}?${Z[ee.BUILD]}?`);ve("FULL",`^${Z[ee.FULLPLAIN]}$`);ve("LOOSEPLAIN",`[v=\\s]*${Z[ee.MAINVERSIONLOOSE]}${Z[ee.PRERELEASELOOSE]}?${Z[ee.BUILD]}?`);ve("LOOSE",`^${Z[ee.LOOSEPLAIN]}$`);ve("GTLT","((?:<|>)?=?)");ve("XRANGEIDENTIFIERLOOSE",`${Z[ee.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);ve("XRANGEIDENTIFIER",`${Z[ee.NUMERICIDENTIFIER]}|x|X|\\*`);ve("XRANGEPLAIN",`[v=\\s]*(${Z[ee.XRANGEIDENTIFIER]})(?:\\.(${Z[ee.XRANGEIDENTIFIER]})(?:\\.(${Z[ee.XRANGEIDENTIFIER]})(?:${Z[ee.PRERELEASE]})?${Z[ee.BUILD]}?)?)?`);ve("XRANGEPLAINLOOSE",`[v=\\s]*(${Z[ee.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Z[ee.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Z[ee.XRANGEIDENTIFIERLOOSE]})(?:${Z[ee.PRERELEASELOOSE]})?${Z[ee.BUILD]}?)?)?`);ve("XRANGE",`^${Z[ee.GTLT]}\\s*${Z[ee.XRANGEPLAIN]}$`);ve("XRANGELOOSE",`^${Z[ee.GTLT]}\\s*${Z[ee.XRANGEPLAINLOOSE]}$`);ve("COERCEPLAIN",`(^|[^\\d])(\\d{1,${H6}})(?:\\.(\\d{1,${H6}}))?(?:\\.(\\d{1,${H6}}))?`);ve("COERCE",`${Z[ee.COERCEPLAIN]}(?:$|[^\\d])`);ve("COERCEFULL",Z[ee.COERCEPLAIN]+`(?:${Z[ee.PRERELEASE]})?(?:${Z[ee.BUILD]})?(?:$|[^\\d])`);ve("COERCERTL",Z[ee.COERCE],!0);ve("COERCERTLFULL",Z[ee.COERCEFULL],!0);ve("LONETILDE","(?:~>?)");ve("TILDETRIM",`(\\s*)${Z[ee.LONETILDE]}\\s+`,!0);ps.tildeTrimReplace="$1~";ve("TILDE",`^${Z[ee.LONETILDE]}${Z[ee.XRANGEPLAIN]}$`);ve("TILDELOOSE",`^${Z[ee.LONETILDE]}${Z[ee.XRANGEPLAINLOOSE]}$`);ve("LONECARET","(?:\\^)");ve("CARETTRIM",`(\\s*)${Z[ee.LONECARET]}\\s+`,!0);ps.caretTrimReplace="$1^";ve("CARET",`^${Z[ee.LONECARET]}${Z[ee.XRANGEPLAIN]}$`);ve("CARETLOOSE",`^${Z[ee.LONECARET]}${Z[ee.XRANGEPLAINLOOSE]}$`);ve("COMPARATORLOOSE",`^$
`).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)returnnull;this.sockets[e]||(this.sockets[e]=[]);letr=newYYe.Socket({writable:!1});returnthis.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;letn=this.sockets[e],o=n.indexOf(r);o!==-1&&(n.splice(o,1),this.totalSocketCount--,n.length===0&&deletethis.sockets[e])}getName(e){returnthis.isSecureEndpoint(e)?JYe.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){leto={...r,secureEndpoint:this.isSecureEndpoint(r)},s=this.getName(o),a=this.incrementSockets(s);Promise.resolve().then(()=>this.connect(e,o)).then(c=>{if(this.decrementSockets(s,a),cinstanceofmne.Agent)try{returnc.addRequest(e,o)}catch(u){returnn(u)}this[bs].currentSocket=c,super.createSocket(e,r,n)},c=>{this.decrementSockets(s,a),n(c)})}createConnection(){lete=this[bs].currentSocket;if(this[bs].currentSocket=void0,!e)thrownewError("No socket was returned in the `connect()` function");returne}getdefaultPort(){returnthis[bs].defaultPort??(this.protocol==="https:"?443:80)}setdefaultPort(e){this[bs]&&(this[bs].defaultPort=e)}getprotocol(){returnthis[bs].protocol??(this.isSecureEndpoint()?"https:":"http:")}setprotocol(e){this[bs]&&(this[bs].protocol=e)}};Yr.Agent=_S});varEne=h(Yl=>{"use strict";varjYe=Yl&&Yl.__importDefault||function(t){returnt&&t.__esModule?t:{default:t}};Object.defineProperty(Yl,"__esModule",{value:!0});Yl.parseProxyResponse=void0;var$Ye=jYe(tE()),rE=(0,$Ye.default)("https-proxy-agent:parse-proxy-response");functionKYe(t){returnnewPromise((e,r)=>{letn=0,o=[];functions(){letl=t.read();l?p(l):t.once("readable",s)}i(s,"read");functiona(){t.removeListener("end",c),t.removeListener("error",u),t.removeListener("readable",s)}i(a,"cleanup");functionc(){a(),rE("onend"),r(newError("Proxy connection ended before receiving CONNECT response"))}i(c,"onend");functionu(l){a(),rE("onerror %o",l),r(l)}i(u,"onerror");functionp(l){o.push(l),n+=l.length;letA=Buffer.concat(o,n),b=A.indexOf(`\r
`);let{connect:p,buffered:l}=awaitu;if(e.emit("proxyConnect",p),this.emit("proxyConnect",p,e),p.statusCode===200)returne.once("socket",iJe),r.secureEndpoint?(iM("Upgrading socket connection to TLS"),Cne.connect({...Bne(yne(r),"host","path","port"),socket:o})):o;o.destroy();letA=newnE.Socket({writable:!1});returnA.readable=!0,e.once("socket",b=>{iM("Replaying proxy buffer for failed request"),(0,tJe.default)(b.listenerCount("data")>0),b.push(l),b.push(null)}),A}};oE.protocols=["http","https"];Nn.HttpsProxyAgent=oE;functioniJe(t){t.resume()}i(iJe,"resume");functionBne(t,...e){letr={},n;for(nint)e.includes(n)||(r[n]=t[n]);returnr}i(Bne,"omit")});varwne=h(ur=>{"use strict";varaJe=ur&&ur.__createBinding||(Object.create?(function(t,e,r,n){n===void0&&(n=r);varo=Object.getOwnPropertyDescriptor(e,r);(!o||("get"ino?!e.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:i(function(){returne[r]},"get")}),Object.defineProperty(t,n,o)}):(function(t,e,r,n){n===void0&&(n=r),t[n]=e[r]})),cJe=ur&&ur.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Rne=ur&&ur.__importStar||function(t){if(t&&t.__esModule)returnt;vare={};if(t!=null)for(varrint)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&aJe(e,t,r);returncJe(e,t),e};Object.defineProperty(ur,"__esModule",{value:!0});ur.req=ur.json=ur.toBuffer=void0;varuJe=Rne(require("http")),pJe=Rne(require("https"));asyncfunctionNne(t){lete=0,r=[];forawait(letnoft)e+=n.length,r.push(n);returnBuffer.concat(r,e)}i(Nne,"toBuffer");ur.toBuffer=Nne;asyncfunctionAJe(t){letr=(awaitNne(t)).toString("utf8");try{returnJSON.parse(r)}catch(n){leto=n;throwo.message+=` (input: ${r})`,o}}i(AJe,"json");ur.json=AJe;functionlJe(t,e={}){letn=((typeoft=="string"?t:t.href).startsWith("https:")?pJe:uJe).request(t,e),o=newPromise((s,a)=>{n.once("response",s).once("error",a).end()});returnn.then=o.then.bind(o),n}i(lJe,"req");ur.req=lJe});varxne=h(Jr=>{"use strict";varFne=Jr&&Jr.__createBinding||(Object.create?(function(t,e,r,n){n===void0&&(n=r);varo=Object.getOwnPropertyDescriptor(e,r);(!o||("get"ino?!e.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:i(function(){returne[r]},"get")}),Object.defineProperty(t,n,o)}):(function(t,e,r,n){n===void0&&(n=r),t[n]=e[r]})),dJe=Jr&&Jr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Wne=Jr&&Jr.__importStar||function(t){if(t&&t.__esModule)returnt;vare={};if(t!=null)for(varrint)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Fne(e,t,r);returndJe(e,t),e},bJe=Jr&&Jr.__exportStar||function(t,e){for(varrint)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&Fne(e,t,r)};Object.defineProperty(Jr,"__esModule",{value:!0});Jr.Agent=void0;varfJe=Wne(require("net")),Sne=Wne(require("http")),MJe=require("https");bJe(wne(),Jr);varfs=Symbol("AgentBaseInternalState"),PS=classextendsSne.Agent{static{i(this,"Agent")}constructor(e){super(e),this[fs]={}}isSecureEndpoint(e){if(e){if(typeofe.secureEndpoint=="boolean")returne.secureEndpoint;if(typeofe.protocol=="string")returne.protocol==="https:"}let{stack:r}=newError;returntypeofr!="string"?!1:r.split(`
`).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)returnnull;this.sockets[e]||(this.sockets[e]=[]);letr=newfJe.Socket({writable:!1});returnthis.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;letn=this.sockets[e],o=n.indexOf(r);o!==-1&&(n.splice(o,1),this.totalSocketCount--,n.length===0&&deletethis.sockets[e])}getName(e){return(typeofe.secureEndpoint=="boolean"?e.secureEndpoint:this.isSecureEndpoint(e))?MJe.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){leto={...r,secureEndpoint:this.isSecureEndpoint(r)},s=this.getName(o),a=this.incrementSockets(s);Promise.resolve().then(()=>this.connect(e,o)).then(c=>{if(this.decrementSockets(s,a),cinstanceofSne.Agent)returnc.addRequest(e,o);this[fs].currentSocket=c,super.createSocket(e,r,n)},c=>{this.decrementSockets(s,a),n(c)})}createConnection(){lete=this[fs].currentSocket;if(this[fs].currentSocket=void0,!e)thrownewError("No socket was returned in the `connect()` function");returne}getdefaultPort(){returnthis[fs].defaultPort??(this.protocol==="https:"?443:80)}setdefaultPort(e){this[fs]&&(this[fs].defaultPort=e)}getprotocol(){returnthis[fs].protocol??(this.isSecureEndpoint()?"https:":"http:")}setprotocol(e){this[fs]&&(this[fs].protocol=e)}};Jr.Agent=PS});varLne=h(wn=>{"use strict";varhJe=wn&&wn.__createBinding||(Object.create?(function(t,e,r,n){n===void0&&(n=r);varo=Object.getOwnPropertyDescriptor(e,r);(!o||("get"ino?!e.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:i(function(){returne[r]},"get")}),Object.defineProperty(t,n,o)}):(function(t,e,r,n){n===void0&&(n=r),t[n]=e[r]})),mJe=wn&&wn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Tne=wn&&wn.__importStar||function(t){if(t&&t.__esModule)returnt;vare={};if(t!=null)for(varrint)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&hJe(e,t,r);returnmJe(e,t),e},zJe=wn&&wn.__importDefault||function(t){returnt&&t.__esModule?t:{default:t}};Object.defineProperty(wn,"__esModule",{value:!0});wn.HttpProxyAgent=void0;vargJe=Tne(require("net")),OJe=Tne(require("tls")),EJe=zJe(tE()),CJe=require("events"),yJe=xne(),vne=require("url"),Jl=(0,EJe.default)("http-proxy-agent"),sE=classextendsyJe.Agent{static{i(this,"HttpProxyAgent")}constructor(e,r){super(r),this.proxy=typeofe=="string"?newvne.URL(e):e,this.proxyHeaders=r?.headers??{},Jl("Creating new HttpProxyAgent instance: %o",this.proxy.href);letn=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),o=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={...r?BJe(r,"headers"):null,host:n,port:o}}addRequest(e,r){e._header=null,this.setRequestProps(e,r),super.addRequest(e,r)}setRequestProps(e,r){let{proxy:n}=this,o=r.secureEndpoint?"https:":"http:",s=e.getHeader("host")||"localhost",a=`${o}//${s}`,c=newvne.URL(e.path,a);r.port!==80&&(c.port=String(r.port)),e.path=String(c);letu=typeofthis.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders};if(n.username||n.password){letp=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;u["Proxy-Authorization"]=`Basic ${Buffer.from(p).toString("base64")}`}u["Proxy-Connection"]||(u["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(letpofObject.keys(u)){letl=u[p];l&&e.setHeader(p,l)}}asyncconnect(e,r){e._header=null,e.path.includes("://")||this.setRequestProps(e,r);letn,o;Jl("Regenerating stored HTTP header string for request"),e._implicitHeader(),e.outputData&&e.outputData.length>0&&(Jl("Patching connection write() output buffer with updated header"),n=e.outputData[0].data,o=n.indexOf(`\r
`)+4,e.outputData[0].data=e._header+n.substring(o),Jl("Output buffer: %o",e.outputData[0].data));lets;returnthis.proxy.protocol==="https:"?(Jl("Creating `tls.Socket`: %o",this.connectOpts),s=OJe.connect(this.connectOpts)):(Jl("Creating `net.Socket`: %o",this.connectOpts),s=gJe.connect(this.connectOpts)),await(0,CJe.once)(s,"connect"),s}};sE.protocols=["http","https"];wn.HttpProxyAgent=sE;functionBJe(t,...e){letr={},n;for(nint)e.includes(n)||(r[n]=t[n]);returnr}i(BJe,"omit")});varioe=h(zE=>{"use strict";Object.defineProperty(zE,"__esModule",{value:!0});zE.state=void0;zE.state={instrumenterImplementation:void0}});varCoe=h(yE=>{"use strict";Object.defineProperty(yE,"__esModule",{value:!0});yE.state=void0;yE.state={operationRequestMap:newWeakMap}});vartae=h(d2=>{"use strict";Object.defineProperty(d2,"__esModule",{value:!0});varHe0=require("os"),Xe0=require("util");functionVe0(t){returnt&&typeoft=="object"&&"default"int?t:{default:t}}i(Ve0,"_interopDefaultLegacy");varYe0=Ve0(Xe0);functionJe0(t,...e){process.stderr.write(`${Ye0.default.format(t,...e)}${He0.EOL}`)}i(Je0,"log");varHie=typeofprocess<"u"&&process.env&&process.env.DEBUG||void0,Vie,zT=[],gT=[],UC=[];Hie&&OT(Hie);varYie=Object.assign(t=>Jie(t),{enable:OT,enabled:ET,disable:je0,log:Je0});functionOT(t){Vie=t,zT=[],gT=[];lete=/\*/g,r=t.split(",").map(n=>n.trim().replace(e,".*?"));for(letnofr)n.startsWith("-")?gT.push(newRegExp(`^${n.substr(1)}$`)):zT.push(newRegExp(`^${n}$`));for(letnofUC)n.enabled=ET(n.namespace)}i(OT,"enable");functionET(t){if(t.endsWith("*"))return!0;for(leteofgT)if(e.test(t))return!1;for(leteofzT)if(e.test(t))return!0;return!1}i(ET,"enabled");functionje0(){lett=Vie||"";returnOT(""),t}i(je0,"disable");functionJie(t){lete=Object.assign(r,{enabled:ET(t),destroy:$e0,log:Yie.log,namespace:t,extend:Ke0});functionr(...n){e.enabled&&(n.length>0&&(n[0]=`${t}${n[0]}`),e.log(...n))}returni(r,"debug"),UC.push(e),e}i(Jie,"createDebugger");function$e0(){lett=UC.indexOf(this);returnt>=0?(UC.splice(t,1),!0):!1}i($e0,"destroy");functionKe0(t){lete=Jie(`${this.namespace}:${t}`);returne.log=this.log,e}i(Ke0,"extend");varVM=Yie,jie=newSet,PC=typeofprocess<"u"&&process.env&&process.env.AZURE_LOG_LEVEL||void0,GC,HC=VM("azure");HC.log=(...t)=>{VM.log(...t)};varCT=["verbose","info","warning","error"];PC&&(eae(PC)?$ie(PC):console.error(`AZURE_LOG_LEVEL set to unknown log level '${PC}'; logging is not enabled. Acceptable values: ${CT.join(", ")}.`));function$ie(t){if(t&&!eae(t))thrownewError(`Unknown log level '${t}'. Acceptable values: ${CT.join(",")}`);GC=t;lete=[];for(letrofjie)Zie(r)&&e.push(r.namespace);VM.enable(e.join(","))}i($ie,"setLogLevel");functionZe0(){returnGC}i(Ze0,"getLogLevel");varXie={verbose:400,info:300,warning:200,error:100};functione00(t){lete=HC.extend(t);returnKie(HC,e),{error:kC(e,"error"),warning:kC(e,"warning"),info:kC(e,"info"),verbose:kC(e,"verbose")}}i(e00,"createClientLogger");functionKie(t,e){e.log=(...r)=>{t.log(...r)}}i(Kie,"patchLogMethod");functionkC(t,e){letr=Object.assign(t.extend(e),{level:e});if(Kie(t,r),Zie(r)){letn=VM.disable();VM.enable(n+","+r.namespace)}returnjie.add(r),r}i(kC,"createLogger");functionZie(t){return!!(GC&&Xie[t.level]<=Xie[GC])}i(Zie,"shouldEnable");functioneae(t){returnCT.includes(t)}i(eae,"isAzureLogLevel");d2.AzureLogger=HC;d2.createClientLogger=e00;d2.getLogLevel=Ze0;d2.setLogLevel=$ie});varqT=h(JM=>{"use strict";Object.defineProperty(JM,"__esModule",{value:!0});varb2=newWeakMap,XC=newWeakMap,YM=classt{static{i(this,"AbortSignal")}constructor(){this.onabort=null,b2.set(this,[]),XC.set(this,!1)}getaborted(){if(!XC.has(this))thrownewTypeError("Expected `this` to be an instance of AbortSignal.");returnXC.get(this)}staticgetnone(){returnnewt}addEventListener(e,r){if(!b2.has(this))thrownewTypeError("Expected `this` to be an instance of AbortSignal.");b2.get(this).push(r)}removeEventListener(e,r){if(!b2.has(this))thrownewTypeError("Expected `this` to be an instance of AbortSignal.");letn=b2.get(this),o=n.indexOf(r);o>-
See https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details`))}i(Bc0,"logUnexpecedPropertyAccessOnce");function qc0(){Object.keys(P4).forEach(function(t){delete P4[t]})}i(qc0,"resetLoggedProperties")});var U4=h(Ys=>{"usestrict";Ys.__esModule=!0;Ys.HandlebarsEnvironment=EQ;function jle(t){return t&&t.__esModule?t:{default:t}}i(jle,"_interopRequireDefault");var Fp=jt(),Dc0=sn(),gQ=jle(Dc0),Ic0=MQ(),Rc0=Xle(),Nc0=mQ(),k4=jle(Nc0),wc0=zQ(),Sc0="4.7.9";Ys.VERSION=Sc0;var Fc0=8;Ys.COMPILER_REVISION=Fc0;var Wc0=7;Ys.LAST_COMPATIBLE_COMPILER_REVISION=Wc0;var xc0={1:"<=1.0.rc.2",2:"==1.0.0-rc.3",3:"==1.0.0-rc.4",4:"==1.x.x",5:"==2.0.0-alpha.x",6:">=2.0.0-beta.1",7:">=4.0.0<4.3.0",8:">=4.3.0"};Ys.REVISION_CHANGES=xc0;var OQ="[objectObject]";function EQ(t,e,r){this.helpers=t||{},this.partials=e||{},this.decorators=r||{},Ic0.registerDefaultHelpers(this),Rc0.registerDefaultDecorators(this)}i(EQ,"HandlebarsEnvironment");EQ.prototype={constructor:EQ,logger:k4.default,log:k4.default.log,registerHelper:i(function(e,r){if(Fp.toString.call(e)===OQ){if(r)throw new gQ.default("Argnotsupportedwithmultiplehelpers");Fp.extend(this.helpers,e)}else this.helpers[e]=r},"registerHelper"),unregisterHelper:i(function(e){delete this.helpers[e]},"unregisterHelper"),registerPartial:i(function(e,r){if(Fp.toString.call(e)===OQ)Fp.extend(this.partials,e);else{if(typeof r>"u")throw new gQ.default('Attempting to register a partial called "'+e+'" as undefined');this.partials[e]=r}},"registerPartial"),unregisterPartial:i(function(e){delete this.partials[e]},"unregisterPartial"),registerDecorator:i(function(e,r){if(Fp.toString.call(e)===OQ){if(r)throw new gQ.default("Argnotsupportedwithmultipledecorators");Fp.extend(this.decorators,e)}else this.decorators[e]=r},"registerDecorator"),unregisterDecorator:i(function(e){delete this.decorators[e]},"unregisterDecorator"),resetLoggedPropertyAccesses:i(function(){wc0.resetLoggedProperties()},"resetLoggedPropertyAccesses")};var vc0=k4.default.log;Ys.log=vc0;Ys.createFrame=Fp.createFrame;Ys.logger=k4.default});var Kle=h((G4,$le)=>{"usestrict";G4.__esModule=!0;function CQ(t){this.string=t}i(CQ,"SafeString");CQ.prototype.toString=CQ.prototype.toHTML=function(){return""+this.string};G4.default=CQ;$le.exports=G4.default});var Zle=h(yQ=>{"usestrict";yQ.__esModule=!0;yQ.wrapHelper=Tc0;function Tc0(t,e){if(typeof t!="function")return t;var r=i(function(){var o=arguments[arguments.length-1];return arguments[arguments.length-1]=e(o),t.apply(this,arguments)},"wrapper");return r}i(Tc0,"wrapHelper")});var s2e=h(Wc=>{"usestrict";Wc.__esModule=!0;Wc.checkRevision=Uc0;Wc.template=Gc0;Wc.wrapProgram=H4;Wc.resolvePartial=Hc0;Wc.invokePartial=Xc0;Wc.noop=n2e;function Lc0(t){return t&&t.__esModule?t:{default:t}}i(Lc0,"_interopRequireDefault");function Qc0(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}i(Qc0,"_interopRequireWildcard");var _c0=jt(),U2=Qc0(_c0),Pc0=sn(),fa=Lc0(Pc0),Ma=U4(),e2e=MQ(),kc0=Zle(),t2e=zQ();function Uc0(t){var e=t&&t[0]||1,r=Ma.COMPILER_REVISION;if(!(e>=Ma.LAST_COMPATIBLE_COMPILER_REVISION&&e<=Ma.COMPILER_REVISION))if(e<Ma.LAST_COMPATIBLE_COMPILER_REVISION){var n=Ma.REVISION_CHANGES[r],o=Ma.REVISION_CHANGES[e];throw new fa.default("TemplatewasprecompiledwithanolderversionofHandlebarsthanthecurrentruntime.Pleaseupdateyourprecompilertoanewerversion("+n+")ordowngradeyourruntimetoanolderversion("+o+").")}else throw new fa.default("TemplatewasprecompiledwithanewerversionofHandlebarsthanthecurrentruntime.Pleaseupdateyourruntimetoanewerversion("+t[1]+").")}i(Uc0,"checkRevision");function Gc0(t,e){if(!e)throw new fa.default("Noenvironmentpassedtotemplate");if(!t||!t.main)throw new fa.default("Unknowntemplateobject:"+typeof t);t.main.decorator=t.main_d,e.VM.checkRevision(t.compiler);var r=t.compiler&&t.compiler[0]===7;function n(a,c,u){u.hash&&(c=U2.extend({},c,u.hash),u.ids&&(u.ids[0]=!0)),a=e.VM.res
`)}i(Cb0,"fromDER")});varCq=h(Yc=>{"use strict";Object.defineProperty(Yc,"__esModule",{value:!0});Yc.SHA2_HASH_ALGOS=Yc.RSA_SIGNATURE_ALGOS=Yc.ECDSA_SIGNATURE_ALGOS=void0;Yc.ECDSA_SIGNATURE_ALGOS={"1.2.840.10045.4.3.1":"sha224","1.2.840.10045.4.3.2":"sha256","1.2.840.10045.4.3.3":"sha384","1.2.840.10045.4.3.4":"sha512"};Yc.RSA_SIGNATURE_ALGOS={"1.2.840.113549.1.1.14":"sha224","1.2.840.113549.1.1.11":"sha256","1.2.840.113549.1.1.12":"sha384","1.2.840.113549.1.1.13":"sha512"};Yc.SHA2_HASH_ALGOS={"2.16.840.1.101.3.4.2.1":"sha256","2.16.840.1.101.3.4.2.2":"sha384","2.16.840.1.101.3.4.2.3":"sha512"}});varXP=h(yq=>{"use strict";Object.defineProperty(yq,"__esModule",{value:!0});yq.RFC3161TimestampVerificationError=void0;varHP=classextendsError{static{i(this,"RFC3161TimestampVerificationError")}};yq.RFC3161TimestampVerificationError=HP});varkfe=h(ri=>{"use strict";varyb0=ri&&ri.__createBinding||(Object.create?(function(t,e,r,n){n===void0&&(n=r);varo=Object.getOwnPropertyDescriptor(e,r);(!o||("get"ino?!e.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:i(function(){returne[r]},"get")}),Object.defineProperty(t,n,o)}):(function(t,e,r,n){n===void0&&(n=r),t[n]=e[r]})),Bb0=ri&&ri.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),qb0=ri&&ri.__importStar||(function(){vart=i(function(e){returnt=Object.getOwnPropertyNames||function(r){varn=[];for(varoinr)Object.prototype.hasOwnProperty.call(r,o)&&(n[n.length]=o);returnn},t(e)},"ownKeys");returnfunction(e){if(e&&e.__esModule)returne;varr={};if(e!=null)for(varn=t(e),o=0;o<n.length;o++)n[o]!=="default"&&yb0(r,e,n[o]);returnBb0(r,e),r}})();Object.defineProperty(ri,"__esModule",{value:!0});ri.TSTInfo=void0;varPfe=qb0(Ed()),Db0=Cq(),Ib0=XP(),VP=class{static{i(this,"TSTInfo")}root;constructor(e){this.root=e}getversion(){returnthis.root.subs[0].toInteger()}getgenTime(){returnthis.root.subs[4].toDate()}getmessageImprintHashAlgorithm(){lete=this.messageImprintObj.subs[0].subs[0].toOID();returnDb0.SHA2_HASH_ALGOS[e]}getmessageImprintHashedMessage(){returnthis.messageImprintObj.subs[1].value}getraw(){returnthis.root.toDER()}verify(e){letr=Pfe.digest(this.messageImprintHashAlgorithm,e);if(!Pfe.bufferEqual(r,this.messageImprintHashedMessage))thrownewIb0.RFC3161TimestampVerificationError("message imprint does not match artifact")}getmessageImprintObj(){returnthis.root.subs[2]}};ri.TSTInfo=VP});varGfe=h(ni=>{"use strict";varRb0=ni&&ni.__createBinding||(Object.create?(function(t,e,r,n){n===void0&&(n=r);varo=Object.getOwnPropertyDescriptor(e,r);(!o||("get"ino?!e.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:i(function(){returne[r]},"get")}),Object.defineProperty(t,n,o)}):(function(t,e,r,n){n===void0&&(n=r),t[n]=e[r]})),Nb0=ni&&ni.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),wb0=ni&&ni.__importStar||(function(){vart=i(function(e){returnt=Object.getOwnPropertyNames||function(r){varn=[];for(varoinr)Object.prototype.hasOwnProperty.call(r,o)&&(n[n.length]=o);returnn},t(e)},"ownKeys");returnfunction(e){if(e&&e.__esModule)returne;varr={};if(e!=null)for(varn=t(e),o=0;o<n.length;o++)n[o]!=="default"&&Rb0(r,e,n[o]);returnNb0(r,e),r}})();Object.defineProperty(ni,"__esModule",{value:!0});ni.RFC3161Timestamp=void0;varSb0=gq(),YP=wb0(Ed()),Ufe=Cq(),dm=XP(),Fb0=kfe(),Wb0="1.2.840.113549.1.7.2",xb0="1.2.840.113549.1.9.16.1.4",vb0="1.2.840.113549.1.9.4",JP=classt{static{i(this,"RFC3161Timestamp")}root;constructor(e){this.root=e}staticparse(e){letr=Sb0.ASN1Obj.parseBuffer(e);returnnewt(r)}getstatus(){returnthis.pkiStatusInfoObj.subs[0].toInteger()}getcontentType(){returnthis.contentTypeObj.toOID()}geteContentType(){returnthis.eContentTypeObj.toOID()}getsigningTime(){returnthis.tstInfo.genTime}getsignerIssuer(){returnthis.signerSidObj.subs[0].value}getsignerSerialNumber(){returnthis.signerSidObj.subs[1].value}getsignerDigestAlgorith
`,rM0=/\u2014 (\S+) (\S+)\n/g;function nM0(t,e){let r=t.inclusionProof,n=Bk.fromString(r.checkpoint.envelope),o=Gq.fromString(n.note);if(!oM0(n,e))throw new Rd.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid checkpoint signature"});return o}i(nM0,"verifyCheckpoint");function oM0(t,e){let r=Buffer.from(t.note,"utf-8");return t.signatures.some(n=>{let o=e.find(s=>yMe.crypto.bufferEqual(s.logID.subarray(0,4),n.keyHint)&&s.baseURL.includes(n.name));return o?yMe.crypto.verify(r,o.publicKey,n.signature):!1})}i(oM0,"verifySignedNote");var Bk=class t{static{i(this,"SignedNote")}note;signatures;constructor(e,r){this.note=e,this.signatures=r}static fromString(e){if(!e.includes(yk))throw new Rd.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"missing checkpoint separator"});let r=e.indexOf(yk),n=e.slice(0,r+1),s=e.slice(r+yk.length).matchAll(rM0),a=Array.from(s,c=>{let[,u,p]=c,l=Buffer.from(p,"base64");if(l.length<5)throw new Rd.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"malformed checkpoint signature"});return{name:u,keyHint:l.subarray(0,4),signature:l.subarray(4)}});if(a.length===0)throw new Rd.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"no signatures found in checkpoint"});return new t(n,a)}},Gq=class t{static{i(this,"LogCheckpoint")}origin;logSize;logHash;rest;constructor(e,r,n,o){this.origin=e,this.logSize=r,this.logHash=n,this.rest=o}static fromString(e){let r=e.trimEnd().split(`
`);if(r.length<3)throw new Rd.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"too few lines in checkpoint header"});let n=r[0],o;try{o=BigInt(r[1])}catch{throw new Rd.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid checkpoint log size"})}let s=Buffer.from(r[2],"base64"),a=r.slice(3);return new t(n,o,s,a)}};mm.LogCheckpoint=Gq});var qMe=h(Ik=>{"use strict";Object.defineProperty(Ik,"__esModule",{value:!0});Ik.verifyMerkleInclusion=aM0;var Dk=vo(),Hq=Rt(),sM0=Buffer.from([0]),iM0=Buffer.from([1]);function aM0(t,e){let r=t.inclusionProof,n;try{n=BigInt(r.logIndex)}catch{throw new Hq.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid inclusion proof log index"})}let o=BigInt(e.logSize);if(n<0n||n>=o)throw new Hq.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:`invalidindex:${n}`});let{inner:s,border:a}=cM0(n,o);if(r.hashes.length!==s+a)throw new Hq.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid hash count"});let c=r.hashes.slice(0,s),u=r.hashes.slice(s),p=bM0(t.canonicalizedBody),l=pM0(uM0(p,c,n),u);if(!Dk.crypto.bufferEqual(l,e.logHash))throw new Hq.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"calculated root hash does not match inclusion proof"})}i(aM0,"verifyMerkleInclusion");function cM0(t,e){let r=AM0(t,e),n=lM0(t>>BigInt(r));return{inner:r,border:n}}i(cM0,"decompInclProof");function uM0(t,e,r){return e.reduce((n,o,s)=>r>>BigInt(s)&BigInt(1)?qk(o,n):qk(n,o),t)}i(uM0,"chainInner");function pM0(t,e){return e.reduce((r,n)=>qk(n,r),t)}i(pM0,"chainBorderRight");function AM0(t,e){return dM0(t^e-BigInt(1))}i(AM0,"innerProofSize");function lM0(t){return t.toString(2).split("1").length-1}i(lM0,"onesCount");function dM0(t){return t===0n?0:t.toString(2).length}i(dM0,"bitLength");function qk(t,e){return Dk.crypto.digest("sha256",iM0,t,e)}i(qk,"hashChildren");function bM0(t){return Dk.crypto.digest("sha256",sM0,t)}i(bM0,"hashLeaf")});var IMe=h(Rk=>{"use strict";Object.defineProperty(Rk,"__esModule",{value:!0});Rk.verifyTLogSET=hM0;var DMe=vo(),fM0=Rt(),MM0=Bd();function hM0(t,e){if(!(0,MM0.filterTLogAuthorities)(e,{logID:t.logId.keyId,targetDate:new Date(Number(t.integratedTime)*1e3)}).some(o=>{let s=mM0(t),a=Buffer.from(DMe.json.canonicalize(s),"utf8"),c=t.inclusionPromise.signedEntryTimestamp;return DMe.crypto.verify(a,o.publicKey,c)}))throw new fM0.VerificationError({code:"TLOG_INCLUSION_PROMISE_ERROR",message:"inclusion promise could not be verified"})}i(hM0,"verifyTLogSET");function mM0(t){let{integratedTime:e,logIndex:r,logId:n,canonicalizedBody:o}=t;return{body:o.toString("base64"),integratedTime:Number(e),logIndex:Number(r),logID:n.keyId.toString("hex")}}i(mM0,"toVerificationPayload")});var NMe=h(Vq=>{"use strict";Object.defineProperty(Vq,"__esModule",{value:!0});Vq.verifyTLogBody=CM0;Vq.verifyTLogInclusion=yM0;var RMe=gMe(),Xq=Rt(),Nk=OMe(),wk=EMe(),zM0=CMe(),gM0=BMe(),OM0=qMe(),EM0=IMe();function CM0(t,e){let{kind:r,version:n}=t.kindVersion,o;try{o=JSON.parse(t.canonicalizedBody.toString("utf8"))}catch{throw new Xq.VerificationError({code:"TLOG_BODY_ERROR",message:"invalid canonicalized body"})}if(r!==o.kind||n!==o.apiVersion)throw new Xq.VerificationError({code:"TLOG_BODY_ERROR",message:`kind/versionmismatch-expected:${r}/${n},received:${o.kind}/${o.apiVersion}`});switch(r){case"dsse":if(n==Nk.DSSE_API_VERSION_V1)return(0,Nk.verifyDSSETLogBody)(o,e);{let s=RMe.Entry.fromJSON(o);return(0,Nk.verifyDSSETLogBodyV2)(s,e)}case"intoto":return(0,zM0.verifyIntotoTLogBody)(o,e);case"hashedrekord":if(n==wk.HASHEDREKORD_API_VERSION_V1)return(0,wk.verifyHashedRekordTLogBody)(o,e);{let s=RMe.Entry.fromJSON(o);return(0,wk.verifyHashedRekordTLogBodyV2)(s,e)}default:throw new Xq.VerificationError({code:"TLOG_BODY_ERROR",message:`unsupportedkind:${r}`})}}i(CM0,"verifyTLogBody");function yM0(t,e){let r=!1;if(BM0(t)&&((0,EM0.verifyTLogSET)(t,e),r=!0),qM0(t)){let n=(0,gM0.verifyCheckpoint)(t,e);(0,OM0.verifyMerkleInclusion)(t,n),r=!0}if(!r)throw new Xq.VerificationError({code:"TLOG_MISSING_INCLUSION_ERROR",message:"inclusion c
You can add a runtime option to disable the check or this warning:
See https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details`))}i(Rh0,"logUnexpecedPropertyAccessOnce");functionNh0(){Object.keys(CD).forEach(function(t){deleteCD[t]})}i(Nh0,"resetLoggedProperties")});varBD=h(Ai=>{"use strict";Ai.__esModule=!0;Ai.HandlebarsEnvironment=Zk;functionOhe(t){returnt&&t.__esModule?t:{default:t}}i(Ohe,"_interopRequireDefault");varoA=Nt(),wh0=no(),$k=Ohe(wh0),Sh0=Vk(),Fh0=hhe(),Wh0=Jk(),yD=Ohe(Wh0),xh0=jk(),vh0="4.7.10";Ai.VERSION=vh0;varTh0=8;Ai.COMPILER_REVISION=Th0;varLh0=7;Ai.LAST_COMPATIBLE_COMPILER_REVISION=Lh0;varQh0={1:"<= 1.0.rc.2",2:"== 1.0.0-rc.3",3:"== 1.0.0-rc.4",4:"== 1.x.x",5:"== 2.0.0-alpha.x",6:">= 2.0.0-beta.1",7:">= 4.0.0 <4.3.0",8:">= 4.3.0"};Ai.REVISION_CHANGES=Qh0;varKk="[object Object]";functionZk(t,e,r){this.helpers=t||{},this.partials=e||{},this.decorators=r||{},Sh0.registerDefaultHelpers(this),Fh0.registerDefaultDecorators(this)}i(Zk,"HandlebarsEnvironment");Zk.prototype={constructor:Zk,logger:yD.default,log:yD.default.log,registerHelper:i(function(e,r){if(oA.toString.call(e)===Kk){if(r)thrownew$k.default("Arg not supported with multiple helpers");oA.extend(this.helpers,e)}elsethis.helpers[e]=r},"registerHelper"),unregisterHelper:i(function(e){deletethis.helpers[e]},"unregisterHelper"),registerPartial:i(function(e,r){if(oA.toString.call(e)===Kk)oA.extend(this.partials,e);else{if(typeofr>"u")thrownew$k.default('Attempting to register a partial called "'+e+'" as undefined');this.partials[e]=r}},"registerPartial"),unregisterPartial:i(function(e){deletethis.partials[e]},"unregisterPartial"),registerDecorator:i(function(e,r){if(oA.toString.call(e)===Kk){if(r)thrownew$k.default("Arg not supported with multiple decorators");oA.extend(this.decorators,e)}elsethis.decorators[e]=r},"registerDecorator"),unregisterDecorator:i(function(e){deletethis.decorators[e]},"unregisterDecorator"),resetLoggedPropertyAccesses:i(function(){xh0.resetLoggedProperties()},"resetLoggedPropertyAccesses")};var_h0=yD.default.log;Ai.log=_h0;Ai.createFrame=oA.createFrame;Ai.logger=yD.default});varChe=h((qD,Ehe)=>{"use strict";qD.__esModule=!0;functione7(t){this.string=t}i(e7,"SafeString");e7.prototype.toString=e7.prototype.toHTML=function(){return""+this.string};qD.default=e7;Ehe.exports=qD.default});varyhe=h(t7=>{"use strict";t7.__esModule=!0;t7.wrapHelper=Ph0;functionPh0(t,e){if(typeoft!="function")returnt;varr=i(function(){varo=arguments[arguments.length-1];returnarguments[arguments.length-1]=e(o),t.apply(this,arguments)},"wrapper");returnr}i(Ph0,"wrapHelper")});varRhe=h(Zc=>{"use strict";Zc.__esModule=!0;Zc.checkRevision=Vh0;Zc.template=Yh0;Zc.wrapProgram=DD;Zc.resolvePartial=Jh0;Zc.invokePartial=jh0;Zc.noop=Dhe;functionkh0(t){returnt&&t.__esModule?t:{default:t}}i(kh0,"_interopRequireDefault");functionUh0(t){if(t&&t.__esModule)returnt;vare={};if(t!=null)for(varrint)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);returne.default=t,e}i(Uh0,"_interopRequireWildcard");varGh0=Nt(),sA=Uh0(Gh0),Hh0=no(),Qo=kh0(Hh0),Ia=BD(),Bhe=Vk(),Xh0=yhe(),r7=jk();functionVh0(t){vare=t&&t[0]||1,r=Ia.COMPILER_REVISION;if(!(e>=Ia.LAST_COMPATIBLE_COMPILER_REVISION&&e<=Ia.COMPILER_REVISION))if(e<Ia.LAST_COMPATIBLE_COMPILER_REVISION){varn=Ia.REVISION_CHANGES[r],o=Ia.REVISION_CHANGES[e];thrownewQo.default("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version ("+n+") or downgrade your runtime to an older version ("+o+").")}elsethrownewQo.default("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+t[1]+").")}i(Vh0,"checkRevision");functionYh0(t,e){if(!e)thrownewQo.default("No environment passed to template");if(!t||!t.main)thrownewQo.default("Unknown template object: "+typeoft);t.main.decorator=t.main_d,e.VM.checkRevision(t.compiler);varr=t.compiler&&t.compiler[0]===7;functionn(a,c,u){u.hash&&(c=sA.extend({},c,u.hash),u.ids&&(u.ids[0]=!0)),a=e.VM.res
`)}return p}else throw new Qo.default("The partial "+u.name+" could not be compiled when running in runtime-only mode")}i(n,"invokePartialWrapper");var o={strict:i(function(c,u,p){if(!c||!(u in c))throw new Qo.default('"'+u+'" not defined in '+c,{loc:p});return o.lookupProperty(c,u)},"strict"),lookupProperty:i(function(c,u){var p=c[u];if(p==null||Object.prototype.hasOwnProperty.call(c,u)&&!r7.isPrototypeConstructor(c,u,p)||r7.resultIsAllowed(p,o.protoAccessControl,u))return p},"lookupProperty"),lookup:i(function(c,u){for(var p=c.length,l=0;l<p;l++){var A=c[l]&&o.lookupProperty(c[l],u);if(A!=null)return A}},"lookup"),lambda:i(function(c,u){return typeof c=="function"?c.call(u):c},"lambda"),escapeExpression:sA.escapeExpression,invokePartial:n,fn:i(function(c){var u=t[c];return u.decorator=t[c+"_d"],u},"fn"),programs:[],program:i(function(c,u,p,l,A){var b=this.programs[c],M=this.fn(c);return u||A||l||p?b=DD(this,c,M,u,p,l,A):b||(b=this.programs[c]=DD(this,c,M)),b},"program"),data:i(function(c,u){for(;c&&u--;)c=c._parent;return c},"data"),mergeIfNeeded:i(function(c,u){var p=c||u;return c&&u&&c!==u&&(p=sA.extend({},u,c)),p},"mergeIfNeeded"),nullContext:Object.seal({}),noop:e.VM.noop,compilerInfo:t.compiler};function s(a){var c=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],u=c.data;s._setup(c),!c.partial&&t.useData&&(u=$h0(a,u));var p=void 0,l=t.useBlockParams?[]:void 0;t.useDepths&&(c.depths?p=a!=c.depths[0]?[a].concat(c.depths):c.depths:p=[a]);function A(b){return""+t.main(o,b,o.helpers,o.partials,u,l,p)}return i(A,"main"),A=Ihe(t.main,A,o,c.depths||[],u,l),A(a,c)}return i(s,"ret"),s.isTop=!0,s._setup=function(a){if(a.partial)o.protoAccessControl=a.protoAccessControl,o.helpers=a.helpers,o.partials=a.partials,o.decorators=a.decorators,o.hooks=a.hooks;else{var c={};qhe(c,e.helpers,o),qhe(c,a.helpers,o),o.helpers=c,t.usePartial&&(o.partials=o.mergeIfNeeded(a.partials,e.partials)),(t.usePartial||t.useDecorators)&&(o.decorators=sA.extend({},e.decorators,a.decorators)),o.hooks={},o.protoAccessControl=r7.createProtoAccessControl(a);var u=a.allowCallsToHelperMissing||r;Bhe.moveHelperToHooks(o,"helperMissing",u),Bhe.moveHelperToHooks(o,"blockHelperMissing",u)}},s._child=function(a,c,u,p){if(t.useBlockParams&&!u)throw new Qo.default("must pass block params");if(t.useDepths&&!p)throw new Qo.default("must pass parent depths");return DD(o,a,t[a],c,0,u,p)},s}i(Yh0,"template");function DD(t,e,r,n,o,s,a){function c(u){var p=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],l=a;return a&&u!=a[0]&&!(u===t.nullContext&&a[0]===null)&&(l=[u].concat(a)),r(t,u,t.helpers,t.partials,p.data||n,s&&[p.blockParams].concat(s),l)}return i(c,"prog"),c=Ihe(r,c,t,a,n,s),c.program=e,c.depth=a?a.length:0,c.blockParams=o||0,c}i(DD,"wrapProgram");function Jh0(t,e,r){return t?typeof t!="function"&&!r.name&&(r.name=t,t=ID(r.partials,t)):r.name==="@partial-block"?t=ID(r.data,"partial-block"):t=ID(r.partials,r.name),t}i(Jh0,"resolvePartial");function jh0(t,e,r){var n=ID(r.data,"partial-block");r.partial=!0,r.ids&&(r.data.contextPath=r.ids[0]||r.data.contextPath);var o=void 0;if(r.fn&&r.fn!==Dhe&&(function(){r.data=Ia.createFrame(r.data);var s=r.fn;o=r.data["partial-block"]=i(function(c){var u=arguments.length<=1||arguments[1]===void 0?{}:arguments[1];return u.data=Ia.createFrame(u.data),u.data["partial-block"]=n,s(c,u)},"partialBlockWrapper"),s.partials&&(r.partials=sA.extend({},r.partials,s.partials))})(),t===void 0&&o&&(t=o),t===void 0)throw new Qo.default("The partial "+r.name+" could not be found");if(t instanceof Function)return t(e,r)}i(jh0,"invokePartial");function Dhe(){return""}i(Dhe,"noop");function ID(t,e){if(t&&Object.prototype.hasOwnProperty.call(t,e))return t[e]}i(ID,"lookupOwnProperty");function $h0(t,e){return(!e||!("root"in e))&&(e=e?Ia.createFrame(e):{},e.root=t),e}i($h0,"initData");function Ihe(t,e,r,n,o,s){if(t.decorator){var a={};e=t.decorator(e,a,r,n&&n[0],o,s,n),sA.extend(e,a)}return e}i(Ihe,"executeDecorators");function qhe(t,e,r){e&&Object.keys(e).forEach(function(n){var o=e[n];t[n]=Kh0(o,r)})}i(qhe,"addHelpers");funct
`+this.lexer.showPosition()+`
Expecting `+ae.join(", ")+", got '"+(this.terminals_[D]||D)+"'":We="Parse error on line "+(A+1)+": Unexpected "+(D==1?"end of input":"'"+(this.terminals_[D]||D)+"'"),this.parseError(We,{text:this.lexer.match,token:this.terminals_[D]||D,line:this.lexer.yylineno,loc:y,expected:ae})}}if(v[0]instanceofArray&&v.length>1)thrownewError("Parse Error: multiple actions possible at state: "+W+", token: "+D);switch(v[0]){case1:a.push(D),c.push(this.lexer.yytext),u.push(this.lexer.yylloc),a.push(v[1]),D=null,x?(D=x,x=null):(b=this.lexer.yyleng,l=this.lexer.yytext,A=this.lexer.yylineno,y=this.lexer.yylloc,M>0&&M--);break;case2:if(Ae=this.productions_[v[1]][1],Ne.$=c[c.length-Ae],Ne._$={first_line:u[u.length-(Ae||1)].first_line,last_line:u[u.length-1].last_line,first_column:u[u.length-(Ae||1)].first_column,last_column:u[u.length-1].last_column},E&&(Ne._$.range=[u[u.length-(Ae||1)].range[0],u[u.length-1].range[1]]),De=this.performAction.call(Ne,l,b,A,this.yy,v[1],c,u),typeofDe<"u")returnDe;Ae&&(a=a.slice(0,-1*Ae*2),c=c.slice(0,-1*Ae),u=u.slice(0,-1*Ae)),a.push(this.productions_[v[1]][0]),c.push(Ne.$),u.push(Ne._$),Fe=p[a[a.length-2]][a[a.length-1]],a.push(Fe);break;case3:return!0}}return!0},"parse")},e=(function(){varn={EOF:1,parseError:i(function(s,a){if(this.yy.parser)this.yy.parser.parseError(s,a);elsethrownewError(s)},"parseError"),setInput:i(function(s){returnthis._input=s,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:i(function(){vars=this._input[0];this.yytext+=s,this.yyleng++,this.offset++,this.match+=s,this.matched+=s;vara=s.match(/(?:\r\n?|\n).*/g);returna?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),s},"input"),unput:i(function(s){vara=s.length,c=s.split(/(?:\r\n?|\n)/g);this._input=s+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-a-1),this.offset-=a;varu=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),c.length-1&&(this.yylineno-=c.length-1);varp=this.yylloc.range;returnthis.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:c?(c.length===u.length?this.yylloc.first_column:0)+u[u.length-c.length].length-c[0].length:this.yylloc.first_column-a},this.options.ranges&&(this.yylloc.range=[p[0],p[0]+this.yyleng-a]),this},"unput"),more:i(function(){returnthis._more=!0,this},"more"),less:i(function(s){this.unput(this.match.slice(s))},"less"),pastInput:i(function(){vars=this.matched.substr(0,this.matched.length-this.match.length);return(s.length>20?"...":"")+s.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:i(function(){vars=this.match;returns.length<20&&(s+=this._input.substr(0,20-s.length)),(s.substr(0,20)+(s.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:i(function(){vars=this.pastInput(),a=newArray(s.length+1).join("-");returns+this.upcomingInput()+`
`+a+"^"},"showPosition"),next:i(function(){if(this.done)returnthis.EOF;this._input||(this.done=!0);vars,a,c,u,p,l;this._more||(this.yytext="",this.match="");for(varA=this._currentRules(),b=0;b<A.length&&(c=this._input.match(this.rules[A[b]]),!(c&&(!a||c[0].length>a[0].length)&&(a=c,u=b,!this.options.flex)));b++);returna?(l=a[0].match(/(?:\r\n?|\n).*/g),l&&(this.yylineno+=l.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:l?l[l.length-1].length-l[l.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._input=this._input.slice(a[0].length),this.matched+=a[0],s=this.performAction.call(this,this.yy,this,A[u],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),s||void0):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}i(tD0,"_nonIterableRest");rz.exports=tD0,rz.exports.__esModule=!0,rz.exports.default=rz.exports});varC4e=h((WO1,nz)=>{varrD0=aye(),nD0=Kye(),oD0=O4e(),sD0=E4e();functioniD0(t,e){returnrD0(t)||nD0(t,e)||oD0(t,e)||sD0()}i(iD0,"_slicedToArray");nz.exports=iD0,nz.exports.__esModule=!0,nz.exports.default=nz.exports});varB4e=h((vO1,y4e)=>{"use strict";varaD0=C5().forEach,cD0=$m(),uD0=cD0("forEach");y4e.exports=uD0?[].forEach:i(function(e){returnaD0(this,e,arguments.length>1?arguments[1]:void0)},"forEach")});varD4e=h(()=>{"use strict";varpD0=w0(),q4e=B4e();pD0({target:"Array",proto:!0,forced:[].forEach!==q4e},{forEach:q4e})});varR4e=h((_O1,I4e)=>{"use strict";D4e();varAD0=Go();I4e.exports=AD0("Array","forEach")});varw4e=h((PO1,N4e)=>{"use strict";varlD0=R4e();N4e.exports=lD0});varS4e=h(()=>{});varW4e=h((GO1,F4e)=>{"use strict";vardD0=tb(),bD0=Kt(),fD0=Ir(),MD0=w4e();S4e();vardU=Array.prototype,hD0={DOMTokenList:!0,NodeList:!0};F4e.exports=function(t){vare=t.forEach;returnt===dU||fD0(dU,t)&&e===dU.forEach||bD0(hD0,dD0(t))?MD0:e}});varbU=h((HO1,x4e)=>{x4e.exports=W4e()});varv4e=h(()=>{"use strict";varmD0=w0(),zD0=i5().includes,gD0=b1(),OD0=Y7(),ED0=gD0(function(){return!Array(1).includes()});mD0({target:"Array",proto:!0,forced:ED0},{includes:i(function(e){returnzD0(this,e,arguments.length>1?arguments[1]:void0)},"includes")});OD0("includes")});varL4e=h((JO1,T4e)=>{"use strict";v4e();varCD0=Go();T4e.exports=CD0("Array","includes")});var_4e=h((jO1,Q4e)=>{"use strict";varyD0=pn(),BD0=Na(),qD0=I1(),DD0=qD0("match");Q4e.exports=function(t){vare;returnyD0(t)&&((e=t[DD0])!==void0?!!e:BD0(t)==="RegExp")}});vark4e=h(($O1,P4e)=>{"use strict";varID0=_4e(),RD0=TypeError;P4e.exports=function(t){if(ID0(t))thrownewRD0("The method doesn't accept regular expressions");returnt}});varG4e=h((KO1,U4e)=>{"use strict";varND0=I1(),wD0=ND0("match");U4e.exports=function(t){vare=/./;try{"/./"[t](e)}catch{try{returne[wD0]=!1,"/./"[t](e)}catch{}}return!1}});varX4e=h(()=>{"use strict";varSD0=w0(),FD0=t1(),WD0=k4e(),xD0=cA(),H4e=hi(),vD0=G4e(),TD0=FD0("".indexOf);SD0({target:"String",proto:!0,forced:!vD0("includes")},{includes:i(function(e){return!!~TD0(H4e(xD0(this)),H4e(WD0(e)),arguments.length>1?arguments[1]:void0)},"includes")})});varY4e=h((r31,V4e)=>{"use strict";X4e();varLD0=Go();V4e.exports=LD0("String","includes")});var$4e=h((n31,j4e)=>{"use strict";varJ4e=Ir(),QD0=L4e(),_D0=Y4e(),fU=Array.prototype,MU=String.prototype;j4e.exports=function(t){vare=t.includes;returnt===fU||J4e(fU,t)&&e===fU.includes?QD0:typeoft=="string"||t===MU||J4e(MU,t)&&e===MU.includes?_D0:e}});varZ4e=h((o31,K4e)=>{"use strict";varPD0=$4e();K4e.exports=PD0});varoz=h((s31,eBe)=>{eBe.exports=Z4e()});varhU=h((i31,tBe)=>{"use strict";tBe.exports=`
Inordertobeiterable,non-arrayobjectsmusthavea[Symbol.iterator]()method.`)}var s=!0,a=!1,c;return{s:i(function(){r=(0,L50.default)(t)},"s"),n:i(function(){var p=r.next();return s=p.done,p},"n"),e:i(function(p){a=!0,c=p},"e"),f:i(function(){try{!s&&r.return!=null&&r.return()}finally{if(a)throw c}},"f")}}i(cz,"_createForOfIteratorHelper");function X50(t,e){var r;if(t){if(typeof t=="string")return Mqe(t,e);var n=(0,ao.default)(r=Object.prototype.toString.call(t)).call(r,8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return(0,k50.default)(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Mqe(t,e)}}i(X50,"_unsupportedIterableToArray");function Mqe(t,e){(e==null||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}i(Mqe,"_arrayLikeToArray");var _0="xregexp",zA={astral:!1,namespacing:!1},f1={exec:RegExp.prototype.exec,test:RegExp.prototype.test,match:String.prototype.match,replace:String.prototype.replace,split:String.prototype.split},mi={},iz={},sb={},CU=[],ib="default",hqe="class",V50={default:/\\(?:0(?:[0-3][0-7]{0,2}|[4-7][0-7]?)?|[1-9]\d*|x[\dA-Fa-f]{2}|u(?:[\dA-Fa-f]{4}|{[\dA-Fa-f]+})|c[A-Za-z]|[\s\S])|\(\?(?:[:=!]|<[=!])|[?*+]\?|{\d+(?:,\d*)?}\??|[\s\S]/,class:/\\(?:[0-3][0-7]{0,2}|[4-7][0-7]?|x[\dA-Fa-f]{2}|u(?:[\dA-Fa-f]{4}|{[\dA-Fa-f]+})|c[A-Za-z]|[\s\S])|[\s\S]/},Y50=/\$(?:{([\w$]+)}|<([\w$]+)>|(\d\d?|[\s\S]))/g,J50=f1.exec.call(/()??/,"")[1]===void 0,j50=(0,mA.default)(/x/)!==void 0,$50={},Eqe=$50.toString;function BU(t){var e=!0;try{if(new RegExp("",t),t==="y"){var r=(function(){return"gy"})(),n=".a".replace(new RegExp("a",r),".")==="..";n&&(e=!1)}}catch{e=!1}return e}i(BU,"hasNativeFlag");var Cqe=BU("u"),qU=BU("y"),yqe={g:!0,i:!0,m:!0,u:Cqe,y:qU};function Bqe(t,e,r,n,o){var s;if(t[_0]={captureNames:e},o)return t;if(t.__proto__)t.__proto__=J.prototype;else for(var a in J.prototype)t[a]=J.prototype[a];return t[_0].source=r,t[_0].flags=n&&(0,H50.default)(s=n.split("")).call(s).join(""),t}i(Bqe,"augment");function az(t){return f1.replace.call(t,/([\s\S])(?=[\s\S]*\1)/g,"")}i(az,"clipDuplicates");function OA(t,e){var r;if(!J.isRegExp(t))throw new TypeError("Type RegExp expected");var n=t[_0]||{},o=K50(t),s="",a="",c=null,u=null;return e=e||{},e.removeG&&(a+="g"),e.removeY&&(a+="y"),a&&(o=f1.replace.call(o,new RegExp("[".concat(a,"]+"),"g"),"")),e.addG&&(s+="g"),e.addY&&(s+="y"),s&&(o=az(o+s)),e.isInternalOnly||(n.source!==void 0&&(c=n.source),(0,mA.default)(n)!=null&&(u=s?az((0,mA.default)(n)+s):(0,mA.default)(n))),t=Bqe(new RegExp(e.source||t.source,o),Z50(t)?(0,ao.default)(r=n.captureNames).call(r,0):null,c,u,e.isInternalOnly),t}i(OA,"copyRegex");function qqe(t){return(0,Oqe.default)(t,16)}i(qqe,"dec");function Dqe(t,e,r){return t.input[t.index-1]==="("||t.input[t.index+t[0].length]===")"||t.input[t.index-1]==="|"||t.input[t.index+t[0].length]==="|"||t.index<1||t.index+t[0].length>=t.input.length||f1.test.call(/^\(\?[:=!]/,t.input.substr(t.index-3,3))||eI0(t.input,t.index+t[0].length,r)?"":"(?:)"}i(Dqe,"getContextualTokenSeparator");function K50(t){return j50?(0,mA.default)(t):f1.exec.call(/\/([a-z]*)$/i,RegExp.prototype.toString.call(t))[1]}i(K50,"getNativeFlags");function Z50(t){return!!(t[_0]&&t[_0].captureNames)}i(Z50,"hasNamedCapture");function Iqe(t){return(0,Oqe.default)(t,10).toString(16)}i(Iqe,"hex");function eI0(t,e,r){var n="\\(\\?#[^)]*\\)",o="#[^#\\n]*",s="[?*+]|{\\d+(?:,\\d*)?}";return f1.test.call((0,gA.default)(r).call(r,"x")?/^(?:\s|#[^#\n]*|\(\?#[^)]*\))*(?:[?*+]|{\d+(?:,\d*)?})/:/^(?:\(\?#[^)]*\))*(?:[?*+]|{\d+(?:,\d*)?})/,(0,ao.default)(t).call(t,e))}i(eI0,"isQuantifierNext");function DU(t,e){return Eqe.call(t)==="[object ".concat(e,"]")}i(DU,"isType");function Rqe(t){for(;t.length<4;)t="0".concat(t);return t}i(Rqe,"pad4");function tI0(t,e){if(az(e)!==e)throw new SyntaxError("Invalid duplicate regex flag ".concat(e));t=f1.replace.call(t,/^\(\?([\w$]+)\)/,function(s,a){if(f1.test.call(/[gy]/,a))throw new SyntaxError("Cannot use flag g or y in mode modifier ".concat(s));return e=az(e+a),""});var
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}vars=!0,a=!1,c;return{s:i(function(){r=(0,TI0.default)(t)},"s"),n:i(function(){varp=r.next();returns=p.done,p},"n"),e:i(function(p){a=!0,c=p},"e"),f:i(function(){try{!s&&r.return!=null&&r.return()}finally{if(a)throwc}},"f")}}i(HI0,"_createForOfIteratorHelper");functionXI0(t,e){varr;if(t){if(typeoft=="string")returnMDe(t,e);varn=(0,kI0.default)(r=Object.prototype.toString.call(t)).call(r,8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return(0,PI0.default)(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))returnMDe(t,e)}}i(XI0,"_unsupportedIterableToArray");functionMDe(t,e){(e==null||e>t.length)&&(e=t.length);for(varr=0,n=newArray(e);r<e;r++)n[r]=t[r];returnn}i(MDe,"_arrayLikeToArray");varVI0=i(function(e){varr={},n=e._dec,o=e._hex,s=e._pad4;functiona(b){returnb.replace(/[- _]+/g,"").toLowerCase()}i(a,"normalize");functionc(b){varM=/^\\[xu](.+)/.exec(b);returnM?n(M[1]):b.charCodeAt(b[0]==="\\"?1:0)}i(c,"charCode");functionu(b){varM="",z=-1;return(0,GI0.default)(e).call(e,b,/(\\x..|\\u....|\\?[\s\S])(?:-(\\x..|\\u....|\\?[\s\S]))?/,function(O){vary=c(O[1]);y>z+1&&(M+="\\u".concat(s(o(z+1))),y>z+2&&(M+="-\\u".concat(s(o(y-1))))),z=c(O[2]||O[1])}),z<65535&&(M+="\\u".concat(s(o(z+1))),z<65534&&(M+="-\\uFFFF")),M}i(u,"invertBmp");functionp(b){varM="b!";returnr[b][M]||(r[b][M]=u(r[b].bmp))}i(p,"cacheInvertedBmp");functionl(b,M){varz=r[b],O="";if(z.bmp&&!z.isBmpLast){vary;O=(0,wU.default)(y="[".concat(z.bmp,"]")).call(y,z.astral?"|":"")}if(z.astral&&(O+=z.astral),z.isBmpLast&&z.bmp){varE;O+=(0,wU.default)(E="".concat(z.astral?"|":"","[")).call(E,z.bmp,"]")}returnM?"(?:(?!".concat(O,")(?:[\uD800-\uDBFF][\uDC00-\uDFFF]|[\0-\uFFFF]))"):"(?:".concat(O,")")}i(l,"buildAstral");functionA(b,M){varz=M?"a!":"a=";returnr[b][z]||(r[b][z]=l(b,M))}i(A,"cacheAstral"),e.addToken(/\\([pP])(?:{(\^?)([^}]*)}|([A-Za-z]))/,function(b,M,z){varO="Invalid double negation ",y="Unknown Unicode token ",E="Unicode token missing data ",B="Astral mode required for Unicode token ",q="Astral mode does not support Unicode tokens within character classes",D=b[1]==="P"||!!b[2],x=(0,UI0.default)(z).call(z,"A"),W=a(b[4]||b[3]),v=r[W];if(b[1]==="P"&&b[2])thrownewSyntaxError(O+b[0]);if(!r.hasOwnProperty(W))thrownewSyntaxError(y+b[0]);if(v.inverseOf){if(W=a(v.inverseOf),!r.hasOwnProperty(W)){varie;thrownewReferenceError((0,wU.default)(ie="".concat(E+b[0]," -> ")).call(ie,v.inverseOf))}v=r[W],D=!D}if(!(v.bmp||x))thrownewSyntaxError(B+b[0]);if(x){if(M==="class")thrownewSyntaxError(q);returnA(W,D)}returnM==="class"?D?p(W):v.bmp:"".concat((D?"[^":"[")+v.bmp,"]")},{scope:"all",optionalFlags:"A",leadChar:"\\"}),e.addUnicodeData=function(b){varM="Unicode token requires name",z="Unicode token has no character data ",O=HI0(b),y;try{for(O.s();!(y=O.n()).done;){varE=y.value;if(!E.name)thrownewError(M);if(!(E.inverseOf||E.bmp||E.astral))thrownewError(z+E.name);r[a(E.name)]=E,E.alias&&(r[a(E.alias)]=E)}}catch(B){O.e(B)}finally{O.f()}e.cache.flush("patterns")},e._getUnicodeProperty=function(b){varM=a(b);returnr[M]}},"_default");bz.default=VI0;hDe.exports=bz.default});vargDe=h((uE1,zDe)=>{zDe.exports=[{name:"InAdlam",astral:"\uD83A[\uDD00-\uDD5F]"},{name:"InAegean_Numbers",astral:"\uD800[\uDD00-\uDD3F]"},{name:"InAhom",astral:"\uD805[\uDF00-\uDF3F]"},{name:"InAlchemical_Symbols",astral:"\uD83D[\uDF00-\uDF7F]"},{name:"InAlphabetic_Presentation_Forms",bmp:"\uFB00-\uFB4F"},{name:"InAnatolian_Hieroglyphs",astral:"\uD811[\uDC00-\uDE7F]"},{name:"InAncient_Greek_Musical_Notation",astral:"\uD834[\uDE00-\uDE4F]"},{name:"InAncient_Greek_Numbers",astral:"\uD800[\uDD40-\uDD8F]"},{name:"InAncient_Symbols",astral:"\uD800[\uDD90-\uDDCF]"},{name:"InArabic",bmp:"\u0600-\u06FF"},{name:"InArabic_Extended_A",bmp:"\u08A0-\u08FF"},{name:"InArabic_Mathematical_Alphabetic_Symbols",astral:"\uD83B[\uDE00-\uDEFF]"},{name:"InArabic_Presentation_Forms_A",bmp:"\uFB50-\uFDFF"},{name:"InArabic_Presentation_Forms_B",
Supportbooleaninputlist:\`true | True | TRUE | false | False | FALSE\``)}i(QZ,"getBooleanInput");functione6(t,e){if(process.env.GITHUB_OUTPUT||"")returnmb("OUTPUT",Hz(t,e));process.stdout.write(Zw.EOL),Yo("set-output",{name:t},Vo(e))}i(e6,"setOutput");function_Z(t){process.exitCode=Kw.Failure,Nl(t)}i(_Z,"setFailed");functionHi(){returnprocess.env.RUNNER_DEBUG==="1"}i(Hi,"isDebug");functionN(t){Yo("debug",{},t)}i(N,"debug");functionNl(t,e={}){Yo("error",cI(e),tinstanceofError?t.toString():t)}i(Nl,"error");functionr0(t,e={}){Yo("warning",cI(e),tinstanceofError?t.toString():t)}i(r0,"warning");functionS(t){process.stdout.write(t+Zw.EOL)}i(S,"info");functionPu(t){pI("group",t)}i(Pu,"startGroup");functionku(){pI("endgroup")}i(ku,"endGroup");functionct(t,e){returnvke(this,void0,void0,function*(){Pu(t);letr;try{r=yielde()}finally{ku()}returnr})}i(ct,"group");functionXO(t,e){if(process.env.GITHUB_STATE||"")returnmb("STATE",Hz(t,e));Yo("save-state",{name:t},Vo(e))}i(XO,"saveState");functionPZ(t){returnprocess.env[`STATE_${t}`]||""}i(PZ,"getState");varzh=w(require("fs"),1),d8=w(require("os"),1),b8=w(require("path"),1);varUZ=w(require("os"),1);functionIf(t){returnt==null?"":typeoft=="string"||tinstanceofString?t:JSON.stringify(t)}i(If,"toCommandValue");functionGZ(t,e,r){letn=newt6(t,e,r);process.stdout.write(n.toString()+UZ.EOL)}i(GZ,"issueCommand");varkZ="::",t6=class{static{i(this,"Command")}constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){lete=kZ+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";letr=!0;for(letninthis.properties)if(this.properties.hasOwnProperty(n)){leto=this.properties[n];o&&(r?r=!1:e+=",",e+=`${n}=${Lke(o)}`)}}returne+=`${kZ}${Tke(this.message)}`,e}};functionTke(t){returnIf(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}i(Tke,"escapeData");functionLke(t){returnIf(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}i(Lke,"escapeProperty");varYZ=w(require("os"),1);varXZ=require("os"),Rf=require("fs");varr6=function(t,e,r,n){functiono(s){returnsinstanceofr?s:newr(function(a){a(s)})}returni(o,"adopt"),new(r||(r=Promise))(function(s,a){functionc(l){try{p(n.next(l))}catch(A){a(A)}}i(c,"fulfilled");functionu(l){try{p(n.throw(l))}catch(A){a(A)}}i(u,"rejected");functionp(l){l.done?s(l.value):o(l.value).then(c,u)}i(p,"step"),p((n=n.apply(t,e||[])).next())})},{access:Qke,appendFile:_ke,writeFile:Pke}=Rf.promises,HZ="GITHUB_STEP_SUMMARY";varn6=class{static{i(this,"Summary")}constructor(){this._buffer=""}filePath(){returnr6(this,void0,void0,function*(){if(this._filePath)returnthis._filePath;lete=process.env[HZ];if(!e)thrownewError(`Unable to find environment variable for $${HZ}. Check if your runtime environment supports job summaries.`);try{yieldQke(e,Rf.constants.R_OK|Rf.constants.W_OK)}catch{thrownewError(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}returnthis._filePath=e,this._filePath})}wrap(e,r,n={}){leto=Object.entries(n).map(([s,a])=>` ${s}="${a}"`).join("");returnr?`<${e}${o}>${r}</${e}>`:`<${e}${o}>`}write(e){returnr6(this,void0,void0,function*(){letr=!!e?.overwrite,n=yieldthis.filePath();returnyield(r?Pke:_ke)(n,this._buffer,{encoding:"utf8"}),this.emptyBuffer()})}clear(){returnr6(this,void0,void0,function*(){returnthis.emptyBuffer().write({overwrite:!0})})}stringify(){returnthis._buffer}isEmptyBuffer(){returnthis._buffer.length===0}emptyBuffer(){returnthis._buffer="",this}addRaw(e,r=!1){returnthis._buffer+=e,r?this.addEOL():this}addEOL(){returnthis.addRaw(XZ.EOL)}addCodeBlock(e,r){letn=Object.assign({},r&&{lang:r}),o=this.wrap("pre",this.wrap("code",e),n);returnthis.addRaw(o).addEOL()}addList(e,r=!1){letn=r?"ol":"ul",o=e.map(a=>this.wrap("li",a)).join(""),s=this.wrap(n,o);returnthis.addRaw(s).addEOL()}addTable(e){letr=e.map(o=>{lets=o.map(a=>{if(typeofa=="string")returnthis.wrap("td",a);let{header:c,data:u,cols
`,"utf-8")],o=QJe(n);o&&t.headers.set("Content-Length",o),t.body=awaitYne(n)}i(_Je,"buildRequestBody");varaM="multipartPolicy",PJe=70,kJe=newSet("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'()+,-./:=?");functionUJe(t){if(t.length>PJe)thrownewError(`Multipart boundary "${t}" exceeds maximum length of 70 characters`);if(Array.from(t).some(e=>!kJe.has(e)))thrownewError(`Multipart boundary "${t}" contains invalid characters`)}i(UJe,"assertValidBoundary");functionlE(){return{name:aM,asyncsendRequest(t,e){if(!t.multipartBody)returne(t);if(t.body)thrownewError("multipartBody and regular body cannot be set at the same time");letr=t.multipartBody.boundary,n=t.headers.get("Content-Type")??"multipart/mixed",o=n.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/);if(!o)thrownewError(`Got multipart request body, but content-type header was not multipart: ${n}`);let[,s,a]=o;if(a&&r&&a!==r)thrownewError(`Multipart boundary was specified as ${a} in the header, but got ${r} in the request body`);returnr??=a,r?UJe(r):r=vJe(),t.headers.set("Content-Type",`${s}; boundary=${r}`),await_Je(t,t.multipartBody.parts,r),t.multipartBody=void0,e(t)}}}i(lE,"multipartPolicy");functiondE(){returnv3()}i(dE,"createEmptyPipeline");varJne=F3({logLevelEnvVarName:"AZURE_LOG_LEVEL",namespace:"azure"}),Jk0=Jne.logger;functionMs(t){returnJne.createClientLogger(t)}i(Ms,"createClientLogger");varhs=Ms("core-rest-pipeline");functionYS(t={}){returnk3({logger:hs.info,...t})}i(YS,"logPolicy");varJS=U3;functionjS(t={}){returnG3(t)}i(jS,"redirectPolicy");varbE=w(require("node:os"),1),fE=w(require("node:process"),1);functionjne(){return"User-Agent"}i(jne,"getHeaderName");asyncfunction$ne(t){if(fE.default&&fE.default.versions){lete=`${bE.default.type()}${bE.default.release()}; ${bE.default.arch()}`,r=fE.default.versions;r.bun?t.set("Bun",`${r.bun} (${e})`):r.deno?t.set("Deno",`${r.deno} (${e})`):r.node&&t.set("Node",`${r.node} (${e})`)}}i($ne,"setPlatformSpecificData");varME="1.22.2";function$Je(t){lete=[];for(let[r,n]oft){leto=n?`${r}/${n}`:r;e.push(o)}returne.join(" ")}i($Je,"getUserAgentString");functionKne(){returnjne()}i(Kne,"getUserAgentHeaderName");asyncfunctionhE(t){lete=newMap;e.set("core-rest-pipeline",ME),await$ne(e);letr=$Je(e);returnt?`${t}${r}`:r}i(hE,"getUserAgentValue");varZne=Kne(),eoe="userAgentPolicy";function$S(t={}){lete=hE(t.userAgentPrefix);return{name:eoe,asyncsendRequest(r,n){returnr.headers.has(Zne)||r.headers.set(Zne,awaite),n(r)}}}i($S,"userAgentPolicy");varjr=classextendsError{static{i(this,"AbortError")}constructor(e){super(e),this.name="AbortError"}};functionKS(t,e){let{cleanupBeforeAbort:r,abortSignal:n,abortErrorMsg:o}=e??{};returnnewPromise((s,a)=>{functionc(){a(newjr(o??"The operation was aborted."))}i(c,"rejectOnAbort");functionu(){n?.removeEventListener("abort",p)}i(u,"removeListeners");functionp(){r?.(),u(),c()}if(i(p,"onAbort"),n?.aborted)returnc();try{t(l=>{u(),s(l)},l=>{u(),a(l)})}catch(l){a(l)}n?.addEventListener("abort",p)})}i(KS,"createAbortablePromise");varrje="The delay was aborted.";functioncM(t,e){letr,{abortSignal:n,abortErrorMsg:o}=e??{};returnKS(s=>{r=setTimeout(s,t)},{cleanupBeforeAbort:i(()=>clearTimeout(r),"cleanupBeforeAbort"),abortSignal:n,abortErrorMsg:o??rje})}i(cM,"delay");functionMc(t){if(Yu(t))returnt.message;{lete;try{typeoft=="object"&&t?e=JSON.stringify(t):e=String(t)}catch{e="[unable to stringify input]"}return`Unknown error ${e}`}}i(Mc,"getErrorMessage");functiontoe(t){returnYu(t)}i(toe,"isError");functionjl(){returnVu()}i(jl,"randomUUID");varl0=$u;varroe=Symbol("rawContent");functioneF(t){returntypeoft[roe]=="function"}i(eF,"hasRawContent");functionnoe(t){returneF(t)?t[roe]():t}i(noe,"getRawContent");varmE=aM;functiontF(){lett=lE();return{name:mE,sendRequest:i(async(e,r)=>{if(e.multipartBody)for(letnofe.multipartBody.parts)eF(n.body)&&(n.body=noe(n.body));returnt.sendRequest(e,r)},"sendRequest")}}i(tF,"multipartPolicy");varrF=H3;functionnF(){returnX3()}i(nF,"decompressResponsePolicy");fun
`&&t[s]!=="\r";s++)u+=t[s];if(u=u.trim(),u[u.length-1]==="/"&&(u=u.substring(0,u.length-1),s--),!q$e(u)){let A;return u.trim().length===0?A="Invalid space after '<'.":A="Tag '"+u+"' is an invalid name.",O1("InvalidTag",A,Ut(t,s))}let p=O$e(t,s);if(p===!1)return O1("InvalidAttr","Attributes for '"+u+"' have open quote.",Ut(t,s));let l=p.value;if(s=p.index,l[l.length-1]==="/"){let A=s-l.length;l=l.substring(0,l.length-1);let b=koe(l,e);if(b===!0)n=!0;else return O1(b.err.code,b.err.msg,Ut(t,A+b.err.line))}else if(c)if(p.tagClosed){if(l.trim().length>0)return O1("InvalidTag","Closing tag '"+u+"' can't have attributes or invalid starting.",Ut(t,a));if(r.length===0)return O1("InvalidTag","Closing tag '"+u+"' has not been opened.",Ut(t,a));{let A=r.pop();if(u!==A.tagName){let b=Ut(t,A.tagStartPos);return O1("InvalidTag","Expected closing tag '"+A.tagName+"' (opened in line "+b.line+", col "+b.col+") instead of closing tag '"+u+"'.",Ut(t,a))}r.length==0&&(o=!0)}}else return O1("InvalidTag","Closing tag '"+u+"' doesn't have proper closing.",Ut(t,s));else{let A=koe(l,e);if(A!==!0)return O1(A.err.code,A.err.msg,Ut(t,s-l.length+A.err.line));if(o===!0)return O1("InvalidXml","Multiple possible root nodes found.",Ut(t,s));e.unpairedTags.indexOf(u)!==-1||r.push({tagName:u,tagStartPos:a}),n=!0}for(s++;s<t.length;s++)if(t[s]==="<")if(t[s+1]==="!"){s++,s=Poe(t,s);continue}else if(t[s+1]==="?"){if(s=_oe(t,++s),s.err)return s}else break;else if(t[s]==="&"){let A=y$e(t,s);if(A==-1)return O1("InvalidChar","char '&' is not expected.",Ut(t,s));s=A}else if(o===!0&&!Qoe(t[s]))return O1("InvalidXml","Extra text at the end",Ut(t,s));t[s]==="<"&&s--}}else{if(Qoe(t[s]))continue;return O1("InvalidChar","char '"+t[s]+"' is not expected.",Ut(t,s))}if(n){if(r.length==1)return O1("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",Ut(t,r[0].tagStartPos));if(r.length>0)return O1("InvalidXml","Invalid '"+JSON.stringify(r.map(s=>s.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return O1("InvalidXml","Start tag expected.",1);return!0}i(wE,"validate");function Qoe(t){return t===" "||t===" "||t===`
`||t==="\r"}i(Qoe,"isWhiteSpace");function _oe(t,e){let r=e;for(;e<t.length;e++)if(t[e]=="?"||t[e]==" "){let n=t.substr(r,e-r);if(e>5&&n==="xml")return O1("InvalidXml","XML declaration allowed only at the start of the document.",Ut(t,e));if(t[e]=="?"&&t[e+1]==">"){e++;break}else continue}return e}i(_oe,"readPI");function Poe(t,e){if(t.length>e+5&&t[e+1]==="-"&&t[e+2]==="-"){for(e+=3;e<t.length;e++)if(t[e]==="-"&&t[e+1]==="-"&&t[e+2]===">"){e+=2;break}}else if(t.length>e+8&&t[e+1]==="D"&&t[e+2]==="O"&&t[e+3]==="C"&&t[e+4]==="T"&&t[e+5]==="Y"&&t[e+6]==="P"&&t[e+7]==="E"){let r=1;for(e+=8;e<t.length;e++)if(t[e]==="<")r++;else if(t[e]===">"&&(r--,r===0))break}else if(t.length>e+9&&t[e+1]==="["&&t[e+2]==="C"&&t[e+3]==="D"&&t[e+4]==="A"&&t[e+5]==="T"&&t[e+6]==="A"&&t[e+7]==="["){for(e+=8;e<t.length;e++)if(t[e]==="]"&&t[e+1]==="]"&&t[e+2]===">"){e+=2;break}}return e}i(Poe,"readCommentAndCDATA");var z$e='"',g$e="'";function O$e(t,e){let r="",n="",o=!1;for(;e<t.length;e++){if(t[e]===z$e||t[e]===g$e)n===""?n=t[e]:n!==t[e]||(n="");else if(t[e]===">"&&n===""){o=!0;break}r+=t[e]}return n!==""?!1:{value:r,index:e,tagClosed:o}}i(O$e,"readAttributeStr");var E$e=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function koe(t,e){let r=RE(t,E$e),n={};for(let o=0;o<r.length;o++){if(r[o][1].length===0)return O1("InvalidAttr","Attribute '"+r[o][2]+"' has no space in starting.",gM(r[o]));if(r[o][3]!==void 0&&r[o][4]===void 0)return O1("InvalidAttr","Attribute '"+r[o][2]+"' is without value.",gM(r[o]));if(r[o][3]===void 0&&!e.allowBooleanAttributes)return O1("InvalidAttr","boolean attribute '"+r[o][2]+"' is not allowed.",gM(r[o]));let s=r[o][2];if(!B$e(s))return O1("InvalidAttr","Attribute '"+s+"' is an invalid name.",gM(r[o]));if(!Object.prototype.hasOwnProperty.call(n,s))n[s]=1;else return O1("InvalidAttr","Attribute '"+s+"' is repeated.",gM(r[o]))}return!0}i(koe,"validateAttributeString");function C$e(t,e){let r=/\d/;for(t[e]==="x"&&(e++,r=/[\da-fA-F]/);e<t.length;e++){if(t[e]===";")return e;if(!t[e].match(r))break}return-1}i(C$e,"validateNumberAmpersand");function y$e(t,e){if(e++,t[e]===";")return-1;if(t[e]==="#")return e++,C$e(t,e);let r=0;for(;e<t.length;e++,r++)if(!(t[e].match(/\w/)&&r<20)){if(t[e]===";")break;return-1}return e}i(y$e,"validateAmpersand");function O1(t,e,r){return{err:{code:t,msg:e,line:r.line||r,col:r.col}}}i(O1,"getErrorObject");function B$e(t){return IF(t)}i(B$e,"validateAttrName");function q$e(t){return IF(t)}i(q$e,"validateTagName");function Ut(t,e){let r=t.substring(0,e).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}i(Ut,"getLineNumberForPosition");function gM(t){return t.startIndex+t[1].length}i(gM,"getPositionFromMatch");var Uoe={amp:"&",AMP:"&",lt:"<",LT:"<",gt:">",GT:">",quot:'"',QUOT:'"',apos:"'",lsquo:"\u2018",rsquo:"\u2019",ldquo:"\u201C",rdquo:"\u201D",lsquor:"\u201A",rsquor:"\u2019",ldquor:"\u201E",bdquo:"\u201E",comma:",",period:".",colon:":",semi:";",excl:"!",quest:"?",num:"#",dollar:"$",percent:"%",amp:"&",ast:"*",commat:"@",lowbar:"_",verbar:"|",vert:"|",sol:"/",bsol:"\\",lbrace:"{",rbrace:"}",lbrack:"[",rbrack:"]",lpar:"(",rpar:")",nbsp:"\xA0",iexcl:"\xA1",cent:"\xA2",pound:"\xA3",curren:"\xA4",yen:"\xA5",brvbar:"\xA6",sect:"\xA7",uml:"\xA8",copy:"\xA9",COPY:"\xA9",ordf:"\xAA",laquo:"\xAB",not:"\xAC",shy:"\xAD",reg:"\xAE",REG:"\xAE",macr:"\xAF",deg:"\xB0",plusmn:"\xB1",sup2:"\xB2",sup3:"\xB3",acute:"\xB4",micro:"\xB5",para:"\xB6",middot:"\xB7",cedil:"\xB8",sup1:"\xB9",ordm:"\xBA",raquo:"\xBB",frac14:"\xBC",frac12:"\xBD",half:"\xBD",frac34:"\xBE",iquest:"\xBF",times:"\xD7",div:"\xF7",divide:"\xF7"},Goe={Agrave:"\xC0",agrave:"\xE0",Aacute:"\xC1",aacute:"\xE1",Acirc:"\xC2",acirc:"\xE2",Atilde:"\xC3",atilde:"\xE3",Auml:"\xC4",auml:"\xE4",Aring:"\xC5",aring:"\xE5",AElig:"\xC6",aelig:"\xE6",Ccedil:"\xC7",ccedil:"\xE7",Egrave:"\xC8",egrave:"\xE8",Eacute:"\xC9",eacute:"\xE9",Ecirc:"\xCA",ecirc:"\xEA",Euml:"\xCB",euml:"\xEB",Igrave:"\xCC",igrave:"\xEC",Iacute:"\xCD",iacute:"\xED",Icirc:"\xCE",icirc:"\xEE",Iuml:"\xCF",iuml:"\xEF",ETH:"\xD0",eth:"\xF0",Ntilde:"\xD1",ntil
`);let e=new Ar("!xml"),r=e,n="";this.matcher.reset(),this.entityDecoder.reset(),this.entityExpansionCount=0,this.currentExpandedLength=0;let o=this.options,s=new CM(o.processEntities),a=t.length;for(let c=0;c<a;c++)if(t[c]==="<"){let p=t.charCodeAt(c+1);if(p===47){let l=r2(t,">",c,"ClosingTagisnotclosed."),A=t.substring(c+2,l).trim();if(o.removeNSPrefix){let M=A.indexOf(":");M!==-1&&(A=A.substr(M+1))}A=vF(o.transformTagName,A,"",o).tagName,r&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher));let b=this.matcher.getCurrentTag();if(A&&o.unpairedTagsSet.has(A))throw new Error(`Unpaired tag can not be used as closing tag: </${A}>`);b&&o.unpairedTagsSet.has(b)&&(this.matcher.pop(),this.tagsNodeStack.pop()),this.matcher.pop(),this.isCurrentNodeStopNode=!1,r=this.tagsNodeStack.pop(),n="",c=l}else if(p===63){let l=TF(t,c,!1,"?>");if(!l)throw new Error("PiTagisnotclosed.");n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let A=this.buildAttributesMap(l.tagExp,this.matcher,l.tagName,!0);if(A){let b=A[this.options.attributeNamePrefix+"version"];this.entityDecoder.setXmlVersion(Number(b)||1),s.setXmlVersion(Number(b)||1)}if(!(o.ignoreDeclaration&&l.tagName==="?xml"||o.ignorePiTags)){let b=new Ar(l.tagName);b.add(o.textNodeName,""),l.tagName!==l.tagExp&&l.attrExpPresent&&o.ignoreAttributes!==!0&&(b[":@"]=A),this.addChild(r,b,this.readonlyMatcher,c)}c=l.closeIndex+1}else if(p===33&&t.charCodeAt(c+2)===45&&t.charCodeAt(c+3)===45){let l=r2(t,"-->",c+4,"Commentisnotclosed.");if(o.commentPropName){let A=t.substring(c+4,l-2);n=this.saveTextToParentTag(n,r,this.readonlyMatcher),r.add(o.commentPropName,[{[o.textNodeName]:A}])}c=l}else if(p===33&&t.charCodeAt(c+2)===68){let l=s.readDocType(t,c);this.entityDecoder.addInputEntities(l.entities),c=l.i}else if(p===33&&t.charCodeAt(c+2)===91){let l=r2(t,"]]>",c,"CDATAisnotclosed.")-2,A=t.substring(c+9,l);n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let b=this.parseTextData(A,r.tagname,this.readonlyMatcher,!0,!1,!0,!0);b==null&&(b=""),o.cdataPropName?r.add(o.cdataPropName,[{[o.textNodeName]:A}]):r.add(o.textNodeName,b),c=l+2}else{let l=TF(t,c,o.removeNSPrefix);if(!l){let W=t.substring(Math.max(0,c-50),Math.min(a,c+50));throw new Error(`readTagExp returned undefined at position ${c}. Context: "${W}"`)}let A=l.tagName,b=l.rawTagName,M=l.tagExp,z=l.attrExpPresent,O=l.closeIndex;if({tagName:A,tagExp:M}=vF(o.transformTagName,A,M,o),o.strictReservedNames&&(A===o.commentPropName||A===o.cdataPropName||A===o.textNodeName||A===o.attributesGroupName))throw new Error(`Invalid tag name: ${A}`);r&&n&&r.tagname!=="!xml"&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher,!1));let y=r;y&&o.unpairedTagsSet.has(y.tagname)&&(r=this.tagsNodeStack.pop(),this.matcher.pop());let E=!1;M.length>0&&M.lastIndexOf("/")===M.length-1&&(E=!0,A[A.length-1]==="/"?(A=A.substr(0,A.length-1),M=A):M=M.substr(0,M.length-1),z=A!==M);let B=null,q={},D;D=J$e(b),A!==e.tagname&&this.matcher.push(A,{},D),A!==M&&z&&(B=this.buildAttributesMap(M,this.matcher,A),B&&(q=Y$e(B,o))),A!==e.tagname&&(this.isCurrentNodeStopNode=this.isItStopNode());let x=c;if(this.isCurrentNodeStopNode){let W="";if(E)c=l.closeIndex;else if(o.unpairedTagsSet.has(A))c=l.closeIndex;else{let ie=this.readStopNodeData(t,b,O+1);if(!ie)throw new Error(`Unexpected end of ${b}`);c=ie.i,W=ie.tagContent}let v=new Ar(A);B&&(v[":@"]=B),v.add(o.textNodeName,W),this.matcher.pop(),this.isCurrentNodeStopNode=!1,this.addChild(r,v,this.readonlyMatcher,x)}else{if(E){({tagName:A,tagExp:M}=vF(o.transformTagName,A,M,o));let W=new Ar(A);B&&(W[":@"]=B),this.addChild(r,W,this.readonlyMatcher,x),this.matcher.pop(),this.isCurrentNodeStopNode=!1}else if(o.unpairedTagsSet.has(A)){let W=new Ar(A);B&&(W[":@"]=B),this.addChild(r,W,this.readonlyMatcher,x),this.matcher.pop(),this.isCurrentNodeStopNode=!1,c=l.closeIndex;continue}else{let W=new Ar(A);if(this.tagsNodeStack.length>o.maxNestedTags)throw new Error("Maximumnestedtagsexceeded");this.tagsNodeStack.push(r),B&&(W[":@"]=B),this.addChild(r,W,this.readonlyMatcher,x),r=W}n="",c=O}}}else n+=t[c];return e.child},"parse
${c}:${decodeURIComponent(s[c])}`}returnn}};varo1=classextendssp{static{i(this,"StorageSharedKeyCredential")}accountName;accountKey;constructor(e,r){super(),this.accountName=e,this.accountKey=Buffer.from(r,"base64")}create(e,r){returnnewIM(e,r,this)}computeHMACSHA256(e){return(0,Ose.createHmac)("sha256",this.accountKey).update(e,"utf8").digest("base64")}};var_1=Ms("storage-common");varSn;(function(t){t[t.EXPONENTIAL=0]="EXPONENTIAL",t[t.FIXED=1]="FIXED"})(Sn||(Sn={}));varEc={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:Sn.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void0},IKe=newjr("The operation was aborted."),RM=classextendsOs{static{i(this,"StorageRetryPolicy")}retryOptions;constructor(e,r,n=Ec){super(e,r),this.retryOptions={retryPolicyType:n.retryPolicyType?n.retryPolicyType:Ec.retryPolicyType,maxTries:n.maxTries&&n.maxTries>=1?Math.floor(n.maxTries):Ec.maxTries,tryTimeoutInMs:n.tryTimeoutInMs&&n.tryTimeoutInMs>=0?n.tryTimeoutInMs:Ec.tryTimeoutInMs,retryDelayInMs:n.retryDelayInMs&&n.retryDelayInMs>=0?Math.min(n.retryDelayInMs,n.maxRetryDelayInMs?n.maxRetryDelayInMs:Ec.maxRetryDelayInMs):Ec.retryDelayInMs,maxRetryDelayInMs:n.maxRetryDelayInMs&&n.maxRetryDelayInMs>=0?n.maxRetryDelayInMs:Ec.maxRetryDelayInMs,secondaryHost:n.secondaryHost?n.secondaryHost:Ec.secondaryHost}}asyncsendRequest(e){returnthis.attemptSendRequest(e,!1,1)}asyncattemptSendRequest(e,r,n){leto=e.clone(),s=r||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||n%2===1;s||(o.url=UE(o.url,this.retryOptions.secondaryHost)),this.retryOptions.tryTimeoutInMs&&(o.url=Oc(o.url,ea.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString()));leta;try{if(_1.info(`RetryPolicy: =====> Try=${n}${s?"Primary":"Secondary"}`),a=awaitthis._nextPolicy.sendRequest(o),!this.shouldRetry(s,n,a))returna;r=r||!s&&a.status===404}catch(c){if(_1.error(`RetryPolicy: Caught error, message: ${c.message}, code: ${c.code}`),!this.shouldRetry(s,n,a,c))throwc}returnawaitthis.delay(s,n,e.abortSignal),this.attemptSendRequest(e,r,++n)}shouldRetry(e,r,n,o){if(r>=this.retryOptions.maxTries)return_1.info(`RetryPolicy: Attempt(s) ${r} >= maxTries ${this.retryOptions.maxTries}, no further try.`),!1;lets=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(o){for(letaofs)if(o.name.toUpperCase().includes(a)||o.message.toUpperCase().includes(a)||o.code&&o.code.toString().toUpperCase()===a)return_1.info(`RetryPolicy: Network error ${a} found, will retry.`),!0}if(n||o){leta=n?n.status:o?o.statusCode:0;if(!e&&a===404)return_1.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(a===503||a===500)return_1.info(`RetryPolicy: Will retry for status code ${a}.`),!0}if(n&&n?.status>=400){leta=n.headers.get(qe.X_MS_CopySourceErrorCode);if(a!==void0)switch(a){case"InternalError":case"OperationTimedOut":case"ServerBusy":return!0}}returno?.code==="PARSE_ERROR"&&o?.message.startsWith('Error "Error: Unclosed root tag')?(_1.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0):!1}asyncdelay(e,r,n){leto=0;if(e)switch(this.retryOptions.retryPolicyType){caseSn.EXPONENTIAL:o=Math.min((Math.pow(2,r-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;caseSn.FIXED:o=this.retryOptions.retryDelayInMs;break}elseo=Math.random()*1e3;return_1.info(`RetryPolicy: Delay for ${o}ms`),XE(o,n,IKe)}};varNM=class{static{i(this,"StorageRetryPolicyFactory")}retryOptions;constructor(e){this.retryOptions=e}create(e,r){returnnewRM(e,r,this.retryOptions)}};varRKe="storageBrowserPolicy";functionEse(){return{name:RKe,asyncsendRequest(t,e){returnl0||((t.method==="GET"||t.method==="HEAD")&&(t.url=Oc(t.url,ea.Parameters.FORCE_BROWSER_NO_CACHE,newDate().getTime().toString())),t.headers.delete(qe.COOKIE),t.headers.delete(qe.CONTENT_LENGTH)),e(t)}}}i(Ese,"storageBrowserPolicy");varNKe="StorageCorrectContentLengthPolicy";functionCse(){functiont(e){e.body&&(
`}),c}i(n,"getCanonicalizedHeadersString");function o(s){let a=GE(s.url)||"/",c="";c+=`/${t.accountName}${a}`;let u=HE(s.url),p={};if(u){let l=[];for(let A in u)if(Object.prototype.hasOwnProperty.call(u,A)){let b=A.toLowerCase();p[b]=u[A],l.push(b)}l.sort();for(let A of l)c+=`
`),s=e.computeHMACSHA256(o);return{sasQueryParameters:newNo(t.version,s,n,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:o}}i(Le0,"generateBlobSASQueryParameters20150405");functionQe0(t,e){if(t=bp(t),!t.identifier&&!(t.permissions&&t.expiresOn))thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));leto;t.permissions&&(t.blobName?o=Ls.parse(t.permissions.toString()).toString():o=Qs.parse(t.permissions.toString()).toString());lets=[o||"",t.startsOn?d0(t.startsOn,!1):"",t.expiresOn?d0(t.expiresOn,!1):"",dp(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Ro(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
`),a=e.computeHMACSHA256(s);return{sasQueryParameters:newNo(t.version,a,o,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:s}}i(Qe0,"generateBlobSASQueryParameters20181109");function_e0(t,e){if(t=bp(t),!t.identifier&&!(t.permissions&&t.expiresOn))thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));leto;t.permissions&&(t.blobName?o=Ls.parse(t.permissions.toString()).toString():o=Qs.parse(t.permissions.toString()).toString());lets=[o||"",t.startsOn?d0(t.startsOn,!1):"",t.expiresOn?d0(t.expiresOn,!1):"",dp(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Ro(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
`),a=e.computeHMACSHA256(s);return{sasQueryParameters:newNo(t.version,a,o,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,void0,void0,void0,t.encryptionScope),stringToSign:s}}i(_e0,"generateBlobSASQueryParameters20201206");functionPe0(t,e){if(t=bp(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));leto;t.permissions&&(t.blobName?o=Ls.parse(t.permissions.toString()).toString():o=Qs.parse(t.permissions.toString()).toString());lets=[o||"",t.startsOn?d0(t.startsOn,!1):"",t.expiresOn?d0(t.expiresOn,!1):"",dp(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?d0(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?d0(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.ipRange?Ro(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(s);return{sasQueryParameters:newNo(t.version,a,o,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey),stringToSign:s}}i(Pe0,"generateBlobSASQueryParametersUDK20181109");functionke0(t,e){if(t=bp(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));leto;t.permissions&&(t.blobName?o=Ls.parse(t.permissions.toString()).toString():o=Qs.parse(t.permissions.toString()).toString());lets=[o||"",t.startsOn?d0(t.startsOn,!1):"",t.expiresOn?d0(t.expiresOn,!1):"",dp(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?d0(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?d0(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void0,t.correlationId,t.ipRange?Ro(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(s);return{sasQueryParameters:newNo(t.version,a,o,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId),stringToSign:s}}i(ke0,"generateBlobSASQueryParametersUDK20200210");functionUe0(t,e){if(t=bp(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));leto;t.permissions&&(t.blobName?o=Ls.parse(t.permissions.toString()).toString():o=Qs.parse(t.permissions.toString()).toString());lets=[o||"",t.startsOn?d0(t.startsOn,!1):"",t.expiresOn?d0(t.expiresOn,!1):"",dp(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?d0(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?d0(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void0,t.correlationId,t.ipRange?Ro(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(s);return{sasQueryParameters:newNo(t.version,a,o,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope),stringToSign:s}}i(Ue0,"generateBlobSASQueryParametersUDK20201206");functionGe0(t,e){if(t=bp(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));leto;t.permissions&&(t.blobName?o=Ls.parse(t.permissions.toString()).toString():o=Qs.parse(t.permissions.toString()).toString());lets=[o||"",t.startsOn?d0(t.startsOn,!1):"",t.expiresOn?d0(t.expiresOn,!1):"",dp(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?d0(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?d0(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void0,t.correlationId,void0,t.delegatedUserObjectId,t.ipRange?Ro(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(s);return{sasQueryParameters:newNo(t.version,a,o,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope,t.delegatedUserObjectId),stringToSign:s}}i(Ge0,"generateBlobSASQueryParametersUDK20250705");functiondp(t,e,r){letn=[`/blob/${t}/${e}`];returnr&&n.push(`/${r}`),n.join("")}i(dp,"getCanonicalName");functionbp(t){lete=t.version?t.version:jE;if(t.snapshotTime&&e<"2018-11-09")throwRangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(t.blobName===void0&&t.snapshotTime)throwRangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(t.versionId&&e<"2019-10-10")throwRangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(t.blobName===void0&&t.versionId)throwRangeError("Must provide 'blobName' when providing 'versionId'.");if(t.permissions&&t.permissions.setImmutabilityPolicy&&e<"2020-08-04")throwRangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(t.permissions&&t.permissions.deleteVersion&&e<"2019-10-10")throwRangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(t.permissions&&t.permissions.permanentDelete&&e<"2019-10-10")throwRangeError("'version' must be >= '2019-10-10' when providing 'y' permission.");if(t.permissions&&t.permissions.tag&&e<"2019-12-12")throwRangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(e<"2020-02-10"&&t.permissions&&(t.permissions.move||t.permissions.execute))throwRangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(e<"2021-04-10"&&t.permissions&&t.permissions.filterByTags)throwRangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");if(e<"2020-02-10"&&(t.preauthorizedAgentObjectId||t.correlationId))throwRangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");if(t.encryptionScope&&e<"2020-12-06")throwRangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.");returnt.version=e,t}i(bp,"SASSignatureValuesSanityCheckAndAutofill");varUM=class{static{i(this,"BlobLeaseClient")}_leaseId;_url;_containerOrBlobOperation;_isContainer;getleaseId(){returnthis._leaseId}geturl(){returnthis._url}constructor(e,r){letn=e.storageClientContext;this._url=e.url,e.name===void0?(this._isContainer=!0,this._containerOrBlobOperation=n.container):(this._isContainer=!1,this._containerOrBlobOperation=n.blob),r||(r=jl()),this._leaseId=r}asyncacquireLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Bo||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Bo||r.conditions?.tagConditions))thrownewRangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");returnpe.withSpan("BlobLeaseClient-acquireLease",r,asyncn=>be(awaitthis._containerOrBlobOperation.acquireLease({abortSignal:r.abortSignal,duration:e,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},proposedLeaseId:this._leaseId,tracingOptions:n.tracingOptions})))}asyncchangeLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Bo||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Bo||r.conditions?.tagConditions))thrownewRangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");returnpe.withSpan("BlobLeaseClient-changeLease",r,asyncn=>{leto=be(awaitthis._containerOrBlobOperation.changeLease(this._leaseId,e,{abortSignal:r.abortSignal,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},tracingOptions:n.tracingOptions}));returnthis._leaseId=e,o})}asyncreleaseLease(e={}){if(this._isContainer&&(e.conditions?.i
Ifyouareusingself-hostedrunners,pleasemakesureyourrunnerhasaccesstoallGitHubendpoints:https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/about-self-hosted-runners#communication-between-self-hosted-runners-and-github`;super(r),this.code=e,this.name="NetworkError"}};M2.isNetworkErrorCode=t=>t?["ECONNRESET","ENOTFOUND","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH"].includes(t):!1;var mp=class extends Error{static{i(this,"UsageError")}constructor(){super(`Cache storage quota has been hit. Unable to upload any new cache entries.
Moreinfoonstoragelimits:https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#calculating-minute-and-storage-spending`),this.name="UsageError"}};mp.isUsageErrorMessage=t=>t?t.includes("insufficient usage"):!1;var ZM=class extends Error{static{i(this,"RateLimitError")}constructor(e){super(e),this.name="RateLimitError"}};var e10=function(t,e,r,n){function o(s){return s instanceof r?s:new r(function(a){a(s)})}return i(o,"adopt"),new(r||(r=Promise))(function(s,a){function c(l){try{p(n.next(l))}catch(A){a(A)}}i(c,"fulfilled");function u(l){try{p(n.throw(l))}catch(A){a(A)}}i(u,"rejected");function p(l){l.done?s(l.value):o(l.value).then(c,u)}i(p,"step"),p((n=n.apply(t,e||[])).next())})},kT=class{static{i(this,"UploadProgress")}constructor(e){this.contentLength=e,this.sentBytes=0,this.displayedComplete=!1,this.startTime=Date.now()}setSentBytes(e){this.sentBytes=e}getTransferredBytes(){return this.sentBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete)return;let e=this.sentBytes,r=(100*(e/this.contentLength)).toFixed(1),n=Date.now()-this.startTime,o=(e/(1024*1024)/(n/1e3)).toFixed(1);S(`Sent ${e} of ${this.contentLength} (${r}%), ${o} MBs/sec`),this.isDone()&&(this.displayedComplete=!0)}onProgress(){return e=>{this.setSentBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){let r=i(()=>{this.display(),this.isDone()||(this.timeoutHandle=setTimeout(r,e))},"displayCallback");this.timeoutHandle=setTimeout(r,e)}stopDisplayTimer(){this.timeoutHandle&&(clearTimeout(this.timeoutHandle),this.timeoutHandle=void 0),this.display()}};function Lae(t,e,r){return e10(this,void 0,void 0,function*(){var n;let o=new ua(t),s=o.getBlockBlobClient(),a=new kT((n=r?.archiveSizeBytes)!==null&&n!==void 0?n:0),c={blockSize:r?.uploadChunkSize,concurrency:r?.uploadConcurrency,maxSingleShotSize:128*1024*1024,onProgress:a.onProgress()};try{a.startDisplayTimer(),N(`BlobClient: ${o.name}:${o.accountName}:${o.containerName}`);let u=yield s.uploadFile(e,c);if(u._response.status>=400)throw new ty(`uploadCacheArchiveSDK: upload failed with status code ${u._response.status}`);return u}catch(u){throw r0(`uploadCacheArchiveSDK: internal error uploading cache archive: ${u.message}`),u}finally{a.stopDisplayTimer()}})}i(Lae,"uploadCacheArchiveSDK");var _ae=w(require("buffer"),1),_s=w(require("fs"),1),Pae=w(require("stream"),1),kae=w(require("util"),1);var ry=function(t,e,r,n){function o(s){return s instanceof r?s:new r(function(a){a(s)})}return i(o,"adopt"),new(r||(r=Promise))(function(s,a){function c(l){try{p(n.next(l))}catch(A){a(A)}}i(c,"fulfilled");function u(l){try{p(n.throw(l))}catch(A){a(A)}}i(u,"rejected");function p(l){l.done?s(l.value):o(l.value).then(c,u)}i(p,"step"),p((n=n.apply(t,e||[])).next())})};function ny(t){return t?t>=200&&t<300:!1}i(ny,"isSuccessStatusCode");function t10(t){return t?t>=500:!0}i(t10,"isServerErrorStatusCode");function r10(t){return t?[n1.BadGateway,n1.ServiceUnavailable,n1.GatewayTimeout].includes(t):!1}i(r10,"isRetryableStatusCode");function n10(t){return ry(this,void 0,void 0,function*(){return new Promise(e=>setTimeout(e,t))})}i(n10,"sleep");function Qae(t,e,r){return ry(this,arguments,void 0,function*(n,o,s,a=q3,c=D3,u=void 0){let p="",l=1;for(;l<=a;){let A,b,M=!1;try{A=yield o()}catch(z){u&&(A=u(z)),M=!0,p=z.message}if(A&&(b=s(A),!t10(b)))return A;if(b&&(M=r10(b),p=`Cache service responded with ${b}`),N(`${n} - Attempt ${l} of ${a} failed with error: ${p}`),!M){N(`${n} - Error is not retryable`);break}yield n10(c),l++}throw Error(`${n} failed: ${p}`)})}i(Qae,"retry");function eh(t,e){return ry(this,arguments,void 0,function*(r,n,o=q3,s=D3){return yield Qae(r,n,a=>a.statusCode,o,s,a=>{if(a instanceof ls)return{statusCode:a.statusCode,result:null,headers:{},error:a}})})}i(eh,"retryTypedResponse");function h2(t,e){return ry(this,arguments,void 0,function*(r,n,o=q3,s=D3){return yield Qae(r,n,a=>a.message.statusCode,o,s)})}i(h2,"retryHttpClientResponse");var Tn=function(t,e,r,n){function o(s){return s instanceof r?s:new r(function(a
Othercacheswithsimilarkey:`);for(let c of s?.artifactCaches||[])N(`CacheKey:${c?.cacheKey},CacheVersion:${c?.cacheVersion},CacheScope:${c?.scope},CacheCreated:${c?.creationTime}`)}}})}i(A10,"printCachesListForDiagnostics");function VT(t,e,r){return fr(this,void 0,void 0,function*(){let n=new tce.URL(t),o=Xae(r);n.hostname.endsWith(".blob.core.windows.net")?o.useAzureSdk?yield Gae(t,e,o):o.concurrentBlobDownloads?yield Uae(t,e,o):yield sy(t,e):yield sy(t,e)})}i(VT,"downloadCache");function nce(t,e,r){return fr(this,void 0,void 0,function*(){let n=XT(),o=Pl(e,r?.compressionMethod,r?.enableCrossOsArchive),s={key:t,version:o,cacheSize:r?.cacheSize};return yield eh("reserveCache",()=>fr(this,void 0,void 0,function*(){return n.postJson(rh("caches"),s)}))})}i(nce,"reserveCache");function ece(t,e){return`bytes${t}-${e}/*`}i(ece,"getContentRange");function l10(t,e,r,n,o){return fr(this,void 0,void 0,function*(){N(`Uploading chunk of size ${o-n+1} bytes at offset ${n} with content range: ${ece(n,o)}`);let s={"Content-Type":"application/octet-stream","Content-Range":ece(n,o)},a=yield h2(`uploadChunk (start: ${n}, end: ${o})`,()=>fr(this,void 0,void 0,function*(){return t.sendStream("PATCH",e,r(),s)}));if(!ny(a.message.statusCode))throw new Error(`Cache service responded with ${a.message.statusCode} during upload chunk.`)})}i(l10,"uploadChunk");function d10(t,e,r,n){return fr(this,void 0,void 0,function*(){let o=As(r),s=rh(`caches/${e.toString()}`),a=m2.openSync(r,"r"),c=UT(n),u=fS("uploadConcurrency",c.uploadConcurrency),p=fS("uploadChunkSize",c.uploadChunkSize),l=[...new Array(u).keys()];N("Awaiting all uploads");let A=0;try{yield Promise.all(l.map(()=>fr(this,void 0,void 0,function*(){for(;A<o;){let b=Math.min(o-A,p),M=A,z=A+b-1;A+=p,yield l10(t,s,()=>m2.createReadStream(r,{fd:a,start:M,end:z,autoClose:!1}).on("error",O=>{throw new Error(`Cache upload failed because file read failed with ${O.message}`)}),M,z)}})))}finally{m2.closeSync(a)}})}i(d10,"uploadFile");function b10(t,e,r){return fr(this,void 0,void 0,function*(){let n={size:r};return yield eh("commitCache",()=>fr(this,void 0,void 0,function*(){return t.postJson(rh(`caches/${e.toString()}`),n)}))})}i(b10,"commitCache");function YT(t,e,r,n){return fr(this,void 0,void 0,function*(){if(UT(n).useAzureSdk){if(!r)throw new Error("Azure Storage SDK can only be used when a signed URL is provided.");yield Lae(r,e,n)}else{let s=XT();N("Upload cache"),yield d10(s,t,e,n),N("Commiting cache");let a=As(e);S(`Cache Size: ~${Math.round(a/(1024*1024))} MB (${a} B)`);let c=yield b10(s,t,a);if(!ny(c.statusCode))throw new Error(`Cache service responded with ${c.statusCode} during commit cache.`);S("Cache saved successfully")}})}i(YT,"saveCache");var $ce=w(Gce(),1),B1=w(y1(),1),rn=w(y1(),1),Cp=w(y1(),1),yp=w(y1(),1),Bp=w(y1(),1);var kL=w(y1(),1),UL=w(y1(),1),Yce=w(y1(),1),Jce=w(y1(),1),jce=w(y1(),1);var QL=w(y1(),1),_L=w(y1(),1),Hce=w(y1(),1),Xce=w(y1(),1),Vce=w(y1(),1);var PL=class extends Vce.MessageType{static{i(this,"CacheScope$Type")}constructor(){super("github.actions.results.entities.v1.CacheScope",[{no:1,name:"scope",kind:"scalar",T:9},{no:2,name:"permission",kind:"scalar",T:3}])}create(e){let r={scope:"",permission:"0"};return globalThis.Object.defineProperty(r,Xce.MESSAGE_TYPE,{enumerable:!1,value:this}),e!==void 0&&(0,Hce.reflectionMergePartial)(this,r,e),r}internalBinaryRead(e,r,n,o){let s=o??this.create(),a=e.pos+r;for(;e.pos<a;){let[c,u]=e.tag();switch(c){case 1:s.scope=e.string();break;case 2:s.permission=e.int64().toString();break;default:let p=n.readUnknownField;if(p==="throw")throw new globalThis.Error(`Unknown field ${c} (wire type ${u}) for ${this.typeName}`);let l=e.skip(u);p!==!1&&(p===!0?_L.UnknownFieldHandler.onRead:p)(this.typeName,s,c,u,l)}}return s}internalBinaryWrite(e,r,n){e.scope!==""&&r.tag(1,QL.WireType.LengthDelimited).string(e.scope),e.permission!=="0"&&r.tag(2,QL.WireType.Varint).int64(e.permission);let o=n.writeUnknownFields;return o!==!1&&(o==!0?_L.UnknownFieldHandler.onWrite:o)(this.typeName,e,r),r}},Xy=new PL;var GL=class extends jce.Mess
`));let n=yield s8(r,"create");yield i8(n,t)})}i(c8,"createTar");var W2=function(t,e,r,n){function o(s){return s instanceof r?s:new r(function(a){a(s)})}return i(o,"adopt"),new(r||(r=Promise))(function(s,a){function c(l){try{p(n.next(l))}catch(A){a(A)}}i(c,"fulfilled");function u(l){try{p(n.throw(l))}catch(A){a(A)}}i(u,"rejected");function p(l){l.done?s(l.value):o(l.value).then(c,u)}i(p,"step"),p((n=n.apply(t,e||[])).next())})},Fo=class t extends Error{static{i(this,"ValidationError")}constructor(e){super(e),this.name="ValidationError",Object.setPrototypeOf(this,t.prototype)}},qp=class t extends Error{static{i(this,"ReserveCacheError")}constructor(e){super(e),this.name="ReserveCacheError",Object.setPrototypeOf(this,t.prototype)}},u8="cache write denied:",jy=class t extends qp{static{i(this,"CacheWriteDeniedError")}constructor(e){super(e),this.name="CacheWriteDeniedError",Object.setPrototypeOf(this,t.prototype)}},tue=I3,$y=class t extends Error{static{i(this,"CacheReadDeniedError")}constructor(e){super(e),this.name="CacheReadDeniedError",Object.setPrototypeOf(this,t.prototype)}},Ky=class t extends Error{static{i(this,"FinalizeCacheError")}constructor(e){super(e),this.name="FinalizeCacheError",Object.setPrototypeOf(this,t.prototype)}};function rue(t){if(!t||t.length===0)throw new Fo("Path Validation Error: At least one directory or file path is required")}i(rue,"checkPaths");function p8(t){if(t.length>512)throw new Fo(`Key Validation Error: ${t} cannot be larger than 512 characters.`);if(!/^[^,]*$/.test(t))throw new Fo(`Key Validation Error: ${t} cannot contain commas.`)}i(p8,"checkKey");function A8(){return th()==="v2"?!!process.env.ACTIONS_RESULTS_URL:!!process.env.ACTIONS_CACHE_URL}i(A8,"isFeatureAvailable");function nue(t,e,r,n){return W2(this,arguments,void 0,function*(o,s,a,c,u=!1){let p=th();N(`Cache service version: ${p}`),rue(o);let l=HT();if(!Yae(l)){S(`Cache restore skipped: the effective cache-mode '${l}' does not permit reads.`),N(`Skipped restore for paths [${o.join(", ")}] with primary key '${s}'.`);return}return p==="v2"?yield Rr0(o,s,a,c,u):yield Ir0(o,s,a,c,u)})}i(nue,"restoreCache");function Ir0(t,e,r,n){return W2(this,arguments,void 0,function*(o,s,a,c,u=!1){var p;a=a||[];let l=[s,...a];if(N("Resolved Keys:"),N(JSON.stringify(l)),l.length>10)throw new Fo("Key Validation Error: Keys are limited to a maximum of 10.");for(let M of l)p8(M);let A=yield eM(),b="";try{let M;try{M=yield rce(l,o,{compressionMethod:A,enableCrossOsArchive:u})}catch(O){let y=(p=O?.message)!==null&&p!==void 0?p:"";throw y.includes(tue)?new $y(y):O}if(!M?.archiveLocation)return;if(c?.lookupOnly)return S("Lookup only - skipping download"),M.cacheKey;b=mh.join(yield Kf(),dc(A)),N(`Archive Path: ${b}`),yield VT(M.archiveLocation,b,c),Hi()&&(yield hh(b,A));let z=As(b);return S(`Cache Size: ~${Math.round(z/(1024*1024))} MB (${z} B)`),yield a8(b,A),S("Cache restored successfully"),M.cacheKey}catch(M){let z=M;if(z.name===Fo.name)throw M;z instanceof ls&&typeof z.statusCode=="number"&&z.statusCode>=500?Nl(`Failed to restore: ${M.message}`):r0(`Failed to restore: ${M.message}`)}finally{try{yield Zf(b)}catch(M){N(`Failed to delete archive: ${M}`)}}})}i(Ir0,"restoreCacheV1");function Rr0(t,e,r,n){return W2(this,arguments,void 0,function*(o,s,a,c,u=!1){var p;c=Object.assign(Object.assign({},c),{useAzureSdk:!0}),a=a||[];let l=[s,...a];if(N("Resolved Keys:"),N(JSON.stringify(l)),l.length>10)throw new Fo("Key Validation Error: Keys are limited to a maximum of 10.");for(let b of l)p8(b);let A="";try{let b=o8(),M=yield eM(),z={key:s,restoreKeys:a,version:Pl(o,M,u)},O;try{O=yield b.GetCacheEntryDownloadURL(z)}catch(B){let q=(p=B?.message)!==null&&p!==void 0?p:"";throw q.includes(tue)?new $y(q):B}if(!O.ok){N(`Cache not found for version ${z.version} of keys: ${l.join(", ")}`);return}if(z.key!==O.matchedKey?S(`Cache hit for restore-key: ${O.matchedKey}`):S(`Cache hit for: ${O.matchedKey}`),c?.lookupOnly)return S("Lookup only - skipping download"),O.matchedKey;A=mh.join(yield Kf(),dc(M)),N(`Archive path: ${A}`),N(`Starting download of archive to: ${A}`)
`)}i(Bn0,"_buildMessageForResponseErrors");var qn0=class extends Error{static{i(this,"GraphqlResponseError")}constructor(t,e,r){super(Bn0(r)),this.request=t,this.headers=e,this.response=r,this.errors=r.errors,this.data=r.data,Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}name="GraphqlResponseError";errors;data},Dn0=["method","baseUrl","url","headers","request","query","mediaType","operationName"],In0=["query","method","url"],Gue=/\/api\/v3\/?$/;function Rn0(t,e,r){if(r){if(typeof e=="string"&&"query"in r)return Promise.reject(new Error('[@octokit/graphql] "query" cannot be used as variable name'));for(let a in r)if(In0.includes(a))return Promise.reject(new Error(`[@octokit/graphql] "${a}" cannot be used as variable name`))}let n=typeof e=="string"?Object.assign({query:e},r):e,o=Object.keys(n).reduce((a,c)=>Dn0.includes(c)?(a[c]=n[c],a):(a.variables||(a.variables={}),a.variables[c]=n[c],a),{}),s=n.baseUrl||t.endpoint.DEFAULTS.baseUrl;return Gue.test(s)&&(o.url=s.replace(Gue,"/api/graphql")),t(o).then(a=>{if(a.data.errors){let c={};for(let u of Object.keys(a.headers))c[u]=a.headers[u];throw new qn0(o,c,a.data)}return a.data.data})}i(Rn0,"graphql");function B8(t,e){let r=t.defaults(e);return Object.assign(i((o,s)=>Rn0(r,o,s),"newApi"),{defaults:B8.bind(null,r),endpoint:r.endpoint})}i(B8,"withDefaults");var Ro1=B8(Ch,{headers:{"user-agent":`octokit-graphql.js/${yn0} ${wc()}`},method:"POST",url:"/graphql"});function Hue(t){return B8(t,{method:"POST",url:"/graphql"})}i(Hue,"withCustomRequest");var q8="(?:[a-zA-Z0-9_-]+)",Xue="\\.",Vue=new RegExp(`^${q8}${Xue}${q8}${Xue}${q8}$`),Nn0=Vue.test.bind(Vue);async function wn0(t){let e=Nn0(t),r=t.startsWith("v1.")||t.startsWith("ghs_"),n=t.startsWith("ghu_");return{type:"token",token:t,tokenType:e?"app":r?"installation":n?"user-to-server":"oauth"}}i(wn0,"auth");function Sn0(t){return t.split(/\./).length===3?`bearer ${t}`:`token ${t}`}i(Sn0,"withAuthorizationPrefix");async function Fn0(t,e,r,n){let o=e.endpoint.merge(r,n);return o.headers.authorization=Sn0(t),e(o)}i(Fn0,"hook");var Yue=i(function(e){if(!e)throw new Error("[@octokit/auth-token] No token passed to createTokenAuth");if(typeof e!="string")throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string");return e=e.replace(/^(token|bearer) +/i,""),Object.assign(wn0.bind(null,e),{hook:Fn0.bind(null,e)})},"createTokenAuth2");var D8="7.0.6";var Jue=i(()=>{},"noop"),Wn0=console.warn.bind(console),xn0=console.error.bind(console);function vn0(t={}){return typeof t.debug!="function"&&(t.debug=Jue),typeof t.info!="function"&&(t.info=Jue),typeof t.warn!="function"&&(t.warn=Wn0),typeof t.error!="function"&&(t.error=xn0),t}i(vn0,"createLogger");var jue=`octokit-core.js/${D8} ${wc()}`,p4=class{static{i(this,"Octokit")}static VERSION=D8;static defaults(e){return class extends this{static{i(this,"OctokitWithDefaults")}constructor(...n){let o=n[0]||{};if(typeof e=="function"){super(e(o));return}super(Object.assign({},e,o,o.userAgent&&e.userAgent?{userAgent:`${o.userAgent} ${e.userAgent}`}:null))}}}static plugins=[];static plugin(...e){let r=this.plugins;return class extends this{static{i(this,"NewOctokit")}static plugins=r.concat(e.filter(o=>!r.includes(o)))}}constructor(e={}){let r=new Cue.Collection,n={baseUrl:Ch.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:r.bind(null,"request")}),mediaType:{previews:[],format:""}};if(n.headers["user-agent"]=e.userAgent?`${e.userAgent} ${jue}`:jue,e.baseUrl&&(n.baseUrl=e.baseUrl),e.previews&&(n.mediaType.previews=e.previews),e.timeZone&&(n.headers["time-zone"]=e.timeZone),this.request=Ch.defaults(n),this.graphql=Hue(this.request).defaults(n),this.log=vn0(e.log),this.hook=r,e.authStrategy){let{authStrategy:s,...a}=e,c=s(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:a},e.auth));r.wrap("request",c.hook),this.auth=c}else if(!e.auth)this.auth=async()=>({type:"unauthenticated"});else{let s=Yue(e.auth);r.wrap("request",s.hook),this.auth=s}let o=this.constructor;for(let s=0;s<o.plugins.length;++s)
`,a).length:A,p?(c===null?0:c.length)+u.length:0,p?u.length+A:0);return b<M},"__needMoreData"),parse:i(function(n,o,s,a){let{bom:c,comment_no_infix:u,delimiter_auto:p,encoding:l,from_line:A,ltrim:b,max_record_size:M,raw:z,relax_quotes:O,rtrim:y,skip_empty_lines:E,to:B,to_line:q}=this.options,{comment:D,escape:x,quote:W,record_delimiter:v}=this.options,{bomSkipped:ie,delimiterDiscovered:De,delimiterBufPrevious:Ne,rawBuffer:Ee,escapeIsQuote:Ae}=this.state;if(!De&&p){let ke;if(Ne===void 0?ke=n:Ne!==void 0&&n===void 0?ke=Ne:ke=Buffer.concat([Ne,n]),n=void 0,o||ke.length>p.size)this.options.delimiter=[Buffer.from(Mde(ke,this.options.delimiter_auto))],this.state.previousBuf=ke,this.state.delimiterBufPrevious=void 0,this.state.delimiterDiscovered=!0;else{this.state.delimiterBufPrevious=ke;return}}let{previousBuf:Fe}=this.state,ae;if(Fe===void 0)if(n===void 0){a();return}else ae=n;else Fe!==void 0&&n===void 0?ae=Fe:ae=Buffer.concat([Fe,n]);if(ie===!1)if(c===!1)this.state.bomSkipped=!0;else if(ae.length<3){if(o===!1){this.state.previousBuf=ae;return}}else{for(let ke in Z2)if(Z2[ke].compare(ae,0,Z2[ke].length)===0){let C0=Z2[ke].length;this.state.bufBytesStart+=C0,ae=ae.slice(C0);let ht=K2({...this.original_options,encoding:ke});for(let p0 in ht)this.options[p0]=ht[p0];({comment:D,escape:x,quote:W}=this.options);break}this.state.bomSkipped=!0}let We=ae.length,k;for(k=0;k<We&&!this.__needMoreData(k,We,o);k++){if(this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1),q!==-1&&this.info.lines>q){this.state.stop=!0,a();return}this.state.quoting===!1&&v.length===0&&this.__autoDiscoverRecordDelimiter(ae,k)&&(v=this.options.record_delimiter);let ke=ae[k];if(z===!0&&Ee.append(ke),(ke===Cp0||ke===yp0)&&this.state.wasRowDelimiter===!1&&(this.state.wasRowDelimiter=!0),this.state.escaping===!0)this.state.escaping=!1;else{if(x!==null&&this.state.quoting===!0&&this.__isEscape(ae,k,ke)&&k+x.length<We)if(Ae){if(this.__isQuote(ae,k+x.length)){this.state.escaping=!0,k+=x.length-1;continue}}else{this.state.escaping=!0,k+=x.length-1;continue}if(this.state.commenting===!1&&this.__isQuote(ae,k))if(this.state.quoting===!0){let p0=ae[k+W.length],Y1=y&&this.__isCharTrimable(ae,k+W.length),q0=D!==null&&this.__compareBytes(D,ae,k+W.length,p0),ne=this.__isDelimiter(ae,k+W.length,p0),Ho=v.length===0?this.__autoDiscoverRecordDelimiter(ae,k+W.length):this.__isRecordDelimiter(p0,ae,k+W.length);if(x!==null&&this.__isEscape(ae,k,ke)&&this.__isQuote(ae,k+x.length))k+=x.length-1;else if(!p0||ne||Ho||q0||Y1){this.state.quoting=!1,this.state.wasQuoting=!0,k+=W.length-1;continue}else if(O===!1){let ln=this.__error(new Ve("CSV_INVALID_CLOSING_QUOTE",["Invalid Closing Quote:",`got "${String.fromCharCode(p0)}"`,`at line ${this.info.lines}`,"instead of delimiter, record delimiter, trimable character","(if activated) or comment"],this.options,this.__infoField()));if(ln!==void 0)return ln}else this.state.quoting=!1,this.state.wasQuoting=!0,this.state.field.prepend(W),k+=W.length-1}else if(this.state.field.length!==0){if(O===!1){let p0=this.__infoField(),Y1=Object.keys(Z2).map(ne=>Z2[ne].equals(this.state.field.toString())?ne:!1).filter(Boolean)[0],q0=this.__error(new Ve("INVALID_OPENING_QUOTE",["Invalid Opening Quote:",`a quote is found on field ${JSON.stringify(p0.column)} at line ${p0.lines}, value is ${JSON.stringify(this.state.field.toString(l))}`,Y1?`(${Y1} bom)`:void 0],this.options,p0,{field:this.state.field}));if(q0!==void 0)return q0}}else{this.state.quoting=!0,k+=W.length-1;continue}if(this.state.quoting===!1){let p0=this.__isRecordDelimiter(ke,ae,k);if(p0!==0){if(this.state.commenting&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0)this.info.comment_lines++;else{if(this.state.enabled===!1&&this.info.lines+(this.state.wasRowDelimiter===!0?1:0)>=A){this.state.enabled=!0,this.__resetField(),this.__resetRecord(),k+=p0-1;continue}if(E===!0&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0){this.info.empty_lines++,k+=p0-1;continue}this.info.bytes=this.state.bufBytesSt
${n}`)},"onRetry")})}static isPullTransientError(e){return/Client\.Timeout exceeded|TLS handshake timeout|i\/o timeout|context deadline exceeded|request canceled|connection reset by peer|connection refused|connection timed out|temporary failure|unexpected EOF|\bEOF\b|server misbehaving/i.test(e)||/\b(500|502|503|504)\b/.test(e)||/\b(service unavailable|bad gateway|gateway timeout|internal server error)\b/i.test(e)}};var m0=class t{static{i(this,"Buildx")}_version;_versionOnce;_standalone;static containerNamePrefix="buildx_buildkit_";constructor(e){this._standalone=e?.standalone,this._version="",this._versionOnce=!1}static get configDir(){return process.env.BUILDX_CONFIG||gr.default.join(qt.configDir,"buildx")}static get refsDir(){return gr.default.join(t.configDir,"refs")}static get refsGroupDir(){return gr.default.join(t.refsDir,"__group__")}static get certsDir(){return gr.default.join(t.configDir,"certs")}async isStandalone(){let e=this._standalone??!await qt.isAvailable();return N(`Buildx.isStandalone: ${e}`),e}async getCommand(e){let r=await this.isStandalone();return{command:r?"buildx":"docker",args:r?e:["buildx",...e]}}async isAvailable(){let e=await this.getCommand([]),r=await Oe.getExecOutput(e.command,e.args,{ignoreReturnCode:!0,silent:!0}).then(n=>n.stderr.length>0&&n.exitCode!=0?(N(`Buildx.isAvailable cmd err: ${n.stderr.trim()}`),!1):n.exitCode==0).catch(n=>(N(`Buildx.isAvailable error: ${n}`),!1));return N(`Buildx.isAvailable: ${r}`),r}async version(){if(this._versionOnce)return this._version;this._versionOnce=!0;let e=await this.getCommand(["version"]);return this._version=await Oe.getExecOutput(e.command,e.args,{ignoreReturnCode:!0,silent:!0}).then(r=>{if(r.stderr.length>0&&r.exitCode!=0)throw new Error(r.stderr.trim());return t.parseVersion(r.stdout.trim())}),this._version}async printVersion(){let e=await this.getCommand(["version"]);await Oe.exec(e.command,e.args,{failOnStdErr:!1})}static parseVersion(e){let r=/\sv?([0-9a-f]{7}|[0-9.]+)/.exec(e);if(!r)throw new Error("Cannot parse buildx version");return r[1]}static getErrorMessage(e){let r=(0,Cde.stripVTControlCharacters)(e).split(/[\r\n]/),n="";for(let o=r.length-1;o>=0;o--){let s=r[o].trim();if(s.startsWith("ERROR:"))return s.slice(6).trim()||"unknown error";n||=s}return n||"unknown error"}async versionSatisfies(e,r){let n=r??await this.version();if(!n)return N("Buildx.versionSatisfies false: undefined version"),!1;let o=yde.satisfies(n,e)||/^[0-9a-f]{7}$/.exec(n)!==null;return N(`Buildx.versionSatisfies ${n} statisfies ${e}: ${o}`),o}static resolveCertsDriverOpts(e,r,n){let o;try{o=new URL(r)}catch{return[]}if(o.protocol!="tcp:")return[];let s=[];if(Object.keys(n).length==0)return s;let a=o.hostname;if(o.port.length>0&&(a+=`-${o.port}`),n.cacert!==void 0){let c=gr.default.join(t.certsDir,`cacert_${a}.pem`);Yn.default.writeFileSync(c,n.cacert),s.push(`cacert=${c}`)}if(n.cert!==void 0){let c=gr.default.join(t.certsDir,`cert_${a}.pem`);Yn.default.writeFileSync(c,n.cert),s.push(`cert=${c}`)}if(n.key!==void 0){let c=gr.default.join(t.certsDir,`key_${a}.pem`);Yn.default.writeFileSync(c,n.key),s.push(`key=${c}`)}return e!="remote"?[]:s}static localState(e,r){let[n,o,s]=e.split("/");if(!n||!o||!s)throw new Error(`Invalid build reference: ${e}`);let a=gr.default.join(r||t.refsDir,n,o,s);if(!Yn.default.existsSync(a))throw new Error(`Local state not found in ${a}`);return t.fixLocalState(JSON.parse(Yn.default.readFileSync(a,"utf8")))}static fixLocalState(e){let r=i(function(a){let c=a.match(/(.*)(https?:\/{1,2}\S+|ssh:\/{1,2}\S+|git:\/{1,2}\S+)/i);if(c&&c.length==3){let u=c[1],p=c[2];return p.startsWith("https:/")&&!p.startsWith("https://")&&(p=p.replace("https:/","https://")),p.startsWith("http:/")&&!p.startsWith("http://")&&(p=p.replace("http:/","http://")),p.startsWith("ssh:/")&&!p.startsWith("ssh://")&&(p=p.replace("ssh:/","ssh://")),p.startsWith("git:/")&&!p.startsWith("git://")&&(p=p.replace("git:/","git://")),[p,u,!0]}return[a,"",!1]},"fnTrimToValidContext"),[n,o,s]=r(e.LocalPath);return s&&(e.LocalPath=n,e.DockerfilePath.indexOf(o)===0&&(e.DockerfilePa
More info: ${u.url}`);let M=u.range&&u.range.length>0?u.range[0]?.start.line:void 0,z=!1;for(let O of a)if(O.remote||O.path.endsWith(p)&&O.content===l){c.push({title:A,message:b,file:O.path,startLine:M}),z=!0;break}z||N(`Buildx.convertWarningsToGitHubAnnotations: skipping warning without matching Dockerfile ${p}: ${A}`)}return c}};var Lp=w(require("fs"),1),c_=w(require("path"),1);var fB=class t{static{i(this,"Build")}buildx;iidFilename;metadataFilename;constructor(e){this.buildx=e?.buildx||new m0,this.iidFilename=`build-iidfile-${c0.generateRandomString()}.txt`,this.metadataFilename=`build-metadata-${c0.generateRandomString()}.json`}async gitContext(e){let r=new Set(["ref","checksum","subdir"]),n=e?.attrs||{},o=Object.entries(n).filter(([M])=>!r.has(M)),s=c0.parseBoolOrDefault(n["fetch-by-commit"]),a=e?.ref||n.ref||Vt.ref;a.startsWith("refs/")?a.startsWith("refs/pull/")&&c0.parseBoolOrDefault(process.env.DOCKER_DEFAULT_GIT_CONTEXT_PR_HEAD_REF)&&(a=a.replace(/\/merge$/g,"/head")):a=`refs/heads/${a}`;let c=`${a0.serverURL}/${Vt.repo.owner}/${Vt.repo.repo}.git`,u=e?.checksum||n.checksum,p=e?.subdir||n.subdir,l=e?.format;if(!l){if(l="fragment",o.length>0)l="query";else if(c0.parseBoolOrDefault(process.env.BUILDX_SEND_GIT_QUERY_AS_INPUT))try{await this.buildx.versionSatisfies(">=0.29.0")&&(l="query")}catch{}}let A=Vt.sha||a;a.startsWith("refs/pull/")&&a.endsWith("/head")&&(A=typeof Vt.payload.pull_request?.head?.sha=="string"?Vt.payload.pull_request.head.sha:a);let b=u||A;if(l==="query"){let M=[`ref=${s||u?a:b}`],z=s?b:u;z&&M.push(`checksum=${z}`),p&&p!=="."&&M.push(`subdir=${p}`);for(let[O,y]of o)M.push(`${O}=${y}`);return`${c}?${M.join("&")}`}return`${c}#${b}${p&&p!=="."?`:${p}`:""}`}getImageIDFilePath(){return c_.default.join(s0.tmpDir(),this.iidFilename)}resolveImageID(){let e=this.getImageIDFilePath();if(Lp.default.existsSync(e))return Lp.default.readFileSync(e,{encoding:"utf-8"}).trim()}getMetadataFilePath(){return c_.default.join(s0.tmpDir(),this.metadataFilename)}resolveMetadata(){let e=this.getMetadataFilePath();if(!Lp.default.existsSync(e))return;let r=Lp.default.readFileSync(e,{encoding:"utf-8"}).trim();if(r!=="null")return JSON.parse(r)}resolveRef(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.ref"in e)return e["buildx.build.ref"]}resolveProvenance(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.provenance"in e)return e["buildx.build.provenance"]}resolveWarnings(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.warnings"in e)return e["buildx.build.warnings"]}resolveDigest(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"containerimage.digest"in e)return e["containerimage.digest"]}static resolveSecretString(e){let[r,n]=t.resolveSecret(e,{redact:!0});return`id=${r},src=${n}`}static resolveSecretFile(e){let[r,n]=t.resolveSecret(e,{asFile:!0});return`id=${r},src=${n}`}static resolveSecretEnv(e){let[r,n]=t.parseSecretKvp(e);return`id=${r},env=${n}`}static resolveSecret(e,r){let[n,o]=t.parseSecretKvp(e,r?.redact);if(r?.asFile){if(!Lp.default.existsSync(o))throw new Error(`secret file ${o} not found`);return[n,o]}let s=s0.tmpName({tmpdir:s0.tmpDir()});return Lp.default.writeFileSync(s,o),[n,s]}static getProvenanceInput(e){let r=Ur(e);if(!r)return r;try{return QZ(e)?`builder-id=${a0.workflowRunURL(!0)}`:"false"}catch{return t.resolveProvenanceAttrs(r)}}static resolveProvenanceAttrs(e){if(!e)return`builder-id=${a0.workflowRunURL(!0)}`;let r=W1(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(let n of r)if(n.toString().split(/(?<=^[^=]+?)=/).map(s=>s.trim())[0]=="builder-id")return e;return`${e},builder-id=${a0.workflowRunURL(!0)}`}static resolveCacheToAttrs(e,r){if(!e)return e;let n="registry",o="",s="",a=W1(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(let c of a){let u=c.toString().split(/(?<=^[^=]+?)=/).map(p=>p.trim());u[0]==="type"?n=u[1]:u[0]==="repository"?o=u[1]:u[0]==="ghtoken"&&(s=u[1])}return n==="gha"&&(o||(e=`${e},repository=${a0.repository}`),!s&&r&&(e=`${e},ghtoken=${r}`)),e}static hasLocalExporter(e){return t.hasExporterType("local",e)}static hasTarExporter(e){return t.hasExpo
`),{delimiter:",",trim:!0,columns:!1,relaxColumnCount:!0});for(let o of n){if(o.length==1&&!o[0].startsWith("type="))return e=="local";for(let[s,a]of o.map(c=>c.split("=").map(u=>u.trim())))if(s=="type"&&a==e)return!0}return!1}static hasAttestationType(e,r){let n=W1(r,{delimiter:",",trim:!0,columns:!1,relaxColumnCount:!0});for(let o of n)for(let[s,a]of o.map(c=>c.split("=").map(u=>u.trim())))if(s=="type"&&a==e)return!0;return!1}static resolveAttestationAttrs(e){let r=W1(e,{delimiter:",",trim:!0,columns:!1,relaxColumnCount:!0}),n=[];for(let o of r)for(let s of o)try{let a=c0.parseBool(s);n.push(`disabled=${!a}`)}catch{n.push(s)}return n.join(",")}static hasGitAuthTokenSecret(e,r){for(let n of e){if(r&&n.startsWith(`GIT_AUTH_TOKEN.${r}=`))return!0;if(n.startsWith("GIT_AUTH_TOKEN="))return!0}return!1}static parseSecretKvp(e,r){let n=e.indexOf("="),o=e.substring(0,n),s=e.substring(n+1);if(o.length==0||s.length==0)throw new Error(`${e} is not a valid secret`);return r&&ss(s),[o,s]}};var u_=w(require("fs"),1),Bde=w(require("path"),1);var MB=class t{static{i(this,"Bake")}buildx;metadataFilename;constructor(e){this.buildx=e?.buildx||new m0,this.metadataFilename=`bake-metadata-${c0.generateRandomString()}.json`}getMetadataFilePath(){return Bde.default.join(s0.tmpDir(),this.metadataFilename)}resolveMetadata(){let e=this.getMetadataFilePath();if(!u_.default.existsSync(e))return;let r=u_.default.readFileSync(e,{encoding:"utf-8"}).trim();if(r!=="null")return JSON.parse(r)}resolveRefs(e){if(!e&&(e=this.resolveMetadata(),!e))return;let r=new Array;for(let n in e)"buildx.build.ref"in e[n]&&r.push(e[n]["buildx.build.ref"]);return r.length>0?r:void 0}resolveWarnings(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.warnings"in e)return e["buildx.build.warnings"]}async getDefinition(e,r){r=r||{ignoreReturnCode:!0},r.ignoreReturnCode=!0,r.env=Object.assign({},process.env,r.env||{},e.githubToken?{BUILDX_BAKE_GIT_AUTH_TOKEN:e.githubToken}:{});let n=["bake"],o,s=[],a=[...e.files||[],e.source];if(a){for(let u of a.map(p=>p?p.trim():""))if(u.length!=0){if(!c0.isValidRef(u)){s.push(u);continue}if(o)throw new Error("Only one remote bake definition can be defined");o=u}}o&&n.push(o);for(let u of s)n.push("--file",u);if(e.overrides)for(let u of e.overrides)n.push("--set",u);if(e.vars)for(let u of e.vars)n.push("--var",u);if(e.allow)for(let u of e.allow)n.push("--allow",u);e.call&&n.push("--call",e.call),e.load&&n.push("--load"),e.noCache&&n.push("--no-cache"),e.provenance&&n.push("--provenance",e.provenance),e.push&&n.push("--push"),e.sbom&&n.push("--sbom",e.sbom);let c=await this.buildx.getCommand([...n,"--print",...e.targets||[]]);return await Oe.getExecOutput(c.command,c.args,r).then(u=>{if(u.stderr.length>0&&u.exitCode!=0)throw new Error(`cannot parse bake definitions: ${m0.getErrorMessage(u.stderr)}`);return t.parseDefinition(u.stdout.trim())})}static parseDefinition(e){let r=JSON.parse(e);for(let n in r.target){let o=r.target[n];o.attest&&Array.isArray(o.attest)&&(o.attest=o.attest.map(s=>t.parseAttestEntry(s))),o["cache-from"]&&Array.isArray(o["cache-from"])&&(o["cache-from"]=o["cache-from"].map(s=>t.parseCacheEntry(s))),o["cache-to"]&&Array.isArray(o["cache-to"])&&(o["cache-to"]=o["cache-to"].map(s=>t.parseCacheEntry(s))),o.output&&Array.isArray(o.output)&&(o.output=o.output.map(s=>t.parseExportEntry(s))),o.secret&&Array.isArray(o.secret)&&(o.secret=o.secret.map(s=>t.parseSecretEntry(s))),o.ssh&&Array.isArray(o.ssh)&&(o.ssh=o.ssh.map(s=>t.parseSSHEntry(s)))}return r}static parseAttestEntry(e){if(typeof e!="string")return e;let r={type:""},n=W1(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(let o of n){let[s,a]=o.toString().split(/(?<=^[^=]+?)=/).map(c=>c.trim());switch(s){case"type":r.type=a;break;case"disabled":r.disabled=c0.parseBool(a);break;default:r[s]=a}}return r}static parseCacheEntry(e){if(typeof e!="string")return e;let r={type:""},n=W1(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];if(n.length===1&&!n[0].includes("="))return r.type="registry",r.ref=n[0],r;for(let o of n){let[s,a]=o.toString().split(/(?<=^[^=]+?)=/).map(c
`)[0])}static async isHeadDetached(e){return await t.exec(["branch","--show-current"],e).then(r=>r.length==0)}static async getDetachedRef(e){let r=await t.exec(["show","-s","--pretty=%D"],e);N(`detached HEAD ref: ${r}`);let n=r.replace(/^grafted, /,"").trim();if(n==="HEAD")return await t.inferRefFromHead(e);let o=n.match(/^HEAD, (.*)$/);if(!o||!o[1])throw new Error(`Cannot find detached HEAD ref in "${r}"`);let s=o[1].trim();if(s.startsWith("tag: "))return await t.findDetachedTagRef(s,r,e);if(s.match(/^pull\/\d+\/(head|merge)$/))return`refs/${s}`;let c=s.match(/^[^/]+\/[^/]+, (.+)$/);if(c)return`refs/heads/${c[1].trim()}`;let u=s.match(/^[^/]+\/(.+)$/);if(u)return`refs/heads/${u[1].trim()}`;throw new Error(`Unsupported detached HEAD ref in "${r}"`)}static async exec(e=[],r){return await Oe.getExecOutput("git",e,{cwd:r,ignoreReturnCode:!0,silent:!0}).then(n=>{if(n.stderr.length>0&&n.exitCode!=0)throw new Error(n.stderr);return n.stdout.trim()})}static async inferRefFromHead(e){let r=await t.findContainingRef("refs/heads/",e);if(r)return r;let n=await t.findContainingRef("refs/remotes/",e);if(n){let a=n.match(/^refs\/remotes\/[^/]+\/(.+)$/);return a?`refs/heads/${a[1]}`:n}let o=await t.exec(["tag","--contains","HEAD"],e),[s]=o.split(`
`).map(a=>a.trim()).filter(a=>a.length>0).sort((a,c)=>c.length-a.length);for(let a of s){let c=`tag: ${a.slice(10)}`;if(e===c||e.startsWith(`${c}, `))return a}if(s.length===1)return s[0];throw new Error(`Cannot find detached tag ref in "${r}"`)}static async findContainingRef(e,r){let n=await t.exec(["for-each-ref","--format=%(refname)","--contains","HEAD","--sort=-committerdate",e],r),[o]=n.split(`
${p}`),u.errors.some(l=>l.code==="MANIFEST_UNKNOWN"))S(`Cosign verify command failed with MANIFEST_UNKNOWN, retrying attempt ${a+1}/${o}...
${p}`),await new Promise(l=>setTimeout(l,Math.pow(2,a)*100));else throw s}else throw new Error(`Cosign verify command failed with: ${qr.getErrorMessage(c.stderr)}`)}throw s}async signProvenanceBlobs(e){if(!await this.cosign.isAvailable())throw new Error("Cosign is required to sign provenance blobs");let r={};try{if(!process.env.ACTIONS_ID_TOKEN_REQUEST_URL)throw new Error('missing "id-token" permission. Please add "permissions: id-token: write" to your workflow.');let n={noTransparencyLog:e.noTransparencyLog,rekorV2:e.rekorV2},o=await this.cosignSigningConfigArgs(n),s=t.getProvenanceBlobs(e);for(let a of Object.keys(s))await ct(`Signing ${a}`,async()=>{let c=s[a],u=ci.default.join(ci.default.dirname(a),`${e.name??"provenance"}.sigstore.json`),p=t.getProvenanceSubjects(c);if(p.length===0){r0(`No subjects found in provenance ${a}, skip signing.`);return}let l=ci.default.join(ci.default.dirname(a),p[0].name),A=["attest-blob","--yes","--oidc-provider","github-actions",...await this.bundleFormatArgs(),"--statement",a,"--type",_Me,"--bundle",u,...o];S(`[command]${this.cosign.binPath} ${[...A,l].join(" ")}`);let b=await Oe.getExecOutput(this.cosign.binPath,["--verbose",...A,l],{ignoreReturnCode:!0,silent:!0,env:Object.assign({},process.env,{COSIGN_EXPERIMENTAL:"1"})}),M=qr.parseCommandOutput(b.stderr.trim());if(b.exitCode!=0)if(M.errors&&M.errors.length>0){let O=M.errors.map(y=>`- [${y.code}] ${y.message} : ${y.detail}`).join(`
`,bakeTarget:Ur("bake-target")||"docker-metadata-action",githubToken:Ur("github-token")}}i(YMe,"getInputs");async function JMe(t,e){if(t.startsWith("git:"))return await VMe(t.slice(4));switch(t){case"workflow":return await wM0(e);case"git":return await VMe();default:throw new Error(`Invalidcontextsource:${t}`)}}i(JMe,"getContext");async function wM0(t){let e=a0.context;return/pull_request_target/.test(e.eventName)&&(e.ref=`refs/pull/${e.payload.number}/merge`),/true/i.test(process.env.DOCKER_METADATA_PR_HEAD_SHA||"")&&(/pull_request/.test(e.eventName)||/pull_request_target/.test(e.eventName))&&e.payload?.pull_request?.head?.sha!=null&&(e.sha=e.payload.pull_request.head.sha),{commitDate:await SM0(e.sha,t),...e}}i(wM0,"getContextFromWorkflow");async function VMe(t){let e=await ma.context(t);return{commitDate:await ma.commitDate(e.sha,t),...e}}i(VMe,"getContextFromGit");async function SM0(t,e){let r=a0.context.payload;if(r.commits){let n=r.commits.find(o=>o.id===t)?.timestamp;if(n)return new Date(n)}if(r.head_commit&&r.head_commit.id===t)return new Date(r.head_commit.timestamp);try{let n=await e.github.octokit.rest.repos.getCommit({owner:a0.context.repo.owner,repo:a0.context.repo.repo,ref:t});if(n.data.commit.committer?.date)return new Date(n.data.commit.committer.date);throw new Error("Committer date not found")}catch(n){return N(`FailedtogetcommitdatefromGitHubAPI:${n.message}`),new Date}}i(SM0,"getCommitDateFromWorkflow");var Ta=w(zme(),1),A5e=w(require("fs"),1),l5e=w(require("path"),1),Oz=w(Bme(),1),An=w(i5e(),1),cb=w(Gn(),1);function c5e(t){let e=[];if(t.length==1){let r=!1,n=W1(t[0],{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(let o of n){let s=o.toString().split("=").map(a=>a.trim());if(s.length==1)e.push({name:s[0],enable:!0});else{r=!0;break}}if(!r)return a5e(e)}e=[];for(let r of t){let n={name:"",enable:!0},o=W1(r,{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(let s of o){let a=s.toString().split("=").map(c=>c.trim());if(a.length==1)n.name=a[0];else{let c=a[0].toLowerCase(),u=a[1];switch(c){case"name":{n.name=u;break}case"enable":{if(!["true","false"].includes(u))throw new Error(`Invalidenableattributevalue:${r}`);n.enable=/true/i.test(u);break}default:throw new Error(`Unknownimageattribute:${r}`)}}}if(n.name.length==0)throw new Error(`Imagenameattributeempty:${r}`);e.push(n)}return a5e(e)}i(c5e,"Transform");function a5e(t){Pu("Processing images input");for(let e of t)S(`name=${e.name},enable=${e.enable}`);return ku(),t}i(a5e,"output");var HU=(u=>(u.Schedule="schedule",u.Semver="semver",u.Pep440="pep440",u.Match="match",u.Edge="edge",u.Ref="ref",u.Raw="raw",u.Sha="sha",u))(HU||{}),v5=(n=>(n.Branch="branch",n.Tag="tag",n.PR="pr",n))(v5||{}),T5=(r=>(r.Short="short",r.Long="long",r))(T5||{}),GU=class{static{i(this,"Tag")}type;attrs;constructor(){this.attrs={}}toString(){let e=[`type=${this.type}`];for(let r in this.attrs)e.push(`${r}=${this.attrs[r]}`);return e.join(",")}},tN0={schedule:"1000",semver:"900",pep440:"900",match:"800",edge:"700",ref:"600",raw:"200",sha:"100"};function u5e(t){let e=[];t.length==0&&(t=["type=schedule","type=ref,event=branch","type=ref,event=tag","type=ref,event=pr"]);for(let n of t)e.push(rN0(n));let r=e.sort((n,o)=>Number(n.attrs.priority)<Number(o.attrs.priority)?1:Number(n.attrs.priority)>Number(o.attrs.priority)?-1:0);Pu("Processing tags input");for(let n of r)S(n.toString());return ku(),r}i(u5e,"Transform");function rN0(t){let e=W1(t,{relaxColumnCount:!0,skipEmptyLines:!0})[0],r=new GU;for(let n of e){let o=n.toString().split(/(?<=^[^=]+?)=/).map(s=>s.trim());if(o.length==1)r.attrs.value=o[0];else{let s=o[0].toLowerCase(),a=o[1];switch(s){case"type":{if(!Object.values(HU).includes(a))throw new Error(`Unknowntagtypeattribute:${a}`);r.type=a;break}default:{r.attrs[s]=a;break}}}}switch(r.type==null&&(r.type="raw"),r.type){case"schedule":{Object.prototype.hasOwnProperty.call(r.attrs,"pattern")||(r.attrs.pattern="nightly");break}case"semver":case"pep440":{if(!Object.prototype.hasOwnProperty.call(r.attrs,"pattern"))throw new Error(`Missingpatternattributefo