Agriculture-front-end/dist/assets/jsencrypt.ed0a786e.js

23 lines
57 KiB
JavaScript
Raw Normal View History

2023-07-24 18:07:54 +08:00
var Ot={exports:{}};/*! For license information please see jsencrypt.min.js.LICENSE.txt */(function(tt,Q){(function(bt,nt){tt.exports=nt()})(window,()=>(()=>{var bt={155:x=>{var A,T,b=x.exports={};function $(){throw new Error("setTimeout has not been defined")}function et(){throw new Error("clearTimeout has not been defined")}function st(B){if(A===setTimeout)return setTimeout(B,0);if((A===$||!A)&&setTimeout)return A=setTimeout,setTimeout(B,0);try{return A(B,0)}catch{try{return A.call(null,B,0)}catch{return A.call(this,B,0)}}}(function(){try{A=typeof setTimeout=="function"?setTimeout:$}catch{A=$}try{T=typeof clearTimeout=="function"?clearTimeout:et}catch{T=et}})();var P,O=[],j=!1,Y=-1;function K(){j&&P&&(j=!1,P.length?O=P.concat(O):Y=-1,O.length&&J())}function J(){if(!j){var B=st(K);j=!0;for(var L=O.length;L;){for(P=O,O=[];++Y<L;)P&&P[Y].run();Y=-1,L=O.length}P=null,j=!1,function(R){if(T===clearTimeout)return clearTimeout(R);if((T===et||!T)&&clearTimeout)return T=clearTimeout,clearTimeout(R);try{T(R)}catch{try{return T.call(null,R)}catch{return T.call(this,R)}}}(B)}}function F(B,L){this.fun=B,this.array=L}function V(){}b.nextTick=function(B){var L=new Array(arguments.length-1);if(arguments.length>1)for(var R=1;R<arguments.length;R++)L[R-1]=arguments[R];O.push(new F(B,L)),O.length!==1||j||st(J)},F.prototype.run=function(){this.fun.apply(null,this.array)},b.title="browser",b.browser=!0,b.env={},b.argv=[],b.version="",b.versions={},b.on=V,b.addListener=V,b.once=V,b.off=V,b.removeListener=V,b.removeAllListeners=V,b.emit=V,b.prependListener=V,b.prependOnceListener=V,b.listeners=function(B){return[]},b.binding=function(B){throw new Error("process.binding is not supported")},b.cwd=function(){return"/"},b.chdir=function(B){throw new Error("process.chdir is not supported")},b.umask=function(){return 0}}},nt={};function z(x){var A=nt[x];if(A!==void 0)return A.exports;var T=nt[x]={exports:{}};return bt[x](T,T.exports,z),T.exports}z.d=(x,A)=>{for(var T in A)z.o(A,T)&&!z.o(x,T)&&Object.defineProperty(x,T,{enumerable:!0,get:A[T]})},z.o=(x,A)=>Object.prototype.hasOwnProperty.call(x,A);var Tt={};return(()=>{function x(r){return"0123456789abcdefghijklmnopqrstuvwxyz".charAt(r)}function A(r,t){return r&t}function T(r,t){return r|t}function b(r,t){return r^t}function $(r,t){return r&~t}function et(r){if(r==0)return-1;var t=0;return(65535&r)==0&&(r>>=16,t+=16),(255&r)==0&&(r>>=8,t+=8),(15&r)==0&&(r>>=4,t+=4),(3&r)==0&&(r>>=2,t+=2),(1&r)==0&&++t,t}function st(r){for(var t=0;r!=0;)r&=r-1,++t;return t}z.d(Tt,{default:()=>Kt});var P,O="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";function j(r){var t,e,i="";for(t=0;t+3<=r.length;t+=3)e=parseInt(r.substring(t,t+3),16),i+=O.charAt(e>>6)+O.charAt(63&e);for(t+1==r.length?(e=parseInt(r.substring(t,t+1),16),i+=O.charAt(e<<2)):t+2==r.length&&(e=parseInt(r.substring(t,t+2),16),i+=O.charAt(e>>2)+O.charAt((3&e)<<4));(3&i.length)>0;)i+="=";return i}function Y(r){var t,e="",i=0,n=0;for(t=0;t<r.length&&r.charAt(t)!="=";++t){var s=O.indexOf(r.charAt(t));s<0||(i==0?(e+=x(s>>2),n=3&s,i=1):i==1?(e+=x(n<<2|s>>4),n=15&s,i=2):i==2?(e+=x(n),e+=x(s>>2),n=3&s,i=3):(e+=x(n<<2|s>>4),e+=x(15&s),i=0))}return i==1&&(e+=x(n<<2)),e}var K,J={decode:function(r){var t;if(K===void 0){var e=`= \f
\r \xA0\u2028\u2029`;for(K=Object.create(null),t=0;t<64;++t)K["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(t)]=t;for(K["-"]=62,K._=63,t=0;t<e.length;++t)K[e.charAt(t)]=-1}var i=[],n=0,s=0;for(t=0;t<r.length;++t){var o=r.charAt(t);if(o=="=")break;if((o=K[o])!=-1){if(o===void 0)throw new Error("Illegal character at offset "+t);n|=o,++s>=4?(i[i.length]=n>>16,i[i.length]=n>>8&255,i[i.length]=255&n,n=0,s=0):n<<=6}}switch(s){case 1:throw new Error("Base64 encoding incomplete: at least 2 bits missing");case 2:i[i.length]=n>>10;break;case 3:i[i.length]=n>>16,i[i.length]=n>>8&255}return i},re:/-----BEGIN [^-]+-----([A-Za-z0-9+\/=\s]+)-----END [^-]+-----|begin-base64[^\n]+\n([A-Za-z0-9+\/=\s]+)====/,unarmor:function(r){var t=J.re.exec(r);if(t)if(t[1])r=t[1];else{if(!t[2])throw new Error("RegExp out of sync");r=t[2]}return J.decode(r)}},F=1e13,V=function(){function r(t){this.buf=[+t||0]}return r.prototype.mulAdd=function(t,e){var i,n,s=this.buf,o=s.length;for(i=0;i<o;++i)(n=s[i]*t+e)<F?e=0:n-=(e=0|n/F)*F,s[i]=n;e>0&&(s[i]=e)},r.prototype.sub=function(t){var e,i,n=this.buf,s=n.length;for(e=0;e<s;++e)(i=n[e]-t)<0?(i+=F,t=1):t=0,n[e]=i;for(;n[n.length-1]===0;)n.pop()},r.prototype.toString=function(t){if((t||10)!=10)throw new Error("only base 10 is supported");for(var e=this.buf,i=e[e.length-1].toString(),n=e.length-2;n>=0;--n)i+=(F+e[n]).toString().substring(1);return i},r.prototype.valueOf=function(){for(var t=this.buf,e=0,i=t.length-1;i>=0;--i)e=e*F+t[i];return e},r.prototype.simplify=function(){var t=this.buf;return t.length==1?t[0]:this},r}(),B=/^(\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/,L=/^(\d\d\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/;function R(r,t){return r.length>t&&(r=r.substring(0,t)+"\u2026"),r}var U,ot=function(){function r(t,e){this.hexDigits="0123456789ABCDEF",t instanceof r?(this.enc=t.enc,this.pos=t.pos):(this.enc=t,this.pos=e)}return r.prototype.get=function(t){if(t===void 0&&(t=this.pos++),t>=this.enc.length)throw new Error("Requesting byte offset ".concat(t," on a stream of length ").concat(this.enc.length));return typeof this.enc=="string"?this.enc.charCodeAt(t):this.enc[t]},r.prototype.hexByte=function(t){return this.hexDigits.charAt(t>>4&15)+this.hexDigits.charAt(15&t)},r.prototype.hexDump=function(t,e,i){for(var n="",s=t;s<e;++s)if(n+=this.hexByte(this.get(s)),i!==!0)switch(15&s){case 7:n+=" ";break;case 15:n+=`
`;break;default:n+=" "}return n},r.prototype.isASCII=function(t,e){for(var i=t;i<e;++i){var n=this.get(i);if(n<32||n>176)return!1}return!0},r.prototype.parseStringISO=function(t,e){for(var i="",n=t;n<e;++n)i+=String.fromCharCode(this.get(n));return i},r.prototype.parseStringUTF=function(t,e){for(var i="",n=t;n<e;){var s=this.get(n++);i+=s<128?String.fromCharCode(s):s>191&&s<224?String.fromCharCode((31&s)<<6|63&this.get(n++)):String.fromCharCode((15&s)<<12|(63&this.get(n++))<<6|63&this.get(n++))}return i},r.prototype.parseStringBMP=function(t,e){for(var i,n,s="",o=t;o<e;)i=this.get(o++),n=this.get(o++),s+=String.fromCharCode(i<<8|n);return s},r.prototype.parseTime=function(t,e,i){var n=this.parseStringISO(t,e),s=(i?B:L).exec(n);return s?(i&&(s[1]=+s[1],s[1]+=+s[1]<70?2e3:1900),n=s[1]+"-"+s[2]+"-"+s[3]+" "+s[4],s[5]&&(n+=":"+s[5],s[6]&&(n+=":"+s[6],s[7]&&(n+="."+s[7]))),s[8]&&(n+=" UTC",s[8]!="Z"&&(n+=s[8],s[9]&&(n+=":"+s[9]))),n):"Unrecognized time: "+n},r.prototype.parseInteger=function(t,e){for(var i,n=this.get(t),s=n>127,o=s?255:0,h="";n==o&&++t<e;)n=this.get(t);if((i=e-t)==0)return s?-1:0;if(i>4){for(h=n,i<<=3;(128&(+h^o))==0;)h=+h<<1,--i;h="("+i+` bit)
`}s&&(n-=256);for(var a=new V(n),c=t+1;c<e;++c)a.mulAdd(256,this.get(c));return h+a.toString()},r.prototype.parseBitString=function(t,e,i){for(var n=this.get(t),s="("+((e-t-1<<3)-n)+` bit)
`,o="",h=t+1;h<e;++h){for(var a=this.get(h),c=h==e-1?n:0,f=7;f>=c;--f)o+=a>>f&1?"1":"0";if(o.length>i)return s+R(o,i)}return s+o},r.prototype.parseOctetString=function(t,e,i){if(this.isASCII(t,e))return R(this.parseStringISO(t,e),i);var n=e-t,s="("+n+` byte)
`;n>(i/=2)&&(e=t+i);for(var o=t;o<e;++o)s+=this.hexByte(this.get(o));return n>i&&(s+="\u2026"),s},r.prototype.parseOID=function(t,e,i){for(var n="",s=new V,o=0,h=t;h<e;++h){var a=this.get(h);if(s.mulAdd(128,127&a),o+=7,!(128&a)){if(n==="")if((s=s.simplify())instanceof V)s.sub(80),n="2."+s.toString();else{var c=s<80?s<40?0:1:2;n=c+"."+(s-40*c)}else n+="."+s.toString();if(n.length>i)return R(n,i);s=new V,o=0}}return o>0&&(n+=".incomplete"),n},r}(),It=function(){function r(t,e,i,n,s){if(!(n instanceof St))throw new Error("Invalid tag value.");this.stream=t,this.header=e,this.length=i,this.tag=n,this.sub=s}return r.prototype.typeName=function(){switch(this.tag.tagClass){case 0:switch(this.tag.tagNumber){case 0:return"EOC";case 1:return"BOOLEAN";case 2:return"INTEGER";case 3:return"BIT_STRING";case 4:return"OCTET_STRING";case 5:return"NULL";case 6:return"OBJECT_IDENTIFIER";case 7:return"ObjectDescriptor";case 8:return"EXTERNAL";case 9:return"REAL";case 10:return"ENUMERATED";case 11:return"EMBEDDED_PDV";case 12:return"UTF8String";case 16:return"SEQUENCE";case 17:return"SET";case 18:return"NumericString";case 19:return"PrintableString";case 20:return"TeletexString";case 21:return"VideotexString";case 22:return"IA5String";case 23:return"UTCTime";case 24:return"GeneralizedTime";case 25:return"GraphicString";case 26:return"VisibleString";case 27:return"GeneralString";case 28:return"UniversalString";case 30:return"BMPString"}return"Universal_"+this.tag.tagNumber.toString();case 1:return"Application_"+this.tag.tagNumber.toString();case 2:return"["+this.tag.tagNumber.toString()+"]";case 3:return"Private_"+this.tag.tagNumber.toString()}},r.prototype.content=function(t){if(this.tag===void 0)return null;t===void 0&&(t=1/0);var e=this.posContent(),i=Math.abs(this.length);if(!this.tag.isUniversal())return this.sub!==null?"("+this.sub.length+" elem)":this.stream.parseOctetString(e,e+i,t);switch(this.tag.tagNumber){case 1:return this.stream.get(e)===0?"false":"true";case 2:return this.stream.parseInteger(e,e+i);case 3:return this.sub?"("+this.sub.length+" elem)":this.stream.parseBitString(e,e+i,t);case 4:return this.sub?"("+this.sub.length+" elem)":this.stream.parseOctetString(e,e+i,t);case 6:return this.stream.parseOID(e,e+i,t);case 16:case 17:return this.sub!==null?"("+this.sub.length+" elem)":"(no elem)";case 12:return R(this.stream.parseStringUTF(e,e+i),t);case 18:case 19:case 20:case 21:case 22:case 26:return R(this.stream.parseStringISO(e,e+i),t);case 30:return R(this.stream.parseStringBMP(e,e+i),t);case 23:case 24:return this.stream.parseTime(e,e+i,this.tag.tagNumber==23)}return null},r.prototype.toString=function(){return this.typeName()+"@"+this.stream.pos+"[header:"+this.header+",length:"+this.length+",sub:"+(this.sub===null?"null":this.sub.length)+"]"},r.prototype.toPrettyString=function(t){t===void 0&&(t="");var e=t+this.typeName()+" @"+this.stream.pos;if(this.length>=0&&(e+="+"),e+=this.length,this.tag.tagConstructed?e+=" (constructed)":!this.tag.isUniversal()||this.tag.tagNumber!=3&&this.tag.tagNumber!=4||this.sub===null||(e+=" (encapsulates)"),e+=`
`,this.sub!==null){t+=" ";for(var i=0,n=this.sub.length;i<n;++i)e+=this.sub[i].toPrettyString(t)}return e},r.prototype.posStart=function(){return this.stream.pos},r.prototype.posContent=function(){return this.stream.pos+this.header},r.prototype.posEnd=function(){return this.stream.pos+this.header+Math.abs(this.length)},r.prototype.toHexString=function(){return this.stream.hexDump(this.posStart(),this.posEnd(),!0)},r.decodeLength=function(t){var e=t.get(),i=127&e;if(i==e)return i;if(i>6)throw new Error("Length over 48 bits not supported at position "+(t.pos-1));if(i===0)return null;e=0;for(var n=0;n<i;++n)e=256*e+t.get();return e},r.prototype.getHexStringValue=function(){var t=this.toHexString(),e=2*this.header,i=2*this.length;return t.substr(e,i)},r.decode=function(t){var e;e=t instanceof ot?t:new ot(t,0);var i=new ot(e),n=new St(e),s=r.decodeLength(e),o=e.pos,h=o-i.pos,a=null,c=function(){var v=[];if(s!==null){for(var g=o+s;e.pos<g;)v[v.length]=r.decode(e);if(e.pos!=g)throw new Error("Content size is not correct for container starting at offset "+o)}else try{for(;;){var S=r.decode(e);if(S.tag.isEOC())break;v[v.length]=S}s=o-e.pos}catch(y){throw new Error("Exception while decoding undefined length content: "+y)}return v};if(n.tagConstructed)a=c();else if(n.isUniversal()&&(n.tagNumber==3||n.tagNumber==4))try{if(n.tagNumber==3&&e.get()!=0)throw new Error("BIT STRINGs with unused bits cannot encapsulate.");a=c();for(var f=0;f<a.length;++f)if(a[f].tag.isEOC())throw new Error("EOC is not supposed to be actual content.")}catch{a=null}if(a===null){if(s===null)throw new Error("We can't skip over an invalid tag with undefined length at offset "+o);e.pos=o+Math.abs(s)}return new r(i,h,s,n,a)},r}(),St=function(){function r(t){var e=t.get();if(this.tagClass=e>>6,this.tagConstructed=(32&e)!=0,this.tagNumber=31&e,this.tagNumber==31){var i=new V;do e=t.get(),i.mulAdd(128,127&e);while(128&e);this.tagNumber=i.simplify()}}return r.prototype.isUniversal=function(){return this.tagClass===0},r.prototype.isEOC=function(){return this.tagClass===0&&this.tagNumber===0},r}(),I=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],Nt=(1<<26)/I[I.length-1],p=function(){function r(t,e,i){t!=null&&(typeof t=="number"?this.fromNumber(t,e,i):e==null&&typeof t!="string"?this.fromString(t,256):this.fromString(t,e))}return r.prototype.toString=function(t){if(this.s<0)return"-"+this.negate().toString(t);var e;if(t==16)e=4;else if(t==8)e=3;else if(t==2)e=1;else if(t==32)e=5;else{if(t!=4)return this.toRadix(t);e=2}var i,n=(1<<e)-1,s=!1,o="",h=this.t,a=this.DB-h*this.DB%e;if(h-- >0)for(a<this.DB&&(i=this[h]>>a)>0&&(s=!0,o=x(i));h>=0;)a<e?(i=(this[h]&(1<<a)-1)<<e-a,i|=this[--h]>>(a+=this.DB-e)):(i=this[h]>>(a-=e)&n,a<=0&&(a+=this.DB,--h)),i>0&&(s=!0),s&&(o+=x(i));return s?o:"0"},r.prototype.negate=function(){var t=d();return r.ZERO.subTo(this,t),t},r.prototype.abs=function(){return this.s<0?this.negate():this},r.prototype.compareTo=function(t){var e=this.s-t.s;if(e!=0)return e;var i=this.t;if((e=i-t.t)!=0)return this.s<0?-e:e;for(;--i>=0;)if((e=this[i]-t[i])!=0)return e;return 0},r.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+at(this[this.t-1]^this.s&this.DM)},r.prototype.mod=function(t){var e=d();return this.abs().divRemTo(t,null,e),this.s<0&&e.compareTo(r.ZERO)>0&&t.subTo(e,e),e},r.prototype.modPowInt=function(t,e){var i;return i=t<256||e.isEven()?new Et(e):new wt(e),this.exp(t,i)},r.prototype.clone=function(){var t=d();return this.copyTo(t),t},r.protot
\r \xA0\u2028\u2029`;for(P={},m=0;m<16;++m)P[E.charAt(m)]=m;for(E=E.toLowerCase(),m=10;m<16;++m)P[E.charAt(m)]=m;for(m=0;m<k.length;++m)P[k.charAt(m)]=-1}var N=[],M=0,X=0;for(m=0;m<y.length;++m){var l=y.charAt(m);if(l=="=")break;if((l=P[l])!=-1){if(l===void 0)throw new Error("Illegal character at offset "+m);M|=l,++X>=2?(N[N.length]=M,M=0,X=0):M<<=4}}if(X)throw new Error("Hex encoding incomplete: 4 bits missing");return N}(e):J.unarmor(e),o=It.decode(s);if(o.sub.length===3&&(o=o.sub[2].sub[0]),o.sub.length===9){i=o.sub[1].getHexStringValue(),this.n=w(i,16),n=o.sub[2].getHexStringValue(),this.e=parseInt(n,16);var h=o.sub[3].getHexStringValue();this.d=w(h,16);var a=o.sub[4].getHexStringValue();this.p=w(a,16);var c=o.sub[5].getHexStringValue();this.q=w(c,16);var f=o.sub[6].getHexStringValue();this.dmp1=w(f,16);var v=o.sub[7].getHexStringValue();this.dmq1=w(v,16);var g=o.sub[8].getHexStringValue();this.coeff=w(g,16)}else{if(o.sub.length!==2)return!1;if(o.sub[0].sub){var S=o.sub[1].sub[0];i=S.sub[0].getHexStringValue(),this.n=w(i,16),n=S.sub[1].getHexStringValue(),this.e=parseInt(n,16)}else i=o.sub[0].getHexStringValue(),this.n=w(i,16),n=o.sub[1].getHexStringValue(),this.e=parseInt(n,16)}return!0}catch{return!1}},t.prototype.getPrivateBaseKey=function(){var e={array:[new u.asn1.DERInteger({int:0}),new u.asn1.DERInteger({bigint:this.n}),new u.asn1.DERInteger({int:this.e}),new u.asn1.DERInteger({bigint:this.d}),new u.asn1.DERInteger({bigint:this.p}),new u.asn1.DERInteger({bigint:this.q}),new u.asn1.DERInteger({bigint:this.dmp1}),new u.asn1.DERInteger({bigint:this.dmq1}),new u.asn1.DERInteger({bigint:this.coeff})]};return new u.asn1.DERSequence(e).getEncodedHex()},t.prototype.getPrivateBaseKeyB64=function(){return j(this.getPrivateBaseKey())},t.prototype.getPublicBaseKey=function(){var e=new u.asn1.DERSequence({array:[new u.asn1.DERObjectIdentifier({oid:"1.2.840.113549.1.1.1"}),new u.asn1.DERNull]}),i=new u.asn1.DERSequence({array:[new u.asn1.DERInteger({bigint:this.n}),new u.asn1.DERInteger({int:this.e})]}),n=new u.asn1.DERBitString({hex:"00"+i.getEncodedHex()});return new u.asn1.DERSequence({array:[e,n]}).getEncodedHex()},t.prototype.getPublicBaseKeyB64=function(){return j(this.getPublicBaseKey())},t.wordwrap=function(e,i){if(!e)return e;var n="(.{1,"+(i=i||64)+`})( +|$
?)|(.{1,`+i+"})";return e.match(RegExp(n,"g")).join(`
`)},t.prototype.getPrivateKey=function(){var e=`-----BEGIN RSA PRIVATE KEY-----
`;return(e+=t.wordwrap(this.getPrivateBaseKeyB64())+`
`)+"-----END RSA PRIVATE KEY-----"},t.prototype.getPublicKey=function(){var e=`-----BEGIN PUBLIC KEY-----
`;return(e+=t.wordwrap(this.getPublicBaseKeyB64())+`
`)+"-----END PUBLIC KEY-----"},t.hasPublicKeyProperty=function(e){return(e=e||{}).hasOwnProperty("n")&&e.hasOwnProperty("e")},t.hasPrivateKeyProperty=function(e){return(e=e||{}).hasOwnProperty("n")&&e.hasOwnProperty("e")&&e.hasOwnProperty("d")&&e.hasOwnProperty("p")&&e.hasOwnProperty("q")&&e.hasOwnProperty("dmp1")&&e.hasOwnProperty("dmq1")&&e.hasOwnProperty("coeff")},t.prototype.parsePropertiesFrom=function(e){this.n=e.n,this.e=e.e,e.hasOwnProperty("d")&&(this.d=e.d,this.p=e.p,this.q=e.q,this.dmp1=e.dmp1,this.dmq1=e.dmq1,this.coeff=e.coeff)},t}(Lt),Rt=z(155),Ct=Rt!==void 0?(At=Rt.env)===null||At===void 0?void 0:"3.3.1":void 0;const Kt=function(){function r(t){t===void 0&&(t={}),t=t||{},this.default_key_size=t.default_key_size?parseInt(t.default_key_size,10):1024,this.default_public_exponent=t.default_public_exponent||"010001",this.log=t.log||!1,this.key=null}return r.prototype.setKey=function(t){this.log&&this.key&&console.warn("A key was already set, overriding existing."),this.key=new Bt(t)},r.prototype.setPrivateKey=function(t){this.setKey(t)},r.prototype.setPublicKey=function(t){this.setKey(t)},r.prototype.decrypt=function(t){try{return this.getKey().decrypt(Y(t))}catch{return!1}},r.prototype.encrypt=function(t){try{return j(this.getKey().encrypt(t))}catch{return!1}},r.prototype.sign=function(t,e,i){try{return j(this.getKey().sign(t,e,i))}catch{return!1}},r.prototype.verify=function(t,e,i){try{return this.getKey().verify(t,Y(e),i)}catch{return!1}},r.prototype.getKey=function(t){if(!this.key){if(this.key=new Bt,t&&{}.toString.call(t)==="[object Function]")return void this.key.generateAsync(this.default_key_size,this.default_public_exponent,t);this.key.generate(this.default_key_size,this.default_public_exponent)}return this.key},r.prototype.getPrivateKey=function(){return this.getKey().getPrivateKey()},r.prototype.getPrivateKeyB64=function(){return this.getKey().getPrivateBaseKeyB64()},r.prototype.getPublicKey=function(){return this.getKey().getPublicKey()},r.prototype.getPublicKeyB64=function(){return this.getKey().getPublicBaseKeyB64()},r.version=Ct,r}()})(),Tt.default})())})(Ot);const Vt=Ot.exports,Ut=`MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAKoR8mX0rGKLqzcWmOzbfj64K8ZIgOdH
nzkXSOVOZbFu/TJhZ7rFAN+eaGkl3C4buccQd/EjEsj9ir7ijT7h96MCAwEAAQ==`,kt=`MIIBVAIBADANBgkqhkiG9w0BAQEFAASCAT4wggE6AgEAAkEAqhHyZfSsYourNxaY
7Nt+PrgrxkiA50efORdI5U5lsW79MmFnusUA355oaSXcLhu5xxB38SMSyP2KvuKN
PuH3owIDAQABAkAfoiLyL+Z4lf4Myxk6xUDgLaWGximj20CUf+5BKKnlrK+Ed8gA
kM0HqoTt2UZwA5E2MzS4EI2gjfQhz5X28uqxAiEA3wNFxfrCZlSZHb0gn2zDpWow
cSxQAgiCstxGUoOqlW8CIQDDOerGKH5OmCJ4Z21v+F25WaHYPxCFMvwxpcw99Ecv
DQIgIdhDTIqD2jfYjPTY8Jj3EDGPbH2HHuffvflECt3Ek60CIQCFRlCkHpi7hthh
YhovyloRYsM+IS9h/0BzlEAuO0ktMQIgSPT3aFAgJYwKpqRYKlLDVcflZFCKY7u3
UP8iWi1Qw0Y=`;function _t(tt){const Q=new Vt;return Q.setPublicKey(Ut),Q.encrypt(tt)}function Zt(tt){const Q=new Vt;return Q.setPrivateKey(kt),Q.decrypt(tt)}export{Zt as d,_t as e};