/*! OpenPGP.js v5.2.1 - 2022-03-15 - this is LGPL licensed code, see LICENSE/our website https://openpgpjs.org/ for more information. */constze="undefined"!=typeofwindow?window:"undefined"!=typeofglobal?global:"undefined"!=typeofself?self:{};Object.defineProperty(Ae,"__esModule",{value:!0});varqe=Ce(4300),Ve=Ce(2781),tt=Ce(6113),rt=Ce(9796),it=Ce(2037),nt=Ce(3837),ot=Ce(4293);functionc(ke){returnke&&"object"==typeofke&&"default"inke?ke:{default:ke}}varct=c(qe),ht=c(Ve),ft=c(tt),yt=c(rt),mt=c(it),kt=c(nt),St=c(ot);constEt=Symbol("doneWritingPromise"),Pt=Symbol("doneWritingResolve"),Bt=Symbol("doneWritingReject"),Dt=Symbol("readingIndex");classvextendsArray{constructor(){super(),this[Et]=newPromise(((ke,Ae)=>{this[Pt]=ke,this[Bt]=Ae})),this[Et].catch((()=>{}))}}function_(ke){returnke&&ke.getReader&&Array.isArray(ke)}functionk(ke){if(!_(ke)){constAe=ke.getWriter(),Ce=Ae.releaseLock;returnAe.releaseLock=()=>{Ae.closed.catch((function(){})),Ce.call(Ae)},Ae}this.stream=ke}v.prototype.getReader=function(){returnvoid0===this[Dt]&&(this[Dt]=0),{read:async()=>(awaitthis[Et],this[Dt]===this.length?{value:void0,done:!0}:{value:this[this[Dt]++],done:!1})}},v.prototype.readToEnd=asyncfunction(ke){awaitthis[Et];constAe=ke(this.slice(this[Dt]));returnthis.length=0,Ae},v.prototype.clone=function(){constke=newv;returnke[Et]=this[Et].then((()=>{ke.push(...this)})),ke},k.prototype.write=asyncfunction(ke){this.stream.push(ke)},k.prototype.close=asyncfunction(){this.stream[Pt]()},k.prototype.abort=asyncfunction(ke){returnthis.stream[Bt](ke),ke},k.prototype.releaseLock=function(){};constRt="object"==typeofze.process&&"object"==typeofze.process.versions,Tt=Rt&&ht.default.Readable;functionE(ke){return_(ke)?"array":ze.ReadableStream&&ze.ReadableStream.prototype.isPrototypeOf(ke)?"web":Lt&&Lt.prototype.isPrototypeOf(ke)?"ponyfill":Tt&&Tt.prototype.isPrototypeOf(ke)?"node":!(!ke||!ke.getReader)&&"web-like"}functionP(ke){returnUint8Array.prototype.isPrototypeOf(ke)}functionx(ke){if(1===ke.length)returnke[0];letAe=0;for(letCe=0;Ce<ke.length;Ce++){if(!P(ke[Ce]))throwError("concatUint8Array: Data must be in the form of a Uint8Array");Ae+=ke[Ce].length}constCe=newUint8Array(Ae);letze=0;returnke.forEach((function(ke){Ce.set(ke,ze),ze+=ke.length})),Ce}constKt=Rt&&ct.default.Buffer,It=Rt&&ht.default.Readable;letUt,Ot;if(It){Ut=function(ke){letAe=!1;returnnewLt({start(Ce){ke.pause(),ke.on("data",(ze=>{Ae||(Kt.isBuffer(ze)&&(ze=newUint8Array(ze.buffer,ze.byteOffset,ze.byteLength)),Ce.enqueue(ze),ke.pause())})),ke.on("end",(()=>{Ae||Ce.close()})),ke.on("error",(ke=>Ce.error(ke)))},pull(){ke.resume()},cancel(Ce){Ae=!0,ke.destroy(Ce)}})};classeextendsIt{constructor(ke,Ae){super(Ae),this._reader=H(ke)}async_read(ke){try{for(;;){const{done:ke,value:Ae}=awaitthis._reader.read();if(ke){this.push(null);break}if(!this.push(Ae)||this._cancelling){this._reading=!1;break}}}catch(ke){this.emit("error",ke)}}_destroy(ke){this._reader.cancel(ke)}}Ot=function(ke,Ae){returnnewe(ke,Ae)}}constNt=newWeakSet,zt=Symbol("externalBuffer");functionU(ke){if(this.stream=ke,ke[zt]&&(this[zt]=ke[zt].slice()),_(ke)){constAe=ke.getReader();returnthis._read=Ae.read.bind(Ae),this._releaseLock=()=>{},void(this._cancel=()=>{})}letAe=E(ke);if("node"===Ae&&(ke=Ut(ke)),Ae){constAe=ke.getReader();returnthis._read=Ae.read.bind(Ae),this._releaseLock=()=>{Ae.closed.catch((function(){})),Ae.releaseLock()},void(this._cancel=Ae.cancel.bind(Ae))}letCe=!1;this._read=async()=>Ce||Nt.has(ke)?{value:void0,done:!0}:(Ce=!0,{value:ke,done:!1}),this._releaseLock=()=>{if(Ce)try{Nt.add(ke)}catch(ke){}}}U.prototype.read=asyncfunction(){if(this[zt]&&this[zt].length){return{done:!1,value:this[zt].shift()}}returnthis._read()},U.prototype.releaseLock=function(){this[zt]&&(this.stream[zt]=this[zt]),this._releaseLock()},U.prototype.cancel=function(ke){returnthis._cancel(ke)},U.prototype.readLine=asyncfunction(){letke,Ae=[];for(;!ke;){let{done:Ce,value:ze}=awaitthis.read();if(ze+="",Ce)returnAe.length?W(Ae):void0;constqe=ze.indexOf("\n")+1