/*! OpenPGP.js v5.9.0 - 2023-05-15 - this is LGPL licensed code, see LICENSE/our website https://openpgpjs.org/ for more information. */constqe="undefined"!=typeofwindow?window:"undefined"!=typeofglobal?global:"undefined"!=typeofself?self:{};Object.defineProperty(Se,"__esModule",{value:!0});varFe=Ke(4300),$e=Ke(2781),rt=Ke(6113),it=Ke(9796),nt=Ke(2037),st=Ke(3837),ut=Ke(4293);functionc(Ae){returnAe&&"object"==typeofAe&&"default"inAe?Ae:{default:Ae}}varht=c(Fe),ft=c($e),yt=c(rt),mt=c(it),vt=c(nt),_t=c(st),Rt=c(ut);constKt=Symbol("doneWritingPromise"),It=Symbol("doneWritingResolve"),Ut=Symbol("doneWritingReject"),Ot=Symbol("readingIndex");classvextendsArray{constructor(){super(),this[Kt]=newPromise(((Ae,Se)=>{this[It]=Ae,this[Ut]=Se})),this[Kt].catch((()=>{}))}}function_(Ae){returnAe&&Ae.getReader&&Array.isArray(Ae)}functionk(Ae){if(!_(Ae)){constSe=Ae.getWriter(),Ke=Se.releaseLock;returnSe.releaseLock=()=>{Se.closed.catch((function(){})),Ke.call(Se)},Se}this.stream=Ae}v.prototype.getReader=function(){returnvoid0===this[Ot]&&(this[Ot]=0),{read:async()=>(awaitthis[Kt],this[Ot]===this.length?{value:void0,done:!0}:{value:this[this[Ot]++],done:!1})}},v.prototype.readToEnd=asyncfunction(Ae){awaitthis[Kt];constSe=Ae(this.slice(this[Ot]));returnthis.length=0,Se},v.prototype.clone=function(){constAe=newv;returnAe[Kt]=this[Kt].then((()=>{Ae.push(...this)})),Ae},k.prototype.write=asyncfunction(Ae){this.stream.push(Ae)},k.prototype.close=asyncfunction(){this.stream[It]()},k.prototype.abort=asyncfunction(Ae){returnthis.stream[Ut](Ae),Ae},k.prototype.releaseLock=function(){};constNt="object"==typeofqe.process&&"object"==typeofqe.process.versions,jt=Nt&&ft.default.Readable;functionE(Ae){return_(Ae)?"array":qe.ReadableStream&&qe.ReadableStream.prototype.isPrototypeOf(Ae)?"web":Zt&&Zt.prototype.isPrototypeOf(Ae)?"ponyfill":jt&&jt.prototype.isPrototypeOf(Ae)?"node":!(!Ae||!Ae.getReader)&&"web-like"}functionP(Ae){returnUint8Array.prototype.isPrototypeOf(Ae)}functionx(Ae){if(1===Ae.length)returnAe[0];letSe=0;for(letKe=0;Ke<Ae.length;Ke++){if(!P(Ae[Ke]))throwError("concatUint8Array: Data must be in the form of a Uint8Array");Se+=Ae[Ke].length}constKe=newUint8Array(Se);letqe=0;returnAe.forEach((function(Ae){Ke.set(Ae,qe),qe+=Ae.length})),Ke}constFt=Nt&&ht.default.Buffer,Lt=Nt&&ft.default.Readable;letHt,Wt;if(Lt){Ht=function(Ae){letSe=!1;returnnewZt({start(Ke){Ae.pause(),Ae.on("data",(qe=>{Se||(Ft.isBuffer(qe)&&(qe=newUint8Array(qe.buffer,qe.byteOffset,qe.byteLength)),Ke.enqueue(qe),Ae.pause())})),Ae.on("end",(()=>{Se||Ke.close()})),Ae.on("error",(Ae=>Ke.error(Ae)))},pull(){Ae.resume()},cancel(Ke){Se=!0,Ae.destroy(Ke)}})};classeextendsLt{constructor(Ae,Se){super(Se),this._reader=H(Ae)}async_read(Ae){try{for(;;){const{done:Ae,value:Se}=awaitthis._reader.read();if(Ae){this.push(null);break}if(!this.push(Se)||this._cancelling){this._reading=!1;break}}}catch(Ae){this.emit("error",Ae)}}_destroy(Ae){this._reader.cancel(Ae)}}Wt=function(Ae,Se){returnnewe(Ae,Se)}}constGt=newWeakSet,$t=Symbol("externalBuffer");functionI(Ae){if(this.stream=Ae,Ae[$t]&&(this[$t]=Ae[$t].slice()),_(Ae)){constSe=Ae.getReader();returnthis._read=Se.read.bind(Se),this._releaseLock=()=>{},void(this._cancel=()=>{})}letSe=E(Ae);if("node"===Se&&(Ae=Ht(Ae)),Se){constSe=Ae.getReader();returnthis._read=Se.read.bind(Se),this._releaseLock=()=>{Se.closed.catch((function(){})),Se.releaseLock()},void(this._cancel=Se.cancel.bind(Se))}letKe=!1;this._read=async()=>Ke||Gt.has(Ae)?{value:void0,done:!0}:(Ke=!0,{value:Ae,done:!1}),this._releaseLock=()=>{if(Ke)try{Gt.add(Ae)}catch(Ae){}}}I.prototype.read=asyncfunction(){if(this[$t]&&this[$t].length){return{done:!1,value:this[$t].shift()}}returnthis._read()},I.prototype.releaseLock=function(){this[$t]&&(this.stream[$t]=this[$t]),this._releaseLock()},I.prototype.cancel=function(Ae){returnthis._cancel(Ae)},I.prototype.readLine=asyncfunction(){letAe,Se=[];for(;!Ae;){let{done:Ke,value:qe}=awaitthis.read();if(qe+="",Ke)returnSe.length?W(Se):void0;constFe=qe.indexOf("\n")+1